Details on how to support ingestion and analytics for multiple sub-organizations from a single Context.ai account.
For embedded integrations, Context.ai supports ingesting and producing analytics that are scoped to to subtenants via a single integration. This means you can use the same API key to support generating analytics for multiple sub-accounts, with guaranteed isolation between your users.
To support multi-tenant ingestion, include a unique
tenant_idfield within each
upsertrequest. The tenant ID can be any string under 40 characters, but must remain fixed across the lifetime of the tenant. You are responsible for generating and storing the unique identifier for each sub-account.
"messages": [ ... ],
// This field should be set to a string that uniquely identifies the
// tenant associated with this ingestion request.
When using multi-tenant ingestion, analytics can also be consumed on a per-tenant basis. This means that all metrics and analysis will be specifically scoped each unique
To consume analytics for a sub-tenant, pass same tenant ID as a URL query parameter in all
A request to the below URL will fetch all conversations under the tenant with ID