Skip to main content
POST
Add Request Log to Draft Dataset
Legacy Dataset, Evaluation, and Report endpoints are deprecated for new workflows. Use the Tables API for new dataset import, evaluation, scoring, recalculation, and reporting workflows.
Add a request log as a row in the draft dataset version for a dataset group. PromptLayer extracts request inputs, metadata, scores, tags, prompt data, and response data into dataset columns.

Behavior Notes

  • A draft dataset version must already exist for the dataset group.
  • The request log and dataset group must belong to the same workspace.
  • New columns are automatically added from the request log’s available data fields.
  • If no draft exists, the endpoint returns 404.

Authorizations

X-API-KEY
string
header
required

Body

application/json
dataset_group_id
integer
required

ID of the dataset group containing the draft.

Required range: x >= 1
request_log_id
integer
required

ID of the request log to add as a dataset row.

Required range: x >= 1

Response

Request log added to draft dataset.

success
enum<boolean>
required
Available options:
true
message
string
required
draft_dataset_id
integer
required

ID of the draft dataset.