Skip to main content
GET
/
api
/
public
/
v2
/
evaluations
/
{evaluation_id}
/
rows
Get Evaluation Rows
curl --request GET \
  --url https://api.promptlayer.com/api/public/v2/evaluations/{evaluation_id}/rows \
  --header 'X-API-KEY: <x-api-key>'
{
  "success": true,
  "message": "<string>",
  "columns": [
    "<string>"
  ],
  "rows": [
    [
      {
        "type": "dataset",
        "value": "<unknown>",
        "status": "PASSED",
        "error_message": "<string>"
      }
    ]
  ],
  "page": 123,
  "per_page": 123,
  "total": 123,
  "pages": 123
}
Retrieve paginated evaluation results with dataset input variables and evaluation cell outcomes. Each row is an array of cells matching the order of the columns array. Dataset input columns appear first, followed by evaluation result columns.

Authentication

This endpoint requires API key authentication.

Cell Formats

There are two types of cells in the response: Dataset cells contain the input data:
{
  "type": "dataset",
  "value": "input value"
}
Evaluation cells contain the evaluation results:
{
  "type": "eval",
  "status": "PASSED",
  "value": "result value"
}
Failed evaluation cells may also include an error_message field:
{
  "type": "eval",
  "status": "FAILED",
  "value": null,
  "error_message": "Error details"
}

Example Response

{
  "success": true,
  "message": "success",
  "columns": ["input", "expected_output", "accuracy", "relevance"],
  "rows": [
    [
      {"type": "dataset", "value": "What is PromptLayer?"},
      {"type": "dataset", "value": "A prompt management platform"},
      {"type": "eval", "status": "PASSED", "value": 0.95},
      {"type": "eval", "status": "PASSED", "value": 0.88}
    ]
  ],
  "page": 1,
  "per_page": 10,
  "pages": 3,
  "total": 25
}

Headers

X-API-KEY
string
required

Your PromptLayer API key.

Path Parameters

evaluation_id
integer
required

The ID of the evaluation to retrieve rows from

Query Parameters

workspace_id
integer

Filter by specific workspace ID. Defaults to current user's workspace.

Required range: x >= 1
page
integer
default:1

Page number for pagination

Required range: x >= 1
per_page
integer
default:10

Number of rows per page (max 100)

Required range: 1 <= x <= 100

Response

Successful response

success
boolean
required
message
string
required
columns
string[]
required

Ordered list of column names. Dataset columns appear first, followed by evaluation columns.

rows
object[][]
required

Array of rows, each row is an array of cells

page
integer
required
per_page
integer
required
total
integer
required
pages
integer
required