Skip to main content
PATCH
/
v1
/
qa-rules
/
{qaRuleId}
Update QA Rule
curl --request PATCH \
  --url https://api.sigmamind.ai/v1/qa-rules/{qaRuleId} \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "ruleName": "Tone & Professionalism Check",
  "ruleDescription": "Ensures agents maintain a professional and empathetic tone throughout the conversation.",
  "evaluationCriteria": "Evaluate whether agent greeted the customer by name, avoided interrupting, and closed with a resolution summary.",
  "expectedValue": true,
  "agentIds": [
    "D5D0p7TUs66TTAEAx"
  ]
}
'
{
  "qaRuleId": "rule_YYdKgw1masomMfe8",
  "workspaceId": "org_V6eZ2zg8ziDx5pft",
  "ruleName": "Tone & Professionalism Check",
  "ruleDescription": "Ensures agents maintain a professional and empathetic tone throughout the conversation.",
  "agents": [
    {
      "name": "New AI Agent",
      "agentId": "agent_D5D0p7TUs66TTAEAx",
      "status": "Live"
    }
  ],
  "evaluationCriteria": "Evaluate whether agent greeted the customer by name, avoided interrupting, and closed with a resolution summary.",
  "expectedValue": true
}

Documentation Index

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

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

Authorizations

X-API-Key
string
header
required

Authenticate every request by passing your API key in the X-API-Key header. To get your key, go to Dashboard → API Keys and create or copy your Production API key.

Path Parameters

qaRuleId
string
required

The unique identifier of the QA rule to update.

Body

application/json
ruleName
string

The name of the QA rule, used to identify it in rule lists and evaluation reports.

Example:

"Tone & Professionalism Check"

ruleDescription
string

A brief explanation of what this QA rule evaluates and its intended purpose.

Example:

"Ensures agents maintain a professional and empathetic tone throughout the conversation."

evaluationCriteria
string

The specific criteria used to evaluate agent responses against this rule.

Example:

"Evaluate whether agent greeted the customer by name, avoided interrupting, and closed with a resolution summary."

expectedValue
enum<boolean>

The expected outcome of the evaluation criteria that determines a successful QA result. Set to true if the evaluation criteria returning true should be treated as a Success, or false if the evaluation criteria returning true should be treated as a Fail.

Available options:
true,
false
Example:

true

agentIds
string[]

List of agent Ids on which QA rule would apply

Example:
["D5D0p7TUs66TTAEAx"]

Response

OK

qaRuleId
string

The unique identifier of the QA rule.

Example:

"rule_YYdKgw1masomMfe8"

workspaceId
string

The unique identifier of the workspace this QA rule belongs to.

Example:

"org_V6eZ2zg8ziDx5pft"

ruleName
string

The name of the QA rule, used to identify it in rule lists and evaluation reports.

Example:

"Tone & Professionalism Check"

ruleDescription
string

A brief explanation of what this QA rule evaluates and its intended purpose.

Example:

"Ensures agents maintain a professional and empathetic tone throughout the conversation."

agents
object[]
evaluationCriteria
string

The specific criteria or rubric used to evaluate agent responses against this rule.

Example:

"Evaluate whether agent greeted the customer by name, avoided interrupting, and closed with a resolution summary."

expectedValue
boolean

The expected evaluation result that determines whether the QA rule is satisfied. When the evaluation criteria returns a result matching this expected value, the interaction is marked as a Success; otherwise it is marked as a Fail.

Example:

true