prompts

Update an existing prompt

put/api/v1/prompts/

Request

  • Base URL
    https://api.syllable.cloud
  • URL
    https://api.syllable.cloud/api/v1/prompts/
  • Auth
    API key in header Syllable-API-Key

Request body

namestring required

The prompt name

descriptionstring nullable

The description of the prompt

labelsstring[] nullable

The prompt labels. Omit this field to keep the existing labels; send an empty list or null to remove them.

typestring required

The type of the prompt

contextstring nullable

The prompt text that will be sent to the LLM at the beginning of the conversation

toolsstring[]

Names of tools to which the prompt has access

session_end_enabledboolean

Whether session end functionality is enabled for this prompt

session_end_tool_idinteger nullable

ID of the optional session end tool associated with the prompt

edit_commentsstring nullable

The comments for the most recent edit to the prompt

idinteger required

The internal ID of the prompt

include_default_toolsboolean

Whether to include the default tools (hangup) in the list of tools for the prompt (also includes set_current_language if any of the agents assigned to the prompt have Dynamic Language Switching enabled). If you remove one of the default tools from your prompt, you might want to disable this option so that the tool is not added again when updated.

Example request

{
  "name": "Weather Agent Prompt",
  "description": "Prompt for a weather agent.",
  "labels": [
    "Outbound",
    "Hospital"
  ],
  "type": "prompt_v1",
  "context": "You are a weather agent. Answer the user's questions about weather and nothing else.",
  "tools": [],
  "llm_config": {
    "model": "gpt-4o",
    "version": "2024-05-13",
    "api_version": "2024-06-01",
    "temperature": 1,
    "seed": 123
  },
  "session_end_tool_id": 1,
  "edit_comments": "Updated prompt text to include requirement to not answer questions that aren't about weather.",
  "id": 1,
  "include_default_tools": true
}

Response

Successful Response

namestring required

The prompt name

descriptionstring nullable

The description of the prompt

labelsstring[] nullable

The prompt labels

typestring required

The type of the prompt

contextstring nullable

The prompt text that will be sent to the LLM at the beginning of the conversation

toolsstring[]

Names of the tools to which the prompt has access (DEPRECATED - use information from full tools field instead)

session_end_enabledboolean

Whether session end functionality is enabled for this prompt

session_end_tool_idinteger nullable

ID of the optional session end tool associated with the prompt

edit_commentsstring nullable

The comments for the most recent edit to the prompt

idinteger required

The internal ID of the prompt

last_updatedstring nullable required

The last updated date of the prompt

last_updated_bystring nullable

Email address of the user who most recently updated the prompt

agent_countinteger nullable

The number of agents using the prompt

version_numberinteger nullable

The version number of the current version of the prompt

Changes

    • breaking

      the response's body type changed from object to no type for status

    • warning

      removed the optional property from the response with the status

    • info

      added the new optional request property /

    • info

      added to the response body anyOf list for the response status

    • info

      added the optional property / to the response with the status

    • info

      added the new optional request property

    • info

      added the optional property to the response with the status