Skip to main content
GET
List surveys

Authorizations

next-auth.session-token
string
cookie
required

NextAuth session JWT cookie. Development: often next-auth.session-token. Production (HTTPS): often __Secure-next-auth.session-token. Send the cookie your browser receives after sign-in.

Query Parameters

workspaceId
string<cuid2>
required

Workspace identifier. This is the canonical container ID for v3 APIs.

limit
integer
default:20

Page size (max 250)

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

Opaque cursor returned as meta.nextCursor from the previous page. Omit on the first request.

includeTotalCount
boolean
default:true

Whether to calculate meta.totalCount for this request. Set to false on cursor-pagination follow-up requests to skip the extra count query; in that case meta.totalCount is null.

filter[name][contains]
string

Case-insensitive substring match on survey name (same as in-app list filters).

Maximum string length: 512
filter[status][in]
enum<string>[]

Survey status filter. Repeat the parameter (filter[status][in]=draft&filter[status][in]=inProgress) or use comma-separated values (filter[status][in]=draft,inProgress). Invalid values → 400. archived is a pseudo-status: it does not match a real survey status but includes archived (soft-deleted) surveys in the result set. Archived surveys are otherwise excluded from the default list.

Available options:
draft,
inProgress,
paused,
completed,
archived
filter[type][in]
enum<string>[]

Survey type filter (link / app). Same repeat-or-comma rules as filter[status][in].

Available options:
link,
app
filter[visibility][in]
enum<string>[]

Keep only surveys with one of these visibilities, as each item reports it (a survey with a change in flight counts as restricted). Same repeat-or-comma rules as filter[status][in]; unknown values → 400. Filters within the readable set: a workspace member asking for restricted gets their own restricted surveys, an organisation manager gets everyone's.

restricted: readable by the owner and the organisation's owners and managers only. The owner's access is conditional on their workspace access, level for level: they read the survey only while they can read the workspace, and edit it only while they can write to it — being the owner grants nothing the workspace does not. workspace: readable by everyone with access to the workspace — today's behaviour.

Available options:
restricted,
workspace
filter[owner][in]
enum<string>[]

me keeps surveys whose owner is the caller; others keeps the rest, ownerless surveys included. Relative to the signed-in user, so an API key sending this parameter gets 400.

Available options:
me,
others
sortBy
enum<string>

Sort order. Defaults to updatedAt. The cursor token is bound to the selected sort order.

Available options:
createdAt,
updatedAt,
name,
relevance

Response

Surveys retrieved successfully

data
object[]
required
meta
object
required

The list meta for surveys — pagination, the filtered total, and the workspace total. Both counting fields are required but nullable, gated on includeTotalCount.