Autional Autional
API Reference GitHub autional.com →

GET /oauth/{provider}/callback

Callback endpoint after third-party OAuth provider authorization. Exchanges the authorization code for an access token and fetches user info.

OAuth None application/json

Request Parameters

NameInTypeRequiredDefaultExampleConstraintsDescription
provider path string Yes Provider name
code query string Yes Authorization code returned by third party
state query string Yes Signed state parameter

Responses

StatusDescriptionSchema
200Callback processing result (contains masked token and user info)dto.DataResponse-dto_OAuthCallbackResponse
400Missing code or invalid stategitee_com_linmes_authms_base_dto.SimpleResponse
404Unsupported providergitee_com_linmes_authms_base_dto.SimpleResponse
500Failed to exchange authorization code or fetch user infogitee_com_linmes_authms_base_dto.SimpleResponse

Referenced Schemas

dto.DataResponse-dto_OAuthCallbackResponse

FieldTypeRequiredExampleConstraintsDescription
code integer No
data dto.OAuthCallbackResponse No
message string No
timestamp string No

dto.OAuthCallbackResponse

OAuth authorization callback result

FieldTypeRequiredExampleConstraintsDescription
provider string No github Provider
state string No state-123 Status
token string No gho_abc1... Token (masked)
user_info object No User info

gitee_com_linmes_authms_base_dto.SimpleResponse

FieldTypeRequiredExampleConstraintsDescription
code integer No
message string No
timestamp string No