GET Session Status
This endpoint gets status of an user session
Endpoint
GET /account/api/v1/session/status
Description
This API endpoint retrieves the status of a session associated with a specified account.
Request Parameters
Query Parameters
-
ownerId (string, required): The unique identifier of the account owner, usually the
app_user_id
. -
domain (string, required): The
app
associated with the account, usually a string like"instagram"
,"amazon"
.
Request Headers
-
Content-Type: application/json
-
Authorization: Bearer <API_KEY>
Response
The response will be { "status": SessionStatusEnum }
where SessionStatusEnum
is one of:
• "active": Session is valid and ready for automation.
• "revoked": Session is invalid and the user needs to log in again.
• "unknown": Unable to determine the session status.
Handling “unknown” Status
For newly connected users, the endpoint may initially return "unknown"
even when the session is active.
Recommended approach:
- Retry the request up to three times with a short delay between attempts.
- If the status remains
"unknown"
, prompt the user to reconnect.
Success (200 OK)
Returns the status of the session.
Example response:
{
"status": "active" | "revoked" | "unknown"
}
Error (404 Not Found)
Returned if the session does not exist.
Example response:
{
"error": "Session not found"
}
Error (403 Forbidden)
Returned if the client does not have the necessary permissions to access the session status.
Example response:
{
"error": "Forbidden: Access to the requested resource is denied."
}
Was this page helpful?