Skip to main content

Domain Authorizations

The domain authorizations model can be used by a customer to add 3rd-party credentials to their Cloudonix domain, so that applications in the domain can make use of 3rd-party services, such as Text-To-Speech (STT) services or Large Language Models (LLM).

API Reference

Base Path /customers/self/domains/{domain-id}/authorizations[/{usage}[/{provider}]]

The domain authorizations model is a document with two separation level - first by authorization usage, and secondly by service provider. This allows application to use different keys for different services from the same provider.

For each usage and provider, the domain authorizations document had a JSON object that contains the prvovided 3rd-party authorization credentials. For most services this will be a complex object that contains multiple fields - whose exact format is provider dependant and will be detailed below for each service provider. Some service providers use a simple "API key" authorization - in which case the credential will be an object with a single field named key, whose value is the authorization key.

Available "Usage" types

Currently 3rd-party domain authorization are used to enable the following usages:

  • byov : Text-To-Speech (BYOV) for CXML applications using the <Say> verb.
  • llm : Large Language Models for CXML applications using the <Converse> verb.

Supported Text-To-Speech Service Providers

Cloudonix BYOV integration currently supports the following Text-To-Speech services, for the byov usage:

  • aws : AWS Polly - format: an object with the fields: region, accessKeyId, and secretAccessKey.
  • gcp : Google Text-To-Speech - format: the Google Cloud Project service account JSON object.
  • azure : Azure Speech AI - format: an object with the fields: region and key.
  • elevenlabs : ElevenLabs - format: an object with the field key.

Supported Large Language Model Service Providers

Cloudonix LLM integration currently supports the following Large Language Model services, for the llm usage:

  • openai : OpenAI ChatGPT - format: an object with the fields: organization, project, key. The first two are optional but will be verified if provided.
  • anthropic : Anthropic Claude - format: an object with the field key.

List All Active Domain Authorizations

GET /customers/{customer}/domains/{domain}/authorizations

List all active and valid domain authorizations, for all usage and for all providers. Only "usage" and "provider" fields for existing credentials will be listed.

Example

$ curl 'https://api.cloudonix.io/domains/cloudonix-demo-customer.cloudonix.net/authorizations'
--header 'Authorization: Bearer XI•••••••••••••••'

{
"byov": {
"aws": { "region": "us-east-1", "accessKeyId": "AKI…", "secretAccessKey": "…"},
"gcp: { "type": "service_account", "project": … },
"azure": { "region": "eastus", "key": "" },
"elevenlabs": { "key": "" },
},
"llm": {
"openai": { "organization": "org-…", "project": "proj-…", "key": "sk-svacct-…" },
"anthropic": { "key": "…" }
}
}

Retrieve a 3rd-Party Domain Authorization By Usage and Providers

GET /customers/{customer}/domains/{domain}/authorizations/{usage}/{provider}

Report on just a single authorization credential for a specific usage and provider.

Example

$ curl 'https://api.cloudonix.io/domains/cloudonix-demo-customer.cloudonix.net/authorizations/byov/aws'
--header 'Authorization: Bearer XI•••••••••••••••'

{
"byov": {
"aws": { "region": "us-east-1", "accessKeyId": "AKI…", "secretAccessKey": "…"}
}
}

Add or Update a 3rd-Party Domain Authorization

PUT /customers/{customer}/domains/{domain}/authorizations/{usage}/{provider}

Set a 3rd-party domain authorization credential for the specified usage and provider. The request's body should be a JSON document of the correct format for the provider. The API will verify that the credentials are valid and working and will return a 200 OK response if the authorization credentials are valid, or a 403 Forbidden error otherwise.

Example

$ curl 'https://api.cloudonix.io/domains/cloudonix-demo-customer.cloudonix.net/authorizations/byov/aws'
--header 'Authorization: Bearer XI•••••••••••••••' -X PUT -H 'Content-Type: application/json'
--data '{"region": "us-east-1", "accessKeyId": "AKI…", "secretAccessKey": "…"}'

{
"byov": {
"aws": { "region": "us-east-1", "accessKeyId": "AKI…", "secretAccessKey": "…"}
}
}

Remove a 3rd-Party Domain Authorization

DELETE /customers/{customer}/domains/{domain}/authorizations/{usage}/{provider}

Delete a 3rd-party credential from the domain.