Skip to main content
POST
/
api
/
v1
/
secrets
Create Secret
curl --request POST \
  --url https://api.primeintellect.ai/api/v1/secrets/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "value": "<string>",
  "description": "<string>",
  "teamId": "<string>",
  "isFile": false
}
'
{
  "data": {
    "id": "<string>",
    "name": "<string>",
    "createdAt": "2023-11-07T05:31:56Z",
    "updatedAt": "2023-11-07T05:31:56Z",
    "description": "<string>",
    "isFile": false,
    "userId": "<string>",
    "teamId": "<string>"
  },
  "status": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
name
string
required

Name of the secret (must start with uppercase, only uppercase, numbers, underscores)

Required string length: 1 - 255
value
string
required

The secret value to store (will be encrypted)

Minimum string length: 1
description
string | null

Optional description of the secret

Maximum string length: 500
teamId
string | null

Optional team ID for team-level secrets

isFile
boolean
default:false

Whether this secret represents a file (max 64KB base64 encoded)

Response

Successful Response

data
SecretResponse · object

Response data

status
string | null

Response status