Update a portal
curl --request PATCH \
--url https://app.yampi.ai/api/v1/accounts/{account_id}/portals/{id} \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '
{
"color": "#FFFFFF",
"custom_domain": "yampi.ai.help",
"header_text": "Handbook",
"homepage_link": "https://yampi.ai/",
"name": "Handbook",
"page_title": "Handbook",
"slug": "handbook",
"archived": false,
"config": {
"allowed_locales": [
"en",
"es"
],
"default_locale": "en"
}
}
'const options = {
method: 'PATCH',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
color: '#FFFFFF',
custom_domain: 'yampi.ai.help',
header_text: 'Handbook',
homepage_link: 'https://yampi.ai/',
name: 'Handbook',
page_title: 'Handbook',
slug: 'handbook',
archived: false,
config: {allowed_locales: ['en', 'es'], default_locale: 'en'}
})
};
fetch('https://app.yampi.ai/api/v1/accounts/{account_id}/portals/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.yampi.ai/api/v1/accounts/{account_id}/portals/{id}"
payload = {
"color": "#FFFFFF",
"custom_domain": "yampi.ai.help",
"header_text": "Handbook",
"homepage_link": "https://yampi.ai/",
"name": "Handbook",
"page_title": "Handbook",
"slug": "handbook",
"archived": False,
"config": {
"allowed_locales": ["en", "es"],
"default_locale": "en"
}
}
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"payload": {
"id": 123,
"archived": false,
"color": "#1F93FF",
"config": {
"allowed_locales": [
{
"code": "en",
"articles_count": 32,
"categories_count": 9
}
]
},
"custom_domain": "ayuda.yampi.ai",
"header_text": "Handbook",
"homepage_link": "https://yampi.ai",
"name": "Handbook",
"slug": "handbook",
"page_title": "Handbook",
"account_id": 123,
"inbox": {
"id": 123,
"name": "Yampi",
"website_url": "yampi.ai",
"channel_type": "Channel::WebWidget",
"avatar_url": "https://example.com/avatar.png",
"widget_color": "#1F93FF",
"website_token": "4cWzuf9i9jxN9tbnv8K9STKU",
"enable_auto_assignment": true,
"web_widget_script": "<script>...</script>",
"welcome_title": "Hi there ! 🙌🏼",
"welcome_tagline": "We make it simple to connect with us.",
"greeting_enabled": true,
"greeting_message": "Hey there 👋, Thank you for reaching out to us.",
"channel_id": 123,
"working_hours_enabled": true,
"enable_email_collect": true,
"csat_survey_enabled": true,
"timezone": "America/Los_Angeles",
"business_name": "Yampi",
"hmac_mandatory": true
},
"logo": {
"id": 123,
"portal_id": 123,
"file_type": "image/png",
"account_id": 123,
"file_url": "https://example.com/logo.png",
"blob_id": 123,
"filename": "square.png"
},
"meta": {
"all_articles_count": 32,
"categories_count": 9,
"default_locale": "en"
}
}
}{
"description": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>",
"code": "<string>"
}
]
}{
"description": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>",
"code": "<string>"
}
]
}Help Center
Update a portal
Update a portal to account
PATCH
/
api
/
v1
/
accounts
/
{account_id}
/
portals
/
{id}
Update a portal
curl --request PATCH \
--url https://app.yampi.ai/api/v1/accounts/{account_id}/portals/{id} \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '
{
"color": "#FFFFFF",
"custom_domain": "yampi.ai.help",
"header_text": "Handbook",
"homepage_link": "https://yampi.ai/",
"name": "Handbook",
"page_title": "Handbook",
"slug": "handbook",
"archived": false,
"config": {
"allowed_locales": [
"en",
"es"
],
"default_locale": "en"
}
}
'const options = {
method: 'PATCH',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
color: '#FFFFFF',
custom_domain: 'yampi.ai.help',
header_text: 'Handbook',
homepage_link: 'https://yampi.ai/',
name: 'Handbook',
page_title: 'Handbook',
slug: 'handbook',
archived: false,
config: {allowed_locales: ['en', 'es'], default_locale: 'en'}
})
};
fetch('https://app.yampi.ai/api/v1/accounts/{account_id}/portals/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.yampi.ai/api/v1/accounts/{account_id}/portals/{id}"
payload = {
"color": "#FFFFFF",
"custom_domain": "yampi.ai.help",
"header_text": "Handbook",
"homepage_link": "https://yampi.ai/",
"name": "Handbook",
"page_title": "Handbook",
"slug": "handbook",
"archived": False,
"config": {
"allowed_locales": ["en", "es"],
"default_locale": "en"
}
}
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"payload": {
"id": 123,
"archived": false,
"color": "#1F93FF",
"config": {
"allowed_locales": [
{
"code": "en",
"articles_count": 32,
"categories_count": 9
}
]
},
"custom_domain": "ayuda.yampi.ai",
"header_text": "Handbook",
"homepage_link": "https://yampi.ai",
"name": "Handbook",
"slug": "handbook",
"page_title": "Handbook",
"account_id": 123,
"inbox": {
"id": 123,
"name": "Yampi",
"website_url": "yampi.ai",
"channel_type": "Channel::WebWidget",
"avatar_url": "https://example.com/avatar.png",
"widget_color": "#1F93FF",
"website_token": "4cWzuf9i9jxN9tbnv8K9STKU",
"enable_auto_assignment": true,
"web_widget_script": "<script>...</script>",
"welcome_title": "Hi there ! 🙌🏼",
"welcome_tagline": "We make it simple to connect with us.",
"greeting_enabled": true,
"greeting_message": "Hey there 👋, Thank you for reaching out to us.",
"channel_id": 123,
"working_hours_enabled": true,
"enable_email_collect": true,
"csat_survey_enabled": true,
"timezone": "America/Los_Angeles",
"business_name": "Yampi",
"hmac_mandatory": true
},
"logo": {
"id": 123,
"portal_id": 123,
"file_type": "image/png",
"account_id": 123,
"file_url": "https://example.com/logo.png",
"blob_id": 123,
"filename": "square.png"
},
"meta": {
"all_articles_count": 32,
"categories_count": 9,
"default_locale": "en"
}
}
}{
"description": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>",
"code": "<string>"
}
]
}{
"description": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>",
"code": "<string>"
}
]
}Authorizations
Token de usuario. Envía el valor en el header api_access_token. Lo obtienes en el perfil (GET /api/v1/profile) o al regenerarlo.
Path Parameters
The numeric ID of the account
The slug identifier of the portal
Body
application/json
Header color for help-center in hex format
Example:
"#FFFFFF"
Custom domain to display help center.
Example:
"yampi.ai.help"
Help center header
Example:
"Handbook"
link to main dashboard
Example:
"https://yampi.ai/"
Name for the portal
Example:
"Handbook"
Page title for the portal
Example:
"Handbook"
Slug for the portal to display in link
Example:
"handbook"
Status to check if portal is live
Example:
false
Configuration about supporting locales
Example:
{
"allowed_locales": ["en", "es"],
"default_locale": "en"
}
Response
Success
Show child attributes
Show child attributes