---
title: "Create CVM from provision"
method: POST
path: "/api/v1/cvms"
tags: ["CVMs"]
---

# Create CVM from provision

`POST /api/v1/cvms`

Creates a CVM using cached provision data from /cvms/provision. Requires compose_hash from the provision response.

## Request body

- CreateTappRequest
  - `app_id` string, required — The calculated app ID from compose file.
  - `compose_hash` string, required — The compose hash of the app compose file.
  - `encrypted_env` string, nullable — The encrypted environment variables.
  - `kms_id` string, nullable — The KMS ID.
  - `contract_address` string, nullable — The contract address.
  - `deployer_address` string, nullable — The deployer address.
  - `env_keys` string[], nullable — The environment variables to use for the app.

## Response `200`

Created CVM record with teepod info

- VM
  - `id` integer, required
  - `name` string, required
  - `status` string, required
  - `teepod_id` integer, required
  - `teepod` TeepodMeta
    - `id` integer, required
    - `name` string, required
  - `user_id` integer, nullable
  - `app_id` string, required
  - `vm_uuid` string, nullable
  - `instance_id` string, nullable
  - `app_url` string, nullable
  - `base_image` string, nullable
  - `vcpu` integer, required
  - `memory` integer, required
  - `disk_size` integer, required
  - `manifest_version` integer, nullable
  - `version` string, nullable
  - `runner` string, nullable
  - `docker_compose_file` string, nullable
  - `features` string[], nullable
  - `created_at` string, date-time, required
  - `encrypted_env_pubkey` string, nullable

## Other responses

- `400` — Invalid payload or provision data expired
- `401` — Authentication required
- `422` — Provision data not found

---

[API](https://skmtc.net/phala/apis/phala-cloud-api.md) · [All operations](https://skmtc.net/phala/apis/phala-cloud-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/phala/phala-cloud-api/versions/83c6ae62e860/schema)
