Ana içeriğe geç

List Keys

Endpoint​

GET /apiops/projects/{projectName}/keys/

Authentication​

Requires a Personal API Access Token.

Authorization: Bearer YOUR_TOKEN

Request​

Headers​

HeaderValueRequired
AuthorizationBearer {token}Yes

Path Parameters​

ParameterTypeRequiredDescription
projectNamestringYesProject name

Query Parameters​

None.

Response​

Success Response (200 OK)​

{
"status": "SUCCESS",
"resultList": [
{
"id": "key-id-123",
"name": "my-key",
"description": "Key for API encryption",
"projectId": "project-id",
"keyType": "SECRET_KEY",
"algorithm": "AES",
"cryptoKeyInfoEnvironmentList": [
{
"environmentName": "production",
"alias": "my-key-alias",
"source": null
}
]
}
]
}

Response Fields​

FieldTypeDescription
statusstringResponse status: SUCCESS or FAILURE
resultListarray[object]List of keys

Key Object​

FieldTypeDescription
idstringKey ID (internal identifier)
namestringKey name
descriptionstringKey description
projectIdstringProject ID where key belongs
keyTypestringKey type: SECRET_KEY, PRIVATE_KEY, or PUBLIC_KEY
algorithmstringSymmetric key algorithm — populated when keyType is SECRET_KEY: AES, DES, DESede, or RSA. null for PRIVATE_KEY / PUBLIC_KEY.
cryptoKeyInfoEnvironmentListarray[object]List of key environments

Key Environment Object​

FieldTypeDescription
environmentNamestringEnvironment name where the key is deployed
aliasstringKey alias (optional identifier)
sourcestringInternal origin marker for this environment entry, set during export/import merges. Not settable through the create/update request bodies.

Note: The key material itself (content) is never returned by this endpoint — it is write-only, accepted on Create Key / Update Key but not echoed back here or by Get Key. The environment entry also carries environmentName directly; no separate lookup against environmentId is needed.

cURL Example​

curl -X GET \
"https://demo.apinizer.com/apiops/projects/MyProject/keys/" \
-H "Authorization: Bearer YOUR_TOKEN"

Notes and Warnings​

  • Key Content is never returned:

    • The key material (content) is write-only — it is accepted by Create Key / Update Key but is not included in this response
    • To retrieve the raw material itself, use Export Key File (subject to SECRETS + EXPORT_IMPORT permission)
  • Multiple Environments:

    • Each key can be deployed to multiple environments
    • Each environment has separate key configuration
  • Environment Name:

    • Response carries environmentName directly on each environment entry — no separate lookup is needed
    • algorithm is only populated for SECRET_KEY keys

Permissions​

User must have any permission in the project (read access).