ChatKomodo Docs Home Sign in

API reference · Account

Business profile

Get the business profile

GET/v1/profile

The business profile of the calling tenant: where the business operates, its timezone, language, industry and billing currency.

Responses

  • 200Profile
    Response fields
    • business_namestring | nullrequired
    • countrystringrequired
      ISO 3166-1 alpha-2 code, e.g. GB
      Exactly 2 characters
    • timezonestringrequired
      IANA timezone, e.g. Europe/London. Drives business hours, the send window and the dates shown in the dashboard
    • localestringrequired
      Language of the messages the platform sends on the business's behalf (OTP, opt-out confirmations, notices)
      One of: en, id
    • industrystring | nullrequired
      Selects the onboarding starter pack
      One of: ecommerce, retail, restaurant, healthcare, beauty, fitness, education, real_estate, automotive, travel, hospitality, logistics, finance, insurance, saas, professional_services, events, nonprofit, government, other
    • currencystringrequired
      Billing currency (see /v1/billing/options for what can actually be charged)
      One of: IDR, USD
    • configuredbooleanrequired
      true once the owner saved the profile at least once
    • calling_codestringrequired
      Digits, e.g. 44. Local-format numbers (07700 900123) are resolved with this code
    • suggested_timezonesarray of string
      Timezones of the country, for pickers
    • industriesarray of string
    • localesarray of string
Request
curl "https://api.chatkomodo.com/v1/profile" \
  -H "Authorization: Bearer $CHATKOMODO_API_KEY"
const res = await fetch('https://api.chatkomodo.com/v1/profile', {
  method: 'GET',
  headers: {
    Authorization: `Bearer ${process.env.CHATKOMODO_API_KEY}`,
  },
});
const data = await res.json();
if (!res.ok) throw new Error(`${data.code}: ${data.error}`);
console.log(data);
import os
import requests

res = requests.get(
    "https://api.chatkomodo.com/v1/profile",
    headers={
        "Authorization": f"Bearer {os.environ['CHATKOMODO_API_KEY']}",
    },
    timeout=30,
)
res.raise_for_status()
print(res.json())
<?php
require 'vendor/autoload.php';

$client = new GuzzleHttp\Client();
$res = $client->request('GET', 'https://api.chatkomodo.com/v1/profile', [
    'headers' => [
        'Authorization' => 'Bearer ' . getenv('CHATKOMODO_API_KEY'),
    ],
]);

print_r(json_decode((string) $res->getBody(), true));
Response 200
{
  "business_name": "string",
  "country": "GB",
  "timezone": "Asia/Jakarta",
  "locale": "en",
  "industry": "ecommerce",
  "currency": "IDR",
  "configured": true,
  "calling_code": "482913",
  "suggested_timezones": [
    "Asia/Jakarta"
  ],
  "industries": [
    "string"
  ],
  "locales": [
    "en"
  ]
}

Update the business profile

PUT/v1/profile

Update the business profile (partial update). Account owner only.

Request body

  • business_namestring | null
    Up to 100 characters
  • countrystring
    Changing the country also resets timezone and currency unless you send them too
    Exactly 2 characters
  • timezonestring
  • localestring
    One of: en, id
  • industrystring | null
    One of: ecommerce, retail, restaurant, healthcare, beauty, fitness, education, real_estate, automotive, travel, hospitality, logistics, finance, insurance, saas, professional_services, events, nonprofit, government, other
  • currencystring
    One of: IDR, USD

Responses

  • 200Updated profile
    Response fields
    • business_namestring | nullrequired
    • countrystringrequired
      ISO 3166-1 alpha-2 code, e.g. GB
      Exactly 2 characters
    • timezonestringrequired
      IANA timezone, e.g. Europe/London. Drives business hours, the send window and the dates shown in the dashboard
    • localestringrequired
      Language of the messages the platform sends on the business's behalf (OTP, opt-out confirmations, notices)
      One of: en, id
    • industrystring | nullrequired
      Selects the onboarding starter pack
      One of: ecommerce, retail, restaurant, healthcare, beauty, fitness, education, real_estate, automotive, travel, hospitality, logistics, finance, insurance, saas, professional_services, events, nonprofit, government, other
    • currencystringrequired
      Billing currency (see /v1/billing/options for what can actually be charged)
      One of: IDR, USD
    • configuredbooleanrequired
      true once the owner saved the profile at least once
    • calling_codestringrequired
      Digits, e.g. 44. Local-format numbers (07700 900123) are resolved with this code
    • suggested_timezonesarray of string
      Timezones of the country, for pickers
    • industriesarray of string
    • localesarray of string
  • 400Validation error (VALIDATION_FAILED)
  • 403Not the account owner (FORBIDDEN)
