Logo
Search
Docs

Fields & validation

Every field with its exact validation rule, nullability, and the database column that stores it.

Agent

FieldInTypeRequiredNullableRules (verbatim)DB column
namebodystringcreate: yes · update: when presentnocreate required|string|max:255 · update sometimes|required|string|max:255ai_projects.name
descriptionbodystringnoyessometimes|nullable|string|max:5000ai_projects.description
instructionsbodystringnoyessometimes|nullable|string|max:10000ai_projects.instructions
memorystringRead-only. Returned on the agent resource; a memory key in an update request is ignored.ai_project_memories (managed by the platform)

Constraints:

  • Sending null (or omitting on create) clears/leaves empty description and instructions; name can never be null or empty.
  • DELETE requires ownership; a write-shared collaborator can edit but not delete.

Chat

FieldInTypeRequiredNullableRules (verbatim)DB column
modelbody (create)stringnoyessometimes|nullable|string|max:255ai_chats.model
titlebody (rename)stringyesnorequired|string|max:255ai_chats.title (default New chat)

Constraints: every chat operation (read, rename, delete, send) is limited to the token that created the chat — not even the agent owner can read another user’s thread through this API.

Message

FieldInTypeRequiredNullableRules (verbatim)DB column
contentbodystringyesnorequired|string|max:20000ai_chat_messages.content
modelbodystringnoyessometimes|nullable|string|max:255ai_chat_messages.model

Response fields: role is user or assistant (enum in the database); usage (prompt_tokens, completion_tokens, total_tokens) appears only on a freshly generated assistant reply.

Chat-completions request

FieldTypeRequiredNullableRules (verbatim)
modelstringnoyessometimes|nullable|string|max:255
messagesarrayyesnorequired|array|min:1 — must include at least one user turn
messages.*.rolestringyesnorequired|string|in:system,user,assistant
messages.*.contentstringyesnorequired|string|max:20000
agentstringnoyessometimes|nullable|string|max:64
chatstringnoyessometimes|nullable|string|max:64
streambooleannonosometimes|boolean — must be false; true returns 400

Knowledge file

FieldInTypeRequiredRules (verbatim)DB column
filemultipartfileyesrequired|file|max:20480 (20 MB) + extension allow-listai_project_files.path / original_name / mime / size

Allowed extensions: txt, md, markdown, csv, json, log, text, pdf, doc, docx, rtf. Text extraction and indexing run only for txt, md, markdown, csv, json, log, text, capped at 200,000 characters; the other types are stored for reference.

Connector toggles

FieldInTypeRequiredRules (verbatim)DB column
enabled (connector)bodybooleanyesrequired|booleanai_project_mcp_connectors.is_enabled
toolbodystringyesrequired|string|max:255ai_project_mcp_connectors.disabled_tools (JSON list of switched-off tool names)
enabled (tool)bodybooleanyesrequired|booleanai_project_mcp_connectors.disabled_tools

Constraint: a tool that is switched off is never offered to the model during a conversation.