Create API keys
You can create API keys in the Portal frontend app to access the API product that you are subscribed to.
This guide must be completed by a Portal user.
The following restrictions apply:
- API keys are connected to an app that is owned by a team.
- API keys can be created by authorized Portal users only. Portal admins cannot create API keys in the Portal frontend.
- The API key value is shown only at creation time and cannot be retrieved afterwards.
- Members of the team can delete API keys.
- API keys that are created via the frontend app are valid only if the Portal admin set up a corresponding AuthConfig that allows API key authentication for the selected API.
- You must have an approved subscription to access an API with a valid API key.
Before you begin
Portal admins must complete the following tasks:
- Set up a portal web server.
- Secure the login to the portal frontend.
- Set up API key credential management via the portal frontend.
- Approve any pending API subscriptions. Without a valid subscription, access to an API is not granted, even if you have a valid access token.
Portal users must complete the following tasks:
Create a team, an app, and a subscription to your app.
Create API keys
- In your browser, open the portal frontend app, such as http://portal.example.com:8080/ and log in as a Portal user.
- In the frontend app, go to Apps.
- Find the app that you created in the list of apps.


- Click DETAILS.
- In the API Keys section, click ADD API KEY.
- Enter a name for the API key and click ADD API KEY.
- Copy the API key that is displayed to you and save it in a secure location. The API key can be used to securely access the API products you are subscribed to.


Test API keys
You can test access to an API by using the Portal frontend or by running commands from your local machine.
This guide shows you to use your local machine to test an API. To use the portal frontend instead, see View and test APIs.
Save your API key as an environment variable.
export API_KEY="<api-key>"Send a request to the httpbin app.
curl -vik ${INGRESS_GW_ADDRESS}:8080/httpbin/headers \ -H "host: api.example.com" \ -H "api-key: $API_KEY"curl -vik localhost:8080/httpbin/headers \ -H "host: api.example.com" \ -H "api-key: $API_KEY"Example output:
HTTP/1.1 200 OK
Remove API keys
- Log in to the frontend app as a Portal user.
- In the frontend app, go to Apps.
- Find the app that you created in the list of apps.


- Click DETAILS.
- Find the API key that you want to remove and click Delete.
Next
Was this page helpful?