Operation
Get Invitation Details
GET
/users/invitations/{id}Fetch details about a specific invitation.
Returns the invitation status (pending, accepted, expired), the email it was
sent to, and when it expires. Use this to show invitation status in your UI
or to check if you need to resend.
When to use this
- Showing invitation status on a user management page
- Checking if an invitation has expired
- Displaying details before resending
Path parameters
idstringRequired
Returns
Invitation retrieved successfully
Errors
- 400
- Bad Request - Invalid input
- 401
- Unauthorized - Authentication required
- 403
- Forbidden - Insufficient permissions
- 404
- Not Found - Resource not found
- 500
- Internal Server Error
Every error names its code and links to it. All error codes
Notes
Note
Invitations expire after a set period-check the expiresAt field.
Tip
If an invitation has expired, you can resend it to generate a new code.
Related
import { BackstageClient } from '@ticketlayer/backstage';const client = new BackstageClient({ organisationSlug: 'your-org',});client.setAccessToken('YOUR_ACCESS_TOKEN');// Get userinvitation detailsconst userinvitation = await client.userinvitation.get('{{USERINVITATION_ID}}');console.log(`UserInvitation: ${userinvitation.name || userinvitation.id}`);Response 200
{
"invitation": {
"id": "inv_abc123",
"organisationId": "org_xyz789",
"userId": "usr_pending123",
"code": "inv_BvQ8mK...",
"email": "newuser@example.com",
"expiresAt": "2024-01-08T00:00:00.000Z",
"redeemedAt": null,
"createdAt": "2024-01-01T00:00:00.000Z"
}
}