---
title: "Retrieves a flow by its ID."
method: GET
path: "/flow/{flowId}"
tags: ["Flow"]
---

# Retrieves a flow by its ID.

`GET /flow/{flowId}`

## Path parameters

- `flowId` string, required

## Response `200`

OK

- IFlow — A flow definition exposed over the API, identified by a discriminator. Implementations describe the flow's type-specific configuration.
  - `_t` 'RankingFlow', required
  - `id` string, required — The unique identifier of the flow.
  - `name` string, required — The name of the flow.
  - `campaignId` string, required — The ID of the campaign associated with this flow.
  - `flowItemCount` integer, required — The total number of items that have been added to this flow. Incremented atomically on each item creation.
  - `targetResponseCount` integer, nullable, required — Target average response count per completed item. Enables PID-based automatic rate control when set. Null disables PID.
  - `pidProportionalGain` number, double, required — PID proportional gain. Controls how strongly the rate reacts to the current error between target and actual response counts.
  - `pidIntegralGain` number, double, required — PID integral gain. Eliminates steady-state error by accumulating error over time. Includes anti-windup clamping.
  - `pidDerivativeGain` number, double, required — PID derivative gain. Provides damping by reacting to the rate of change of the error, helping prevent overshoot.
  - `pidOutputOffset` number, double, required — Constant offset added to the PID output before clamping, shifting the controller's operating point so the P/I/D terms trim around a non-zero baseline.
  - `pidMinSessionsPerMinute` integer, required — Minimum sessions per minute the PID controller can set. Prevents the rate from dropping to zero.
  - `pidMaxSessionsPerMinute` integer, required — Maximum sessions per minute the PID controller can set. Prevents the rate from exceeding infrastructure capacity.
  - `pidBatchMode` 'Total' | 'PerBatch' | 'PerBatchTimeWeighted', required
  - `serveTimeoutSeconds` integer, nullable, required — Maximum time in seconds a user has to submit an answer after loading the task. Null uses the system-wide default.
  - `drainDurationSeconds` integer, required — Grace period in seconds after an item stops receiving new serves, allowing in-flight responses to complete.
  - `serveToResponseRatio` number, double, nullable, required — Ratio of serves to responses used to calculate how many tasks to serve per expected response.
  - `criteria` string, nullable, required — The comparison instruction shown to annotators during ranking tasks (e.g. "Which image is sharper?").
  - `startingElo` integer, required — The initial Elo rating assigned to new items entering the ranking. Standard default is 1200.
  - `minResponses` integer, required — Minimum number of responses a ranking item must receive before it is considered sufficiently evaluated.
  - `maxResponses` integer, nullable, required — Maximum number of responses a ranking item can receive before being removed from active ranking. Null allows unlimited responses.
  - `serveResponses` integer, nullable, required — Number of accepted responses per rapid at which to stop serving. Null defaults to MaxResponses.
  - `featureFlags` FeatureFlag[], required — Key-value feature flags that enable specific behaviors for this flow (e.g. rapid_hints).
    - `key` string, required
    - `value` string, required
  - `ownerId` string, uuid, required — The ID of the customer who owns the flow.
  - `ownerMail` string, required — The email of the customer who owns the flow.
  - `organizationId` string, required — The id of the organization that owns the entity.
  - `createdAt` string, date-time, required — The timestamp when the flow was created.

## 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)
