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

# Workspace Templates

> Read and replace a workspace's templates manifest, which defines the metrics and charts that new projects in the workspace start with.

## Schema introspection

Every command below with arguments supports two read-only flags for tooling and AI agents:

* `--show-file-schema`: print the JSON Schema for the full request object (the format `--filename` accepts).
* `--show-argument-schema <flag-name>`: print the JSON Schema for one argument's value. Pass the kebab flag name **without** the leading `--` (e.g. `workspace-id`, not `--workspace-id`).

Both write pure JSON to stdout and never call the API. They cannot be combined with any other command-specific flag.

## `get`

Get a workspace's templates manifest

Return the latest version of a workspace's templates manifest: the YAML that defines the
metrics and charts that new projects in the workspace start with. The workspace is
identified by the `workspace_id` path parameter alone. The `x-hh-workspace-id` header does
not participate.

A workspace starts with a copy of its organization's manifest. Its projects use the
workspace's manifest, together with the organization's only when the workspace's manifest
sets `config.merge_strategy` to `merge`.

### Usage

```sh theme={null}
honeyhive workspace-templates get [options]
```

**Accepted keys:** [Control plane fine-grained API key](https://docs.honeyhive.ai/v2/workspace/api-keys.md#key-types)

### Options

| Flag | Type | Required | Description |
| - | - | - | - |
| `--workspace-id` | string | yes | The unique identifier of the workspace |

Also supports `--show-file-schema`, `--show-argument-schema <flag-name>`, and `--filename`. See [Schema introspection](#schema-introspection) for details.

## `update`

Replace a workspace's templates manifest

Save a new version of a workspace's templates manifest, which becomes the latest version.
It decides the metrics and charts that projects created afterward in the workspace start
with. Existing projects are not changed. The workspace is identified by the `workspace_id`
path parameter alone. The `x-hh-workspace-id` header does not participate.

A workspace manifest cannot define `workspace_templates`.

When an API key makes the request and the workspace's latest version already has this
content, nothing is saved and that version is returned, so applying the same manifest
repeatedly is safe.

### Usage

```sh theme={null}
honeyhive workspace-templates update [options]
```

**Accepted keys:** [Control plane fine-grained API key](https://docs.honeyhive.ai/v2/workspace/api-keys.md#key-types)

### Options

| Flag | Type | Required | Description |
| - | - | - | - |
| `--workspace-id` | string | yes | The unique identifier of the workspace |
| `--yaml-content` | string | yes | The templates manifest, as YAML. It must parse and pass templates manifest validation for a workspace, which forbids `workspace_templates`. |

Also supports `--show-file-schema`, `--show-argument-schema <flag-name>`, and `--filename`. See [Schema introspection](#schema-introspection) for details.


## Related topics

- [Templates](https://docs.honeyhive.ai/v2/workspace/templates.md)
- [Workspace Templates Methods](https://docs.honeyhive.ai/v2/control-plane-sdk-reference/typescript/ref/workspace-templates/index.md)
- [Replace a workspace's templates manifest](https://docs.honeyhive.ai/v2/control-plane-api-reference-autogen/workspace-templates/replace-a-workspaces-templates-manifest.md)


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