AI Quality Check
Create an AI quality test case
POST /aiQualityCheck/testCase
POST /aiQualityCheck/testCase
Create a new test case (an AI-agent-bound ticket whose expected result is locked in) so it can be replayed by future test runs. The body specifies the ticket id, target AI agent and the expected result.
Request body
ticketIdintegerbodyTicket to use as the test case.
aiAgentIdintegerbodyAI agent the test case is bound to.
expectedResultobjectbodyThe updated expected result for the test ticket. You can either specify all test conditions, or only some. In this case only the provided test conditions will be provided
Request Example
{
"ticketId": 1,
"aiAgentId": 1,
"expectedResult": {
"contractId": "123456",
"inputParameters": {
"change_meter_reading": {
"_action": null,
"requestedDeposit": 35
}
},
"intentDetection": [
"change_meter_reading",
"change_payment_method"
],
"outcomeActions": {
"change_meter_reading": [
"Update ERP System",
"Inform Customer change is not possible"
]
},
"outcomeNotifications": {
"change_meter_reading": [
"Meter reading is plausible"
]
},
"outcomeText": {
"change_meter_reading": null
},
"outcomeType": {
"change_meter_reading": "interaction"
},
"sentiment": "disappointed",
"tags": [
"sales",
"marketing"
],
"aiSupportLevel": "human",
"sources": {
"change_meter_reading": [
{
"type": "ticket",
"id": "123",
"summary": "Similar case"
},
{
"type": "faq",
"id": "456",
"title": "How to change meter reading"
}
]
},
"error": null
}
}Responses
200 — Created
Response Example
{
"success": true,
"testCase": {
"id": 1,
"ticketId": 1,
"aiAgentIds": [
1,
2,
3
],
"channel": "string",
"summary": "string",
"description": "string",
"expectedResult": null,
"modifiedBy": 1
}
}