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

# List Template Secrets

> List secret names configured for a template

Returns the list of secret keys configured for a template. Values are never returned - only names and whether they are set.

**Required scope:** `secrets:read`

## Path Parameters

**template\_id** `string` *required*

The template ID (e.g. `tmpl_abc123`).

## Headers

**Authorization** `string` *required*

Bearer token. Example: `Bearer runtm_xxx`

**X-Organization-Id** `string` *required*

Organization ID.

## Response

**secrets** `array`

Array of secret key names configured for the template.

**required\_secrets** `array`

Secret keys required by the template.

**has\_all\_required** `boolean`

Whether all required secrets are configured.

```bash cURL theme={null}
curl "https://app.runtm.com/api/cloud/org-templates/tmpl_abc123/secrets" \
  -H "Authorization: Bearer runtm_xxx" \
  -H "X-Organization-Id: org_abc123"
```

```python Python theme={null}
import requests

response = requests.get(
    "https://app.runtm.com/api/cloud/org-templates/tmpl_abc123/secrets",
    headers={
        "Authorization": "Bearer runtm_xxx",
        "X-Organization-Id": "org_abc123",
    },
)

data = response.json()
print(f"Configured: {data['secrets']}")
print(f"Required: {data['required_secrets']}")
print(f"All set: {data['has_all_required']}")
```

```javascript JavaScript theme={null}
const response = await fetch(
  "https://app.runtm.com/api/cloud/org-templates/tmpl_abc123/secrets",
  {
    headers: {
      "Authorization": "Bearer runtm_xxx",
      "X-Organization-Id": "org_abc123",
    },
  }
);

const data = await response.json();
console.log(`Configured: ${data.secrets.join(", ")}`);
console.log(`All required set: ${data.has_all_required}`);
```

```json 200 theme={null}
{
  "secrets": ["DATABASE_URL", "API_SECRET"],
  "required_secrets": ["DATABASE_URL", "API_SECRET", "REDIS_URL"],
  "has_all_required": false
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.