--- title: "JWT issues" slug: "troubleshooting-jwt-issues" description: "Resolve common JWT SSO setup issues, including 401 Unauthorized errors in Postman and login access problems, with our step-by-step solutions." updated: 2026-09-07T01:39:57Z published: 2026-09-07T01:39:57Z canonical: "docs.document360.com/troubleshooting-jwt-issues" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.document360.com/llms.txt > Use this file to discover all available pages before exploring further. # JWT issues If you encounter issues during the JWT SSO setup, refer to the following common errors and their solutions: ## 401-unauthorized error when testing JWT in Postman **Error**: 401 Unauthorized error If you encounter a **401 Unauthorized error** while testing JWT (JSON Web Token) using Postman, this typically occurs because the authorization settings are not configured correctly. **Steps to resolve**: To resolve this error, 1. In Postman, open the request you are testing. 2. Navigate to the **Authorization** tab. 3. Set the authorization type to **Basic Auth**. 4. In the **Username** field, enter the **Client ID**. 5. In the **Password** field, enter the **Client Secret**. 6. Go to the **Body** tab. 7. Select the **raw** option from the dropdown and ensure the format is set to **JSON**. 8. Add the required JSON payload for the API request. 9. Click **Send** to execute the request. Check the response for the expected results. If the request is successful, you should receive an **auth code** or token in the response. --- ## JWT login issue: Unauthorized access **Error:** *Sorry, you're not authorized to access this documentation. Invalid authentication code.* You might encounter this error when logging in to the {{variable.Knowledge base site}} using the JWT configured for reader accounts in the project due to unauthorized access. **Steps to resolve:** 1. Check if the issue is widespread or isolated: Determine whether the problem affects all readers in the project or is specific to readers from a particular region or network. For issues affecting a specific user: If the issue persists after following these steps, please contact the Document360 support team for further assistance: [Contact Document360 Support](https://document360.com/support/) Provide the following details: 1. Ask the user to log in using an incognito/private browsing panel. 2. Try accessing the site using a different internet connection. 3. Attempt logging in from another device to identify if the issue is device-specific. - A generated product log file. For instructions, read the article on [Generating a HAR File](/help/docs/document360-support-generating-a-har-file). - A screen recording that demonstrates the issue in detail. --- ## JWT login times out or returns a 500 error after switching to a custom domain **Error:** Cloudflare 524 timeout / 500 Internal Server Error during JWT login This happens when a knowledge base is served from a custom domain but the callback URL in the application is still pointing to the Document360-provided address (for example, `yourproject.document360.io/jwt/authorize`). JWT login is a direct request and is not automatically forwarded to the custom domain the way a normal page visit is, so the request stops before the authorization code is read. **Steps to resolve:** 1. In the Document360 portal, open your JWT configuration page and click **Configure JWT login**. 2. Click the **Copy** button next to **Callback URL** to get the correct URL for your custom domain (for example, `https://docs.yourcustomdomain.com/jwt/authorize`). 3. Update the callback URL in your application with this value. 4. Check whether the old Document360-provided address is saved anywhere else in your application code or settings and update those as well. **Note:** Authorization codes are single-use. A code from a failed login attempt cannot be retried. Start a fresh sign-in from your custom domain after making the change.