---
title: "Export Traces"
method: GET
path: "/api/traces/export"
tags: ["traces"]
---

# Export Traces

`GET /api/traces/export`

## Query parameters

- `project_id` string, required — project whose traces to export
- `limit` integer
- `format` string — one of records, prompts, raw

## Response `200`

Successful Response

- TracesExportResponse — A project's traces in the requested shape. `format` echoes what produced `records`: - ``records``: ``{"input", "output"}`` environment records, dropping straight into an environment's dataset/train.jsonl. SFT and GRPO both read these. - ``prompts``: ``{"input"}`` only, for GRPO, which samples its own completions. Keeps traces whose reply never arrived, so it usually yields more rows than ``records`` over the same traces. - ``raw``: the stored trace rows with their spans, converted by nothing. `traces` counts what was read; `skipped` is how many produced no record (always 0 for ``raw``).
  - `records` object[], required
  - `traces` integer, required
  - `skipped` integer, required
  - `format` string, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/freesolo/apis/platform-backend.md) · [All operations](https://skmtc.dev/freesolo/apis/platform-backend/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/freesolo/platform-backend/revisions/5626e92675af/schema)
