Skip to main content
Request user authorization and get an authorization code. Your backend exchanges the code for an access token (applyToken) to obtain the user’s information, such as user ID and nickname. See User Authorization for the full flow.

Parameters

Authorization Scopes

Silent authorization (auth_base) does not show a consent dialog and obtains the user information directly; all other scopes require the user’s explicit consent. Silent authorization is only available for first-party Mini Programs. All third-party Mini Programs require explicit user authorization.

Success Callback

Fail Callback

Error Codes

Code Example

The authCode is short-lived and single-use. It must be exchanged server-side via the Rebell OpenAPI for a user context. Never validate the authCode client-side.

my.getOpenUserInfo

Get user information

Backend Authentication

Auth code exchange guide