Troubleshooting issues when using Swagger as a Remedy REST API client
The Swagger user interface (UI) is an HTML/JS web application that can be hosted on simple web servers such as Apache, Microsoft Internet Information Services (IIS), or Apache Tomcat. The Swagger UI provides a sample request response that helps to integrate the AR System server with the REST service.
This topic describes the most common issues that might occur while using the Swagger UI.
Symptoms
- Pages are not displayed for the specified Jetty URLs.
- Pages are not displayed for the specified Swagger URLs.
- One of the following errors is displayed:
Failed to load API definition on Swagger UI
OrPossible cross-origin (CORS) issue
- The API definition is not provided in the Swagger UI.
Scope
Swagger, being a third-party tool, does not affect other areas. If the Jetty server doesn't respond, the Swagger UI and other integrations that use the Jetty server do not work.
Resolution
Perform the following steps to troubleshoot an issue:
Step | Task | Description |
1 | Ensure that the Jetty server is running | By default, the Jetty server runs on port 8008 and port 8443. For more information, see the following documents: |
2 | Enable the Swagger UI |
|
3 | Remove the Cross-Origin Resource Sharing (CORS) restrictions | If the following error occurs in the Swagger UI, remove the CORS restrictions on the Jetty server:
For information about removing CORS restrictions, see the knowledge article How to avoid RSSO from filtering REST requests . If the error prevails, Remedy SSO might be intercepting the requests. |
4 | Configure the Swagger UI to load Remedy AR System definitions | The Swagger UI shows a blank page or the following error:
For more information about configuring the Swagger UI, see the knowledge article How to configure swagger UI to load Remedy REST definitions . |
5 | Using swagger | You cannot use the Swagger UI to send attachments. For more information, see the knowledge article How to send Attachments into REST . |
After you determine a specific symptom or error message, use the following table to identify the solution:
Symptom | Location | Action |
---|---|---|
When you access the Swagger UI, the following error is displayed: | AR System server version 19.08 | Enable CORS settings for the Swagger UI. For more information, see the knowledge article REMEDY REST API - CORS setup for Swagger UI . |
You don't get a response when you access a URL pointing to a REST API. | AR System server version 9.x and later | Enable debug logs on the Jetty server and create a support case. For instructions on how to enable Jetty logs, see the knowledge article Enable Jetty logs |
The browser receives no response when accessing the | Any web server hosting html or javascript | Ensure that the following conditions are met:
If the issue persists, document the steps followed to publish the Swagger UI web pages and create a support case. For more information, see Using Swagger UI on Remedy. |
Comments
Log in or register to comment.