Xsolla-logo

OAuth 2.0認証

get/oauth2/auth

Checks the presence of a valid SSO session. Redirects to the URL passed in the redirect_url parameter with an authorization code.

Request
query Parameters
response_type
required
string

コードが設定され、アプリケーションが成功した場合に認証コードを受け取ることを期待することを示します。

Value: "code"
client_id
required
integer

アプリケーションID。OAuth 2.0クライアントを作成した後で取得します。

redirect_uri
required
string

This URL must match one of the URLs the developer registered when creating the application, and the authorization server should reject the request if it does not match. To set up this parameter, contact your Customer Success Manager.

scope
required
string

リクエストは、アプリケーションが要求する追加的なアクセスを示す1つ以上のスコープ値を持つことができます。認証サーバーは、要求されたスコープをユーザーに表示する必要があります。

state
required
string

状態パラメータは、アプリケーションがリクエスト固有のデータを保存したり、CSRF攻撃を防止するために使用されます。認証サーバーは、変更されていない状態の値をアプリケーションに返さなければなりません。これはおすすめのパラメータです。

audience
required
string

オーディエンスパラメータは、urlエンコードされたスペース(+または%20)で区切られた複数の文字列を含むことができます。オーディエンスの値自体もurlエンコードされている必要があります。

popup
boolean
Default: false

If true is passed method will redirect to widget at first and then to partner's callback. If false, method will redirect straight to partner's callback.

code_challenge
string

Generated challenge from the code_verifier (https://datatracker.ietf.org/doc/html/rfc7636#section-4-2).

code_challenge_method
string

Method used to generate the challenge. For now, you can only use the method S256 to generate code_challenge.

Value: "S256"
widget_only
boolean

Service parameter for pop up flow. Does not affect API behaviour.

enable_post_message_login
boolean

Service parameter for pop up flow. Does not affect API behaviour.

disable_socials
boolean

Service parameter for pop up flow. Does not affect API behaviour.

Responses
302

リダイレクション

400

無効なリクエスト

404

見つかりません

418

私はティーポット

422

処理不可能なエンティティー

429

リクエストの回数が多すぎます

Request samples
Response samples
{
  • "error": {
    }
}