POST
/
sdk
/
v1
/
evaluation-assertions
curl --request POST \
  --url https://api.promptfoundry.ai/sdk/v1/evaluation-assertions \
  --header 'Content-Type: application/json'
{
  "id": "<string>",
  "evaluationId": "<string>",
  "targetValue": "<string>",
  "type": "CONTAINS",
  "jsonPath": "<string>",
  "toolName": "<string>"
}

Body

application/json
evaluationId
string
required
targetValue
string | null
required
type
enum<string>
required

The type of evaluation matcher to use.

Available options:
CONTAINS,
EXACT_MATCH,
JSON_CONTAINS,
JSON_EXACT_MATCH,
TOOL_CALLED,
TOOL_CALLED_WITH
jsonPath
string | null
required

A JSON path to use when matching the response. Only required when type is JSON_EXACT_MATCH or JSON_CONTAINS.

toolName
string | null
required

The name of the tool to match. Only required when type is TOOL_CALLED or TOOL_CALLED_WITH.

Response

201 - application/json
id
string
required
evaluationId
string
required
targetValue
string | null
required
type
enum<string>
required

The type of evaluation matcher to use.

Available options:
CONTAINS,
EXACT_MATCH,
JSON_CONTAINS,
JSON_EXACT_MATCH,
TOOL_CALLED,
TOOL_CALLED_WITH
jsonPath
string | null
required

A JSON path to use when matching the response. Only required when type is JSON_EXACT_MATCH or JSON_CONTAINS.

toolName
string | null
required

The name of the tool to match. Only required when type is TOOL_CALLED or TOOL_CALLED_WITH.