---
title: "Register a Template"
method: POST
path: "/template"
tags: ["template"]
---

# Register a Template

`POST /template`

## Request

- Base URL: `https://api-ch-gva-2.exoscale.com/v2`
- URL: `https://api-ch-gva-2.exoscale.com/v2/template`
- Auth: none declared
- TypeScript: <https://skmtc.dev/exoscale/apis/exoscale-api/docs/template/post.ts> (a function with typed inputs; its response is checked against the schema)

## Request body

- object
  - `application-consistent-snapshot-enabled` boolean: Template with support for Application Consistent Snapshots
  - `maintainer` string: Template maintainer
  - `description` string: Template description
  - `ssh-key-enabled` boolean, required: Enable SSH key-based login
  - `name` string, required: Template name
  - `default-user` string: Template default user
  - `size` integer: Template size
  - `password-enabled` boolean, required: Enable password-based login
  - `build` string: Template build
  - `checksum` string, required: Template MD5 checksum
  - `boot-mode` 'legacy' | 'uefi': Boot mode (default: legacy)
  - `url` string, required: Template source URL
  - `version` string: Template version

## Response `200`

200

- Operation: Operation
  - `id` string, uuid: Operation ID
  - `reason` 'incorrect' | 'unknown' | 'unavailable' | 'forbidden' | 'busy' | 'fault' | 'partial' | 'not-found' | 'interrupted' | 'unsupported' | 'conflict': Operation failure reason
  - `reference` object: Related resource reference
    - `id` string, uuid: Reference ID
    - `link` string: Link to the referenced resource
    - `command` string: Command name
  - `message` string: Operation message
  - `state` 'failure' | 'pending' | 'success' | 'timeout': Operation status

---

[API](https://skmtc.dev/exoscale/apis/exoscale-api.md) - [All operations](https://skmtc.dev/exoscale/apis/exoscale-api/llms.txt) - [OpenAPI document](https://skmtc.dev/exoscale/apis/exoscale-api/revisions/63da6f74c845?raw)
