# How to resolve the authorization page 20029 error

## Problem phenomenon

When testing or using the application, the error 20029 redirect_uri request is illegal and cannot be authorized when accessing the authorization login-free page.

![image.png](//sf3-cn.feishucdn.com/obj/open-platform-opendoc/a3621fc3b2195f4674f71f3c54ccc8fd_guR13VpXqk.png?height=636&lazyload=true&maxWidth=600&width=1630)

## Cause of the problem

Possible reasons are as follows:

- The current application does not match the application that configures the redirect URL. For example, you configure the redirect URL in application B, and use application A [obtain login authorization code](https://open.feishu.cn/document/common-capabilities/sso/api/obtain-oauth-code) in actual development.
- The application is not configured with a redirect URL.

## Solution

1. Get the URL of the page reporting error 20029 and parse the relevant information.

For example, `https://open.feishu.cn/open-apis/authen/v1/index?redirect_uri=http%3a%2f%2fims.shunmed.com%3a188%2fimsen%2ftable.aspx&app_id=cli_a44a4001a727a1234&state=fs_y5b`, where:

- app_id is `cli_a44a4001a727a1234`
	- The redirect URL is `http%3a%2f%2fexample.com%3a8080%2findex%2fdemo.aspx`, which needs to be decoded to `http://example.com:8080/index/demo.aspx` (see [Getting the Authorization Login Authorization Code](https://open.feishu.cn/document/common-capabilities/sso/api/obtain-oauth-code), where the redirect URL parameter `redirect_uri` needs to be encoded in "application/x-www-form-urlencoded" format)

2. Log in to [Developer Console](https://open.feishu.cn/app) and find the application that matches app_id.

If you don't know which application the app_id corresponds to, you can call the [Get Application Information](https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/application-v6/application/get) interface to get the application name, creator and other information through app_id.

3. (Optional) Check whether the application matches.

- If the application you actually developed is not the same application as the application corresponding to the app_id obtained in step 1, it means that the app_id used in the project during the development process is incorrect. You need to replace it with the correct application app_id and make sure that the application is configured with a redirect URL.

- If the app_id is correct, you need to proceed to the next step to configure the redirect URL.

4. Go to the application details page, and configure the redirect URL on the **Development Configuration** > **Security Settings** page.

For example, if the redirect URL obtained in step 1 is `http://example.com:8080/index/demo.aspx`, you need to add this URL to the **Redirect URL** of the application.

![image.png](//sf3-cn.feishucdn.com/obj/open-platform-opendoc/144548cdb47b0099d9a4ca5122bd6271_d8Y1VRplL9.png?height=922&lazyload=true&maxWidth=600&width=2882)warning
**Notice**:
<br>
The application redirect URL list in the developer console needs to include the full path, but if the path is followed by a `?` or `#` suffix, it can be excluded from the redirect URL. For detailed instructions on redirect URLs, see [Configure redirect URLs](https://open.feishu.cn/document/uYjL24iN/uYjN3QjL2YzN04iN2cDN).
<br>
For example, when `http://www.example.com/#/index` is configured as the redirect URL of the application, you only need to configure it as `http://www.example.com`. If it is configured as `http://www.example.com/#/index`, there will be no error, but the actual effective URL is `http://www.example.com`.