---
title: View secret usage
---

[Skip to content](#_top)

[API Reference](https://developers.cloudflare.com/api/python)

[Secrets Store](https://developers.cloudflare.com/api/python/resources/secrets_store)

[Quota](https://developers.cloudflare.com/api/python/resources/secrets_store/subresources/quota)

Copy Markdown

Open in **Claude**Open in **ChatGPT**Open in **Cursor**

---

**Copy Markdown****View as Markdown**

# View secret usage

secrets\_store.quota.get(QuotaGetParams\*\*kwargs) -> [QuotaGetResponse](<https://developers.cloudflare.com/api/python/resources/secrets_store#(resource)%20secrets_store.quota%20%3E%20(model)%20quota_get_response%20%3E%20(schema)>)

GET/accounts/{account\_id}/secrets\_store/quota

Lists the number of secrets used in the account.

##### Security

API Email + API Key

The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.

**Example:**`X-Auth-Email: user@example.com`

The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.

**Example:**`X-Auth-Key: 144c9defac04969c7bfad8efaa8ea194`

##### Accepted Permissions (at least one required)

`Secrets Store Write``Secrets Store Read`

##### ParametersExpand Collapse

account\_id: str

maxLength32

[Link to this property](<#(resource)%20secrets_store.quota%20%3E%20(method)%20get%20%3E%20(params)%20default%20%3E%20(param)%20account_id%20%3E%20(schema)>)

##### ReturnsExpand Collapse

<details>

<summary>

class QuotaGetResponse: …

</summary>

<details>

<summary>

secrets: Secrets

</summary>

quota: float

The number of secrets the account is entitled to use.

<a href="#(resource)%20secrets_store.quota%20%3E%20(model)%20quota_get_response%20%3E%20(schema)%20%3E%20(property)%20secrets%20%3E%20(property)%20quota">Link to this property</a>

usage: float

The number of secrets the account is currently using.

<a href="#(resource)%20secrets_store.quota%20%3E%20(model)%20quota_get_response%20%3E%20(schema)%20%3E%20(property)%20secrets%20%3E%20(property)%20usage">Link to this property</a>

</details>

<a href="#(resource)%20secrets_store.quota%20%3E%20(model)%20quota_get_response%20%3E%20(schema)%20%3E%20(property)%20secrets">Link to this property</a>

</details>

[Link to this property](<#(resource)%20secrets_store.quota%20%3E%20(model)%20quota_get_response%20%3E%20(schema)>)

### View secret usage

Python

HTTPTypeScriptPythonGoTerraform

```
import os
from cloudflare import Cloudflare

client = Cloudflare(
    api_email=os.environ.get("CLOUDFLARE_EMAIL"),  # This is the default and can be omitted
    api_key=os.environ.get("CLOUDFLARE_API_KEY"),  # This is the default and can be omitted
)
quota = client.secrets_store.quota.get(
    account_id="985e105f4ecef8ad9ca31a8372d0c353",
)
print(quota.secrets)
```

200 example

```
{
  "errors": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "messages": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "success": true,
  "result": {
    "secrets": {
      "quota": 10,
      "usage": 10
    }
  },
  "result_info": {
    "count": 1,
    "page": 1,
    "per_page": 20,
    "total_count": 2000,
    "total_pages": 100
  }
}
```

##### Returns Examples

200 example

```
{
  "errors": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "messages": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "success": true,
  "result": {
    "secrets": {
      "quota": 10,
      "usage": 10
    }
  },
  "result_info": {
    "count": 1,
    "page": 1,
    "per_page": 20,
    "total_count": 2000,
    "total_pages": 100
  }
}
```