# List templates

URL: https://docs.hanzo.ai/docs/openapi/legal/get-legal-templates

> Returns the org's effective template catalog: every built-in template, with any the org has overridden replaced by its own latest version.

`GET /v1/legal/templates`

> [Legal →](https://docs.hanzo.ai/docs/openapi/legal) · [All API references →](https://docs.hanzo.ai/docs/openapi) · [Get started →](https://docs.hanzo.ai/docs/guides)

|               |                                           |
| ------------- | ----------------------------------------- |
| **Address**   | `https://api.hanzo.ai/v1/legal/templates` |
| **Method**    | `GET`                                     |
| **Operation** | `get_legal_templates`                     |
| **Auth**      | `Authorization: Bearer $HANZO_API_KEY`    |

Returns the org's effective template catalog: every built-in
template, with any the org has overridden replaced by its own latest version.

The listing carries each template's metadata and its declared MERGE FIELDS — the
keys a document generation must supply — but never the template bodies; fetch one
template to get its body. Templates in the formation and equity categories are
marked counselReview: every document rendered from them carries a counsel notice,
and that posture cannot be dropped by an override.

## Request

`GET /v1/legal/templates` takes no parameters and no body — the credential is the whole request.

## Response

| Status    | Body                  | Meaning |
| --------- | --------------------- | ------- |
| `200`     | legal.templateCatalog | ok      |
| `default` | problem-details       | refused |

`200` body — 11 fields.

| Field                   | In   | Type                  | Always | Description                                                                                                         |
| ----------------------- | ---- | --------------------- | ------ | ------------------------------------------------------------------------------------------------------------------- |
| `data`                  | body | legal.templateView\[] | —      | Data is the catalog, metadata and merge fields only — never the template bodies, which are fetched one at a time.   |
| `data[].category`       | body | string                | —      | Category is the corporate need the template serves: formation, equity, ops or sales.                                |
| `data[].counselReview`  | body | boolean               | —      | CounselReview marks a template whose rendered documents open with the counsel notice.                               |
| `data[].fields`         | body | legal.Field\[]        | —      | Fields declares the merge fields the body consumes — every key a generation must supply, each with its human label. |
| `data[].fields[].key`   | body | string                | —      | Key is the identifier the body substitutes ({{.key}}) and the key a generation's data map must carry.               |
| `data[].fields[].label` | body | string                | —      | Label is the human prompt for whoever fills the value in — "Governing law (state)".                                 |
| `data[].id`             | body | string                | —      | ID is the template's stable id and the path segment that fetches its body — "nda", "msa", "safe".                   |
| `data[].origin`         | body | string                | —      | Origin is "builtin" for a template the platform ships or "org" for one this org saved.                              |
| `data[].title`          | body | string                | —      | Title is the display name, e.g. "Mutual Non-Disclosure Agreement".                                                  |
| `data[].version`        | body | integer (int64)       | —      | Version is which version of this template the caller's org resolves to.                                             |
| `disclaimer`            | body | string                | —      | Disclaimer is the boundary made visible on the wire: Hanzo Legal is document tooling, not legal advice.             |

Failure carries the platform error shape — see [Errors](https://docs.hanzo.ai/docs/errors).

## Examples

**CLI**

```bash
hanzo legal templates list
```

**SDK**

**.ts**

```ts
import { Configuration, LegalApi } from 'hanzoai';

const api = new LegalApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getLegalTemplates();
```

**.py**

```python
from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import LegalApi

client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = LegalApi(client).get_legal_templates()
```

**.go**

```go
cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)

resp, _, err := client.LegalAPI.GetLegalTemplates(context.Background()).Execute()
if err != nil {
	return err
}
```

**.rs**

```rust
use hanzo_client::apis::{configuration::Configuration, legal_api};

let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();

let result = legal_api::get_legal_templates(&cfg, Default::default()).await?;
```

**.java**

```java
import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.LegalApi;

ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));

var result = new LegalApi(client).getLegalTemplates();
```

**HTTP**

```bash
curl https://api.hanzo.ai/v1/legal/templates \
  -H "Authorization: Bearer $HANZO_API_KEY"
```

**MCP**

MCP reaches **legal** through the `legal` tool, which names its 10 operations with its own verbs — this one among them, under a name only MCP declares. `describe` explains any of them:

```bash
curl -X POST https://api.hanzo.ai/v1/mcp \
  -H "Content-Type: application/json" \
  -d '{
       "jsonrpc": "2.0",
       "id": 1,
       "method": "tools/call",
       "params": {
         "name": "describe",
         "arguments": {
           "op": "list_legal_documents"
         }
       }
     }'
```

---

[Legal API](https://docs.hanzo.ai/docs/openapi/legal) · [All Hanzo APIs](https://docs.hanzo.ai/docs/openapi) · [Interactive reference](https://docs.hanzo.ai/docs/openapi/reference)
