On this page
View and test APIs
Explore how to use the frontend app to view the API products you are subscribed to and try out sample API requests.
All self-service features in the frontend app can be accessed only if you set up a secure login for the frontend app. These features are hidden without a secure login. For more information, see Set up a secure login.
APIs
An API represents an API product that the Portal admin set up to bundle the APIs that you are able to access. The following restrictions apply:
- APIs might be marked as private and can be protected by a PortalGroup. Only authorized users can see the API in the frontend app.
- Portal users can view the specification and documentation of public APIs in the API catalog. However, access to an API is denied until the following conditions are met:
- The user’s team is subscribed to an API with an API subscription.
- The API subscription is approved by a Portal admin.
- The user self-serviced the appropriate credentials to access the API.
- Portal users cannot change or remove APIs from the API catalog.
View API specs and docs
- Log in to the frontend app as a Portal user.
- In the frontend app, go to APIs.
- Find the API products that the Portal admin created and select the one you want to see the details for.
- Review the API’s specification (Spec) or documentation (Docs). You can also add the API product to an app by using the SUBSCRIBE button.
Test API access
- Log in to the frontend app as a Portal user.
- Select APIs, and find and select the API product that you are subscribed to. The API specification opens automatically using a Redoc View.
- Click Swagger View to change to the Swagger view.
- Click Authorize. Depending on how the Portal admin protected your API, you either see a window to enter an API key or an ID token. The following image shows an example for an ID token when OAuth auth is enabled for the API.
- Enter the API key or ID token that you created and click Authorize. To create credentials to access your APIs, see Create API credentials.
- Select an API that you want to try, such as
GET tracks/tracks
. - Click Try it out, and then Execute. Verify that you get back a 200 HTTP response code. Note that the Portal admin might set up default rate limits for that API.
Instead of using the portal frontend app, you can also send a curl request to the tracks API to verify that your credentials are working.
API key:
curl -vik http://api.tracks.com/tracks \
-H "api-key: $API_KEY"
ID token from OAuth client:
curl -vik http://api.tracks.com/tracks \
-H "Authorization: Bearer $APP_TOKEN"