Commit a prompt version
Changed onCommits the current draft as a read-only version. No new draft is created; create a version to keep editing.
Request
- Base URLhttps://api.respan.ai
- URLhttps://api.respan.ai/api/prompts/{prompt_id}/commits/
- Auth
- HTTP bearer
- or HTTP bearer
Path parameters
The unique prompt identifier.
Request body
Example request
{
"description": "Improved tone and added error handling"
}Response
Committed version created.
Example response
{
"id": "pv_abc123",
"prompt_version_id": "pv_abc123",
"version": 3,
"description": "Improved system prompt for better context handling",
"messages": [
{
"role": "system",
"content": "You are a helpful assistant. Context: {{context}}"
}
],
"model": "gpt-4o",
"readonly": true,
"is_deployed": false,
"edited_by": {
"id": 123,
"email": "user@example.com",
"first_name": "John",
"last_name": "Doe"
},
"created_at": "2026-02-27T10:00:00Z",
"updated_at": "2026-02-27T10:00:00Z"
}Changes
- breaking
the response property
became nullable for the status - info
api operation id
prompts_commitPromptVersionremoved and replaced withcommitPromptVersion - info
the endpoint scheme security
DashboardJwtwas added to the API - info
api tag
Promptsadded - info
api tag
promptsremoved
- breaking
- warning
removed the optional property
from the response with the status - warning
removed the optional property
from the response with the status - warning
removed the optional property
from the response with the status - info
added the non-success response with the status
- info
removed the non-success response with the status
- info
added the required property
to the response with the status - info
added the required property
to the response with the status
- warning