Renaming and deleting customer lists isn’t available through the API. Do it in the Dashboard.
Authentication
Send your API key in theX-API-KEY header on every request, to the base URL https://api-eg.olimi.ai. See API Authentication.
You only ever see the customer lists that belong to the company your API key is issued to.
Variants
A customer list can have extra columns beyond name and phone number, such as an order number, that the agent can mention during a call. These are called variants. Each one has:slug: the name the agent’s script uses. A script that says{{order_number}}needs a variant with the slugorder_number.name: the column’s display name, for exampleOrder number.
- Campaigns: a campaign is refused with
missing_variants_…if its agent’s script uses a variable that one of its customer lists has no variant for. See Campaigns. - Contacts: each contact stores its value for a variant under the variant’s
id. See Custom fields.
Customer list fields
Variant object
Errors
Always branch onstatusCode first. Most errors also carry a machine-readable errorCode:
Validation errors (
422) have a different body. message is a list of what went wrong, and there’s no errorCode:
message text is for humans and may change, so don’t match on it.