Get Consumer Secret References
Endpoint
GET /apiops/projects/{projectName}/consumers/{consumerKey}/secrets
Authentication
Requires a Personal API Access Token.
Authorization: Bearer YOUR_TOKEN
Request
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
| consumerKey | string | Yes | Consumer key, assigned by the installation. Returned as consumerKey by every consumer response |
Response
200 OK with one reference per kind of secret material:
{
"secretKey": { "name": "partner-secret", "scope": "PROJECT" },
"certificate": { "name": "partner-cert", "scope": "ADMIN" },
"jwkValidation": { "name": "partner-jwk", "scope": "PROJECT" }
}
| Field | Type | Description |
|---|---|---|
| secretKey | object | Reference to the secret key |
| certificate | object | Reference to the certificate |
| publicKey | object | Reference to the public key |
| privateKey | object | Reference to the private key |
| keystore | object | Reference to the keystore |
| truststore | object | Reference to the truststore |
| jwkValidation | object | Reference to the JWK for validation and signing |
| jwkEncryption | object | Reference to the JWK for decryption and encryption |
Each reference has these fields:
| Field | Type | Description |
|---|---|---|
| name | string | Name of the referenced object. The set operations take the same name |
| scope | string | PROJECT when the object belongs to the project of the consumer, ADMIN when it belongs to the admin project |
A reference that is not set is absent. The response never contains the material. To set or remove a reference, use the operations in Secret material, JWK and token settings.
An unknown consumerKey answers 404 resourceNotFound.
cURL Example
curl -X GET \
"https://demo.apinizer.com/apiops/projects/MyProject/consumers/CONSUMER_KEY/secrets" \
-H "Authorization: Bearer YOUR_TOKEN"
Permissions
- User must have
IDENTITY+VIEWpermission in the project - A project outside the scope of the caller answers
404 resourceNotFound, never403 - The admin project has no consumers: a call on it answers
400 malformedRequest(params.reason=platformScopeNotSupported)