List the org’s invitations
GET
/orgs/{org}/invitations
const url = 'https://api.sloose.com/orgs/org_9f3c/invitations';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.sloose.com/orgs/org_9f3c/invitations \ --header 'Authorization: Bearer <token>'Every invitation the org has sent, newest first, with what became of each: pending, accepted, revoked, or expired.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”org
required
The org id the session was issued for. A token for one org can never read another.
string
Example
org_9f3cThe org id the session was issued for. A token for one org can never read another.
Responses
Section titled “Responses”The org’s invitations.
Media typeapplication/json
object
invitations
required
Array<object>
object
id
required
string
email
required
string
role
required
string
status
required
string
expiresAt
required
string
invitedByUserId
required
string
invitedByEmail
required
string
acceptedAt
required
string | null
revokedAt
required
string | null
createdAt
required
string
Example
{ "invitations": [ { "role": "operator", "status": "pending" } ]}No bearer, or one that is expired, revoked or no longer resolves to a member.
Media typeapplication/json
The error envelope every non-2xx answer uses.
object
error
required
Human-readable explanation.
string
code
Machine-readable reason. Absent on a few legacy 400s.
string
key
additional properties
Examplegenerated
{ "error": "example", "code": "example"}The bearer’s role is too low, or it was issued for a different org.
Media typeapplication/json
The error envelope every non-2xx answer uses.
object
error
required
Human-readable explanation.
string
code
Machine-readable reason. Absent on a few legacy 400s.
string
key
additional properties
Examplegenerated
{ "error": "example", "code": "example"}