Skip to main content
POST
/
api
/
v2
/
projects
/
{project_id}
/
datasets
/
id
/
{dataset_id}
/
test-cases
Upload Prompt Test Cases
curl --request POST \
  --url https://api.example.com/api/v2/projects/{project_id}/datasets/id/{dataset_id}/test-cases \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "examples": [
    {
      "inputs": {},
      "history": null,
      "output": null,
      "metadata": null,
      "media_inputs": null,
      "output_message": {
        "content": "<string>",
        "role": "user"
      }
    }
  ]
}
'
{
  "message": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

project_id
string
required
dataset_id
string
required

Body

application/json
examples
TestCaseUploadWithMedia · object[]
required

Response

201 - application/json

SimpleResponseWithMessage(message: str)

message
string
required