listAll(options?: SearchListOptions): Promise<Array<InviteResource>>Walks the pages and resolves with a flat array of every outstanding invitation. Pending invite counts are normally small because acceptance and revocation both remove rows, so this usually costs a single request.
The pagination envelope is dropped, so you lose totalCount and hasMore. Reach for list when you need those numbers, or iterate when you want to stop as soon as you find the invite you were looking for.
Example
const invites = await envless.invites.listAll()
const stale = invites.filter((invite) => invite.status === 'expired')
for (const invite of stale) await envless.invites.revoke(invite.id)Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
options.limit | number | No | Page size used while walking, capped at 100 and defaulting to 100. |
options.offset | number | No | Row to start the walk from, so earlier invites are left out of the result. |
options.search | string | No | Case insensitive substring match on the invited email address, applied to every page. |
options.signal | AbortSignal | No | Cancels every request in the walk. |
Returns
Array<InviteResource> holding each pending invitation in the workspace.
Reads the invites collection. list returns one page as { items, pagination }, listAll collects every page into an array, and iterate streams one item at a time without buffering the whole set.
Worth knowing
- A failure on any page rejects the whole call and the rows already collected are lost.
- Every page is a separate read, so
statusvalues in the array were each computed at a slightly different moment.
Required scopes
members:read
Underlying endpoint
GET /invites
Request and response schema, every error code, and a live playground.
In Python
envless.invites.list_all()
The same method in envless-sdk, the Python SDK, with the same request, retries and errors.
In Ruby
Envless.invites.list_all
The same method in envless-sdk, the Ruby gem, with the same request, retries and errors.
In PHP
$envless->invites->listAll()
The same method in envless/sdk, the PHP SDK, with the same request, retries and errors.