Authentication by sudo

POST/auth/sudo

Base URL: https://api.tinkermode.com

A special endpoint for project administrator to assume the identity of a user to log into an app (a practice commonly known as "sudo"). This is useful for troubleshooting user issues. The caller must first obtain a sudo authorization token, usually from the project's "admin server". The User Session resulted from sudo will automatically expire after 30 minutes. This API call is not allowed for BYOU projects.

Authentication

This endpoint does not require authentication.

Request body

Content type: application/x-www-form-urlencoded

PropertyTypeRequiredConstraintsDescription
tokenstringYesSudo authorization token.

Responses

200 Sudo access granted.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
auth2FTokenstringNoread-only (server-generated)Token used for completing the two-factor authentication process. Token will expire within 3 minutes
expirationTimestringNoread-only (server-generated); format: date-timeThis property is present if token has an expiration time.
sudoerstringNoread-only (server-generated)This property is present if client is authenticated via sudo.
tokenstringNoread-only (server-generated)Access token to be used in the HTTP Authorization header in future API requests.
userIdintegerNoread-only (server-generated)This property is present if token is associated with a user.

401 Authorization is required to access this resource.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

403 Request failed because of invalid data or denied permission.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

429 Request failed because of rate limit.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

500 An unexpected error has occurred.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

503 The service is temporarily unavailable.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.