Skip to main content
PATCH
/
v1
/
system-prompts
/
{system_prompt_id}
/
particles
/
{particle_id}
Update Particle in System Prompt
curl --request PATCH \
  --url https://api.cuadra.ai/v1/system-prompts/{system_prompt_id}/particles/{particle_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "particleVersionId": "pv_abc123",
  "order": 1
}
'
{
  "id": "<string>",
  "particleId": "<string>",
  "order": 123,
  "particleName": "Professional Tone",
  "particleCategory": "tone",
  "particleVersionId": "pv_abc123",
  "pinnedVersion": 2,
  "tokenCount": 25
}

Authorizations

Authorization
string
header
required

JWT token from Stytch B2B authentication (magic link, SSO, or M2M)

Headers

Idempotency-Key
string | null

Path Parameters

system_prompt_id
string
required

System Prompt ID

particle_id
string
required

Particle ID

Body

application/json

Request schema for updating a particle association.

particleVersionId
string | null

Version ID to pin (NULL = use current)

Example:

"pv_abc123"

order
integer | null

Updated order in the composition

Required range: x >= 0
Example:

1

Response

Successful Response

Response schema for a particle within a system prompt.

id
string
required

Association ID

Example:

"spa_abc123"

particleId
string
required

Particle ID

Example:

"part_xyz789"

order
integer
required

Order in composition

Example:

0

particleName
string | null

Particle name (derived)

Example:

"Professional Tone"

particleCategory
enum<string> | null

Particle category (derived)

Available options:
role,
tone,
guardrails,
constraints,
format
Example:

"tone"

particleVersionId
string | null

Pinned version ID (NULL = current)

Example:

"pv_abc123"

pinnedVersion
integer | null

Pinned version number (derived)

Example:

2

tokenCount
integer | null

Token count of the particle content

Example:

25