Skip to main content
GET
List factories
The reference panel describes the current v3 operation. The notes below describe its v2 compatibility API. Follow the v3 request schema for current calls: v3 can move identifiers from the body or query into the URL. Keep the v2 method, path, and payload together when using the compatibility API.

v2 compatibility notes

GET /api/v2/factories/list returns the factories you may read, newest first. A factory is included only when your key or External App holds factories:read at the factory’s home org unit (or an org unit above it). A factory with no home org unit is never returned. Optional filters narrow the list: status (PROVISIONING, ACTIVE, PAUSED, or ARCHIVED), factoryType, and ownerType (worker, team, department, or organization) with ownerId. ownerType and ownerId are given together or not at all. One filter is served by an index, chosen in this order: the owner, then the type, then the status. The other filters are applied to each page, so a filtered page can be short or empty before the last page. An unknown status or ownerType, an empty factoryType or ownerId, or ownerType without ownerId (or the reverse) is 400 bad_request. Pages are at most 50 rows. limit defaults to 50; a larger value is 400 too_big. Pass meta.nextCursor back as cursor while meta.hasMore is true. A page can hold fewer rows than limit, or none, while meta.hasMore is still true: factories you may not read are left out of the page and never counted. A limit that is not a positive integer, an empty cursor, a repeated parameter, or a cursor the server cannot read is 400 bad_request. Each item is a FactoryListItem: the Factory fields plus teamMemberCount (active members), activeTaskCount (tasks in progress), and activeRunCount (active assignments whose workflow or project you may read, plus assignments homed at the factory). Each count reads at most 51 rows. When any count on the page reaches that bound, meta.partial is true and that count is a lower bound of 50.

Authorizations

Authorization
string
header
required

An External App: the JWT it obtains from POST /oauth/token with OAuth2 client_credentials. Pass as Authorization: Bearer <jwt>. An app's static companion key also authenticates as the app, but is deprecated and is not protected by Idempotency-Key.

Query Parameters

status
enum<string>

Only factories in this status.

Available options:
PROVISIONING,
ACTIVE,
PAUSED,
ARCHIVED
factoryType
string

Only factories of this factory type.

Minimum string length: 1
ownerType
enum<string>

Only factories with this owner type; requires ownerId.

Available options:
worker,
team,
department,
organization
ownerId
string

Only factories of this owner; requires ownerType.

Minimum string length: 1
limit
integer
default:50

Rows to read for this page, 1 to 50; a larger value is 400 too_big.

Required range: 1 <= x <= 50
cursor
string

The opaque meta.nextCursor from the previous page.

Minimum string length: 1

Response

Factory page

data
object[]
required
meta
object
required

A list page's continuation. While hasMore is true, nextCursor is a string: pass it as cursor for the next page. hasMore: false ends the list; with truncated: true, more exist past what this list reads, and no cursor reaches them.