Using API v1? See what changes in v2, or the v1 docs
CONNECTION_TOKEN_EXPIRED
The provider's access token expired and could not be refreshed.
HTTP status: 422. Retrying the same request may succeed.
What to do
Retry with backoff. If the error persists, have the user reconnect through PyasConnect.
Hint returned with the error: Retry the request shortly. If it keeps failing, ask the user to reconnect their account.
Why it happens
- A temporary provider outage during refresh
- The refresh token was invalidated
Endpoints that return it
- List calendars
GET /v2/calendars - Create a calendar
POST /v2/calendars - Get a calendar
GET /v2/calendars/{calendarRef} - Update a calendar
PATCH /v2/calendars/{calendarRef} - Delete a calendar
DELETE /v2/calendars/{calendarRef} - List events
GET /v2/events - Create an event
POST /v2/events - Get an event
GET /v2/events/{eventId} - Update an event
PATCH /v2/events/{eventId} - Delete an event
DELETE /v2/events/{eventId} - Import an event
POST /v2/events/import - Create an event from text
POST /v2/events/quick - List an event's attachments
GET /v2/events/{eventId}/attachments - Attach a link
POST /v2/events/{eventId}/attachments - Forward an invitation
POST /v2/events/{eventId}/forward - List occurrences of a recurring event
GET /v2/events/{eventId}/instances - Move an event to another calendar
POST /v2/events/{eventId}/move - Respond to an invitation
POST /v2/events/{eventId}/respond - Delete an attachment
DELETE /v2/events/{eventId}/attachments/{attachmentId} - Upload a file to an event
POST /v2/events/{eventId}/attachments/file - Dismiss a reminder
POST /v2/events/{eventId}/reminder/dismiss - Snooze a reminder
POST /v2/events/{eventId}/reminder/snooze - Download an attachment
GET /v2/events/{eventId}/attachments/{attachmentId}/content