> This page is for API.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.eon.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.eon.io/_mcp/server.

# List Vaults

POST https://%7Baccount-domain%7D.console.eon.io/api/v1/projects/{projectId}/vaults/list

Retrieves a list of vaults in the specified project.

Reference: https://docs.eon.io/api/api-reference/vaults/list-vaults

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Path parameters

- `projectId` (string, required) — ID of the project whose vaults you want to retrieve. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.

### Query parameters

- `pageToken` (string, optional) — Cursor that points to the first record of the next page of results. Get this value from the previous response. To preserve the results in the same order, use the same sorting and filters in the first request as all subsequent requests.
- `pageSize` (integer, optional) — Maximum number of items to return in the response.

## Response

### 200

Vaults retrieved.

- `vaults` (list of BackupVault, required)
- `totalCount` (integer, required) — Total number of restore jobs that matched the filter options.
- `nextToken` (string, optional) — Cursor that points to the first record of the next page of results. Pass this value in the next request.

## Types

### BackupVault

- `id` (string, required) — Vault ID.
- `vaultAccountId` (string, required) — Eon-assigned ID of the vault account.
- `providerAccountId` (string, required) — Cloud provider-assigned ID of the vault account.
- `name` (string, required) — Vault display name.
- `region` (string, required) — Region where the vault is located.
- `isManagedByEon` (boolean, required) — Whether the vault is in an Eon-managed vault account.
- `vaultAttributes` (VaultProviderAttributes, required) — Cloud-provider-specific vault attributes.

### VaultProviderAttributes

Cloud-provider-specific vault attributes.

- `cloudProvider` (enum, required) — Cloud provider. `PROVIDER_UNSPECIFIED` is supported only in responses.
  - Allowed values: `AWS`, `AZURE`, `GCP`, `MONGO_ATLAS`, `PROVIDER_UNSPECIFIED`
- `aws` (AwsVaultConfig, optional) — AWS-specific vault configuration.

### AwsVaultConfig

AWS-specific vault configuration.

- `encryptionKey` (string, optional) — ARN of the KMS key used for encryption. Omitted if the key is managed by Eon.

## Examples

**Response**

```json
{
  "vaults": [
    {
      "id": "37732835-d768-5990-ba93-a7c2d2e6d754",
      "vaultAccountId": "1ee34dc5-0a7c-4e56-a820-917371e05c8d",
      "providerAccountId": "123412341234",
      "name": "AWS US East 1",
      "region": "us-east-1",
      "isManagedByEon": true,
      "vaultAttributes": {
        "cloudProvider": "AWS",
        "aws": {
          "encryptionKey": "arn:aws:kms:us-east-1:123456789012:key/4692190d-ae52-56fe-9937-6aa2c4e3df62"
        }
      }
    }
  ],
  "totalCount": 188,
  "nextToken": "Y2NiMGYyZmMtYjYyZi00OTc5LTgzNjQtYmQ2YjEyYzdjZTNifDE="
}
```

**SDK Code**

```python
import requests

url = "https://{account-domain}.console.eon.io/api/v1/projects/1ee34dc5-0a7c-4e56-a820-917371e05c8d/vaults/list"

querystring = {"pageSize":"10","pageToken":"Yjk3ODZjNjktZTIwZC00NjAxLWE1MzktZjg2NGExM2IxYTZlfDE="}

headers = {"Authorization": "Bearer <token>"}

response = requests.post(url, headers=headers, params=querystring)

print(response.json())
```

```javascript
const url = 'https://{account-domain}.console.eon.io/api/v1/projects/1ee34dc5-0a7c-4e56-a820-917371e05c8d/vaults/list?pageSize=10&pageToken=Yjk3ODZjNjktZTIwZC00NjAxLWE1MzktZjg2NGExM2IxYTZlfDE%3D';
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://{account-domain}.console.eon.io/api/v1/projects/1ee34dc5-0a7c-4e56-a820-917371e05c8d/vaults/list?pageSize=10&pageToken=Yjk3ODZjNjktZTIwZC00NjAxLWE1MzktZjg2NGExM2IxYTZlfDE%3D")
  .header("Authorization", "Bearer <token>")
  .asString();
```