API Management 10.4 | Administering API Portal | Using and Testing APIs | Testing a REST API
 
Testing a REST API
* To test a REST API
1. Switch to the API Gallery page.
Alternatively go to the Home page and type the beginning of the API name into the search box.
2. Click View details for an API.
3. Click Try API in the API details page.
The Try API page is displayed.
4. Select the required stage of the API that you want to test, from the Environment field.
The applications associated with the selected stage are displayed in the Applications field.
Note: This step is applicable only if the API is available in more than one stage.
5. Select an Application to test.
The resources that can be tested are displayed in the left panel.
6. Select a resource.
The methods associated with the resource that can be tested are displayed. If a method is protected by basic authentication, APIKey, OAuth2, or JWT, the same is indicated by a lock symbol.
Note: The HTTP PATCH support is available in API Portal 9.12 onwards.
7. Click a method.
8. Provide the following required values in the Parameters tab:
*Type a value for the path parameters.
*Type a query parameter and its corresponding value.
Note: You can add multiple entries by clicking .
9. Select the required Authorization Type from the Authorization tab and provide the corresponding values:
*No Auth: Specifies that no authentication is required.
*Basic authentication: Specifies basic authentication of user credentials is required. Type the username and password for authentication and click Update.
*Oauth 2.0: Specifies OAuth authentication is required. Provide the required information to fetch a OAuth token to use for authentication. For details on how to generate a OAuth token and use it see, OAuth 2.0 Support.
*JWT: Specifies a JSON Web token is required for authentication. Type a token or select one of the available tokens in the list and click Update. For details on how to generate a JSON web token and use it see, Testing a JWT protected API.
10. Type in the required Header name(s) and corresponding value(s) in the Headers tab. You can add multiple entries by clicking .
11. Click Send.
The request and the response of the API are displayed.
To clear the values entered and response rendered, click Clear.

Copyright © 2015- 2019 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Innovation Release