> ## Documentation Index
> Fetch the complete documentation index at: https://docs.apinizer.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List Keys

> Retrieves all cryptographic keys for a specified project. Keys are used for encryption, decryption, signing, and verification operations.

## Endpoint

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

## Authentication

Requires a Personal API Access Token.

### Header

```
Authorization: Bearer YOUR_TOKEN
```

## Request

### Headers

| Header        | Value            | Required |
| ------------- | ---------------- | -------- |
| Authorization | Bearer `{token}` | Yes      |

### Path Parameters

| Parameter   | Type   | Required | Description  |
| ----------- | ------ | -------- | ------------ |
| projectName | string | Yes      | Project name |

### Query Parameters

None.

## Response

### Success Response (200 OK)

```json theme={null}
{
  "success": true,
  "resultList": [
    {
      "name": "my-key",
      "description": "Key for API encryption",
      "projectId": "project-id",
      "keyType": "RSA",
      "cryptoKeyInfoEnvironmentList": [
        {
          "environmentId": "env-id-123",
          "content": "encrypted-key-content",
          "alias": "my-key-alias"
        }
      ]
    }
  ]
}
```

### Response Fields

| Field      | Type           | Description                             |
| ---------- | -------------- | --------------------------------------- |
| success    | boolean        | Indicates if the request was successful |
| resultList | array\[object] | List of keys                            |

### Key Object

| Field                        | Type           | Description                                            |
| ---------------------------- | -------------- | ------------------------------------------------------ |
| name                         | string         | Key name                                               |
| description                  | string         | Key description                                        |
| projectId                    | string         | Project ID where key belongs                           |
| keyType                      | string         | Key type: `SECRET_KEY`, `PRIVATE_KEY`, or `PUBLIC_KEY` |
| cryptoKeyInfoEnvironmentList | array\[object] | List of key environments                               |

### Key Environment Object

| Field         | Type   | Description                            |
| ------------- | ------ | -------------------------------------- |
| environmentId | string | Environment ID (internal identifier)   |
| content       | string | Encrypted key content (base64-encoded) |
| alias         | string | Key alias (optional identifier)        |

**Note:** Response contains `environmentId` (not `environmentName`). To get environment names, use the [Get Key](/api-reference/keys-secrets/crud/get-key) endpoint or refer to environment management APIs.

## cURL Example

```bash theme={null}
curl -X GET \
  "https://demo.apinizer.com/apiops/projects/MyProject/keys/" \
  -H "Authorization: Bearer YOUR_TOKEN"
```

## Notes and Warnings

* **Key Content**:
  * Key content is encrypted and included in the response
  * Handle key data securely
  * Content is base64-encoded and encrypted

* **Multiple Environments**:
  * Each key can be deployed to multiple environments
  * Each environment has separate key configuration

* **Environment ID**:
  * Response contains `environmentId` (internal identifier)
  * To get environment names, use the [Get Key](/api-reference/keys-secrets/crud/get-key) endpoint

## Permissions

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

## Related Documentation

* [Get Key](/api-reference/keys-secrets/crud/get-key) - Get a specific key
* [Create Key](/api-reference/keys-secrets/crud/create-key) - Create a new key
