Datasets
Create Dataset Version from Request History
POST
Create a dataset version asynchronously from existing request logs. You can populate the version with explicit request log IDs or with structured request-log filters.Documentation Index
Fetch the complete documentation index at: https://docs.promptlayer.com/llms.txt
Use this file to discover all available pages before exploring further.
Behavior Notes
- If both
request_log_idsandfilter_groupare present, explicit request IDs take precedence. - The endpoint queues a background job and reuses the draft dataset for the dataset group when one already exists.
- Jobs are capped at 50,000 request logs.
- Filter-based datasets persist their filter parameters so refresh flows can replay the same query later.
- Completion triggers the
dataset_version_created_from_filter_paramswebhook.
Related
Authorizations
Body
application/json
Dataset version creation payload from request IDs or request-log filters.
Dataset group that will receive the generated dataset version.
Explicit request log IDs to snapshot. When provided, this mode takes precedence over filter_group.
Maximum array length:
50000Structured request-log filters used to populate the dataset asynchronously.
Free-text request-log search query applied with filter_group.
Available options:
request_start_time, input_tokens, output_tokens, cost, latency_ms, status Available options:
asc, desc Request fields or variables to parse into dataset columns.
Maximum number of request logs to include. When set, only the first N matching rows (in the current sort order) are added to the dataset version.
Required range:
x >= 1
