Skip to main content
PATCH
/
v1
/
evals
/
agents
/
{eval_agent_id}
Update Eval Agent
curl --request PATCH \
  --url https://api.bland.ai/v1/evals/agents/{eval_agent_id} \
  --header 'Content-Type: application/json' \
  --header 'authorization: <authorization>' \
  --data '
{
  "name": "<string>",
  "description": {},
  "active_version_id": {},
  "metadata": {}
}
'
{
  "errors": null,
  "data": {
    "agent": {
      "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "org_id": "f0e1d2c3-b4a5-9678-fedc-ba9876543210",
      "key": "empathy-check",
      "name": "Empathy Check (Updated)",
      "description": "Grades how empathetic the agent sounds during difficult conversations.",
      "current_version_id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
      "active_version_id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
      "metadata": {
        "team": "cx-quality"
      },
      "created_at": "2026-03-01T09:00:00.000Z",
      "updated_at": "2026-05-27T11:00:00.000Z",
      "deleted_at": null
    },
    "current_version": {
      "id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
      "org_id": "f0e1d2c3-b4a5-9678-fedc-ba9876543210",
      "eval_agent_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "version_number": 3,
      "name": "Empathy Check v3",
      "description": "Refined grading criteria based on feedback.",
      "state": "editable",
      "modality": "audio",
      "system_prompt_md": "You are an expert call quality reviewer.",
      "prompt_md": "Did the agent express empathy when the caller described their problem?",
      "levels": [
        {
          "level_key": "excellent",
          "label": "Excellent",
          "prompt_md": "The agent clearly and warmly acknowledged the caller's feelings.",
          "color": "emerald"
        },
        {
          "level_key": "poor",
          "label": "Poor",
          "prompt_md": "The agent ignored or dismissed the caller's feelings.",
          "color": "rose"
        }
      ],
      "target_level_keys": ["excellent"],
      "weight": 10,
      "created_from_version_id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
      "created_by": "9a8b7c6d-5e4f-3210-9876-543210fedcba",
      "created_at": "2026-05-15T08:00:00.000Z",
      "updated_at": "2026-05-27T10:00:00.000Z"
    }
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.bland.ai/llms.txt

Use this file to discover all available pages before exploring further.

Headers

authorization
string
required
Your API key for authentication.

Path Parameters

eval_agent_id
string
required
The unique identifier of the eval agent to update.

Body Parameters

name
string
New display name for the eval agent. Between 1 and 200 characters.
description
string | null
Updated description, or null to clear it.
active_version_id
string | null
Repoint the published version to this version ID. Pass null to unpublish the agent.
metadata
object
Key-value metadata to associate with the eval agent. Values must be strings. Replaces the existing metadata object.
This endpoint updates agent-level fields only. To edit prompts, levels, or targets, update the agent’s draft version using the Update Eval Agent Version endpoint.

Response

data.agent
object
The updated eval agent.
data.agent.id
string
Unique identifier for the eval agent.
data.agent.org_id
string
ID of the organization that owns this eval agent.
data.agent.key
string
Unique slug key for the eval agent within the organization.
data.agent.name
string
Display name of the eval agent.
data.agent.description
string | null
Description of what the eval agent grades, or null.
data.agent.current_version_id
string
ID of the current editable draft version.
data.agent.active_version_id
string | null
ID of the published version, or null if unpublished.
data.agent.metadata
object
Updated key-value metadata. Values are strings.
data.agent.created_at
string
ISO 8601 timestamp for when the eval agent was created.
data.agent.updated_at
string
ISO 8601 timestamp for when the eval agent was last updated.
data.agent.deleted_at
string | null
ISO 8601 timestamp if the eval agent has been soft-deleted, otherwise null.
data.current_version
object
The current editable draft version of the eval agent.
data.current_version.id
string
Unique identifier for this version.
data.current_version.org_id
string
ID of the organization that owns this version.
data.current_version.eval_agent_id
string
ID of the parent eval agent.
data.current_version.version_number
integer
Sequential version number.
data.current_version.name
string
Name of this version.
data.current_version.description
string | null
Optional description of this version.
data.current_version.state
string
State of this version. One of editable or archived.
data.current_version.modality
string
One of text or audio.
data.current_version.system_prompt_md
string
The system prompt for the judge LLM, in Markdown.
data.current_version.prompt_md
string
The grading prompt for the judge LLM, in Markdown.
data.current_version.levels
array of objects
Verdict levels for graded mode. Empty array for pass/fail mode.
data.current_version.target_level_keys
array of strings
Which level keys count as a target match.
data.current_version.weight
number
Relative weight of this agent in aggregate scoring. Between 0 and 100.
data.current_version.created_from_version_id
string | null
ID of the version this was forked from, or null.
data.current_version.created_by
string | null
Identifier of the user who created this version, or null.
data.current_version.created_at
string
ISO 8601 timestamp for when this version was created.
data.current_version.updated_at
string
ISO 8601 timestamp for when this version was last updated.
{
  "errors": null,
  "data": {
    "agent": {
      "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "org_id": "f0e1d2c3-b4a5-9678-fedc-ba9876543210",
      "key": "empathy-check",
      "name": "Empathy Check (Updated)",
      "description": "Grades how empathetic the agent sounds during difficult conversations.",
      "current_version_id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
      "active_version_id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
      "metadata": {
        "team": "cx-quality"
      },
      "created_at": "2026-03-01T09:00:00.000Z",
      "updated_at": "2026-05-27T11:00:00.000Z",
      "deleted_at": null
    },
    "current_version": {
      "id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
      "org_id": "f0e1d2c3-b4a5-9678-fedc-ba9876543210",
      "eval_agent_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "version_number": 3,
      "name": "Empathy Check v3",
      "description": "Refined grading criteria based on feedback.",
      "state": "editable",
      "modality": "audio",
      "system_prompt_md": "You are an expert call quality reviewer.",
      "prompt_md": "Did the agent express empathy when the caller described their problem?",
      "levels": [
        {
          "level_key": "excellent",
          "label": "Excellent",
          "prompt_md": "The agent clearly and warmly acknowledged the caller's feelings.",
          "color": "emerald"
        },
        {
          "level_key": "poor",
          "label": "Poor",
          "prompt_md": "The agent ignored or dismissed the caller's feelings.",
          "color": "rose"
        }
      ],
      "target_level_keys": ["excellent"],
      "weight": 10,
      "created_from_version_id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
      "created_by": "9a8b7c6d-5e4f-3210-9876-543210fedcba",
      "created_at": "2026-05-15T08:00:00.000Z",
      "updated_at": "2026-05-27T10:00:00.000Z"
    }
  }
}