Skip to main content
PATCH
/
api
/
v1
/
prompts
/
{prompt_id}
Update Prompt
curl --request PATCH \
  --url https://api.athenahq.ai/api/v1/prompts/{prompt_id} \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "website_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "prompt": "<string>",
  "volume": "<string>",
  "topic_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "countries": [
    "<string>"
  ],
  "primary_country": "<string>",
  "location_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ]
}
'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "text": "<string>",
  "type": "<string>",
  "volume": "<string>",
  "topic_id": "<string>",
  "locations": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "name": "<string>"
    }
  ],
  "countries": [
    "<string>"
  ],
  "before": {
    "text": "<string>",
    "type": "<string>",
    "volume": "<string>",
    "topic_id": "<string>",
    "countries": [
      "<string>"
    ],
    "location_ids": [
      "<string>"
    ]
  }
}

Authorizations

x-api-key
string
header
required

API key for authentication. You can create one here.

Path Parameters

prompt_id
string<uuid>
required

The prompt to update.

Body

application/json
website_id
string<uuid>
required

Website that owns the prompt.

prompt
string

New prompt text. Trimmed; blank is rejected. Editable only while the prompt has no responses yet — changing it after responses have streamed returns 400. Re-sending the current text unchanged (e.g. in a full-object PATCH) is always allowed, as are metadata-only edits.

type
enum<string> | null
Available options:
discovery,
high_intent
volume
string | null
topic_id
string<uuid> | null
countries
string[]
Maximum array length: 1000
primary_country
string | null

When countries is non-empty it must be one of them.

location_ids
string<uuid>[]
Maximum array length: 1000

Response

Prompt updated

id
string<uuid>
text
string
type
string | null
volume
string | null
topic_id
string | null
locations
object[]
countries
string[]
before
object

Pre-update snapshot.