Troubleshooting
Problem
The API keys page appears blank, and users cannot create an API key.
Symptom
Log in to the CP4S console then navigate to General Settings > API Keys .
![image-20220208174252-1](/support/pages/system/files/inline-images/image-20220208174252-1.png)
The page that is displayed has a URL like https://example.cloudpakforsecurity.com/apikeys. The page is blank with the text API Keys showing.
![image-20220208174521-2](/support/pages/system/files/inline-images/image-20220208174521-2.png)
![image-20220208174521-2](/support/pages/system/files/inline-images/image-20220208174521-2.png)
Resolving The Problem
You can use the following steps to generate an API key and obtain the secret for it.
The process shown is through the Chrome web browser. Different browsers may have different steps to achieve the same outcome.
The process shown is through the Chrome web browser. Different browsers may have different steps to achieve the same outcome.
- Open a web browser that has developer tool functionality and go to the account and the API Key page.
- Open the Console (F12 or Inspect). The example shown is from the Chrome web browser.
- Clear the console.
- Paste the fetch API Key command shown:
fetch('/api/apikey/create', { body: JSON.stringify({id: 'apikeyname'}), headers: { Accept: 'application/json', 'Content-Type': 'application/json' }, method: 'POST'}).then(function(res){return res.json()}).then(function(res){console.log(res)}) With a specific apikeyname. - The console returns the resulting API key and secret/password:
Document Location
Worldwide
[{"Type":"MASTER","Line of Business":{"code":"LOB24","label":"Security Software"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSTDPP","label":"IBM Cloud Pak for Security"},"ARM Category":[{"code":"a8m0z0000001jrwAAA","label":"TII"}],"ARM Case Number":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"1.9.0"}]
Was this topic helpful?
Document Information
Modified date:
10 March 2022
UID
ibm16553904