Request
curl -X PUT "https://api.chatkomodo.com/v1/profile" \
  -H "Authorization: Bearer $CHATKOMODO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "business_name": "Acme Retail",
  "country": "GB",
  "timezone": "Europe/London",
  "locale": "en",
  "currency": "USD"
}'
const res = await fetch('https://api.chatkomodo.com/v1/profile', {
  method: 'PUT',
  headers: {
    Authorization: `Bearer ${process.env.CHATKOMODO_API_KEY}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    "business_name": "Acme Retail",
    "country": "GB",
    "timezone": "Europe/London",
    "locale": "en",
    "currency": "USD"
  }),
});
const data = await res.json();
if (!res.ok) throw new Error(`${data.code}: ${data.error}`);
console.log(data);
import os
import requests

res = requests.put(
    "https://api.chatkomodo.com/v1/profile",
    headers={
        "Authorization": f"Bearer {os.environ['CHATKOMODO_API_KEY']}",
    },
    json={
        "business_name": "Acme Retail",
        "country": "GB",
        "timezone": "Europe/London",
        "locale": "en",
        "currency": "USD",
    },
    timeout=30,
)
res.raise_for_status()
print(res.json())
<?php
require 'vendor/autoload.php';

$client = new GuzzleHttp\Client();
$res = $client->request('PUT', 'https://api.chatkomodo.com/v1/profile', [
    'headers' => [
        'Authorization' => 'Bearer ' . getenv('CHATKOMODO_API_KEY'),
    ],
    'json' => [
        'business_name' => 'Acme Retail',
        'country' => 'GB',
        'timezone' => 'Europe/London',
        'locale' => 'en',
        'currency' => 'USD',
    ],
]);

print_r(json_decode((string) $res->getBody(), true));
Response 200
{
  "business_name": "string",
  "country": "GB",
  "timezone": "Asia/Jakarta",
  "locale": "en",
  "industry": "ecommerce",
  "currency": "IDR",
  "configured": true,
  "calling_code": "482913",
  "suggested_timezones": [
    "Asia/Jakarta"
  ],
  "industries": [
    "string"
  ],
  "locales": [
    "en"
  ]
}

List countries

GET/public/countriesNo authentication

Public, cacheable list of countries with their calling code and default timezone, for country pickers (login, signup, profile). No authentication.

Query parameters

  • langstring
    Language of the names/summaries (default en)
    One of: en, id

Responses

  • 200Countries sorted by name
    Response fields
    • countriesarray of objectrequired
    • countries[].isostringrequired
    • countries[].namestringrequired
    • countries[].calling_codestringrequired
    • countries[].timezonestringrequired
Request
curl "https://api.chatkomodo.com/public/countries"
const res = await fetch('https://api.chatkomodo.com/public/countries', {
  method: 'GET',
});
const data = await res.json();
if (!res.ok) throw new Error(`${data.code}: ${data.error}`);
console.log(data);
import os
import requests

res = requests.get(
    "https://api.chatkomodo.com/public/countries",
    timeout=30,
)
res.raise_for_status()
print(res.json())
<?php
require 'vendor/autoload.php';

$client = new GuzzleHttp\Client();
$res = $client->request('GET', 'https://api.chatkomodo.com/public/countries', [
]);

print_r(json_decode((string) $res->getBody(), true));
Response 200
{
  "countries": [
    {
      "iso": "string",
      "name": "Example",
      "calling_code": "482913",
      "timezone": "Asia/Jakarta"
    }
  ]
}

List industries

GET/public/industriesNo authentication

Public list of industries that have an onboarding starter pack. No authentication.

Query parameters

  • langstring
    Language of the names/summaries (default en)
    One of: en, id

Responses

  • 200Industries
    Response fields
    • industriesarray of objectrequired
    • industries[].idstringrequired
    • industries[].namestringrequired
    • industries[].summarystringrequired
Request
curl "https://api.chatkomodo.com/public/industries"
const res = await fetch('https://api.chatkomodo.com/public/industries', {
  method: 'GET',
});
const data = await res.json();
if (!res.ok) throw new Error(`${data.code}: ${data.error}`);
console.log(data);
import os
import requests

res = requests.get(
    "https://api.chatkomodo.com/public/industries",
    timeout=30,
)
res.raise_for_status()
print(res.json())
<?php
require 'vendor/autoload.php';

$client = new GuzzleHttp\Client();
$res = $client->request('GET', 'https://api.chatkomodo.com/public/industries', [
]);

print_r(json_decode((string) $res->getBody(), true));
Response 200
{
  "industries": [
    {
      "id": "01JA5V6Q8M2H7G4K9P3T0R1S2X",
      "name": "Example",
      "summary": "string"
    }
  ]
}