Replace a secret set
Updated
Replaces all the keys in a secret set in one change.
Preview documentation
https://preview.ai.agora.io/conversational-ai/v1/projects/{appid}/secrets/{name}After the request, the set contains only the keys you pass. Keys you omit are removed. Agents keep referencing the set by name, so you don't need to change them.
appidstringThe App ID of your project.
namestringThe name of the secret set.
If-MatchstringThe ETag value from the most recent response for this resource. If the resource has changed since then, the request fails with 412 and reason PreconditionFailed. Retrieve the resource, apply your change again, and retry with the new ETag.
secretsobjectThe secrets, as key-value pairs. Each key is 1 to 64 characters from A-Z, a-z, 0-9, and _, and must be unique within the set. Values are write-only and are never returned. A set can hold at most 64 KiB, measured as the UTF-8 size of its keys and values encoded as a JSON object. A larger set is rejected with 400.
[key: string]stringResponse Body
The secret set was replaced. The response body lists its keys.
Response Headers
namestringThe name of the secret set.
keysarray<string>The names of the keys in the set. Values are never returned.
create_tsintegerThe time the set was created, as a Unix timestamp in seconds.
update_tsintegerThe time the set was last updated, as a Unix timestamp in seconds.
Request examples
curl -X PUT 'https://preview.ai.agora.io/conversational-ai/v1/projects/string/secrets/string' \ -H 'If-Match: string' \ -H 'Content-Type: application/json' \ -d '{ "secrets": { "asr": "<your_asr_api_key>", "llm": "<your_llm_api_key>" }}'Response example
{ "name": "string", "keys": [ "string" ], "create_ts": 0, "update_ts": 0}