Secrets

Create a new secret

Changed on

Create a new secret to store sensitive configuration values

post/v1/deployments/secrets

Request

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

Request body

descriptionstring

Description is an optional human-readable description of the secret's purpose (max 500 characters)

namestring required

Name is the unique identifier for the secret. Can contain alphanumeric characters, underscores, hyphens, forward slashes, and periods (1-100 characters)

project_idstring

ProjectID is ignored - the project is automatically determined from your authentication

ttl_secondsinteger

TTLSeconds is how long the secret lives before it is deleted, between 86400 (1 day) and 1209600 (14 days)

valuestring required

Value is the sensitive data to store securely (e.g., API keys, passwords, tokens). Encrypted at rest.

Response

Secret created successfully

created_atstring

CreatedAt is the ISO8601 timestamp when this secret was created

created_bystring

CreatedBy is the identifier of who created this secret.

descriptionstring

Description is a human-readable description of the secret's purpose

expires_atstring date-time

ExpiresAt is the ISO8601 timestamp when this secret expires and is deleted. Changing the value extends it. Omitted for secrets that never expire

idstring

ID is the unique identifier for this secret

last_updated_bystring

LastUpdatedBy is the identifier of who last updated this secret.

namestring

Name is the name/key of the secret

object'secret'

The object type, which is always secret.

ttl_secondsinteger

TTLSeconds is the secret's lifetime in seconds. Omitted when no TTL is set

updated_atstring

UpdatedAt is the ISO8601 timestamp when this secret was last updated

Changes

    • info

      added the new optional request property

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      endpoint added