GET /auth/authorize

Request Information

Note

When initiating the OAuth authorization process, please ensure that the call is made through a web browser rather than via a regular API request. The authorization endpoint is designed to handle user interaction and authentication flows that require browser-based redirection and user consent.

Resource Description

NameDescriptionTypeAdditional information
client_id

The unique identifier assigned to your application.

string

Required.

response_type

MUST be set to "code."

string

Required.

redirect_uri

The URI to which the Unity AuthServer will redirect the user once the authorization process is complete.

string

Required.

scope

Specifies the set of operations the requested access token should be permitted to use. When requesting multiple scopes, the value must be expressed as a list of space-delimited API scopes.

string

Optional. See Service Extensions and Scopes for further details.

state

An opaque value used by the client to maintain state between the request and callback. This is used to prevent CSRF attacks.

string

Recommended.

Request Format

GET /auth/authorize HTTP/1.1

?response_type=code
&client_id=myTestApp
&redirect_uri=https%3A%2F%2Fexample-app.com%2Fcallback
&scope=openid+profile+email+phone+address
&state=xcoiv98y2kd22vusuye3kch
    

Response Information

Resource Description

NameDescriptionTypeAdditional information
code

The authorization code generated by the Unity AuthServer.

string

Required

state

If the "state" parameter is included in the client authorization request, Unity AuthServer will pass this value back to the client during redirection.

string

Recommended

Response Format

https://example-app.com/callback
?code=g0ZGZmNjVmOWIjNTk2NTk4ZTYyZGI3
&state=xcoiv98y2kd22vusuye3kch