customAgents

Restores a previous system prompt version.

Changed on

Restores a saved system prompt version as the agent's current prompt. The restore records a new history version and returns that version. Use the system prompt versions endpoint to find a version id. <Check title="Required Permissions" icon="key">The user must have manage access to the agent.</Check>

post/agents/{agentId}/systempromptversions/{systemPromptVersionId}/restore

Request

  • Base URL
    https://api.awork.com/api/v1
  • URL
    https://api.awork.com/api/v1/agents/{agentId}/systempromptversions/{systemPromptVersionId}/restore
  • Auth
    HTTP bearer

Path parameters

agentIdstring uuid required

The agent id.

systemPromptVersionIdstring uuid required

The prompt version id.

Response

OK

idstring uuid

The prompt version id.

agentIdstring uuid

The agent id.

versionNumberinteger

The version number, assigned in order of creation.

isCurrentboolean

Whether this is the agent's current system prompt.

systemPromptstring nullable

The system prompt.

createdOnstring date-time nullable

The creation time of the system prompt version.

createdBystring uuid nullable

The user who created the system prompt version.

Changes