Skip to main content
PATCH
Update an ai message

Authorizations

x-api-key
string
header
required

Path Parameters

aiMessageId
string
required
Minimum string length: 1

Body

application/json
name
string
Minimum string length: 1
description
string | null
channel
enum<string>
Available options:
EMAIL,
LINKEDIN,
WHATSAPP,
LINKEDIN_INMAIL,
LINKEDIN_CONNECTION
toneId
string
Minimum string length: 1
model
string
Minimum string length: 1
outputLength
integer
Required range: 0 <= x <= 10
splitMessages
boolean
prompt
string

Plain prompt text. Placeholders: {fieldId} for contact/company/CRM/formula/notes fields (discover via the contact/company field-metadata endpoints), {aiResearch:<id-or-name>}, {aiSnippet:<id-or-name>}, {aiMessage:<id-or-name>} for AI entity references. Validation is strict: unknown or ambiguous tokens return 400 with the invalid tokens and a sample of valid ones. Escape literal braces by doubling them ({{ and }}).

folderId
number | null

Optional folder id. Must belong to this workspace and be an AI message folder — discover with list_ai_message_folders (GET /v1/ai-variables/folders/ai-messages) and create with create_ai_message_folder if missing. Contact/company AI variable folder ids are rejected with 400.

customPromptFieldValues
object[]

Response

AI message updated successfully

status
enum<string>
required
Available options:
success
message
string
required
data
object