List flags
GET
https://api.vercel.com/v2/projects/{projectIdOrName}/feature-flags/flagsRetrieve feature flags for a project. Returns an opaque cursor for pagination.
https://api.vercel.com/v2/projects/{projectIdOrName}/feature-flags/flags
const response = await fetch('https://api.vercel.com/v2/projects/projectIdOrName/feature-flags/flags?state=string&limit=123&cursor=string&search=string&tags=[]&createdBy=string&maintainerIds=[]&includeMarketplaceFlags=true&teamId=string&slug=string', { method: 'GET', headers: { 'Authorization': 'Bearer YOUR_ACCESS_TOKEN', 'Content-Type': 'application/json', },});
const data = await response.json();console.log(data);Response
{ "pagination": { "next": "string" }, "data": [ { "createdAt": "123", "createdBy": "string", "description": "string", "environments": "value", "id": "icfg_1234567890", "kind": "boolean", "maintainerIds": [], "ownerId": "example_id", "permanent": "false", "projectId": "example_id", "revision": "123", "seed": "123", "slug": "string", "state": "active", "tags": [], "typeName": "flag", "updatedAt": "123", "updatedBy": "string", "variants": [ { "description": "string", "id": "icfg_1234567890", "label": "string", "value": "string" } ], "metadata": { "creator": { "id": "icfg_1234567890", "name": "Example Name" } } } ]}AuthorizationbearerToken
Default authentication mechanism
Filter flags by maintainer user id. Repeat the parameter for multiple maintainers (any may match).
Whether to include Marketplace experimentation items in the paginated response. Defaults to false.
400One of the provided values in the request query is invalid.
401The request is not authorized.
402The account is missing a payment so payment method must be updated
403You do not have permission to access this resource.
404Error
410Error
503Error