Secrets

Create a secret

Create a secret in this key's Cloud project. Agents use it without seeing it: a sandbox tool's commands get a placeholder and Dexto attaches the value to requests to its hosts, and an mcp tool's server gets it from Dexto's servers. Recorded in the organization audit log by name.

post/v1/secrets

Request

  • Base URL
    https://api.dexto.ai
  • URL
    https://api.dexto.ai/v1/secrets
  • Auth
    HTTP bearer

Request body

hostsstring[] required

1 to 10 exact public hostnames, such as api.stripe.com, that the value may be sent to over HTTPS. No IP addresses, ports, paths, localhost or wildcards.

namestring required

Unique in the project and fixed: uppercase letters, digits and underscores, starting with a letter. Sandbox commands see it as an environment variable.

valuestring required

The value, at most 16 KiB. It is stored encrypted and never returned.

Response

Created.

created_atstring date-time required
hintstring nullable required

The value's last four characters, when it has at least 20; otherwise null. Never the value.

hostsstring[] required
idstring uuid required
last_used_atstring date-time nullable required

When Dexto last attached the value to a request.

namestring required
object'secret' required
updated_atstring date-time required

Changes

No recorded changes to this operation across all 1 revision of this API.