---
title: "Starts an asynchronous sample generation run."
method: POST
path: "/benchmark/{benchmarkId}/sample-generation"
tags: ["Benchmark", "SampleGeneration"]
---

# Starts an asynchronous sample generation run.

`POST /benchmark/{benchmarkId}/sample-generation`

## Path parameters

- `benchmarkId` string, required

## Request body

- CreateSampleGenerationEndpointInput
  - `samplesPerPrompt` integer, required — How many samples to request per matching prompt (1 to 16).
  - `participantIds` string[], nullable — Restrict generation to specific participants. Defaults to all participants in the benchmark that have a configured faucet.
  - `promptIdentifiers` string[], nullable — Restrict generation to specific prompt identifiers. Defaults to every prompt in the benchmark.
  - `tags` string[], nullable — Restrict generation to prompts having at least one of these tags.

## Response `200`

OK

- CreateSampleGenerationEndpointOutput
  - `id` string, required — The id of the created sample generation request.
  - `totalCount` integer, required — The total number of generation items that were queued.
  - `skippedParticipantIds` string[], required — Participants that matched the selection but were skipped because they have no faucet configured. Empty when explicit participant ids were supplied.

## Other responses

- `400` — Bad Request
- `401` — Unauthenticated
- `403` — Forbidden

---

[API](https://skmtc.net/rapidata/apis/rapidata-api.md) · [All operations](https://skmtc.net/rapidata/apis/rapidata-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/rapidata/rapidata-api/versions/e42ec51c7b88/schema)
