Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.
Request for provisioning a DStack app with automatic resource matching.
Most fields are optional and will be automatically determined by the resource
matching logic in preflight_dstack_app. Only compose_file and name are required.
A whole app-compose JSON file, sent instead of compose_file. Phala Cloud parses it with the same rules as compose_file and serializes it the same way, so the deployed bytes and compose hash match the structured form, not the sent bytes. Needs the compose_advanced feature flag.
For OS images before 0.6.0, True selects dev and False selects non-dev. Ignored for unified images (0.6.0 or later). When None, inferred from the image name or defaults to dev.
Optional nonce for deterministic app_id generation. When provided, app_id must also be provided. System will verify: app_id == get_create_address(team_wallet, nonce)
Allowed encrypted environment variable names. When compose_file does not declare allowed_envs, or sends an empty list, these names populate compose_file.allowed_envs for the guest allowlist.
Deploy without dstack-gateway. Turns the gateway off in compose_file when it does not set gateway_enabled/tproxy_enabled; rejected when compose_file enables the gateway.
Key provider mode. 'local' enables the local key provider in compose_file (and turns off KMS and the gateway where compose_file does not set them); rejected when compose_file sets key_provider or local_key_provider_enabled the other way.
Platform-owned init scripts to run on every boot, as slugs: docker_cleanup erases all local container-runtime stores (images, volumes, all containerd namespaces) and needs OS 0.6.x, ext4 storage and the docker-compose runner; env_merge merges encrypted env on boot, needs OS 0.6.0 or newer and the managed_env_create feature flag. Phala Cloud fixes the run order (docker_cleanup, then env_merge). The deprecated object form {"env_merge": bool} is still accepted. GET /cvms/{cvm_id}/init-scripts shows what an existing CVM runs.
Launch token (at least 32 bytes) the guest requires on every boot before key provisioning. Phala Cloud writes its hash into compose_file.requirements.launch_token_hash and stores the token on the app. For an existing app it must equal the app's token. Needs dstack OS 0.6.0 or newer. Phala Cloud and the node operator can read the token: it protects only against parties who know the public compose.
Gate the CVM with a launch token Phala Cloud generates for a new app, or with the app's existing token. A newly generated token is returned once, in the create (commit) response.
Restrict the guest agent (port 8090) to Phala Cloud by sending false. Omit it to leave the app unchanged; a new app starts unrestricted. Sending true never relaxes an existing restriction: it is rejected with ERR-03-030 when the app is already restricted, because relaxing requires Phala Cloud support.
Opaque key/value metadata for host-side tooling, stored by the dstack VMM with the VM. Not passed to the guest, not measured, and not part of the compose hash: attestation does not cover it, so do not rely on it for security. A non-empty map requires the cvm_annotations feature flag (ERR-03-049) and a node running dstack VMM 0.6.1 or newer (ERR-03-050). Keys must not be empty. Phala Cloud keeps no copy as CVM state and never copies or restores it (a replica starts without it, a relocated CVM keeps what its VMM manifest carries); this create request is recorded in the audit log.
Show child attributes
Response
Prepare returns provision data with a token; commit returns the created CVM
ProvisionDstackAppResponseV2
CreatedVM
Response from DStack app preflight checks containing provisioning details.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Phala","colors":{"primary":"#527a08","light":"#527a08","dark":"#cdfa50"},"logo":{"light":"https://mintcdn.com/phalanetwork-1606097b/Y2wR1-jOsoYpAL6q/images/phala-light.png?fit=max\u0026auto=format\u0026n=Y2wR1-jOsoYpAL6q\u0026q=85\u0026s=fb4f438a36865810867d188289681376","dark":"https://mintcdn.com/phalanetwork-1606097b/Y2wR1-jOsoYpAL6q/images/phala-dark.png?fit=max\u0026auto=format\u0026n=Y2wR1-jOsoYpAL6q\u0026q=85\u0026s=c80d03f4a9b6db1a9aa8f435a980a7a3"},"favicon":"https://mintcdn.com/phalanetwork-1606097b/RUscSf7Rplq7j02n/favicon.ico?fit=max\u0026auto=format\u0026n=RUscSf7Rplq7j02n\u0026q=85\u0026s=701b1391404cffa588fcc80dd945d79e","navbar":{"links":[{"href":"https://github.com/Phala-Network/phala-cloud","label":"GitHub"},{"href":"https://cloud.phala.com/login","label":"Log in"}],"primary":{"type":"button","label":"API Dashboard","href":"https://cloud.phala.com"}},"footer":{"socials":{"discord":"https://phala.com/discord","github":"https://phala.com/github","linkedin":"https://phala.com/linkedin","x":"https://phala.com/x"},"links":[{"header":"Phala Cloud","items":[{"label":"Getting Started","href":"https://docs.phala.network/phala-cloud/getting-started/overview"},{"label":"TEEs, Attestation \u0026 Zero Trust Security","href":"https://docs.phala.network/phala-cloud/attestation/overview"},{"label":"Phala Cloud User Guides","href":"https://docs.phala.network/phala-cloud/phala-cloud-user-guides/create-cvm/overview"},{"label":"Be Production Ready","href":"https://docs.phala.network/phala-cloud/be-production-ready/overview"},{"label":"Use Cases","href":"https://docs.phala.network/phala-cloud/use-cases/overview"},{"label":"References","href":"https://docs.phala.network/phala-cloud/references/overview"},{"label":"Private AI","href":"https://docs.phala.network/phala-cloud/gpu-tee/llm-in-tee"},{"label":"FAQs","href":"https://docs.phala.network/phala-cloud/faqs"}]},{"header":"dstack","items":[{"label":"Overview","href":"https://docs.phala.network/dstack/overview"},{"label":"Local Development","href":"https://docs.phala.network/dstack/local-development"},{"label":"Getting Started","href":"https://docs.phala.network/dstack/getting-started"},{"label":"Hardware Requirements","href":"https://docs.phala.network/dstack/hardware-requirements"},{"label":"Acknowledgement","href":"https://docs.phala.network/dstack/acknowledgement"},{"label":"FAQs","href":"https://docs.phala.network/dstack/faqs"},{"label":"Design Documents","href":"https://docs.phala.network/dstack/design-documents"},{"label":"Cloud Overview","href":"https://docs.phala.network/dstack-cloud/overview"},{"label":"Cloud Quick Start","href":"https://docs.phala.network/dstack-cloud/get-started"}]},{"header":"Private AI","items":[{"label":"LLM in GPU TEE","href":"https://docs.phala.network/phala-cloud/confidential-ai/overview"},{"label":"GPU TEE Inference API","href":"https://docs.phala.network/phala-cloud/confidential-ai/confidential-model/confidential-ai-api"},{"label":"Benchmark","href":"https://docs.phala.network/phala-cloud/confidential-ai/benchmark"},{"label":"FAQs","href":"https://docs.phala.network/phala-cloud/confidential-ai/faqs"}]},{"header":"Network","items":[{"label":"Overview","href":"https://docs.phala.network/network/index"},{"label":"Phala Network","href":"https://docs.phala.network/network/overview/phala-network"},{"label":"Staking","href":"https://docs.phala.network/network/overview/phala-staking"},{"label":"Compute Providers","href":"https://docs.phala.network/network/compute-providers/introduction"}]}]},"seo":{"metatags":{"author":"Phala Cloud","canonical":"https://docs.phala.com","category":"Technology","distribution":"global","keywords":"Phala Cloud, TEE, Trusted Execution Environment, Confidential Computing, Private AI, confidential AI, GPU TEE, Intel TDX, dstack, blockchain, privacy-preserving computing, secure cloud, attestation","language":"en","og:image":"https://raw.githubusercontent.com/Phala-Network/phala-docs/main/images/phala-docs-og.png","og:image:alt":"Phala Cloud — Confidential Computing \u0026 GPU TEE for AI","og:image:width":"1200","og:image:height":"630","og:site_name":"Phala Docs","og:type":"website","og:title":"Phala Cloud Documentation — Private AI on TEE","og:description":"Deploy confidential AI applications on Phala Cloud with hardware-level privacy via Intel TDX, NVIDIA H100 GPU TEE, and verifiable attestation.","robots":"index, follow","twitter:card":"summary_large_image","twitter:creator":"@PhalaNetwork","twitter:site":"@PhalaNetwork","twitter:image":"https://raw.githubusercontent.com/Phala-Network/phala-docs/main/images/phala-docs-og.png","twitter:title":"Phala Cloud Documentation — Private AI on TEE","twitter:description":"Deploy confidential AI applications on Phala Cloud with hardware-level privacy via Intel TDX, NVIDIA H100 GPU TEE, and verifiable attestation."},"indexing":"all"},"icons":{"library":"lucide"},"styling":{"codeblocks":"system","latex":true},"integrations":{"ga4":{"measurementId":"G-RHRW9RL5LG"},"gtm":{"tagId":"GTM-TX3VQZP"}},"errors":{"404":{"redirect":false}},"contextual":{"options":["copy","view","chatgpt","claude","mcp"],"display":"header"},"thumbnails":{"background":"https://mintcdn.com/phalanetwork-1606097b/Z_xV6g4Cdei2rfqm/images/phala-docs-og.png?fit=max\u0026auto=format\u0026n=Z_xV6g4Cdei2rfqm\u0026q=85\u0026s=e0d65106aa4afa7766452b497d5ec9ca"},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"phalanetwork-1606097b","hasAudioNarration":false,"actualSubdomain":"phalanetwork-1606097b","customDomains":["docs.phala.com"],"gitSource":{"type":"github","owner":"phala-network","repo":"phala-docs","deployBranch":"main","contentDirectory":"","isPrivate":false,"mountPath":"","label":""},"feedback":{"thumbs":true,"edits":true,"issues":true},"entitlements":{},"buildId":"6aef3b3d6d3ec31a32f4c59c","clientVersion":"0.0.4076","searchFilterCounts":[{"language":"default","tag":"Phala Cloud","count":650},{"language":"default","tag":"API \u0026 SDK","count":163},{"language":"default","tag":"Phala Cloud API","count":110},{"language":"default","tag":"Private AI","count":100},{"language":"default","tag":"Phala Cloud CLI","count":84},{"language":"default","tag":"CVMs","count":54},{"language":"default","tag":"Resources","count":42},{"language":"default","tag":"dstack Cloud","count":22},{"language":"default","tag":"JavaScript SDK","count":22},{"language":"default","tag":"Apps","count":20}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"fonts.css","content":"@font-face{font-family:\"ABCArizonaFlare\";src:url(\"/fonts/exa/ABCArizonaFlare-Regular.woff2\") format(\"woff2\");font-style:normal;font-weight:400 700;font-display:block}@font-face{font-family:\"ABCDiatype\";src:url(\"/fonts/exa/ABCDiatype-Regular.woff2\") format(\"woff2\");font-style:normal;font-weight:400 700;font-display:block}@font-face{font-family:\"SuisseIntlMono\";src:url(\"/fonts/exa/SuisseIntlMono-Regular-WebTrial.woff2\") format(\"woff2\");font-style:normal;font-weight:400 700;font-display:block}@font-face{font-family:\"ABCArizonaFlare Fallback\";src:local(\"Georgia\"), local(\"Times New Roman\");size-adjust:94%;ascent-override:95%;descent-override:22%;line-gap-override:0%}@font-face{font-family:\"ABCDiatype Fallback\";src:local(\"Trebuchet MS\"), local(\"Arial\");size-adjust:97%;ascent-override:92%;descent-override:23%;line-gap-override:0%}@font-face{font-family:\"SuisseIntlMono Fallback\";src:local(\"SFMono-Regular\"), local(\"Consolas\"), local(\"Menlo\"),\n local(\"Liberation Mono\");size-adjust:100%;ascent-override:90%;descent-override:22%;line-gap-override:0%}:root{--v3-heading: \"ABCArizonaFlare\", \"ABCArizonaFlare Fallback\", Georgia, serif;--v3-body: \"ABCDiatype\", \"ABCDiatype Fallback\", \"Trebuchet MS\", Arial,\n sans-serif;--v3-mono: \"SuisseIntlMono\", \"SuisseIntlMono Fallback\", \"SFMono-Regular\",\n Consolas, monospace}body,input,button,select,textarea{font-family:var(--v3-body)}h1,h2{font-family:var(--v3-heading);font-weight:400;letter-spacing:0}h3,h4,h5,h6{font-family:var(--v3-body);font-weight:600;letter-spacing:0}code,pre,kbd,samp,.font-mono{font-family:var(--v3-mono)}"},{"filePath":"style.css","content":":root{--base-50: oklch(0.983 0.0034 145.55);--base-100: oklch(0.9691 0.0037 146.57);--base-200: oklch(0.9258 0.0048 147.01);--base-300: oklch(0.869 0.0054 148);--base-400: oklch(0.7067 0.0061 149.29);--base-500: oklch(0.5535 0.0066 150.55);--base-600: oklch(0.4449 0.0065 151.33);--base-700: oklch(0.3731 0.0059 150.75);--base-800: oklch(0.2731 0.0051 150.35);--base-900: oklch(0.2123 0.0048 151.01);--base-950: oklch(0.1386 0.0044 150.49);--base-1000: oklch(0.0909 0.0041 150.95);--primary-300: #cdfa50;--primary-500: oklch(0.7708 0.2308 126.52);--primary-600: oklch(0.6514 0.1967 127.14);--primary-700: oklch(0.5343 0.1568 126.91);--phala-blue-50: #f0f2ff;--phala-blue-100: #d5dbf8;--phala-blue-200: #bfc8f0;--phala-blue-300: #aabbff;--phala-blue-500: #6b80cc;--phala-blue-900: #2d3250;--phala-purple-300: #b88fd0;--phala-purple-500: #7e3daf;--phala-orange-300: #f5902c;--surface-marketing: #f7f8f3;--surface-marketing-cool: #f0f1ec;--surface-marketing-light: #fbfcf8;--surface-trust-path: #070908;--surface-trust-card: #101310;--radius: 4px}button,a[role=\"button\"],.btn,[class*=\"button\"]{border-radius:4px!important}[class*=\"Card\"],[class*=\"Callout\"],[class*=\"Note\"],[class*=\"Warning\"],[class*=\"Tip\"],[class*=\"Info\"],[class*=\"Frame\"],[class*=\"Update\"],pre,.code,.callout,.card{border-radius:0!important}[class*=\"badge\"]:not([class*=\"dot\"]),[class*=\"Badge\"]:not([class*=\"Dot\"]),[class*=\"pill\"],[class*=\"Pill\"]{border-radius:4px!important}[class*=\"Card\"]:not([class*=\"card-group\"]),[class*=\"Callout\"],[class*=\"Note\"],[class*=\"Warning\"],[class*=\"Tip\"],[class*=\"Info\"],[class*=\"Frame\"],[class*=\"Update\"],.callout,.card{box-shadow:none!important;border-width:1px!important}.card-group,[class*=\"card-group\"]{border:0!important;background:transparent!important;box-shadow:none!important;padding:0!important;border-radius:0!important;gap:1px!important}a[role=\"button\"],.btn,button.button,button[data-component=\"button\"]{min-height:44px;padding-inline:1rem;border-radius:4px!important;box-shadow:none!important;font-family:var(--v3-body, \"ABCDiatype\", \"Trebuchet MS\", Arial, sans-serif);font-weight:500;letter-spacing:0;transition:opacity 150ms ease, background-color 150ms ease,\n border-color 150ms ease}a[role=\"button\"]:hover,.btn:hover,button.button:hover,button[data-component=\"button\"]:hover{opacity:0.9;box-shadow:none!important}button{border-radius:4px!important}@media (min-width: 1024px){#sidebar,aside[id=\"sidebar\"],aside.sidebar,[class*=\"sidebar-content\"]{padding-top:1rem!important}}.sidebar-group-header{font-family:var(--v3-body, \"ABCDiatype\", sans-serif)!important;font-size:14px!important;font-weight:600!important;letter-spacing:0!important;color:var(--base-800)!important;margin-top:1.75rem!important;margin-bottom:0.5rem!important}.sidebar-group-header:first-child{margin-top:0!important}.dark .sidebar-group-header,[data-theme=\"dark\"] .sidebar-group-header{color:var(--base-100)!important}li[id^=\"/\"]>a,li[data-title]>a,.sidebar-group li>a,.sidebar-group li>button{font-size:13.5px!important;font-weight:400!important;color:var(--base-600)!important;border-radius:4px!important;outline:0!important;outline-offset:0!important}li[id^=\"/\"]>a:hover,li[data-title]>a:hover,.sidebar-group li>a:hover,.sidebar-group li>button:hover{color:var(--primary-700)!important;background-color:rgba(0, 0, 0, 0.03)!important}li[id^=\"/\"]>a:hover svg,li[data-title]>a:hover svg,.sidebar-group li>a:hover svg,.sidebar-group li>button:hover svg{color:var(--primary-700)!important;background-color:var(--primary-700)!important}.dark li[id^=\"/\"]>a,.dark li[data-title]>a,[data-theme=\"dark\"] li[id^=\"/\"]>a{color:var(--base-400)!important}.dark li[id^=\"/\"]>a:hover,.dark li[data-title]>a:hover,[data-theme=\"dark\"] li[id^=\"/\"]>a:hover{color:var(--primary-300)!important;background-color:rgba(255, 255, 255, 0.05)!important}li[data-active=\"true\"]>a,a[aria-current=\"page\"]{background-color:var(--surface-marketing-cool)!important;background-image:none!important;color:var(--base-800)!important;font-weight:500!important;text-shadow:none!important;border-radius:4px!important;--tw-bg-opacity: 1 !important}li[data-active=\"true\"]>a:hover{background-color:var(--surface-marketing-cool)!important;color:var(--base-800)!important}.dark li[data-active=\"true\"]>a,.dark a[aria-current=\"page\"],[data-theme=\"dark\"] li[data-active=\"true\"]>a{background-color:rgba(255, 255, 255, 0.08)!important;color:var(--base-100)!important}.nav-tabs-item[data-active=\"true\"],a.nav-tabs-item[data-active=\"true\"]{color:var(--primary-700)!important}@media (min-width: 768px){#table-of-contents-layout{display:flex!important}}#table-of-contents-layout{border-left:1px solid var(--base-200);padding-left:1.25rem!important}.dark #table-of-contents-layout,[data-theme=\"dark\"] #table-of-contents-layout{border-left-color:var(--base-800)}#table-of-contents h2{font-size:14px!important;margin:0!important}#table-of-contents>button,#table-of-contents h2 button,#table-of-contents-layout #table-of-contents>:first-child:not(nav):not(ul):not(ol),#table-of-contents-layout>:first-child:not(:has(#table-of-contents)):not(nav):not(ul):not(ol),#table-of-contents-layout>:first-child>:first-child:not(#table-of-contents):not(nav):not(ul):not(ol){font-family:var(--font-sans, \"Inter\", system-ui, sans-serif)!important;font-size:14px!important;line-height:1.25rem!important;font-weight:500!important;letter-spacing:0!important;text-transform:none!important;color:var(--base-600)!important}#table-of-contents-layout #table-of-contents>:first-child:not(nav):not(ul):not(ol) :is(span,div,p,h2,h3,h4,h5,h6),#table-of-contents-layout>:first-child:not(:has(#table-of-contents)):not(nav):not(ul):not(ol) :is(span,div,p,h2,h3,h4,h5,h6),#table-of-contents-layout>:first-child>:first-child:not(#table-of-contents):not(nav):not(ul):not(ol) :is(span,div,p,h2,h3,h4,h5,h6){font:inherit!important;letter-spacing:inherit!important;text-transform:inherit!important;color:inherit!important;line-height:inherit!important}.toc-item>a{font-size:13px!important;letter-spacing:0!important;text-transform:none!important;font-family:var(--font-sans, \"Inter\", system-ui, sans-serif)!important;color:var(--base-600)!important}.toc-item>a:hover{color:var(--base-800)!important}.toc-item.is-active>a,.toc-item[data-active=\"true\"]>a,.toc a[aria-current=\"true\"]{color:var(--primary-700)!important;font-weight:500!important}.toc-item[data-depth=\"1\"]{padding-left:1rem}.dark .toc-item>a,[data-theme=\"dark\"] .toc-item>a{color:var(--base-400)!important}.eyebrow,.eyebrow.text-primary,[class*=\"eyebrow\"][class*=\"text-primary\"]{color:var(--primary-600)!important}.dark .eyebrow,.dark .eyebrow.text-primary,[data-theme=\"dark\"] .eyebrow{color:var(--primary-300)!important}article .text-primary,article [class~=\"text-primary\"],article [class*=\"text-primary\"]:not([class*=\"dark:\"]),main .text-primary,main [class~=\"text-primary\"]{color:var(--primary-700)!important}html:not(.dark) body:not(.dark) :is(main,article) [class*=\"cdfa50\"],html:not(.dark) body:not(.dark) :is(main,article) [style*=\"cdfa50\"i]{color:var(--primary-700)!important}article .bg-primary,article [class~=\"bg-primary\"],article [class*=\"bg-primary\"]:not([class*=\"dark:\"]),main .bg-primary,main [class~=\"bg-primary\"]{background-color:var(--primary-700)!important}.dark article .text-primary,.dark article [class~=\"text-primary\"],[data-theme=\"dark\"] article .text-primary,[data-theme=\"dark\"] article [class~=\"text-primary\"],.dark main .text-primary,[data-theme=\"dark\"] main .text-primary{color:var(--primary-300)!important}.dark article .bg-primary,.dark article [class~=\"bg-primary\"],[data-theme=\"dark\"] article .bg-primary,[data-theme=\"dark\"] article [class~=\"bg-primary\"],.dark main .bg-primary,[data-theme=\"dark\"] main .bg-primary{background-color:var(--primary-300)!important}main,article,[class*=\"content\"],[class*=\"Content\"]{max-width:100%}:is(main,article) h1{font-size:32px!important;line-height:1.16!important;font-weight:500!important;letter-spacing:0!important;margin-bottom:1rem!important}:is(main,article) h2{font-size:22px!important;line-height:1.26!important;font-weight:500!important;letter-spacing:0!important;margin-top:2.25rem!important;margin-bottom:0.85rem!important}:is(main,article) h3{font-size:18px!important;line-height:1.3!important;font-weight:600!important;letter-spacing:0!important;margin-top:1.75rem!important;margin-bottom:0.65rem!important}:is(main,article) h4,:is(main,article) h5,:is(main,article) h6{font-weight:600!important;letter-spacing:0!important}p,li{font-size:15px;line-height:1.65}:not(pre)>code{font-family:var(--v3-mono, \"SuisseIntlMono\", monospace);font-size:0.92em;border:1px solid var(--base-200);border-radius:2px;padding:1px 5px}pre{border-radius:0!important;font-family:var(--v3-mono, \"SuisseIntlMono\", monospace);font-size:13px;line-height:1.6}.code-block,div[class~=\"code-block\"],.code-group,div[class~=\"code-group\"]{border-radius:0!important;box-shadow:none!important;overflow:hidden!important}.code-block-background,[class*=\"code-block-background\"],.code-group{border-radius:0!important;box-shadow:none!important;background-color:var(--phala-blue-50)!important}.code-block-background,[class*=\"code-block-background\"]{border:0!important}.dark .code-block-background,.dark .code-group,[data-theme=\"dark\"] .code-block-background,[data-theme=\"dark\"] .code-group{background-color:var(--surface-trust-card)!important}.code-group [role=\"tab\"][data-state=\"active\"],.code-group [role=\"tab\"][aria-selected=\"true\"]{color:var(--primary-600)!important}.code-group [role=\"tab\"][data-state=\"active\"]>div:first-child{color:var(--primary-600)!important}.code-group [role=\"tab\"][data-state=\"active\"]>div.absolute,.code-group [role=\"tab\"][data-state=\"active\"]>div[class*=\"absolute\"][class*=\"bottom\"]{background-color:var(--primary-600)!important;border-radius:0!important}.dark .code-group [role=\"tab\"][data-state=\"active\"],[data-theme=\"dark\"] .code-group [role=\"tab\"][data-state=\"active\"]{color:var(--primary-300)!important}.dark .code-group [role=\"tab\"][data-state=\"active\"]>div.absolute,[data-theme=\"dark\"] .code-group [role=\"tab\"][data-state=\"active\"]>div.absolute{background-color:var(--primary-300)!important}[data-fade-overlay]{display:none!important}.card{border-radius:0!important;box-shadow:none!important;--tw-ring-shadow: 0 0 #0000 !important;--tw-ring-offset-shadow: 0 0 #0000 !important}.card:hover{box-shadow:none!important;border-color:var(--primary-600)!important}.card svg.bg-primary,.card svg[class*=\"bg-primary\"]:not([class*=\"primary-light\"]),.card .text-primary{background-color:var(--primary-600)!important;color:var(--primary-600)!important}.dark .card svg.bg-primary,.dark .card svg[class*=\"bg-primary\"],[data-theme=\"dark\"] .card svg.bg-primary{background-color:var(--primary-300)!important;color:var(--primary-300)!important}.callout{border-radius:0!important;background-color:var(--card, #ffffff)!important;border-width:0!important;border-left:4px solid var(--phala-blue-500)!important;padding:1rem 1.25rem!important;box-shadow:none!important}.callout[data-callout-type=\"warning\"]{border-left-color:var(--phala-orange-300)!important}.callout[data-callout-type=\"info\"]{border-left-color:var(--phala-blue-500)!important}.callout[data-callout-type=\"tip\"]{background-color:var(--phala-blue-300)!important;border-left-color:var(--phala-blue-500)!important}.callout [data-component-part=\"callout-content\"],.callout [data-component-part=\"callout-content\"] *{color:var(--base-800)!important}.callout [data-component-part=\"callout-content\"]>span:first-child>strong:only-child{font-family:var(--v3-mono, \"SuisseIntlMono\", monospace);font-size:11px;font-weight:400;letter-spacing:0.08em;text-transform:uppercase;display:block;margin-bottom:0.25rem;color:var(--base-600)!important}.callout[data-callout-type=\"warning\"] [data-component-part=\"callout-content\"] strong{font-weight:400}.callout [data-component-part=\"callout-icon\"] svg{color:var(--base-600)!important;opacity:0.7}a[href*=\"cloud.phala.com\"]>span.absolute,a[href*=\"cloud.phala.com\"]>span[class*=\"absolute\"][class*=\"inset-0\"]{background-color:var(--primary-300)!important;background-image:none!important;border-radius:4px!important;box-shadow:none!important}a[href*=\"cloud.phala.com\"] span[class*=\"text-white\"],a[href*=\"cloud.phala.com\"] .z-10{color:#000!important}a[href*=\"cloud.phala.com\"] span[class*=\"text-white\"]~svg,a[href*=\"cloud.phala.com\"] svg.text-white\\/90,a[href*=\"cloud.phala.com\"] svg[class*=\"text-white\"],a[href*=\"cloud.phala.com\"] svg path{color:#000!important;stroke:#000!important}a[href*=\"cloud.phala.com\"][target=\"_blank\"]{font-family:var(--v3-body, \"ABCDiatype\", sans-serif);font-weight:500;letter-spacing:0}a[href*=\"cloud.phala.com\"]:hover>span[class*=\"absolute\"]{opacity:0.9!important}[class*=\"Update\"] [class*=\"label\"],[class*=\"update\"] [class*=\"label\"],[class*=\"UpdateLabel\"],[class*=\"changelog\"] h2,[class*=\"Changelog\"] h2{font-family:var(--v3-mono, \"SuisseIntlMono\", monospace);font-size:12px;font-weight:400;letter-spacing:0.08em;text-transform:uppercase}table{border-collapse:collapse;border:1px solid var(--base-200)}th,td{border:1px solid var(--base-200);padding:8px 12px;font-size:14px}th{font-family:var(--v3-mono, \"SuisseIntlMono\", monospace);font-size:11px;font-weight:400;letter-spacing:0.08em;text-transform:uppercase}"}],"page":{"pagePath":"api-reference/cvms/create-cvm-two-phase-on-one-path","slug":"/api-reference/cvms/create-cvm-two-phase-on-one-path","pageMetadata":{"title":"Create CVM (two-phase on one path)","description":"Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms","href":"/api-reference/cvms/create-cvm-two-phase-on-one-path","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"codeStyling":"system","config":{},"pageMetadata":{"title":"Create CVM (two-phase on one path)","description":"Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms","href":"/api-reference/cvms/create-cvm-two-phase-on-one-path","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":["/_mintlify/custom/phalanetwork-1606097b/2c201375ed6be1da/scripts/generate-cli-docs.js"],"openApiReferenceData":{"operation":{"tags":["CVMs"],"summary":"Create CVM (two-phase on one path)","description":"Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.","operationId":"handle_create_cvm_api_v1_cvms_post","responses":{"200":"7854e775-2b15-4d4e-bed6-2ec70729bb5e","400":"24ab6405-e084-4333-96c6-6c03780d9197","401":"05da74e1-9be6-4fff-b7f1-40ec1b484b7a","403":"4fedf3c9-e630-4dcd-926c-6662a67384ff","409":"c86942b4-91f6-45e9-a21c-d9537772c8be","413":"c09aab8d-a610-4e2a-ad25-fddf668a0997","422":"32e61da3-ce43-40e4-9545-cd94072e542b"},"requestBody":"bedc4498-f0c3-4bcc-a5d8-4d893e6a6b3f","method":"post","type":"path","servers":["f8681adb-18b5-43a6-97a9-503a02fd6af3"],"security":[],"path":"/api/v1/cvms","baseUrlOptions":["https://cloud-api.phala.com"],"title":"Create CVM (two-phase on one path)","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"required":true,"content":{"application/json":{"schema":{"oneOf":[{"type":"object","title":"ProvisionDstackAppRequestV2","description":"Request for provisioning a DStack app with automatic resource matching.\n\nMost fields are optional and will be automatically determined by the resource\nmatching logic in preflight_dstack_app. Only compose_file and name are required.","required":["name","compose_file"],"properties":{"compose_file":{"properties":{"name":{"type":"string","title":"Name","isRequired":true,"uniqueKey":"oneOf.0.compose_file.name","typeLabel":"string"},"allowed_envs":{"items":{"type":"string","uniqueKey":"oneOf.0.compose_file.allowed_envs.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Allowed Envs","uniqueKey":"oneOf.0.compose_file.allowed_envs","typeLabel":"string[]"},"bash_script":{"oneOf":[{"type":"string","title":"Bash Script","uniqueKey":"oneOf.0.compose_file.bash_script.oneOf.0","typeLabel":"string"},{"type":"null","title":"Bash Script","uniqueKey":"oneOf.0.compose_file.bash_script.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.bash_script","typeLabel":"string | null"},"default_gateway_domain":{"oneOf":[{"type":"string","title":"Default Gateway Domain","uniqueKey":"oneOf.0.compose_file.default_gateway_domain.oneOf.0","typeLabel":"string"},{"type":"null","title":"Default Gateway Domain","uniqueKey":"oneOf.0.compose_file.default_gateway_domain.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.default_gateway_domain","typeLabel":"string | null"},"docker_compose_file":{"oneOf":[{"type":"string","title":"Docker Compose File","uniqueKey":"oneOf.0.compose_file.docker_compose_file.oneOf.0","typeLabel":"string"},{"type":"null","title":"Docker Compose File","uniqueKey":"oneOf.0.compose_file.docker_compose_file.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.docker_compose_file","typeLabel":"string | null"},"init_script":{"items":{"type":"string","uniqueKey":"oneOf.0.compose_file.init_script.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Init Script","uniqueKey":"oneOf.0.compose_file.init_script","typeLabel":"string[]"},"key_provider":{"oneOf":[{"type":"string","title":"Key Provider","enum":["none","kms","local","tpm"],"uniqueKey":"oneOf.0.compose_file.key_provider.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","title":"Key Provider","uniqueKey":"oneOf.0.compose_file.key_provider.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.key_provider","typeLabel":"enum\u003cstring> | null"},"key_provider_id":{"oneOf":[{"type":"string","title":"Key Provider Id","uniqueKey":"oneOf.0.compose_file.key_provider_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Key Provider Id","uniqueKey":"oneOf.0.compose_file.key_provider_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.key_provider_id","typeLabel":"string | null"},"kms_enabled":{"type":"boolean","title":"Kms Enabled","default":true,"uniqueKey":"oneOf.0.compose_file.kms_enabled","typeLabel":"boolean"},"local_key_provider_enabled":{"type":"boolean","title":"Local Key Provider Enabled","default":false,"uniqueKey":"oneOf.0.compose_file.local_key_provider_enabled","typeLabel":"boolean"},"manifest_version":{"oneOf":[{"type":"integer","title":"Manifest Version","default":2,"uniqueKey":"oneOf.0.compose_file.manifest_version.oneOf.0","typeLabel":"integer"},{"type":"string","title":"Manifest Version","default":2,"uniqueKey":"oneOf.0.compose_file.manifest_version.oneOf.1","typeLabel":"string"}],"uniqueKey":"oneOf.0.compose_file.manifest_version","typeLabel":"integer | string"},"no_instance_id":{"type":"boolean","title":"No Instance Id","default":false,"uniqueKey":"oneOf.0.compose_file.no_instance_id","typeLabel":"boolean"},"port_policy":{"oneOf":[{"type":"object","title":"PortPolicy","description":"Per-instance port policy declared in app-compose. >= v0.5.9.\n\n``restrict_mode=True`` with an empty ``ports`` list is a valid lockdown.\nField order is alphabetical for compose_hash stability.","properties":{"ports":{"items":{"properties":{"port":{"type":"integer","title":"Port","isRequired":true,"uniqueKey":"oneOf.0.compose_file.port_policy.oneOf.0.ports.items.[INDEX].port","typeLabel":"integer"},"pp":{"type":"boolean","title":"Pp","default":false,"uniqueKey":"oneOf.0.compose_file.port_policy.oneOf.0.ports.items.[INDEX].pp","typeLabel":"boolean"}},"type":"object","required":["port"],"title":"PortAttrs","description":"Per-port gateway attribute. Matches dstack_types::PortAttrs.\n\nField order is alphabetical to match the normalized-compose JSON layout\nthe gateway and KMS use for compose_hash.","uniqueKey":"oneOf.0.compose_file.port_policy.oneOf.0.ports.items.[INDEX]","typeLabel":"PortAttrs · object"},"type":"array","title":"Ports","uniqueKey":"oneOf.0.compose_file.port_policy.oneOf.0.ports","typeLabel":"PortAttrs · object[]"},"restrict_mode":{"type":"boolean","title":"Restrict Mode","default":false,"uniqueKey":"oneOf.0.compose_file.port_policy.oneOf.0.restrict_mode","typeLabel":"boolean"}},"uniqueKey":"oneOf.0.compose_file.port_policy.oneOf.0","typeLabel":"PortPolicy · object"},{"type":"null","uniqueKey":"oneOf.0.compose_file.port_policy.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.port_policy","typeLabel":"PortPolicy · object | null"},"pre_launch_script":{"oneOf":[{"type":"string","title":"Pre Launch Script","uniqueKey":"oneOf.0.compose_file.pre_launch_script.oneOf.0","typeLabel":"string"},{"type":"null","title":"Pre Launch Script","uniqueKey":"oneOf.0.compose_file.pre_launch_script.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.pre_launch_script","typeLabel":"string | null"},"public_logs":{"type":"boolean","title":"Public Logs","default":true,"uniqueKey":"oneOf.0.compose_file.public_logs","typeLabel":"boolean"},"public_sysinfo":{"type":"boolean","title":"Public Sysinfo","default":true,"uniqueKey":"oneOf.0.compose_file.public_sysinfo","typeLabel":"boolean"},"public_tcbinfo":{"type":"boolean","title":"Public Tcbinfo","default":true,"uniqueKey":"oneOf.0.compose_file.public_tcbinfo","typeLabel":"boolean"},"runner":{"type":"string","title":"Runner","default":"docker-compose","uniqueKey":"oneOf.0.compose_file.runner","typeLabel":"string"},"requirements":{"oneOf":[{"type":"object","title":"Requirements","description":"Guest requirements (dstack >= 0.6.0), mirroring ``dstack_types::Requirements``.\n\nOnly keys the caller sent are serialized (see ``AppComposeV2._serialize_requirements``),\nso a default-valued key sent explicitly is measured and an unsent key is never added.\nFields are declared alphabetically to match the canonical JSON layout.","properties":{"ephemeral_data_disk":{"type":"boolean","title":"Ephemeral Data Disk","default":false,"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.ephemeral_data_disk","typeLabel":"boolean"},"gpu_policy":{"properties":{"allow_debug":{"type":"boolean","title":"Allow Debug","default":false,"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy.allow_debug","typeLabel":"boolean"},"allow_devtools":{"type":"boolean","title":"Allow Devtools","default":false,"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy.allow_devtools","typeLabel":"boolean"},"allow_insecure_boot":{"type":"boolean","title":"Allow Insecure Boot","default":false,"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy.allow_insecure_boot","typeLabel":"boolean"},"attest_gpu":{"type":"boolean","title":"Attest Gpu","default":true,"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy.attest_gpu","typeLabel":"boolean"},"rego":{"oneOf":[{"type":"string","title":"Rego","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy.rego.oneOf.0","typeLabel":"string"},{"type":"null","title":"Rego","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy.rego.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy.rego","typeLabel":"string | null"}},"additionalProperties":false,"type":"object","title":"GpuPolicy","description":"Guest-enforced GPU policy; defaults describe behavior, not serialized bytes.","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.gpu_policy","typeLabel":"GpuPolicy · object"},"health_check":{"type":"boolean","title":"Health Check","default":false,"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.health_check","typeLabel":"boolean"},"health_status_file":{"oneOf":[{"type":"string","title":"Health Status File","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.health_status_file.oneOf.0","typeLabel":"string"},{"type":"null","title":"Health Status File","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.health_status_file.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.health_status_file","typeLabel":"string | null"},"launch_token_hash":{"oneOf":[{"type":"string","title":"Launch Token Hash","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.launch_token_hash.oneOf.0","typeLabel":"string"},{"type":"null","title":"Launch Token Hash","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.launch_token_hash.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.launch_token_hash","typeLabel":"string | null"},"platforms":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.platforms.oneOf.0.items.[INDEX]","typeLabel":"string"},"title":"Platforms","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.platforms.oneOf.0","typeLabel":"string[]"},{"type":"null","title":"Platforms","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.platforms.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.platforms","typeLabel":"string[] | null"},"tdx_measure_acpi_tables":{"oneOf":[{"type":"boolean","title":"Tdx Measure Acpi Tables","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.tdx_measure_acpi_tables.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Tdx Measure Acpi Tables","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.tdx_measure_acpi_tables.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0.tdx_measure_acpi_tables","typeLabel":"boolean | null"}},"additionalProperties":false,"uniqueKey":"oneOf.0.compose_file.requirements.oneOf.0","typeLabel":"Requirements · object"},{"type":"null","uniqueKey":"oneOf.0.compose_file.requirements.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.requirements","typeLabel":"Requirements · object | null"},"storage_discard":{"oneOf":[{"type":"boolean","title":"Storage Discard","uniqueKey":"oneOf.0.compose_file.storage_discard.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Storage Discard","uniqueKey":"oneOf.0.compose_file.storage_discard.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.storage_discard","typeLabel":"boolean | null"},"event_log_version":{"oneOf":[{"type":"integer","title":"Event Log Version","enum":[1,2],"uniqueKey":"oneOf.0.compose_file.event_log_version.oneOf.0","typeLabel":"enum\u003cinteger>"},{"type":"null","title":"Event Log Version","uniqueKey":"oneOf.0.compose_file.event_log_version.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.event_log_version","typeLabel":"enum\u003cinteger> | null"},"snapshotter":{"oneOf":[{"type":"string","title":"Snapshotter","enum":["overlayfs","stargz"],"uniqueKey":"oneOf.0.compose_file.snapshotter.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","title":"Snapshotter","uniqueKey":"oneOf.0.compose_file.snapshotter.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.snapshotter","typeLabel":"enum\u003cstring> | null"},"verity_volumes":{"oneOf":[{"type":"array","items":{"properties":{"source":{"type":"string","minLength":1,"pattern":"^[^/]+$","title":"Source","isRequired":true,"uniqueKey":"oneOf.0.compose_file.verity_volumes.oneOf.0.items.[INDEX].source","typeLabel":"string"},"target":{"type":"string","title":"Target","isRequired":true,"uniqueKey":"oneOf.0.compose_file.verity_volumes.oneOf.0.items.[INDEX].target","typeLabel":"string"},"verity_root":{"type":"string","title":"Verity Root","isRequired":true,"uniqueKey":"oneOf.0.compose_file.verity_volumes.oneOf.0.items.[INDEX].verity_root","typeLabel":"string"}},"additionalProperties":false,"type":"object","required":["source","target","verity_root"],"title":"VerityVolume","description":"Read-only dm-verity volume pre-seeded into the CVM (dstack >= 0.6.0).\n\nFields are declared alphabetically to match the canonical JSON layout.","uniqueKey":"oneOf.0.compose_file.verity_volumes.oneOf.0.items.[INDEX]","typeLabel":"VerityVolume · object"},"title":"Verity Volumes","uniqueKey":"oneOf.0.compose_file.verity_volumes.oneOf.0","typeLabel":"VerityVolume · object[]"},{"type":"null","title":"Verity Volumes","uniqueKey":"oneOf.0.compose_file.verity_volumes.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.verity_volumes","typeLabel":"VerityVolume · object[] | null"},"gateway_enabled":{"type":"boolean","title":"Gateway Enabled","default":true,"uniqueKey":"oneOf.0.compose_file.gateway_enabled","typeLabel":"boolean"},"features":{"items":{"type":"string","uniqueKey":"oneOf.0.compose_file.features.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Features","default":["kms","tproxy-net"],"uniqueKey":"oneOf.0.compose_file.features","typeLabel":"string[]"},"salt":{"oneOf":[{"type":"string","title":"Salt","uniqueKey":"oneOf.0.compose_file.salt.oneOf.0","typeLabel":"string"},{"type":"null","title":"Salt","uniqueKey":"oneOf.0.compose_file.salt.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.salt","typeLabel":"string | null"},"secure_time":{"type":"boolean","title":"Secure Time","default":false,"uniqueKey":"oneOf.0.compose_file.secure_time","typeLabel":"boolean"},"storage_fs":{"oneOf":[{"type":"string","title":"Storage Fs","default":"zfs","const":"ext4","uniqueKey":"oneOf.0.compose_file.storage_fs.oneOf.0","typeLabel":"string"},{"type":"string","title":"Storage Fs","default":"zfs","const":"zfs","uniqueKey":"oneOf.0.compose_file.storage_fs.oneOf.1","typeLabel":"string"},{"type":"null","title":"Storage Fs","default":"zfs","uniqueKey":"oneOf.0.compose_file.storage_fs.oneOf.2","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.storage_fs","typeLabel":"string · string · null"},"swap_size":{"oneOf":[{"type":"string","title":"Swap Size","uniqueKey":"oneOf.0.compose_file.swap_size.oneOf.0","typeLabel":"string"},{"type":"null","title":"Swap Size","uniqueKey":"oneOf.0.compose_file.swap_size.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.compose_file.swap_size","typeLabel":"string | null"},"tproxy_enabled":{"type":"boolean","title":"Tproxy Enabled","default":true,"uniqueKey":"oneOf.0.compose_file.tproxy_enabled","typeLabel":"boolean"}},"additionalProperties":false,"type":"object","required":["name"],"title":"AppComposeV2","isRequired":true,"uniqueKey":"oneOf.0.compose_file","typeLabel":"AppComposeV2 · object"},"name":{"type":"string","title":"Name","description":"CVM name (used as hostname): 5-63 chars, must start with letter, can contain letters/numbers/hyphens","isRequired":true,"uniqueKey":"oneOf.0.name","typeLabel":"string"},"compose_file_raw":{"type":"string","title":"Compose File Raw","description":"A whole app-compose JSON file, sent instead of compose_file. Phala Cloud parses it with the same rules as compose_file and serializes it the same way, so the deployed bytes and compose hash match the structured form, not the sent bytes. Needs the compose_advanced feature flag.","uniqueKey":"oneOf.0.compose_file_raw","typeLabel":"string"},"instance_type":{"oneOf":[{"type":"string","title":"Instance Type","uniqueKey":"oneOf.0.instance_type.oneOf.0","typeLabel":"string"},{"type":"null","title":"Instance Type","uniqueKey":"oneOf.0.instance_type.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.instance_type","typeLabel":"string | null"},"vcpu":{"oneOf":[{"type":"integer","title":"Vcpu","uniqueKey":"oneOf.0.vcpu.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Vcpu","uniqueKey":"oneOf.0.vcpu.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.vcpu","typeLabel":"integer | null"},"memory":{"oneOf":[{"type":"integer","title":"Memory","uniqueKey":"oneOf.0.memory.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Memory","uniqueKey":"oneOf.0.memory.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.memory","typeLabel":"integer | null"},"disk_size":{"oneOf":[{"type":"integer","title":"Disk Size","uniqueKey":"oneOf.0.disk_size.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Disk Size","uniqueKey":"oneOf.0.disk_size.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.disk_size","typeLabel":"integer | null"},"image":{"oneOf":[{"type":"string","title":"Image","uniqueKey":"oneOf.0.image.oneOf.0","typeLabel":"string"},{"type":"null","title":"Image","uniqueKey":"oneOf.0.image.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.image","typeLabel":"string | null"},"prefer_dev":{"oneOf":[{"type":"boolean","title":"Prefer Dev","description":"For OS images before 0.6.0, True selects dev and False selects non-dev. Ignored for unified images (0.6.0 or later). When None, inferred from the image name or defaults to dev.","uniqueKey":"oneOf.0.prefer_dev.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Prefer Dev","description":"For OS images before 0.6.0, True selects dev and False selects non-dev. Ignored for unified images (0.6.0 or later). When None, inferred from the image name or defaults to dev.","uniqueKey":"oneOf.0.prefer_dev.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.prefer_dev","typeLabel":"boolean | null"},"node":{"oneOf":[{"type":"string","title":"Node","description":"Physical node name","minLength":1,"uniqueKey":"oneOf.0.node.oneOf.0","typeLabel":"string"},{"type":"null","title":"Node","description":"Physical node name","uniqueKey":"oneOf.0.node.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.node","typeLabel":"string | null"},"region":{"oneOf":[{"type":"string","title":"Region","uniqueKey":"oneOf.0.region.oneOf.0","typeLabel":"string"},{"type":"null","title":"Region","uniqueKey":"oneOf.0.region.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.region","typeLabel":"string | null"},"listed":{"type":"boolean","title":"Listed","default":false,"uniqueKey":"oneOf.0.listed","typeLabel":"boolean"},"kms_id":{"oneOf":[{"type":"string","title":"Kms Id","uniqueKey":"oneOf.0.kms_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Kms Id","uniqueKey":"oneOf.0.kms_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_id","typeLabel":"string | null"},"kms":{"oneOf":[{"type":"string","title":"KmsType","default":"phala","enum":["phala","ethereum","base","local","legacy"],"uniqueKey":"oneOf.0.kms.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","default":"phala","uniqueKey":"oneOf.0.kms.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms","typeLabel":"enum\u003cstring> | null"},"kms_contract_id":{"oneOf":[{"type":"string","title":"HashedId[kms_contracts]","description":"A hashed identifier that maps to an internal database ID","format":"hashid","pattern":"^kc_.+","example":"kc_0123abcd","uniqueKey":"oneOf.0.kms_contract_id.oneOf.0","typeLabel":"string\u003chashid>"},{"type":"null","title":"Kms Contract Id","uniqueKey":"oneOf.0.kms_contract_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_contract_id","typeLabel":"string\u003chashid> | null"},"kms_contract":{"oneOf":[{"type":"string","title":"Kms Contract","uniqueKey":"oneOf.0.kms_contract.oneOf.0","typeLabel":"string"},{"type":"null","title":"Kms Contract","uniqueKey":"oneOf.0.kms_contract.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_contract","typeLabel":"string | null"},"nonce":{"oneOf":[{"type":"integer","title":"Nonce","description":"Optional nonce for deterministic app_id generation. When provided, app_id must also be provided. System will verify: app_id == get_create_address(team_wallet, nonce)","uniqueKey":"oneOf.0.nonce.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Nonce","description":"Optional nonce for deterministic app_id generation. When provided, app_id must also be provided. System will verify: app_id == get_create_address(team_wallet, nonce)","uniqueKey":"oneOf.0.nonce.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.nonce","typeLabel":"integer | null"},"app_id":{"oneOf":[{"type":"string","title":"App Id","description":"Optional app_id for manual specification. Required when nonce is provided. Only works with PHALA KMS.","uniqueKey":"oneOf.0.app_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"App Id","description":"Optional app_id for manual specification. Required when nonce is provided. Only works with PHALA KMS.","uniqueKey":"oneOf.0.app_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.app_id","typeLabel":"string | null"},"env_keys":{"items":{"type":"string","uniqueKey":"oneOf.0.env_keys.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Env Keys","description":"Allowed encrypted environment variable names. When compose_file does not declare allowed_envs, or sends an empty list, these names populate compose_file.allowed_envs for the guest allowlist.","uniqueKey":"oneOf.0.env_keys","typeLabel":"string[]"},"ports":{"oneOf":[{"type":"array","items":{"properties":{"vm_port":{"type":"integer","maximum":65535,"minimum":1,"title":"Vm Port","isRequired":true,"uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX].vm_port","typeLabel":"integer"},"protocol":{"type":"string","pattern":"^(tcp|udp)$","title":"Protocol","default":"tcp","uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX].protocol","typeLabel":"string"},"source_cidrs":{"items":{"type":"string","uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX].source_cidrs.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Source Cidrs","description":"IPv4 CIDR allowlist; empty = allow all sources. A list containing 0.0.0.0/0 also allows all sources and is stored as empty. Bare IPs are normalized to /32. Max 50 entries.","uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX].source_cidrs","typeLabel":"string[]"},"description":{"oneOf":[{"type":"string","title":"Description","description":"Optional audit text for this rule. Max 255 chars.","maxLength":255,"uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX].description.oneOf.0","typeLabel":"string"},{"type":"null","title":"Description","description":"Optional audit text for this rule. Max 255 chars.","uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX].description.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX].description","typeLabel":"string | null"}},"additionalProperties":false,"type":"object","required":["vm_port"],"title":"CreateTimePortMappingEntry","description":"Create-time port mapping intent. host_port is server-allocated from\nthe node's managed range, so callers declare vm_port, protocol, and the\noptional source_cidrs / description. NIC 0 is the only NIC a new CVM has,\nso nic_index is not accepted. Unknown keys are rejected so a client and\nserver disagreeing on the shape fails loudly instead of dropping fields.","uniqueKey":"oneOf.0.ports.oneOf.0.items.[INDEX]","typeLabel":"CreateTimePortMappingEntry · object"},"title":"Ports","uniqueKey":"oneOf.0.ports.oneOf.0","typeLabel":"CreateTimePortMappingEntry · object[]"},{"type":"null","title":"Ports","uniqueKey":"oneOf.0.ports.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.ports","typeLabel":"CreateTimePortMappingEntry · object[] | null"},"encrypted_env":{"oneOf":[{"type":"string","title":"Encrypted Env","uniqueKey":"oneOf.0.encrypted_env.oneOf.0","typeLabel":"string"},{"type":"null","title":"Encrypted Env","uniqueKey":"oneOf.0.encrypted_env.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.encrypted_env","typeLabel":"string | null"},"user_config":{"oneOf":[{"type":"string","title":"User Config","uniqueKey":"oneOf.0.user_config.oneOf.0","typeLabel":"string"},{"type":"null","title":"User Config","uniqueKey":"oneOf.0.user_config.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.user_config","typeLabel":"string | null"},"hugepages":{"type":"boolean","title":"Hugepages","default":false,"uniqueKey":"oneOf.0.hugepages","typeLabel":"boolean"},"pin_numa":{"type":"boolean","title":"Pin Numa","default":false,"uniqueKey":"oneOf.0.pin_numa","typeLabel":"boolean"},"gpus":{"oneOf":[{"type":"object","title":"GpuConfig","required":["gpus"],"properties":{"gpus":{"items":{"properties":{"slot":{"type":"string","title":"Slot","isRequired":true,"uniqueKey":"oneOf.0.gpus.oneOf.0.gpus.items.[INDEX].slot","typeLabel":"string"},"product_id":{"oneOf":[{"type":"string","title":"Product Id","uniqueKey":"oneOf.0.gpus.oneOf.0.gpus.items.[INDEX].product_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Product Id","uniqueKey":"oneOf.0.gpus.oneOf.0.gpus.items.[INDEX].product_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.gpus.oneOf.0.gpus.items.[INDEX].product_id","typeLabel":"string | null"}},"type":"object","required":["slot"],"title":"GpuSpec","uniqueKey":"oneOf.0.gpus.oneOf.0.gpus.items.[INDEX]","typeLabel":"GpuSpec · object"},"type":"array","title":"Gpus","isRequired":true,"uniqueKey":"oneOf.0.gpus.oneOf.0.gpus","typeLabel":"GpuSpec · object[]"},"attach_mode":{"oneOf":[{"type":"string","title":"Attach Mode","default":"listed","enum":["listed","all"],"uniqueKey":"oneOf.0.gpus.oneOf.0.attach_mode.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"string","title":"Attach Mode","default":"listed","uniqueKey":"oneOf.0.gpus.oneOf.0.attach_mode.oneOf.1","typeLabel":"string"}],"uniqueKey":"oneOf.0.gpus.oneOf.0.attach_mode","typeLabel":"enum\u003cstring> | string"}},"uniqueKey":"oneOf.0.gpus.oneOf.0","typeLabel":"GpuConfig · object"},{"type":"null","uniqueKey":"oneOf.0.gpus.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.gpus","typeLabel":"GpuConfig · object | null"},"kms_urls":{"items":{"type":"string","uniqueKey":"oneOf.0.kms_urls.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Kms Urls","uniqueKey":"oneOf.0.kms_urls","typeLabel":"string[]"},"gateway_urls":{"items":{"type":"string","uniqueKey":"oneOf.0.gateway_urls.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Gateway Urls","uniqueKey":"oneOf.0.gateway_urls","typeLabel":"string[]"},"skip_gateway":{"oneOf":[{"type":"boolean","title":"Skip Gateway","description":"Deploy without dstack-gateway. Turns the gateway off in compose_file when it does not set gateway_enabled/tproxy_enabled; rejected when compose_file enables the gateway.","uniqueKey":"oneOf.0.skip_gateway.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Skip Gateway","description":"Deploy without dstack-gateway. Turns the gateway off in compose_file when it does not set gateway_enabled/tproxy_enabled; rejected when compose_file enables the gateway.","uniqueKey":"oneOf.0.skip_gateway.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.skip_gateway","typeLabel":"boolean | null"},"key_provider_mode":{"oneOf":[{"type":"string","title":"Key Provider Mode","description":"Key provider mode. 'local' enables the local key provider in compose_file (and turns off KMS and the gateway where compose_file does not set them); rejected when compose_file sets key_provider or local_key_provider_enabled the other way.","enum":["kms","local"],"uniqueKey":"oneOf.0.key_provider_mode.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","title":"Key Provider Mode","description":"Key provider mode. 'local' enables the local key provider in compose_file (and turns off KMS and the gateway where compose_file does not set them); rejected when compose_file sets key_provider or local_key_provider_enabled the other way.","uniqueKey":"oneOf.0.key_provider_mode.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.key_provider_mode","typeLabel":"enum\u003cstring> | null"},"init_scripts":{"items":{"type":"string","enum":["docker_cleanup","env_merge"],"uniqueKey":"oneOf.0.init_scripts.items.[INDEX]","typeLabel":"enum\u003cstring>"},"type":"array","title":"Init Scripts","description":"Platform-owned init scripts to run on every boot, as slugs: docker_cleanup erases all local container-runtime stores (images, volumes, all containerd namespaces) and needs OS 0.6.x, ext4 storage and the docker-compose runner; env_merge merges encrypted env on boot, needs OS 0.6.0 or newer and the managed_env_create feature flag. Phala Cloud fixes the run order (docker_cleanup, then env_merge). The deprecated object form {\"env_merge\": bool} is still accepted. GET /cvms/{cvm_id}/init-scripts shows what an existing CVM runs.","uniqueKey":"oneOf.0.init_scripts","typeLabel":"enum\u003cstring>[]"},"enabled_init_scripts_docker_cleanup":{"type":"boolean","title":"Enabled Init Scripts Docker Cleanup","description":"Deprecated: send init_scripts: [\"docker_cleanup\"]. True adds docker_cleanup to init_scripts.","default":false,"deprecated":true,"uniqueKey":"oneOf.0.enabled_init_scripts_docker_cleanup","typeLabel":"boolean"},"launch_token":{"oneOf":[{"type":"string","title":"Launch Token","description":"Launch token (at least 32 bytes) the guest requires on every boot before key provisioning. Phala Cloud writes its hash into compose_file.requirements.launch_token_hash and stores the token on the app. For an existing app it must equal the app's token. Needs dstack OS 0.6.0 or newer. Phala Cloud and the node operator can read the token: it protects only against parties who know the public compose.","uniqueKey":"oneOf.0.launch_token.oneOf.0","typeLabel":"string"},{"type":"null","title":"Launch Token","description":"Launch token (at least 32 bytes) the guest requires on every boot before key provisioning. Phala Cloud writes its hash into compose_file.requirements.launch_token_hash and stores the token on the app. For an existing app it must equal the app's token. Needs dstack OS 0.6.0 or newer. Phala Cloud and the node operator can read the token: it protects only against parties who know the public compose.","uniqueKey":"oneOf.0.launch_token.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.launch_token","typeLabel":"string | null"},"generate_launch_token":{"type":"boolean","title":"Generate Launch Token","description":"Gate the CVM with a launch token Phala Cloud generates for a new app, or with the app's existing token. A newly generated token is returned once, in the create (commit) response.","default":false,"uniqueKey":"oneOf.0.generate_launch_token","typeLabel":"boolean"},"enabled_guest_agent_access":{"oneOf":[{"type":"boolean","title":"Enabled Guest Agent Access","description":"Restrict the guest agent (port 8090) to Phala Cloud by sending false. Omit it to leave the app unchanged; a new app starts unrestricted. Sending true never relaxes an existing restriction: it is rejected with ERR-03-030 when the app is already restricted, because relaxing requires Phala Cloud support.","uniqueKey":"oneOf.0.enabled_guest_agent_access.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Enabled Guest Agent Access","description":"Restrict the guest agent (port 8090) to Phala Cloud by sending false. Omit it to leave the app unchanged; a new app starts unrestricted. Sending true never relaxes an existing restriction: it is rejected with ERR-03-030 when the app is already restricted, because relaxing requires Phala Cloud support.","uniqueKey":"oneOf.0.enabled_guest_agent_access.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.enabled_guest_agent_access","typeLabel":"boolean | null"},"ssh_key_ids":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"oneOf.0.ssh_key_ids.oneOf.0.items.[INDEX]","typeLabel":"string"},"title":"Ssh Key Ids","description":"SSH key hashids to authorize on the new CVM. Must belong to a member of the workspace. Omit to authorize all of your own active keys.","uniqueKey":"oneOf.0.ssh_key_ids.oneOf.0","typeLabel":"string[]"},{"type":"null","title":"Ssh Key Ids","description":"SSH key hashids to authorize on the new CVM. Must belong to a member of the workspace. Omit to authorize all of your own active keys.","uniqueKey":"oneOf.0.ssh_key_ids.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.ssh_key_ids","typeLabel":"string[] | null"},"annotations":{"additionalProperties":{"type":"string","uniqueKey":"oneOf.0.annotations.additionalProperties","typeLabel":"string"},"type":"object","title":"Annotations","description":"Opaque key/value metadata for host-side tooling, stored by the dstack VMM with the VM. Not passed to the guest, not measured, and not part of the compose hash: attestation does not cover it, so do not rely on it for security. A non-empty map requires the cvm_annotations feature flag (ERR-03-049) and a node running dstack VMM 0.6.1 or newer (ERR-03-050). Keys must not be empty. Phala Cloud keeps no copy as CVM state and never copies or restores it (a replica starts without it, a relocated CVM keeps what its VMM manifest carries); this create request is recorded in the audit log.","uniqueKey":"oneOf.0.annotations","typeLabel":"Annotations · object"}},"uniqueKey":"oneOf.0","typeLabel":"ProvisionDstackAppRequestV2 · object"},{"type":"object","title":"ProvisionDstackAppRequestV2","description":"Request for provisioning a DStack app with automatic resource matching.\n\nMost fields are optional and will be automatically determined by the resource\nmatching logic in preflight_dstack_app. Only compose_file and name are required.","required":["name","compose_file_raw"],"properties":{"compose_file_raw":{"type":"string","title":"Compose File Raw","description":"A whole app-compose JSON file, sent instead of compose_file. Phala Cloud parses it with the same rules as compose_file and serializes it the same way, so the deployed bytes and compose hash match the structured form, not the sent bytes. Needs the compose_advanced feature flag.","isRequired":true,"uniqueKey":"oneOf.1.compose_file_raw","typeLabel":"string"},"name":{"type":"string","title":"Name","description":"CVM name (used as hostname): 5-63 chars, must start with letter, can contain letters/numbers/hyphens","isRequired":true,"uniqueKey":"oneOf.1.name","typeLabel":"string"},"compose_file":{"properties":{"name":{"type":"string","title":"Name","isRequired":true,"uniqueKey":"oneOf.1.compose_file.name","typeLabel":"string"},"allowed_envs":{"items":{"type":"string","uniqueKey":"oneOf.1.compose_file.allowed_envs.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Allowed Envs","uniqueKey":"oneOf.1.compose_file.allowed_envs","typeLabel":"string[]"},"bash_script":{"oneOf":[{"type":"string","title":"Bash Script","uniqueKey":"oneOf.1.compose_file.bash_script.oneOf.0","typeLabel":"string"},{"type":"null","title":"Bash Script","uniqueKey":"oneOf.1.compose_file.bash_script.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.bash_script","typeLabel":"string | null"},"default_gateway_domain":{"oneOf":[{"type":"string","title":"Default Gateway Domain","uniqueKey":"oneOf.1.compose_file.default_gateway_domain.oneOf.0","typeLabel":"string"},{"type":"null","title":"Default Gateway Domain","uniqueKey":"oneOf.1.compose_file.default_gateway_domain.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.default_gateway_domain","typeLabel":"string | null"},"docker_compose_file":{"oneOf":[{"type":"string","title":"Docker Compose File","uniqueKey":"oneOf.1.compose_file.docker_compose_file.oneOf.0","typeLabel":"string"},{"type":"null","title":"Docker Compose File","uniqueKey":"oneOf.1.compose_file.docker_compose_file.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.docker_compose_file","typeLabel":"string | null"},"init_script":{"items":{"type":"string","uniqueKey":"oneOf.1.compose_file.init_script.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Init Script","uniqueKey":"oneOf.1.compose_file.init_script","typeLabel":"string[]"},"key_provider":{"oneOf":[{"type":"string","title":"Key Provider","enum":["none","kms","local","tpm"],"uniqueKey":"oneOf.1.compose_file.key_provider.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","title":"Key Provider","uniqueKey":"oneOf.1.compose_file.key_provider.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.key_provider","typeLabel":"enum\u003cstring> | null"},"key_provider_id":{"oneOf":[{"type":"string","title":"Key Provider Id","uniqueKey":"oneOf.1.compose_file.key_provider_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Key Provider Id","uniqueKey":"oneOf.1.compose_file.key_provider_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.key_provider_id","typeLabel":"string | null"},"kms_enabled":{"type":"boolean","title":"Kms Enabled","default":true,"uniqueKey":"oneOf.1.compose_file.kms_enabled","typeLabel":"boolean"},"local_key_provider_enabled":{"type":"boolean","title":"Local Key Provider Enabled","default":false,"uniqueKey":"oneOf.1.compose_file.local_key_provider_enabled","typeLabel":"boolean"},"manifest_version":{"oneOf":[{"type":"integer","title":"Manifest Version","default":2,"uniqueKey":"oneOf.1.compose_file.manifest_version.oneOf.0","typeLabel":"integer"},{"type":"string","title":"Manifest Version","default":2,"uniqueKey":"oneOf.1.compose_file.manifest_version.oneOf.1","typeLabel":"string"}],"uniqueKey":"oneOf.1.compose_file.manifest_version","typeLabel":"integer | string"},"no_instance_id":{"type":"boolean","title":"No Instance Id","default":false,"uniqueKey":"oneOf.1.compose_file.no_instance_id","typeLabel":"boolean"},"port_policy":{"oneOf":[{"type":"object","title":"PortPolicy","description":"Per-instance port policy declared in app-compose. >= v0.5.9.\n\n``restrict_mode=True`` with an empty ``ports`` list is a valid lockdown.\nField order is alphabetical for compose_hash stability.","properties":{"ports":{"items":{"properties":{"port":{"type":"integer","title":"Port","isRequired":true,"uniqueKey":"oneOf.1.compose_file.port_policy.oneOf.0.ports.items.[INDEX].port","typeLabel":"integer"},"pp":{"type":"boolean","title":"Pp","default":false,"uniqueKey":"oneOf.1.compose_file.port_policy.oneOf.0.ports.items.[INDEX].pp","typeLabel":"boolean"}},"type":"object","required":["port"],"title":"PortAttrs","description":"Per-port gateway attribute. Matches dstack_types::PortAttrs.\n\nField order is alphabetical to match the normalized-compose JSON layout\nthe gateway and KMS use for compose_hash.","uniqueKey":"oneOf.1.compose_file.port_policy.oneOf.0.ports.items.[INDEX]","typeLabel":"PortAttrs · object"},"type":"array","title":"Ports","uniqueKey":"oneOf.1.compose_file.port_policy.oneOf.0.ports","typeLabel":"PortAttrs · object[]"},"restrict_mode":{"type":"boolean","title":"Restrict Mode","default":false,"uniqueKey":"oneOf.1.compose_file.port_policy.oneOf.0.restrict_mode","typeLabel":"boolean"}},"uniqueKey":"oneOf.1.compose_file.port_policy.oneOf.0","typeLabel":"PortPolicy · object"},{"type":"null","uniqueKey":"oneOf.1.compose_file.port_policy.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.port_policy","typeLabel":"PortPolicy · object | null"},"pre_launch_script":{"oneOf":[{"type":"string","title":"Pre Launch Script","uniqueKey":"oneOf.1.compose_file.pre_launch_script.oneOf.0","typeLabel":"string"},{"type":"null","title":"Pre Launch Script","uniqueKey":"oneOf.1.compose_file.pre_launch_script.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.pre_launch_script","typeLabel":"string | null"},"public_logs":{"type":"boolean","title":"Public Logs","default":true,"uniqueKey":"oneOf.1.compose_file.public_logs","typeLabel":"boolean"},"public_sysinfo":{"type":"boolean","title":"Public Sysinfo","default":true,"uniqueKey":"oneOf.1.compose_file.public_sysinfo","typeLabel":"boolean"},"public_tcbinfo":{"type":"boolean","title":"Public Tcbinfo","default":true,"uniqueKey":"oneOf.1.compose_file.public_tcbinfo","typeLabel":"boolean"},"runner":{"type":"string","title":"Runner","default":"docker-compose","uniqueKey":"oneOf.1.compose_file.runner","typeLabel":"string"},"requirements":{"oneOf":[{"type":"object","title":"Requirements","description":"Guest requirements (dstack >= 0.6.0), mirroring ``dstack_types::Requirements``.\n\nOnly keys the caller sent are serialized (see ``AppComposeV2._serialize_requirements``),\nso a default-valued key sent explicitly is measured and an unsent key is never added.\nFields are declared alphabetically to match the canonical JSON layout.","properties":{"ephemeral_data_disk":{"type":"boolean","title":"Ephemeral Data Disk","default":false,"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.ephemeral_data_disk","typeLabel":"boolean"},"gpu_policy":{"properties":{"allow_debug":{"type":"boolean","title":"Allow Debug","default":false,"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy.allow_debug","typeLabel":"boolean"},"allow_devtools":{"type":"boolean","title":"Allow Devtools","default":false,"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy.allow_devtools","typeLabel":"boolean"},"allow_insecure_boot":{"type":"boolean","title":"Allow Insecure Boot","default":false,"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy.allow_insecure_boot","typeLabel":"boolean"},"attest_gpu":{"type":"boolean","title":"Attest Gpu","default":true,"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy.attest_gpu","typeLabel":"boolean"},"rego":{"oneOf":[{"type":"string","title":"Rego","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy.rego.oneOf.0","typeLabel":"string"},{"type":"null","title":"Rego","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy.rego.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy.rego","typeLabel":"string | null"}},"additionalProperties":false,"type":"object","title":"GpuPolicy","description":"Guest-enforced GPU policy; defaults describe behavior, not serialized bytes.","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.gpu_policy","typeLabel":"GpuPolicy · object"},"health_check":{"type":"boolean","title":"Health Check","default":false,"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.health_check","typeLabel":"boolean"},"health_status_file":{"oneOf":[{"type":"string","title":"Health Status File","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.health_status_file.oneOf.0","typeLabel":"string"},{"type":"null","title":"Health Status File","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.health_status_file.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.health_status_file","typeLabel":"string | null"},"launch_token_hash":{"oneOf":[{"type":"string","title":"Launch Token Hash","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.launch_token_hash.oneOf.0","typeLabel":"string"},{"type":"null","title":"Launch Token Hash","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.launch_token_hash.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.launch_token_hash","typeLabel":"string | null"},"platforms":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.platforms.oneOf.0.items.[INDEX]","typeLabel":"string"},"title":"Platforms","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.platforms.oneOf.0","typeLabel":"string[]"},{"type":"null","title":"Platforms","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.platforms.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.platforms","typeLabel":"string[] | null"},"tdx_measure_acpi_tables":{"oneOf":[{"type":"boolean","title":"Tdx Measure Acpi Tables","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.tdx_measure_acpi_tables.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Tdx Measure Acpi Tables","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.tdx_measure_acpi_tables.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0.tdx_measure_acpi_tables","typeLabel":"boolean | null"}},"additionalProperties":false,"uniqueKey":"oneOf.1.compose_file.requirements.oneOf.0","typeLabel":"Requirements · object"},{"type":"null","uniqueKey":"oneOf.1.compose_file.requirements.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.requirements","typeLabel":"Requirements · object | null"},"storage_discard":{"oneOf":[{"type":"boolean","title":"Storage Discard","uniqueKey":"oneOf.1.compose_file.storage_discard.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Storage Discard","uniqueKey":"oneOf.1.compose_file.storage_discard.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.storage_discard","typeLabel":"boolean | null"},"event_log_version":{"oneOf":[{"type":"integer","title":"Event Log Version","enum":[1,2],"uniqueKey":"oneOf.1.compose_file.event_log_version.oneOf.0","typeLabel":"enum\u003cinteger>"},{"type":"null","title":"Event Log Version","uniqueKey":"oneOf.1.compose_file.event_log_version.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.event_log_version","typeLabel":"enum\u003cinteger> | null"},"snapshotter":{"oneOf":[{"type":"string","title":"Snapshotter","enum":["overlayfs","stargz"],"uniqueKey":"oneOf.1.compose_file.snapshotter.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","title":"Snapshotter","uniqueKey":"oneOf.1.compose_file.snapshotter.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.snapshotter","typeLabel":"enum\u003cstring> | null"},"verity_volumes":{"oneOf":[{"type":"array","items":{"properties":{"source":{"type":"string","minLength":1,"pattern":"^[^/]+$","title":"Source","isRequired":true,"uniqueKey":"oneOf.1.compose_file.verity_volumes.oneOf.0.items.[INDEX].source","typeLabel":"string"},"target":{"type":"string","title":"Target","isRequired":true,"uniqueKey":"oneOf.1.compose_file.verity_volumes.oneOf.0.items.[INDEX].target","typeLabel":"string"},"verity_root":{"type":"string","title":"Verity Root","isRequired":true,"uniqueKey":"oneOf.1.compose_file.verity_volumes.oneOf.0.items.[INDEX].verity_root","typeLabel":"string"}},"additionalProperties":false,"type":"object","required":["source","target","verity_root"],"title":"VerityVolume","description":"Read-only dm-verity volume pre-seeded into the CVM (dstack >= 0.6.0).\n\nFields are declared alphabetically to match the canonical JSON layout.","uniqueKey":"oneOf.1.compose_file.verity_volumes.oneOf.0.items.[INDEX]","typeLabel":"VerityVolume · object"},"title":"Verity Volumes","uniqueKey":"oneOf.1.compose_file.verity_volumes.oneOf.0","typeLabel":"VerityVolume · object[]"},{"type":"null","title":"Verity Volumes","uniqueKey":"oneOf.1.compose_file.verity_volumes.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.verity_volumes","typeLabel":"VerityVolume · object[] | null"},"gateway_enabled":{"type":"boolean","title":"Gateway Enabled","default":true,"uniqueKey":"oneOf.1.compose_file.gateway_enabled","typeLabel":"boolean"},"features":{"items":{"type":"string","uniqueKey":"oneOf.1.compose_file.features.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Features","default":["kms","tproxy-net"],"uniqueKey":"oneOf.1.compose_file.features","typeLabel":"string[]"},"salt":{"oneOf":[{"type":"string","title":"Salt","uniqueKey":"oneOf.1.compose_file.salt.oneOf.0","typeLabel":"string"},{"type":"null","title":"Salt","uniqueKey":"oneOf.1.compose_file.salt.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.salt","typeLabel":"string | null"},"secure_time":{"type":"boolean","title":"Secure Time","default":false,"uniqueKey":"oneOf.1.compose_file.secure_time","typeLabel":"boolean"},"storage_fs":{"oneOf":[{"type":"string","title":"Storage Fs","default":"zfs","const":"ext4","uniqueKey":"oneOf.1.compose_file.storage_fs.oneOf.0","typeLabel":"string"},{"type":"string","title":"Storage Fs","default":"zfs","const":"zfs","uniqueKey":"oneOf.1.compose_file.storage_fs.oneOf.1","typeLabel":"string"},{"type":"null","title":"Storage Fs","default":"zfs","uniqueKey":"oneOf.1.compose_file.storage_fs.oneOf.2","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.storage_fs","typeLabel":"string · string · null"},"swap_size":{"oneOf":[{"type":"string","title":"Swap Size","uniqueKey":"oneOf.1.compose_file.swap_size.oneOf.0","typeLabel":"string"},{"type":"null","title":"Swap Size","uniqueKey":"oneOf.1.compose_file.swap_size.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.compose_file.swap_size","typeLabel":"string | null"},"tproxy_enabled":{"type":"boolean","title":"Tproxy Enabled","default":true,"uniqueKey":"oneOf.1.compose_file.tproxy_enabled","typeLabel":"boolean"}},"additionalProperties":false,"type":"object","required":["name"],"title":"AppComposeV2","uniqueKey":"oneOf.1.compose_file","typeLabel":"AppComposeV2 · object"},"instance_type":{"oneOf":[{"type":"string","title":"Instance Type","uniqueKey":"oneOf.1.instance_type.oneOf.0","typeLabel":"string"},{"type":"null","title":"Instance Type","uniqueKey":"oneOf.1.instance_type.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.instance_type","typeLabel":"string | null"},"vcpu":{"oneOf":[{"type":"integer","title":"Vcpu","uniqueKey":"oneOf.1.vcpu.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Vcpu","uniqueKey":"oneOf.1.vcpu.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.vcpu","typeLabel":"integer | null"},"memory":{"oneOf":[{"type":"integer","title":"Memory","uniqueKey":"oneOf.1.memory.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Memory","uniqueKey":"oneOf.1.memory.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.memory","typeLabel":"integer | null"},"disk_size":{"oneOf":[{"type":"integer","title":"Disk Size","uniqueKey":"oneOf.1.disk_size.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Disk Size","uniqueKey":"oneOf.1.disk_size.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.disk_size","typeLabel":"integer | null"},"image":{"oneOf":[{"type":"string","title":"Image","uniqueKey":"oneOf.1.image.oneOf.0","typeLabel":"string"},{"type":"null","title":"Image","uniqueKey":"oneOf.1.image.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.image","typeLabel":"string | null"},"prefer_dev":{"oneOf":[{"type":"boolean","title":"Prefer Dev","description":"For OS images before 0.6.0, True selects dev and False selects non-dev. Ignored for unified images (0.6.0 or later). When None, inferred from the image name or defaults to dev.","uniqueKey":"oneOf.1.prefer_dev.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Prefer Dev","description":"For OS images before 0.6.0, True selects dev and False selects non-dev. Ignored for unified images (0.6.0 or later). When None, inferred from the image name or defaults to dev.","uniqueKey":"oneOf.1.prefer_dev.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.prefer_dev","typeLabel":"boolean | null"},"node":{"oneOf":[{"type":"string","title":"Node","description":"Physical node name","minLength":1,"uniqueKey":"oneOf.1.node.oneOf.0","typeLabel":"string"},{"type":"null","title":"Node","description":"Physical node name","uniqueKey":"oneOf.1.node.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.node","typeLabel":"string | null"},"region":{"oneOf":[{"type":"string","title":"Region","uniqueKey":"oneOf.1.region.oneOf.0","typeLabel":"string"},{"type":"null","title":"Region","uniqueKey":"oneOf.1.region.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.region","typeLabel":"string | null"},"listed":{"type":"boolean","title":"Listed","default":false,"uniqueKey":"oneOf.1.listed","typeLabel":"boolean"},"kms_id":{"oneOf":[{"type":"string","title":"Kms Id","uniqueKey":"oneOf.1.kms_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Kms Id","uniqueKey":"oneOf.1.kms_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.kms_id","typeLabel":"string | null"},"kms":{"oneOf":[{"type":"string","title":"KmsType","default":"phala","enum":["phala","ethereum","base","local","legacy"],"uniqueKey":"oneOf.1.kms.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","default":"phala","uniqueKey":"oneOf.1.kms.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.kms","typeLabel":"enum\u003cstring> | null"},"kms_contract_id":{"oneOf":[{"type":"string","title":"HashedId[kms_contracts]","description":"A hashed identifier that maps to an internal database ID","format":"hashid","pattern":"^kc_.+","example":"kc_0123abcd","uniqueKey":"oneOf.1.kms_contract_id.oneOf.0","typeLabel":"string\u003chashid>"},{"type":"null","title":"Kms Contract Id","uniqueKey":"oneOf.1.kms_contract_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.kms_contract_id","typeLabel":"string\u003chashid> | null"},"kms_contract":{"oneOf":[{"type":"string","title":"Kms Contract","uniqueKey":"oneOf.1.kms_contract.oneOf.0","typeLabel":"string"},{"type":"null","title":"Kms Contract","uniqueKey":"oneOf.1.kms_contract.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.kms_contract","typeLabel":"string | null"},"nonce":{"oneOf":[{"type":"integer","title":"Nonce","description":"Optional nonce for deterministic app_id generation. When provided, app_id must also be provided. System will verify: app_id == get_create_address(team_wallet, nonce)","uniqueKey":"oneOf.1.nonce.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Nonce","description":"Optional nonce for deterministic app_id generation. When provided, app_id must also be provided. System will verify: app_id == get_create_address(team_wallet, nonce)","uniqueKey":"oneOf.1.nonce.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.nonce","typeLabel":"integer | null"},"app_id":{"oneOf":[{"type":"string","title":"App Id","description":"Optional app_id for manual specification. Required when nonce is provided. Only works with PHALA KMS.","uniqueKey":"oneOf.1.app_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"App Id","description":"Optional app_id for manual specification. Required when nonce is provided. Only works with PHALA KMS.","uniqueKey":"oneOf.1.app_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.app_id","typeLabel":"string | null"},"env_keys":{"items":{"type":"string","uniqueKey":"oneOf.1.env_keys.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Env Keys","description":"Allowed encrypted environment variable names. When compose_file does not declare allowed_envs, or sends an empty list, these names populate compose_file.allowed_envs for the guest allowlist.","uniqueKey":"oneOf.1.env_keys","typeLabel":"string[]"},"ports":{"oneOf":[{"type":"array","items":{"properties":{"vm_port":{"type":"integer","maximum":65535,"minimum":1,"title":"Vm Port","isRequired":true,"uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX].vm_port","typeLabel":"integer"},"protocol":{"type":"string","pattern":"^(tcp|udp)$","title":"Protocol","default":"tcp","uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX].protocol","typeLabel":"string"},"source_cidrs":{"items":{"type":"string","uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX].source_cidrs.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Source Cidrs","description":"IPv4 CIDR allowlist; empty = allow all sources. A list containing 0.0.0.0/0 also allows all sources and is stored as empty. Bare IPs are normalized to /32. Max 50 entries.","uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX].source_cidrs","typeLabel":"string[]"},"description":{"oneOf":[{"type":"string","title":"Description","description":"Optional audit text for this rule. Max 255 chars.","maxLength":255,"uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX].description.oneOf.0","typeLabel":"string"},{"type":"null","title":"Description","description":"Optional audit text for this rule. Max 255 chars.","uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX].description.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX].description","typeLabel":"string | null"}},"additionalProperties":false,"type":"object","required":["vm_port"],"title":"CreateTimePortMappingEntry","description":"Create-time port mapping intent. host_port is server-allocated from\nthe node's managed range, so callers declare vm_port, protocol, and the\noptional source_cidrs / description. NIC 0 is the only NIC a new CVM has,\nso nic_index is not accepted. Unknown keys are rejected so a client and\nserver disagreeing on the shape fails loudly instead of dropping fields.","uniqueKey":"oneOf.1.ports.oneOf.0.items.[INDEX]","typeLabel":"CreateTimePortMappingEntry · object"},"title":"Ports","uniqueKey":"oneOf.1.ports.oneOf.0","typeLabel":"CreateTimePortMappingEntry · object[]"},{"type":"null","title":"Ports","uniqueKey":"oneOf.1.ports.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.ports","typeLabel":"CreateTimePortMappingEntry · object[] | null"},"encrypted_env":{"oneOf":[{"type":"string","title":"Encrypted Env","uniqueKey":"oneOf.1.encrypted_env.oneOf.0","typeLabel":"string"},{"type":"null","title":"Encrypted Env","uniqueKey":"oneOf.1.encrypted_env.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.encrypted_env","typeLabel":"string | null"},"user_config":{"oneOf":[{"type":"string","title":"User Config","uniqueKey":"oneOf.1.user_config.oneOf.0","typeLabel":"string"},{"type":"null","title":"User Config","uniqueKey":"oneOf.1.user_config.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.user_config","typeLabel":"string | null"},"hugepages":{"type":"boolean","title":"Hugepages","default":false,"uniqueKey":"oneOf.1.hugepages","typeLabel":"boolean"},"pin_numa":{"type":"boolean","title":"Pin Numa","default":false,"uniqueKey":"oneOf.1.pin_numa","typeLabel":"boolean"},"gpus":{"oneOf":[{"type":"object","title":"GpuConfig","required":["gpus"],"properties":{"gpus":{"items":{"properties":{"slot":{"type":"string","title":"Slot","isRequired":true,"uniqueKey":"oneOf.1.gpus.oneOf.0.gpus.items.[INDEX].slot","typeLabel":"string"},"product_id":{"oneOf":[{"type":"string","title":"Product Id","uniqueKey":"oneOf.1.gpus.oneOf.0.gpus.items.[INDEX].product_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Product Id","uniqueKey":"oneOf.1.gpus.oneOf.0.gpus.items.[INDEX].product_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.gpus.oneOf.0.gpus.items.[INDEX].product_id","typeLabel":"string | null"}},"type":"object","required":["slot"],"title":"GpuSpec","uniqueKey":"oneOf.1.gpus.oneOf.0.gpus.items.[INDEX]","typeLabel":"GpuSpec · object"},"type":"array","title":"Gpus","isRequired":true,"uniqueKey":"oneOf.1.gpus.oneOf.0.gpus","typeLabel":"GpuSpec · object[]"},"attach_mode":{"oneOf":[{"type":"string","title":"Attach Mode","default":"listed","enum":["listed","all"],"uniqueKey":"oneOf.1.gpus.oneOf.0.attach_mode.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"string","title":"Attach Mode","default":"listed","uniqueKey":"oneOf.1.gpus.oneOf.0.attach_mode.oneOf.1","typeLabel":"string"}],"uniqueKey":"oneOf.1.gpus.oneOf.0.attach_mode","typeLabel":"enum\u003cstring> | string"}},"uniqueKey":"oneOf.1.gpus.oneOf.0","typeLabel":"GpuConfig · object"},{"type":"null","uniqueKey":"oneOf.1.gpus.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.gpus","typeLabel":"GpuConfig · object | null"},"kms_urls":{"items":{"type":"string","uniqueKey":"oneOf.1.kms_urls.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Kms Urls","uniqueKey":"oneOf.1.kms_urls","typeLabel":"string[]"},"gateway_urls":{"items":{"type":"string","uniqueKey":"oneOf.1.gateway_urls.items.[INDEX]","typeLabel":"string"},"type":"array","title":"Gateway Urls","uniqueKey":"oneOf.1.gateway_urls","typeLabel":"string[]"},"skip_gateway":{"oneOf":[{"type":"boolean","title":"Skip Gateway","description":"Deploy without dstack-gateway. Turns the gateway off in compose_file when it does not set gateway_enabled/tproxy_enabled; rejected when compose_file enables the gateway.","uniqueKey":"oneOf.1.skip_gateway.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Skip Gateway","description":"Deploy without dstack-gateway. Turns the gateway off in compose_file when it does not set gateway_enabled/tproxy_enabled; rejected when compose_file enables the gateway.","uniqueKey":"oneOf.1.skip_gateway.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.skip_gateway","typeLabel":"boolean | null"},"key_provider_mode":{"oneOf":[{"type":"string","title":"Key Provider Mode","description":"Key provider mode. 'local' enables the local key provider in compose_file (and turns off KMS and the gateway where compose_file does not set them); rejected when compose_file sets key_provider or local_key_provider_enabled the other way.","enum":["kms","local"],"uniqueKey":"oneOf.1.key_provider_mode.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","title":"Key Provider Mode","description":"Key provider mode. 'local' enables the local key provider in compose_file (and turns off KMS and the gateway where compose_file does not set them); rejected when compose_file sets key_provider or local_key_provider_enabled the other way.","uniqueKey":"oneOf.1.key_provider_mode.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.key_provider_mode","typeLabel":"enum\u003cstring> | null"},"init_scripts":{"items":{"type":"string","enum":["docker_cleanup","env_merge"],"uniqueKey":"oneOf.1.init_scripts.items.[INDEX]","typeLabel":"enum\u003cstring>"},"type":"array","title":"Init Scripts","description":"Platform-owned init scripts to run on every boot, as slugs: docker_cleanup erases all local container-runtime stores (images, volumes, all containerd namespaces) and needs OS 0.6.x, ext4 storage and the docker-compose runner; env_merge merges encrypted env on boot, needs OS 0.6.0 or newer and the managed_env_create feature flag. Phala Cloud fixes the run order (docker_cleanup, then env_merge). The deprecated object form {\"env_merge\": bool} is still accepted. GET /cvms/{cvm_id}/init-scripts shows what an existing CVM runs.","uniqueKey":"oneOf.1.init_scripts","typeLabel":"enum\u003cstring>[]"},"enabled_init_scripts_docker_cleanup":{"type":"boolean","title":"Enabled Init Scripts Docker Cleanup","description":"Deprecated: send init_scripts: [\"docker_cleanup\"]. True adds docker_cleanup to init_scripts.","default":false,"deprecated":true,"uniqueKey":"oneOf.1.enabled_init_scripts_docker_cleanup","typeLabel":"boolean"},"launch_token":{"oneOf":[{"type":"string","title":"Launch Token","description":"Launch token (at least 32 bytes) the guest requires on every boot before key provisioning. Phala Cloud writes its hash into compose_file.requirements.launch_token_hash and stores the token on the app. For an existing app it must equal the app's token. Needs dstack OS 0.6.0 or newer. Phala Cloud and the node operator can read the token: it protects only against parties who know the public compose.","uniqueKey":"oneOf.1.launch_token.oneOf.0","typeLabel":"string"},{"type":"null","title":"Launch Token","description":"Launch token (at least 32 bytes) the guest requires on every boot before key provisioning. Phala Cloud writes its hash into compose_file.requirements.launch_token_hash and stores the token on the app. For an existing app it must equal the app's token. Needs dstack OS 0.6.0 or newer. Phala Cloud and the node operator can read the token: it protects only against parties who know the public compose.","uniqueKey":"oneOf.1.launch_token.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.launch_token","typeLabel":"string | null"},"generate_launch_token":{"type":"boolean","title":"Generate Launch Token","description":"Gate the CVM with a launch token Phala Cloud generates for a new app, or with the app's existing token. A newly generated token is returned once, in the create (commit) response.","default":false,"uniqueKey":"oneOf.1.generate_launch_token","typeLabel":"boolean"},"enabled_guest_agent_access":{"oneOf":[{"type":"boolean","title":"Enabled Guest Agent Access","description":"Restrict the guest agent (port 8090) to Phala Cloud by sending false. Omit it to leave the app unchanged; a new app starts unrestricted. Sending true never relaxes an existing restriction: it is rejected with ERR-03-030 when the app is already restricted, because relaxing requires Phala Cloud support.","uniqueKey":"oneOf.1.enabled_guest_agent_access.oneOf.0","typeLabel":"boolean"},{"type":"null","title":"Enabled Guest Agent Access","description":"Restrict the guest agent (port 8090) to Phala Cloud by sending false. Omit it to leave the app unchanged; a new app starts unrestricted. Sending true never relaxes an existing restriction: it is rejected with ERR-03-030 when the app is already restricted, because relaxing requires Phala Cloud support.","uniqueKey":"oneOf.1.enabled_guest_agent_access.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.enabled_guest_agent_access","typeLabel":"boolean | null"},"ssh_key_ids":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"oneOf.1.ssh_key_ids.oneOf.0.items.[INDEX]","typeLabel":"string"},"title":"Ssh Key Ids","description":"SSH key hashids to authorize on the new CVM. Must belong to a member of the workspace. Omit to authorize all of your own active keys.","uniqueKey":"oneOf.1.ssh_key_ids.oneOf.0","typeLabel":"string[]"},{"type":"null","title":"Ssh Key Ids","description":"SSH key hashids to authorize on the new CVM. Must belong to a member of the workspace. Omit to authorize all of your own active keys.","uniqueKey":"oneOf.1.ssh_key_ids.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.ssh_key_ids","typeLabel":"string[] | null"},"annotations":{"additionalProperties":{"type":"string","uniqueKey":"oneOf.1.annotations.additionalProperties","typeLabel":"string"},"type":"object","title":"Annotations","description":"Opaque key/value metadata for host-side tooling, stored by the dstack VMM with the VM. Not passed to the guest, not measured, and not part of the compose hash: attestation does not cover it, so do not rely on it for security. A non-empty map requires the cvm_annotations feature flag (ERR-03-049) and a node running dstack VMM 0.6.1 or newer (ERR-03-050). Keys must not be empty. Phala Cloud keeps no copy as CVM state and never copies or restores it (a replica starts without it, a relocated CVM keeps what its VMM manifest carries); this create request is recorded in the audit log.","uniqueKey":"oneOf.1.annotations","typeLabel":"Annotations · object"}},"uniqueKey":"oneOf.1","typeLabel":"ProvisionDstackAppRequestV2 · object"},{"type":"object","title":"CommitCvmCreateRequest","description":"Second-phase create request identified by a prepare token.","required":["token"],"properties":{"token":{"type":"string","title":"Token","isRequired":true,"uniqueKey":"oneOf.2.token","typeLabel":"string"},"encrypted_env":{"oneOf":[{"type":"string","title":"Encrypted Env","uniqueKey":"oneOf.2.encrypted_env.oneOf.0","typeLabel":"string"},{"type":"null","title":"Encrypted Env","uniqueKey":"oneOf.2.encrypted_env.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.encrypted_env","typeLabel":"string | null"},"transaction_hash":{"oneOf":[{"type":"string","title":"Transaction Hash","uniqueKey":"oneOf.2.transaction_hash.oneOf.0","typeLabel":"string"},{"type":"null","title":"Transaction Hash","uniqueKey":"oneOf.2.transaction_hash.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.transaction_hash","typeLabel":"string | null"},"compose_hash":{"oneOf":[{"type":"string","title":"Compose Hash","uniqueKey":"oneOf.2.compose_hash.oneOf.0","typeLabel":"string"},{"type":"null","title":"Compose Hash","uniqueKey":"oneOf.2.compose_hash.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.compose_hash","typeLabel":"string | null"},"app_id":{"oneOf":[{"type":"string","title":"App Id","uniqueKey":"oneOf.2.app_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"App Id","uniqueKey":"oneOf.2.app_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.app_id","typeLabel":"string | null"},"kms_id":{"oneOf":[{"type":"string","title":"Kms Id","uniqueKey":"oneOf.2.kms_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Kms Id","uniqueKey":"oneOf.2.kms_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.kms_id","typeLabel":"string | null"},"contract_address":{"oneOf":[{"type":"string","title":"Contract Address","uniqueKey":"oneOf.2.contract_address.oneOf.0","typeLabel":"string"},{"type":"null","title":"Contract Address","uniqueKey":"oneOf.2.contract_address.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.contract_address","typeLabel":"string | null"},"deployer_address":{"oneOf":[{"type":"string","title":"Deployer Address","uniqueKey":"oneOf.2.deployer_address.oneOf.0","typeLabel":"string"},{"type":"null","title":"Deployer Address","uniqueKey":"oneOf.2.deployer_address.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.deployer_address","typeLabel":"string | null"},"env_keys":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"oneOf.2.env_keys.oneOf.0.items.[INDEX]","typeLabel":"string"},"title":"Env Keys","uniqueKey":"oneOf.2.env_keys.oneOf.0","typeLabel":"string[]"},{"type":"null","title":"Env Keys","uniqueKey":"oneOf.2.env_keys.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.env_keys","typeLabel":"string[] | null"}},"uniqueKey":"oneOf.2","typeLabel":"CommitCvmCreateRequest · object"},{"type":"object","title":"CreateTappRequest","required":["app_id","compose_hash"],"properties":{"app_id":{"type":"string","title":"App Id","description":"The calculated app ID from compose file.","isRequired":true,"uniqueKey":"oneOf.3.app_id","typeLabel":"string"},"compose_hash":{"type":"string","title":"Compose Hash","description":"The compose hash of the app compose file.","isRequired":true,"uniqueKey":"oneOf.3.compose_hash","typeLabel":"string"},"encrypted_env":{"oneOf":[{"type":"string","title":"Encrypted Env","description":"The encrypted environment variables.","uniqueKey":"oneOf.3.encrypted_env.oneOf.0","typeLabel":"string"},{"type":"null","title":"Encrypted Env","description":"The encrypted environment variables.","uniqueKey":"oneOf.3.encrypted_env.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.3.encrypted_env","typeLabel":"string | null"},"kms_id":{"oneOf":[{"type":"string","title":"Kms Id","description":"The KMS ID.","uniqueKey":"oneOf.3.kms_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Kms Id","description":"The KMS ID.","uniqueKey":"oneOf.3.kms_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.3.kms_id","typeLabel":"string | null"},"contract_address":{"oneOf":[{"type":"string","title":"Contract Address","description":"The contract address.","uniqueKey":"oneOf.3.contract_address.oneOf.0","typeLabel":"string"},{"type":"null","title":"Contract Address","description":"The contract address.","uniqueKey":"oneOf.3.contract_address.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.3.contract_address","typeLabel":"string | null"},"deployer_address":{"oneOf":[{"type":"string","title":"Deployer Address","description":"The deployer address.","uniqueKey":"oneOf.3.deployer_address.oneOf.0","typeLabel":"string"},{"type":"null","title":"Deployer Address","description":"The deployer address.","uniqueKey":"oneOf.3.deployer_address.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.3.deployer_address","typeLabel":"string | null"},"env_keys":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"oneOf.3.env_keys.oneOf.0.items.[INDEX]","typeLabel":"string"},"title":"Env Keys","description":"The environment variables to use for the app.","uniqueKey":"oneOf.3.env_keys.oneOf.0","typeLabel":"string[]"},{"type":"null","title":"Env Keys","description":"The environment variables to use for the app.","uniqueKey":"oneOf.3.env_keys.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.3.env_keys","typeLabel":"string[] | null"}},"uniqueKey":"oneOf.3","typeLabel":"CreateTappRequest · object"}],"uniqueKey":"","typeLabel":"ProvisionDstackAppRequestV2 · object · ProvisionDstackAppRequestV2 · object · CommitCvmCreateRequest · object · CreateTappRequest · object"},"examples":{"Example":{"title":"Example","value":{"compose_file":{"name":"\u003cstring>","allowed_envs":["\u003cstring>"],"bash_script":"\u003cstring>","default_gateway_domain":"\u003cstring>","docker_compose_file":"\u003cstring>","init_script":["\u003cstring>"],"key_provider_id":"\u003cstring>","kms_enabled":true,"local_key_provider_enabled":false,"manifest_version":2,"no_instance_id":false,"port_policy":{"ports":[{"port":123,"pp":false}],"restrict_mode":false},"pre_launch_script":"\u003cstring>","public_logs":true,"public_sysinfo":true,"public_tcbinfo":true,"runner":"docker-compose","requirements":{"ephemeral_data_disk":false,"gpu_policy":{"allow_debug":false,"allow_devtools":false,"allow_insecure_boot":false,"attest_gpu":true,"rego":"\u003cstring>"},"health_check":false,"health_status_file":"\u003cstring>","launch_token_hash":"\u003cstring>","platforms":["\u003cstring>"],"tdx_measure_acpi_tables":true},"storage_discard":true,"verity_volumes":[{"source":"\u003cstring>","target":"\u003cstring>","verity_root":"\u003cstring>"}],"gateway_enabled":true,"features":["kms","tproxy-net"],"salt":"\u003cstring>","secure_time":false,"storage_fs":"zfs","swap_size":"\u003cstring>","tproxy_enabled":true},"name":"\u003cstring>","compose_file_raw":"\u003cstring>","instance_type":"\u003cstring>","vcpu":123,"memory":123,"disk_size":123,"image":"\u003cstring>","prefer_dev":true,"node":"\u003cstring>","region":"\u003cstring>","listed":false,"kms_id":"\u003cstring>","kms":"phala","kms_contract_id":"kc_0123abcd","kms_contract":"\u003cstring>","nonce":123,"app_id":"\u003cstring>","env_keys":["\u003cstring>"],"ports":[{"vm_port":32768,"protocol":"tcp","source_cidrs":["\u003cstring>"],"description":"\u003cstring>"}],"encrypted_env":"\u003cstring>","user_config":"\u003cstring>","hugepages":false,"pin_numa":false,"gpus":{"gpus":[{"slot":"\u003cstring>","product_id":"\u003cstring>"}],"attach_mode":"listed"},"kms_urls":["\u003cstring>"],"gateway_urls":["\u003cstring>"],"skip_gateway":true,"init_scripts":[],"enabled_init_scripts_docker_cleanup":false,"launch_token":"\u003cstring>","generate_launch_token":false,"enabled_guest_agent_access":true,"ssh_key_ids":["\u003cstring>"],"annotations":{}}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"7854e775-2b15-4d4e-bed6-2ec70729bb5e":{"description":"Prepare returns provision data with a token; commit returns the created CVM","content":{"application/json":{"schema":{"oneOf":[{"type":"object","title":"ProvisionDstackAppResponseV2","description":"Response from DStack app preflight checks containing provisioning details.","required":["compose_hash","compose_file","os_image_version","requires_gpu"],"properties":{"compose_hash":{"type":"string","title":"Compose Hash","isRequired":true,"uniqueKey":"oneOf.0.compose_hash","typeLabel":"string"},"compose_file":{"type":"string","title":"Compose File","description":"Exact final app-compose JSON bound to compose_hash","isRequired":true,"uniqueKey":"oneOf.0.compose_file","typeLabel":"string"},"os_image_version":{"type":"string","title":"Os Image Version","isRequired":true,"uniqueKey":"oneOf.0.os_image_version","typeLabel":"string"},"requires_gpu":{"type":"boolean","title":"Requires Gpu","isRequired":true,"uniqueKey":"oneOf.0.requires_gpu","typeLabel":"boolean"},"app_id":{"oneOf":[{"type":"string","title":"App Id","uniqueKey":"oneOf.0.app_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"App Id","uniqueKey":"oneOf.0.app_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.app_id","typeLabel":"string | null"},"app_env_encrypt_pubkey":{"oneOf":[{"type":"string","title":"App Env Encrypt Pubkey","uniqueKey":"oneOf.0.app_env_encrypt_pubkey.oneOf.0","typeLabel":"string"},{"type":"null","title":"App Env Encrypt Pubkey","uniqueKey":"oneOf.0.app_env_encrypt_pubkey.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.app_env_encrypt_pubkey","typeLabel":"string | null"},"teepod_version":{"oneOf":[{"type":"string","title":"Teepod Version","uniqueKey":"oneOf.0.teepod_version.oneOf.0","typeLabel":"string"},{"type":"null","title":"Teepod Version","uniqueKey":"oneOf.0.teepod_version.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.teepod_version","typeLabel":"string | null"},"kms_info":{"oneOf":[{"type":"object","title":"KMSInfo","description":"KMS instance information.","required":["id","url","version"],"properties":{"id":{"type":"string","pattern":"^kms_.+","format":"hashid","title":"HashedId[kms]","description":"Hashed KMS identifier (kms_xxxxx)","examples":["kms_0123abcd"],"isRequired":true,"uniqueKey":"oneOf.0.kms_info.oneOf.0.id","typeLabel":"string\u003chashid>"},"url":{"type":"string","title":"Url","description":"KMS endpoint URL","isRequired":true,"uniqueKey":"oneOf.0.kms_info.oneOf.0.url","typeLabel":"string"},"version":{"type":"string","title":"Version","description":"KMS software version","isRequired":true,"uniqueKey":"oneOf.0.kms_info.oneOf.0.version","typeLabel":"string"},"slug":{"oneOf":[{"type":"string","title":"Slug","description":"Human-readable KMS name","uniqueKey":"oneOf.0.kms_info.oneOf.0.slug.oneOf.0","typeLabel":"string"},{"type":"null","title":"Slug","description":"Human-readable KMS name","uniqueKey":"oneOf.0.kms_info.oneOf.0.slug.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_info.oneOf.0.slug","typeLabel":"string | null"},"chain_id":{"oneOf":[{"type":"integer","title":"Chain Id","description":"Blockchain chain ID if onchain","uniqueKey":"oneOf.0.kms_info.oneOf.0.chain_id.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Chain Id","description":"Blockchain chain ID if onchain","uniqueKey":"oneOf.0.kms_info.oneOf.0.chain_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_info.oneOf.0.chain_id","typeLabel":"integer | null"},"kms_contract_address":{"oneOf":[{"type":"string","title":"Kms Contract Address","description":"Smart contract address if onchain","uniqueKey":"oneOf.0.kms_info.oneOf.0.kms_contract_address.oneOf.0","typeLabel":"string"},{"type":"null","title":"Kms Contract Address","description":"Smart contract address if onchain","uniqueKey":"oneOf.0.kms_info.oneOf.0.kms_contract_address.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_info.oneOf.0.kms_contract_address","typeLabel":"string | null"},"gateway_app_id":{"oneOf":[{"type":"string","title":"Gateway App Id","description":"Gateway application ID","uniqueKey":"oneOf.0.kms_info.oneOf.0.gateway_app_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Gateway App Id","description":"Gateway application ID","uniqueKey":"oneOf.0.kms_info.oneOf.0.gateway_app_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_info.oneOf.0.gateway_app_id","typeLabel":"string | null"},"ca_pubkey":{"oneOf":[{"type":"string","title":"Ca Pubkey","description":"KMS CA public key used as key_provider_id","uniqueKey":"oneOf.0.kms_info.oneOf.0.ca_pubkey.oneOf.0","typeLabel":"string"},{"type":"null","title":"Ca Pubkey","description":"KMS CA public key used as key_provider_id","uniqueKey":"oneOf.0.kms_info.oneOf.0.ca_pubkey.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_info.oneOf.0.ca_pubkey","typeLabel":"string | null"},"k256_pubkey":{"oneOf":[{"type":"string","title":"K256 Pubkey","description":"KMS k256 public key used to verify env encryption pubkey signatures","uniqueKey":"oneOf.0.kms_info.oneOf.0.k256_pubkey.oneOf.0","typeLabel":"string"},{"type":"null","title":"K256 Pubkey","description":"KMS k256 public key used to verify env encryption pubkey signatures","uniqueKey":"oneOf.0.kms_info.oneOf.0.k256_pubkey.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_info.oneOf.0.k256_pubkey","typeLabel":"string | null"}},"uniqueKey":"oneOf.0.kms_info.oneOf.0","typeLabel":"KMSInfo · object"},{"type":"null","uniqueKey":"oneOf.0.kms_info.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.kms_info","typeLabel":"KMSInfo · object | null"},"fmspc":{"oneOf":[{"type":"string","title":"Fmspc","uniqueKey":"oneOf.0.fmspc.oneOf.0","typeLabel":"string"},{"type":"null","title":"Fmspc","uniqueKey":"oneOf.0.fmspc.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.fmspc","typeLabel":"string | null"},"device_id":{"oneOf":[{"type":"string","title":"Device Id","uniqueKey":"oneOf.0.device_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Device Id","uniqueKey":"oneOf.0.device_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.device_id","typeLabel":"string | null"},"os_image_hash":{"oneOf":[{"type":"string","title":"Os Image Hash","uniqueKey":"oneOf.0.os_image_hash.oneOf.0","typeLabel":"string"},{"type":"null","title":"Os Image Hash","uniqueKey":"oneOf.0.os_image_hash.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.os_image_hash","typeLabel":"string | null"},"instance_type":{"oneOf":[{"type":"string","title":"Instance Type","uniqueKey":"oneOf.0.instance_type.oneOf.0","typeLabel":"string"},{"type":"null","title":"Instance Type","uniqueKey":"oneOf.0.instance_type.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.instance_type","typeLabel":"string | null"},"token":{"oneOf":[{"type":"string","title":"Token","description":"Commit token for POST /cvms. Present for same-path two-phase create.","uniqueKey":"oneOf.0.token.oneOf.0","typeLabel":"string"},{"type":"null","title":"Token","description":"Commit token for POST /cvms. Present for same-path two-phase create.","uniqueKey":"oneOf.0.token.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.0.token","typeLabel":"string | null"}},"uniqueKey":"oneOf.0","typeLabel":"ProvisionDstackAppResponseV2 · object"},{"type":"object","title":"CreatedVM","description":"POST /cvms commit response: the created CVM, plus a launch token issued by this create.","required":["id","name","status","teepod_id","app_id","vcpu","memory","disk_size","created_at"],"properties":{"id":{"oneOf":[{"type":"integer","title":"Id","isRequired":true,"uniqueKey":"oneOf.1.id.oneOf.0","typeLabel":"integer"},{"type":"string","title":"HashedId[cvms]","description":"A hashed identifier that maps to an internal database ID","format":"hashid","pattern":"^cvm_.+","example":"cvm_0123abcd","isRequired":true,"uniqueKey":"oneOf.1.id.oneOf.1","typeLabel":"string\u003chashid>"}],"isRequired":true,"uniqueKey":"oneOf.1.id","typeLabel":"integer | string\u003chashid>"},"name":{"type":"string","title":"Name","isRequired":true,"uniqueKey":"oneOf.1.name","typeLabel":"string"},"status":{"type":"string","title":"Status","isRequired":true,"uniqueKey":"oneOf.1.status","typeLabel":"string"},"teepod_id":{"type":"integer","title":"Teepod Id","isRequired":true,"uniqueKey":"oneOf.1.teepod_id","typeLabel":"integer"},"app_id":{"type":"string","title":"App Id","isRequired":true,"uniqueKey":"oneOf.1.app_id","typeLabel":"string"},"vcpu":{"type":"integer","title":"Vcpu","isRequired":true,"uniqueKey":"oneOf.1.vcpu","typeLabel":"integer"},"memory":{"type":"integer","title":"Memory","isRequired":true,"uniqueKey":"oneOf.1.memory","typeLabel":"integer"},"disk_size":{"type":"integer","title":"Disk Size","isRequired":true,"uniqueKey":"oneOf.1.disk_size","typeLabel":"integer"},"created_at":{"type":"string","format":"date-time","title":"Created At","isRequired":true,"uniqueKey":"oneOf.1.created_at","typeLabel":"string\u003cdate-time>"},"teepod":{"oneOf":[{"type":"object","title":"TeepodMeta","required":["id","name"],"properties":{"id":{"type":"integer","title":"Id","isRequired":true,"uniqueKey":"oneOf.1.teepod.oneOf.0.id","typeLabel":"integer"},"name":{"type":"string","title":"Name","isRequired":true,"uniqueKey":"oneOf.1.teepod.oneOf.0.name","typeLabel":"string"}},"uniqueKey":"oneOf.1.teepod.oneOf.0","typeLabel":"TeepodMeta · object"},{"type":"null","uniqueKey":"oneOf.1.teepod.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.teepod","typeLabel":"TeepodMeta · object | null"},"user_id":{"oneOf":[{"type":"integer","title":"User Id","uniqueKey":"oneOf.1.user_id.oneOf.0","typeLabel":"integer"},{"type":"string","title":"HashedId[users]","description":"A hashed identifier that maps to an internal database ID","format":"hashid","pattern":"^usr_.+","example":"usr_0123abcd","uniqueKey":"oneOf.1.user_id.oneOf.1","typeLabel":"string\u003chashid>"},{"type":"null","title":"User Id","uniqueKey":"oneOf.1.user_id.oneOf.2","typeLabel":"null"}],"uniqueKey":"oneOf.1.user_id","typeLabel":"integer | string\u003chashid> | null"},"vm_uuid":{"oneOf":[{"type":"string","title":"Vm Uuid","uniqueKey":"oneOf.1.vm_uuid.oneOf.0","typeLabel":"string"},{"type":"null","title":"Vm Uuid","uniqueKey":"oneOf.1.vm_uuid.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.vm_uuid","typeLabel":"string | null"},"instance_id":{"oneOf":[{"type":"string","title":"Instance Id","uniqueKey":"oneOf.1.instance_id.oneOf.0","typeLabel":"string"},{"type":"null","title":"Instance Id","uniqueKey":"oneOf.1.instance_id.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.instance_id","typeLabel":"string | null"},"app_url":{"oneOf":[{"type":"string","title":"App Url","uniqueKey":"oneOf.1.app_url.oneOf.0","typeLabel":"string"},{"type":"null","title":"App Url","uniqueKey":"oneOf.1.app_url.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.app_url","typeLabel":"string | null"},"base_image":{"oneOf":[{"type":"string","title":"Base Image","uniqueKey":"oneOf.1.base_image.oneOf.0","typeLabel":"string"},{"type":"null","title":"Base Image","uniqueKey":"oneOf.1.base_image.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.base_image","typeLabel":"string | null"},"manifest_version":{"oneOf":[{"type":"integer","title":"Manifest Version","uniqueKey":"oneOf.1.manifest_version.oneOf.0","typeLabel":"integer"},{"type":"null","title":"Manifest Version","uniqueKey":"oneOf.1.manifest_version.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.manifest_version","typeLabel":"integer | null"},"version":{"oneOf":[{"type":"string","title":"Version","uniqueKey":"oneOf.1.version.oneOf.0","typeLabel":"string"},{"type":"null","title":"Version","uniqueKey":"oneOf.1.version.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.version","typeLabel":"string | null"},"runner":{"oneOf":[{"type":"string","title":"Runner","uniqueKey":"oneOf.1.runner.oneOf.0","typeLabel":"string"},{"type":"null","title":"Runner","uniqueKey":"oneOf.1.runner.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.runner","typeLabel":"string | null"},"docker_compose_file":{"oneOf":[{"type":"string","title":"Docker Compose File","uniqueKey":"oneOf.1.docker_compose_file.oneOf.0","typeLabel":"string"},{"type":"null","title":"Docker Compose File","uniqueKey":"oneOf.1.docker_compose_file.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.docker_compose_file","typeLabel":"string | null"},"features":{"oneOf":[{"type":"array","items":{"type":"string","uniqueKey":"oneOf.1.features.oneOf.0.items.[INDEX]","typeLabel":"string"},"title":"Features","uniqueKey":"oneOf.1.features.oneOf.0","typeLabel":"string[]"},{"type":"null","title":"Features","uniqueKey":"oneOf.1.features.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.features","typeLabel":"string[] | null"},"encrypted_env_pubkey":{"oneOf":[{"type":"string","title":"Encrypted Env Pubkey","uniqueKey":"oneOf.1.encrypted_env_pubkey.oneOf.0","typeLabel":"string"},{"type":"null","title":"Encrypted Env Pubkey","uniqueKey":"oneOf.1.encrypted_env_pubkey.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.encrypted_env_pubkey","typeLabel":"string | null"},"launch_token":{"oneOf":[{"type":"string","title":"Launch Token","description":"Plaintext launch token this create stored on a new app (requested with launch_token or generate_launch_token). Returned only here, once; store it. Phala Cloud and the node operator can read it, so it protects only against parties who know the public compose.","uniqueKey":"oneOf.1.launch_token.oneOf.0","typeLabel":"string"},{"type":"null","title":"Launch Token","description":"Plaintext launch token this create stored on a new app (requested with launch_token or generate_launch_token). Returned only here, once; store it. Phala Cloud and the node operator can read it, so it protects only against parties who know the public compose.","uniqueKey":"oneOf.1.launch_token.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.1.launch_token","typeLabel":"string | null"}},"uniqueKey":"oneOf.1","typeLabel":"CreatedVM · object"}],"uniqueKey":"","typeLabel":"ProvisionDstackAppResponseV2 · object | CreatedVM · object"},"examples":{"Example":{"title":"Example","value":{"compose_hash":"\u003cstring>","compose_file":"\u003cstring>","os_image_version":"\u003cstring>","requires_gpu":true,"app_id":"\u003cstring>","app_env_encrypt_pubkey":"\u003cstring>","teepod_version":"\u003cstring>","kms_info":{"id":"kms_0123abcd","url":"\u003cstring>","version":"\u003cstring>","slug":"\u003cstring>","chain_id":123,"kms_contract_address":"\u003cstring>","gateway_app_id":"\u003cstring>","ca_pubkey":"\u003cstring>","k256_pubkey":"\u003cstring>"},"fmspc":"\u003cstring>","device_id":"\u003cstring>","os_image_hash":"\u003cstring>","instance_type":"\u003cstring>","token":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"24ab6405-e084-4333-96c6-6c03780d9197":{"description":"Invalid payload or provision data expired","content":{"_mintlify/placeholder":{"schema":{"type":"object","description":""}}}},"05da74e1-9be6-4fff-b7f1-40ec1b484b7a":{"description":"Authentication required or invalid token","content":{"_mintlify/placeholder":{"schema":{"type":"object","description":""}}}},"4fedf3c9-e630-4dcd-926c-6662a67384ff":{"description":"Commit token belongs to another workspace","content":{"_mintlify/placeholder":{"schema":{"type":"object","description":""}}}},"c86942b4-91f6-45e9-a21c-d9537772c8be":{"description":"Commit token is already being processed","content":{"_mintlify/placeholder":{"schema":{"type":"object","description":""}}}},"c09aab8d-a610-4e2a-ad25-fddf668a0997":{"description":"CVM create request exceeds the byte limit","content":{"_mintlify/placeholder":{"schema":{"type":"object","description":""}}}},"32e61da3-ce43-40e4-9545-cd94072e542b":{"description":"Validation error or provision data not found","content":{"_mintlify/placeholder":{"schema":{"type":"object","description":""}}}}},"security":{},"servers":{"f8681adb-18b5-43a6-97a9-503a02fd6af3":{"url":"https://cloud-api.phala.com"}}},"originalFileLocation":"openapi.json"},"subdomain":"phalanetwork-1606097b","siteName":"Phala","title":"Phala Cloud Documentation — Private AI on TEE","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-07T14:53:09.030Z","originalFileLocation":"api-reference/cvms/create-cvm-two-phase-on-one-path.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.\">\u003cmeta data-mint-head name=\"keywords\" content=\"Phala Cloud, TEE, Trusted Execution Environment, Confidential Computing, Private AI, confidential AI, GPU TEE, Intel TDX, dstack, blockchain, privacy-preserving computing, secure cloud, attestation\">\u003cmeta data-mint-head name=\"application-name\" content=\"Phala\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003cmeta data-mint-head name=\"robots\" content=\"index, follow\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Phala Cloud Documentation — Private AI on TEE\">\u003cmeta data-mint-head property=\"og:description\" content=\"Deploy confidential AI applications on Phala Cloud with hardware-level privacy via Intel TDX, NVIDIA H100 GPU TEE, and verifiable attestation.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Phala Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://raw.githubusercontent.com/Phala-Network/phala-docs/main/images/phala-docs-og.png\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Phala Cloud Documentation — Private AI on TEE\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Deploy confidential AI applications on Phala Cloud with hardware-level privacy via Intel TDX, NVIDIA H100 GPU TEE, and verifiable attestation.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://raw.githubusercontent.com/Phala-Network/phala-docs/main/images/phala-docs-og.png\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/phalanetwork-1606097b/nl48Duk5fn7pmYeb/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Phala\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#527a08\">\u003cmeta data-mint-head name=\"author\" content=\"Phala Cloud\">\u003cmeta data-mint-head name=\"category\" content=\"Technology\">\u003cmeta data-mint-head name=\"distribution\" content=\"global\">\u003cmeta data-mint-head name=\"language\" content=\"en\">\u003cmeta data-mint-head name=\"og:image:alt\" content=\"Phala Cloud — Confidential Computing \u0026amp; GPU TEE for AI\">\u003cmeta data-mint-head name=\"twitter:creator\" content=\"@PhalaNetwork\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/cvms/create-cvm-two-phase-on-one-path.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.phala.com/#organization\",\"name\":\"Phala\",\"url\":\"https://docs.phala.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/phalanetwork-1606097b/Y2wR1-jOsoYpAL6q/images/phala-light.png?fit=max\u0026auto=format\u0026n=Y2wR1-jOsoYpAL6q\u0026q=85\u0026s=fb4f438a36865810867d188289681376\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.phala.com#website\",\"name\":\"Phala\",\"url\":\"https://docs.phala.com\",\"publisher\":{\"@id\":\"https://docs.phala.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path#webpage\",\"url\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path\",\"name\":\"Create CVM (two-phase on one path)\",\"description\":\"Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.\",\"dateModified\":\"2026-11-07T14:53:09.030Z\",\"isPartOf\":{\"@id\":\"https://docs.phala.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Phala Cloud\",\"item\":\"https://docs.phala.com/phala-cloud/what-is/what-is-phala-cloud\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"API \u0026 SDK\",\"item\":\"https://docs.phala.com/phala-cloud/references/overview\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Phala Cloud API\",\"item\":\"https://docs.phala.com/phala-cloud/phala-cloud-api/overview\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Create CVM (two-phase on one path)\",\"item\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path#apireference\",\"headline\":\"Create CVM (two-phase on one path)\",\"name\":\"Create CVM (two-phase on one path)\",\"description\":\"Single entry point for CVM creation. Send a provision payload (compose_file + name) to prepare: validates the configuration, caches it for 14 days, and returns app_id, compose_hash, the env-encryption pubkey, and a commit token. Then send the token back with the encrypted environment to create the CVM. The legacy pair (POST /cvms/provision then POST /cvms with app_id + compose_hash) keeps working during the deprecation window.\",\"url\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path\",\"mainEntityOfPage\":{\"@id\":\"https://docs.phala.com/api-reference/cvms/create-cvm-two-phase-on-one-path#webpage\"},\"image\":\"https://raw.githubusercontent.com/Phala-Network/phala-docs/main/images/phala-docs-og.png\",\"dateModified\":\"2026-11-07T14:53:09.030Z\",\"publisher\":{\"@id\":\"https://docs.phala.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.phala.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Phala\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Phala","nav":{"global":null,"tabs":[{"tab":"Phala Cloud","icon":"cloud","pages":[{"group":"Phala Cloud","pages":[{"title":"What is Phala Cloud","href":"/phala-cloud/what-is/what-is-phala-cloud"},{"group":"Getting Started","pages":[{"title":"Quick Start","href":"/phala-cloud/getting-started/overview"},{"title":"Create Account","href":"/phala-cloud/getting-started/sign-up-for-cloud-account"},{"title":"CVM Deployment","href":"/phala-cloud/getting-started/start-from-cloud-ui"},{"title":"Deploy Your First CVM","href":"/phala-cloud/getting-started/deploy-first-cvm"},{"title":"Explore Templates","href":"/phala-cloud/getting-started/explore-templates/overview"},{"title":"Get and Verify Attestation","href":"/phala-cloud/getting-started/attestation"},{"title":"Migration from dstack v0.3","href":"/phala-cloud/references/migration-from-dstack-v03"}]},{"group":"CVM","pages":[{"title":"CVM Overview","href":"/phala-cloud/cvm/overview"},{"title":"CVM with Docker Compose","href":"/phala-cloud/cvm/create-with-docker-compose"},{"title":"Environment Variables","href":"/phala-cloud/cvm/set-secure-environment-variables"},{"title":"Private Container Registry","href":"/phala-cloud/cvm/create-with-private-docker-image"},{"title":"Scale with Multiple Replicas","href":"/phala-cloud/cvm/multi-replica-scaling"},{"title":"Replicating CVMs","href":"/phala-cloud/cvm/replicating-cvms"},{"title":"Launch Token","href":"/phala-cloud/cvm/launch-token"},{"title":"Advanced CVM Settings","href":"/phala-cloud/cvm/advanced-settings"},{"title":"Deployment Cheat Sheet","href":"/phala-cloud/cvm/deployment-cheat-sheet"},{"title":"OS Image","href":"/phala-cloud/cvm/image/overview"},{"title":"Database","href":"/phala-cloud/storage/access-database"},{"title":"Update Code","href":"/phala-cloud/update/upgrade-application"},{"title":"Scaling","href":"/phala-cloud/update/resize-resource"},{"title":"Update CVM Configuration","href":"/phala-cloud/update/update-cvm-configuration"}]},{"group":"GPU CVM","pages":[{"title":"Deploy AI Models in GPU TEE","href":"/phala-cloud/confidential-ai/gpu-tee-deployment-guide"},{"title":"Deploy and Verify GPU TEE","href":"/phala-cloud/confidential-ai/confidential-gpu/deploy-and-verify"},{"title":"Troubleshooting","href":"/phala-cloud/confidential-ai/confidential-gpu/troubleshooting"},{"title":"Benchmark","href":"/phala-cloud/confidential-ai/benchmark"}]},{"group":"Phala Cloud CLI","pages":[{"title":"CLI Overview","href":"/phala-cloud/phala-cloud-cli/overview"},{"title":"Deploy Your First CVM","href":"/phala-cloud/phala-cloud-cli/start-from-cloud-cli"},{"title":"phala.toml Configuration","href":"/phala-cloud/phala-cloud-cli/phala-toml"},{"title":"Set Up a CI/CD Pipeline","href":"/phala-cloud/phala-cloud-cli/ci-cd-automation/setup-a-ci-cd-pipeline"},{"group":"Deploy","pages":[{"title":"deploy","href":"/phala-cloud/phala-cloud-cli/deploy"},{"title":"instance-types","href":"/phala-cloud/phala-cloud-cli/instance-types"},{"group":"nodes","pages":[{"title":"nodes","hidden":true,"href":"/phala-cloud/phala-cloud-cli/nodes"},{"title":"nodes list","href":"/phala-cloud/phala-cloud-cli/nodes/list"}]},{"title":"os-images","href":"/phala-cloud/phala-cloud-cli/os-images"}]},{"group":"CVM Operations","pages":[{"title":"annotations","href":"/phala-cloud/phala-cloud-cli/annotations"},{"title":"cp","href":"/phala-cloud/phala-cloud-cli/cp"},{"title":"logs","href":"/phala-cloud/phala-cloud-cli/logs"},{"title":"ps","href":"/phala-cloud/phala-cloud-cli/ps"},{"title":"runtime-config","href":"/phala-cloud/phala-cloud-cli/runtime-config"},{"title":"ssh","href":"/phala-cloud/phala-cloud-cli/ssh"}]},{"group":"Resources","pages":[{"group":"apps","pages":[{"title":"apps","hidden":true,"href":"/phala-cloud/phala-cloud-cli/apps"},{"title":"apps launch-token","href":"/phala-cloud/phala-cloud-cli/apps/launch-token"}]},{"group":"instances","pages":[{"title":"instances","hidden":true,"href":"/phala-cloud/phala-cloud-cli/instances"},{"title":"instances ls","href":"/phala-cloud/phala-cloud-cli/instances/ls"},{"title":"instances add","href":"/phala-cloud/phala-cloud-cli/instances/add"},{"title":"instances rm","href":"/phala-cloud/phala-cloud-cli/instances/rm"}]},{"group":"cvms","pages":[{"title":"cvms","hidden":true,"href":"/phala-cloud/phala-cloud-cli/cvms"},{"title":"cvms attestation","href":"/phala-cloud/phala-cloud-cli/cvms/attestation"},{"title":"cvms delete","href":"/phala-cloud/phala-cloud-cli/cvms/delete"},{"title":"cvms device-allowlist","href":"/phala-cloud/phala-cloud-cli/cvms/device-allowlist"},{"title":"cvms get","href":"/phala-cloud/phala-cloud-cli/cvms/get"},{"title":"cvms list","href":"/phala-cloud/phala-cloud-cli/cvms/list"},{"title":"cvms list-nodes","href":"/phala-cloud/phala-cloud-cli/cvms/list-nodes"},{"title":"cvms logs (Deprecated)","href":"/phala-cloud/phala-cloud-cli/cvms/logs"},{"title":"cvms replicate","href":"/phala-cloud/phala-cloud-cli/cvms/replicate"},{"title":"cvms resize","href":"/phala-cloud/phala-cloud-cli/cvms/resize"},{"title":"cvms restart","href":"/phala-cloud/phala-cloud-cli/cvms/restart"},{"title":"cvms serial-logs (Deprecated)","href":"/phala-cloud/phala-cloud-cli/cvms/serial-logs"},{"title":"cvms start","href":"/phala-cloud/phala-cloud-cli/cvms/start"},{"title":"cvms stop","href":"/phala-cloud/phala-cloud-cli/cvms/stop"},{"title":"cvms upgrade (Deprecated)","href":"/phala-cloud/phala-cloud-cli/cvms/upgrade"}]},{"group":"envs","pages":[{"title":"envs","hidden":true,"href":"/phala-cloud/phala-cloud-cli/envs"},{"title":"envs encrypt","href":"/phala-cloud/phala-cloud-cli/envs/encrypt"},{"title":"envs update","href":"/phala-cloud/phala-cloud-cli/envs/update"}]},{"group":"ssh-keys","pages":[{"title":"ssh-keys","hidden":true,"href":"/phala-cloud/phala-cloud-cli/ssh-keys"},{"title":"ssh-keys list","href":"/phala-cloud/phala-cloud-cli/ssh-keys/list"},{"title":"ssh-keys add","href":"/phala-cloud/phala-cloud-cli/ssh-keys/add"},{"title":"ssh-keys remove","href":"/phala-cloud/phala-cloud-cli/ssh-keys/remove"},{"title":"ssh-keys import-github","href":"/phala-cloud/phala-cloud-cli/ssh-keys/import-github"}]},{"group":"allow-devices","pages":[{"title":"allow-devices","hidden":true,"href":"/phala-cloud/phala-cloud-cli/allow-devices"},{"title":"allow-devices list","href":"/phala-cloud/phala-cloud-cli/allow-devices/list"},{"title":"allow-devices add","href":"/phala-cloud/phala-cloud-cli/allow-devices/add"},{"title":"allow-devices remove","href":"/phala-cloud/phala-cloud-cli/allow-devices/remove"},{"title":"allow-devices allow-any","href":"/phala-cloud/phala-cloud-cli/allow-devices/allow-any"},{"title":"allow-devices disallow-any","href":"/phala-cloud/phala-cloud-cli/allow-devices/disallow-any"},{"title":"allow-devices toggle-allow-any","href":"/phala-cloud/phala-cloud-cli/allow-devices/toggle-allow-any"}]},{"group":"kms","pages":[{"title":"kms","hidden":true,"href":"/phala-cloud/phala-cloud-cli/kms"},{"title":"kms list","href":"/phala-cloud/phala-cloud-cli/kms/list"},{"title":"kms nodes","href":"/phala-cloud/phala-cloud-cli/kms/nodes"},{"title":"kms ethereum","href":"/phala-cloud/phala-cloud-cli/kms/ethereum"},{"title":"kms base","href":"/phala-cloud/phala-cloud-cli/kms/base"},{"title":"kms phala","href":"/phala-cloud/phala-cloud-cli/kms/phala"}]}]},{"group":"Profile \u0026 Auth","pages":[{"title":"login","href":"/phala-cloud/phala-cloud-cli/login"},{"title":"logout","href":"/phala-cloud/phala-cloud-cli/logout"},{"group":"profiles","pages":[{"title":"profiles","hidden":true,"href":"/phala-cloud/phala-cloud-cli/profiles"},{"title":"profiles use","href":"/phala-cloud/phala-cloud-cli/profiles/use"},{"title":"profiles rename","href":"/phala-cloud/phala-cloud-cli/profiles/rename"},{"title":"profiles delete","href":"/phala-cloud/phala-cloud-cli/profiles/delete"}]},{"title":"status","href":"/phala-cloud/phala-cloud-cli/status"},{"title":"switch","href":"/phala-cloud/phala-cloud-cli/switch"},{"title":"whoami","href":"/phala-cloud/phala-cloud-cli/whoami"},{"title":"link","href":"/phala-cloud/phala-cloud-cli/link"}]},{"group":"Dev Tools","pages":[{"title":"api","href":"/phala-cloud/phala-cloud-cli/api"},{"group":"simulator","pages":[{"title":"simulator","hidden":true,"href":"/phala-cloud/phala-cloud-cli/simulator"},{"title":"simulator start","href":"/phala-cloud/phala-cloud-cli/simulator/start"},{"title":"simulator stop","href":"/phala-cloud/phala-cloud-cli/simulator/stop"}]},{"title":"keccak256sum","href":"/phala-cloud/phala-cloud-cli/keccak256sum"}]},{"group":"Misc","pages":[{"title":"phala completion","href":"/phala-cloud/phala-cloud-cli/completion"},{"group":"self","pages":[{"title":"self","hidden":true,"href":"/phala-cloud/phala-cloud-cli/self"},{"title":"self update","href":"/phala-cloud/phala-cloud-cli/self/update"}]}]},{"title":"Changelog","href":"/phala-cloud/phala-cloud-cli/changelog"},{"group":"Deprecated","pages":[{"group":"auth","pages":[{"title":"auth (Deprecated)","hidden":true,"href":"/phala-cloud/phala-cloud-cli/auth"},{"title":"auth login (Deprecated)","href":"/phala-cloud/phala-cloud-cli/auth/login"},{"title":"auth logout (Deprecated)","href":"/phala-cloud/phala-cloud-cli/auth/logout"},{"title":"auth status (Deprecated)","href":"/phala-cloud/phala-cloud-cli/auth/status"}]},{"group":"config","pages":[{"title":"config (Deprecated)","hidden":true,"href":"/phala-cloud/phala-cloud-cli/config"},{"title":"config get","href":"/phala-cloud/phala-cloud-cli/config/get"},{"title":"config list","href":"/phala-cloud/phala-cloud-cli/config/list"},{"title":"config set","href":"/phala-cloud/phala-cloud-cli/config/set"}]}]}]},{"group":"Networking","pages":[{"title":"Overview","href":"/phala-cloud/networking/overview"},{"title":"Quickstart","href":"/phala-cloud/networking/quickstart"},{"title":"Expose an HTTP Service","href":"/phala-cloud/networking/expose-http-service"},{"title":"Set Up a Custom Domain","href":"/phala-cloud/networking/setup-custom-domain"},{"title":"Expose TCP Services","href":"/phala-cloud/networking/expose-tcp-service"},{"title":"Enable SSH Access","href":"/phala-cloud/networking/enable-ssh-access"},{"title":"TLS Passthrough","href":"/phala-cloud/networking/tls-passthrough"},{"title":"Set Up gRPC Services","href":"/phala-cloud/networking/setup-grpc-service"},{"title":"Architecture","href":"/phala-cloud/networking/architecture"},{"title":"Network Security","href":"/phala-cloud/networking/security"},{"title":"Domain Attestation","href":"/phala-cloud/networking/domain-attestation"},{"title":"Reference","href":"/phala-cloud/networking/specifications"},{"title":"Troubleshooting","href":"/phala-cloud/networking/troubleshooting"}]},{"group":"Onchain KMS","pages":[{"title":"What is KMS","href":"/phala-cloud/key-management/key-management-protocol"},{"title":"Cloud vs Onchain KMS","href":"/phala-cloud/key-management/cloud-vs-onchain-kms"},{"title":"Understanding Onchain KMS","href":"/phala-cloud/key-management/understanding-onchain-kms"},{"title":"Deploying with Onchain KMS","href":"/phala-cloud/key-management/deploying-with-onchain-kms"},{"title":"Updating with Onchain KMS","href":"/phala-cloud/key-management/updating-with-onchain-kms"},{"title":"Device Management","href":"/phala-cloud/key-management/device-management"},{"title":"Multisig and Governance","href":"/phala-cloud/key-management/multisig-governance"},{"group":"Derived Keys","pages":[{"title":"Get a Deterministic Key","href":"/phala-cloud/key-management/get-a-key"},{"title":"Create Crypto Wallets","href":"/phala-cloud/key-management/create-crypto-wallet"}]}]},{"group":"Trust Center \u0026 Attestation","pages":[{"group":"Trust Center","pages":[{"title":"Trust Center Verification","href":"/phala-cloud/attestation/trust-center-verification"},{"title":"Become a Featured Builder","href":"/phala-cloud/attestation/feature-builder"}]},{"group":"Attestation","pages":[{"title":"Overview","href":"/phala-cloud/attestation/overview"},{"title":"Quickstart","href":"/phala-cloud/attestation/quickstart"},{"title":"Get Attestation","href":"/phala-cloud/attestation/get-attestation"},{"title":"Verify Your Application","href":"/phala-cloud/attestation/verify-your-application"},{"title":"Verify the Platform","href":"/phala-cloud/attestation/verify-the-platform"},{"title":"End-to-End Attestation Verification","href":"/phala-cloud/attestation/verification-guide"},{"title":"Complete Chain of Trust","href":"/phala-cloud/attestation/chain-of-trust"},{"title":"Attestation Fields Reference","href":"/phala-cloud/attestation/attestation-fields"}]}]},{"group":"Security \u0026 Compliance","pages":[{"title":"Compliance \u0026 Certifications","href":"/phala-cloud/security-and-privacy/compliance"},{"title":"Security Audit Report","href":"/phala-cloud/security-and-privacy/security-audit"},{"title":"Security Architecture","href":"/phala-cloud/security-and-privacy/security-architecture"},{"title":"Privacy","href":"/phala-cloud/security-and-privacy/privacy"}]},{"group":"Observability","pages":[{"title":"Public Logs","href":"/phala-cloud/monitoring/public-logs"},{"title":"Serial Logs","href":"/phala-cloud/monitoring/serials-logs"},{"title":"Private Log Viewer","href":"/phala-cloud/monitoring/private-log-viewer"},{"title":"Datadog Integration","href":"/phala-cloud/monitoring/datadog-integration"},{"title":"Troubleshooting Guide","href":"/phala-cloud/troubleshooting/troubleshooting"},{"title":"Private Log Viewer","href":"/phala-cloud/troubleshooting/private-log-viewer"},{"title":"Debug Application","href":"/phala-cloud/troubleshooting/debug-your-application"},{"title":"Production Checklist","href":"/phala-cloud/production-checklist"},{"title":"Performance Report","href":"/phala-cloud/references/performance-report"}]},{"group":"API \u0026 SDK","pages":[{"title":"Overview","href":"/phala-cloud/references/overview"},{"group":"Phala Cloud API","pages":[{"title":"API Overview","href":"/phala-cloud/phala-cloud-api/overview"},{"title":"Attestation API Reference","href":"/phala-cloud/phala-cloud-api/attestations"},{"title":"CVM Deployment via API","href":"/phala-cloud/references/api-deployment-guide"},{"group":"Apps","pages":[{"title":"List apps","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps","href":"/api-reference/apps/list-apps"},{"title":"Get app filter options","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/filter-options","href":"/api-reference/apps/get-app-filter-options"},{"title":"Get app details","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}","href":"/api-reference/apps/get-app-details"},{"title":"Get app attestation data","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/attestations","href":"/api-reference/apps/get-app-attestation-data"},{"title":"Run app TCB evaluation","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/attestations/tcb-evaluation","href":"/api-reference/apps/run-app-tcb-evaluation"},{"title":"List app CVMs","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/cvms","href":"/api-reference/apps/list-app-cvms"},{"title":"Batch check on-chain deployment allowance for all CVMs under an app","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/apps/{app_id}/cvms/is-allowed","href":"/api-reference/apps/batch-check-on-chain-deployment-allowance-for-all-cvms-under-an-app"},{"title":"Create CVM replica","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/apps/{app_id}/cvms/{vm_uuid}/replicas","href":"/api-reference/apps/create-cvm-replica"},{"title":"Create a new instance under an existing app","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/apps/{app_id}/instances","href":"/api-reference/apps/create-a-new-instance-under-an-existing-app"},{"title":"Get device allowlist status","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/device-allowlist","href":"/api-reference/apps/get-device-allowlist-status"},{"title":"Check if app deployment is allowed on-chain","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/apps/{app_id}/is-allowed","href":"/api-reference/apps/check-if-app-deployment-is-allowed-on-chain"},{"title":"Set or rotate the app launch token","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/apps/{app_id}/launch-token","href":"/api-reference/apps/set-or-rotate-the-app-launch-token"},{"title":"Clear the app launch token","deprecated":null,"version":null,"openapi":"/openapi.json delete /api/v1/apps/{app_id}/launch-token","href":"/api-reference/apps/clear-the-app-launch-token"},{"title":"Get app on-chain KMS info","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/kms-info","href":"/api-reference/apps/get-app-on-chain-kms-info"},{"title":"Get pending compose updates","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/pending-updates","href":"/api-reference/apps/get-pending-compose-updates"},{"title":"Preview a pending compose update","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/pending-updates/{vm_uuid}/{compose_hash}/preview","href":"/api-reference/apps/preview-a-pending-compose-update"},{"title":"List app revisions","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/revisions","href":"/api-reference/apps/list-app-revisions"},{"title":"Get revision detail","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/revisions/{revision_id}","href":"/api-reference/apps/get-revision-detail"},{"title":"Redeploy app from a specific revision","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/apps/{app_id}/revisions/{revision_id}/redeploy","href":"/api-reference/apps/redeploy-app-from-a-specific-revision"},{"title":"Get app metered usage","description":"Returns billing usage records from ClickHouse. Defaults to 7-day window if dates not specified.","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/apps/{app_id}/usage","href":"/api-reference/apps/get-app-metered-usage"}]},{"group":"CVMs","pages":[{"title":"Create CVM (two-phase on one path)","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms","href":"/api-reference/cvms/create-cvm-two-phase-on-one-path"},{"title":"List CVMs","description":"Returns CVMs in current workspace.","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms","href":"/api-reference/cvms/list-cvms"},{"title":"List CVMs (paginated)","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/paginated","href":"/api-reference/cvms/list-cvms-paginated"},{"title":"Batch stop CVMs","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/batch-stop","href":"/api-reference/cvms/batch-stop-cvms"},{"title":"Batch refresh CVM instance IDs","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/instance-ids","href":"/api-reference/cvms/batch-refresh-cvm-instance-ids"},{"title":"Handle Batch Cvm Status","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/status/batch","href":"/api-reference/user/handle-batch-cvm-status"},{"title":"Get CVM details","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}","href":"/api-reference/cvms/get-cvm-details"},{"title":"Delete CVM","deprecated":null,"version":null,"openapi":"/openapi.json delete /api/v1/cvms/{cvm_id}","href":"/api-reference/cvms/delete-cvm"},{"title":"Update CVM","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}","href":"/api-reference/cvms/update-cvm"},{"title":"Get CVM annotations","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/annotations","href":"/api-reference/cvms/get-cvm-annotations"},{"title":"Replace CVM annotations","deprecated":null,"version":null,"openapi":"/openapi.json put /api/v1/cvms/{cvm_id}/annotations","href":"/api-reference/cvms/replace-cvm-annotations"},{"title":"Get CVM attestation","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/attestation","href":"/api-reference/cvms/get-cvm-attestation"},{"title":"List available OS images","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/available-os-images","href":"/api-reference/cvms/list-available-os-images"},{"title":"Commit CVM replica (token-based, no auth required)","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/commit-replica","href":"/api-reference/cvms/commit-cvm-replica-token-based-no-auth-required"},{"title":"Get commit token info (no auth required)","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/commit-update","href":"/api-reference/cvms/get-commit-token-info-no-auth-required"},{"title":"Commit CVM update (token-based, no auth required)","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/commit-update","href":"/api-reference/cvms/commit-cvm-update-token-based-no-auth-required"},{"title":"Get raw compose file","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/compose_file","href":"/api-reference/cvms/get-raw-compose-file"},{"title":"Trigger compose file update","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/compose_file","href":"/api-reference/cvms/trigger-compose-file-update"},{"title":"Submit compose file update","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/compose_file","href":"/api-reference/cvms/submit-compose-file-update"},{"title":"Provision compose file update","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/compose_file/provision","href":"/api-reference/cvms/provision-compose-file-update"},{"title":"Diagnose custom domain DNS","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/customize-domain-diagnose","href":"/api-reference/cvms/diagnose-custom-domain-dns"},{"title":"Update Docker Compose file","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/docker-compose","href":"/api-reference/cvms/update-docker-compose-file"},{"title":"Get staged CVM changes","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/draft","href":"/api-reference/cvms/get-staged-cvm-changes"},{"title":"Stage CVM changes","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/draft","href":"/api-reference/cvms/stage-cvm-changes"},{"title":"Discard staged CVM changes","deprecated":null,"version":null,"openapi":"/openapi.json delete /api/v1/cvms/{cvm_id}/draft","href":"/api-reference/cvms/discard-staged-cvm-changes"},{"title":"Apply staged CVM changes","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/draft/apply","href":"/api-reference/cvms/apply-staged-cvm-changes"},{"title":"Get Docker Compose file","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/docker-compose.yml","href":"/api-reference/cvms/get-docker-compose-file"},{"title":"Update environment variables","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/envs","href":"/api-reference/cvms/update-environment-variables"},{"title":"Get firewall availability for this CVM's node","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/firewall-status","href":"/api-reference/cvms/get-firewall-availability-for-this-cvms-node"},{"title":"Get CVM init scripts","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/init-scripts","href":"/api-reference/cvms/get-cvm-init-scripts"},{"title":"Refresh CVM instance ID","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/instance-id","href":"/api-reference/cvms/refresh-cvm-instance-id"},{"title":"Set Trust Center listing for the app","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/listed","href":"/api-reference/cvms/set-trust-center-listing-for-the-app"},{"title":"Handle Update Cvm Name","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/name","href":"/api-reference/cvms/handle-update-cvm-name"},{"title":"Get CVM network info","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/network","href":"/api-reference/cvms/get-cvm-network-info"},{"title":"Get network configuration","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/network-config","href":"/api-reference/cvms/get-network-configuration"},{"title":"Update KMS/Gateway URLs","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/network-config","href":"/api-reference/cvms/update-kmsgateway-urls"},{"title":"Get operation status","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/operation-status","href":"/api-reference/cvms/get-operation-status"},{"title":"List CVM operations","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/operations","href":"/api-reference/cvms/list-cvm-operations"},{"title":"Cancel in-progress CVM operation","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/operations/cancel","href":"/api-reference/cvms/cancel-in-progress-cvm-operation"},{"title":"Update OS image","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/os-image","href":"/api-reference/cvms/update-os-image"},{"title":"Get port mappings","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/ports","href":"/api-reference/cvms/get-port-mappings"},{"title":"Set port mappings","deprecated":null,"version":null,"openapi":"/openapi.json put /api/v1/cvms/{cvm_id}/ports","href":"/api-reference/cvms/set-port-mappings"},{"title":"Get pre-launch script","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/pre-launch-script","href":"/api-reference/cvms/get-pre-launch-script"},{"title":"Update pre-launch script","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/pre-launch-script","href":"/api-reference/cvms/update-pre-launch-script"},{"title":"Replicate CVM","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/replicas","href":"/api-reference/cvms/replicate-cvm"},{"title":"Restart CVM","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/restart","href":"/api-reference/cvms/restart-cvm"},{"title":"Redeploy CVM from a specific revision","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/revisions/{revision_id}/redeploy","href":"/api-reference/cvms/redeploy-cvm-from-a-specific-revision"},{"title":"Handle Update Cvm Scheduled Delete","deprecated":null,"version":null,"openapi":"/openapi.json patch /api/v1/cvms/{cvm_id}/scheduled-delete","href":"/api-reference/cvms/handle-update-cvm-scheduled-delete"},{"title":"Shutdown CVM","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/shutdown","href":"/api-reference/cvms/shutdown-cvm"},{"title":"Start CVM","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/start","href":"/api-reference/cvms/start-cvm"},{"title":"Handle Get Cvm State","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/state","href":"/api-reference/cvms/handle-get-cvm-state"},{"title":"Get CVM system stats","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/stats","href":"/api-reference/cvms/get-cvm-system-stats"},{"title":"Force stop CVM","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/cvms/{cvm_id}/stop","href":"/api-reference/cvms/force-stop-cvm"},{"title":"Get CVM user config","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/cvms/{cvm_id}/user_config","href":"/api-reference/cvms/get-cvm-user-config"}]},{"group":"Attestations","pages":[{"title":"Verify TEE quote","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/attestations/verify","href":"/api-reference/public/verify-tee-quote"},{"title":"View quote details","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/attestations/view/{checksum}","href":"/api-reference/public/view-quote-details"},{"title":"Get quote collateral","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/attestations/collateral/{checksum}","href":"/api-reference/public/get-quote-collateral"},{"title":"Download raw quote","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/attestations/raw/{checksum}","href":"/api-reference/public/download-raw-quote"},{"title":"Check raw quote exists","deprecated":null,"version":null,"openapi":"/openapi.json head /api/v1/attestations/raw/{checksum}","href":"/api-reference/public/check-raw-quote-exists"},{"title":"List recent quotes","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/attestations/recent","href":"/api-reference/public/list-recent-quotes"},{"title":"List nodes","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/attestations/nodes","href":"/api-reference/public/list-nodes"},{"title":"List node device IDs","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/attestations/device_ids","href":"/api-reference/public/list-node-device-ids"},{"title":"List node PPIDs","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/attestations/ppids","href":"/api-reference/public/list-node-ppids"}]},{"group":"KMS","pages":[{"title":"List KMS contracts","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/kms","href":"/api-reference/public/list-kms-contracts"},{"title":"Get KMS contract details","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/kms/{kms_id}","href":"/api-reference/public/get-kms-contract-details"},{"title":"Inspect KMS instance","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/kms/{kms_id}/info","href":"/api-reference/public/inspect-kms-instance"},{"title":"Get app encryption pubkey","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/kms/{kms_id}/pubkey/{app_id}","href":"/api-reference/public/get-app-encryption-pubkey"},{"title":"Get on-chain KMS details by chain","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/kms/on-chain/{chain}","href":"/api-reference/public/get-on-chain-kms-details-by-chain"},{"title":"Predict next app IDs","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/kms/phala/next_app_id","href":"/api-reference/kms/predict-next-app-ids"}]},{"group":"SSH Keys","pages":[{"title":"List user SSH keys","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/user/ssh-keys","href":"/api-reference/user/list-user-ssh-keys"},{"title":"Add SSH key","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/user/ssh-keys","href":"/api-reference/user/add-ssh-key"},{"title":"Delete SSH key","deprecated":null,"version":null,"openapi":"/openapi.json delete /api/v1/user/ssh-keys/{key_id}","href":"/api-reference/user/delete-ssh-key"},{"title":"Import keys from GitHub profile","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/user/ssh-keys/github-profile","href":"/api-reference/user/import-keys-from-github-profile"},{"title":"Sync keys from GitHub","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/user/ssh-keys/github-sync","href":"/api-reference/user/sync-keys-from-github"}]},{"group":"Instance Types","pages":[{"title":"List instance type families","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/instance-types","href":"/api-reference/public/list-instance-type-families"},{"title":"List family instance types","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/instance-types/{family}","href":"/api-reference/public/list-family-instance-types"}]},{"group":"Webhooks","pages":[{"title":"List workspace webhooks","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/workspace/webhooks","href":"/api-reference/webhooks/list-workspace-webhooks"},{"title":"Create workspace webhook","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/workspace/webhooks","href":"/api-reference/webhooks/create-workspace-webhook"},{"title":"Get webhook details","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/workspace/webhooks/{webhook_id}","href":"/api-reference/webhooks/get-webhook-details"},{"title":"Update webhook","deprecated":null,"version":null,"openapi":"/openapi.json put /api/v1/workspace/webhooks/{webhook_id}","href":"/api-reference/webhooks/update-webhook"},{"title":"Delete webhook","deprecated":null,"version":null,"openapi":"/openapi.json delete /api/v1/workspace/webhooks/{webhook_id}","href":"/api-reference/webhooks/delete-webhook"},{"title":"Reveal webhook secret (requires 2FA)","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/workspace/webhooks/{webhook_id}/reveal-secret","href":"/api-reference/webhooks/reveal-webhook-secret-requires-2fa"},{"title":"Rotate webhook secret (requires 2FA)","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/workspace/webhooks/{webhook_id}/rotate-secret","href":"/api-reference/webhooks/rotate-webhook-secret-requires-2fa"},{"title":"Send test webhook event","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/workspace/webhooks/{webhook_id}/test","href":"/api-reference/webhooks/send-test-webhook-event"},{"title":"List webhook deliveries","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/workspace/webhooks/{webhook_id}/deliveries","href":"/api-reference/webhooks/list-webhook-deliveries"},{"title":"Resend a webhook delivery","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v1/workspace/webhooks/{webhook_id}/deliveries/{event_id}/resend","href":"/api-reference/webhooks/resend-a-webhook-delivery"},{"title":"Get webhook delivery stats","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v1/workspace/webhooks/{webhook_id}/stats","href":"/api-reference/webhooks/get-webhook-delivery-stats"}]}]},{"group":"JavaScript SDK","pages":[{"title":"Cloud JS SDK","href":"/phala-cloud/references/cloud-js-sdk/overview"},{"title":"Authentication","href":"/phala-cloud/references/cloud-js-sdk/authentication"},{"title":"CVM Lifecycle","href":"/phala-cloud/references/cloud-js-sdk/cvm-lifecycle"},{"title":"CVM Configuration","href":"/phala-cloud/references/cloud-js-sdk/cvm-configuration"},{"title":"CVM Query","href":"/phala-cloud/references/cloud-js-sdk/cvm-query"},{"title":"provisionCvm","href":"/phala-cloud/references/cloud-js-sdk/provision-cvm"},{"title":"commitCvmProvision","href":"/phala-cloud/references/cloud-js-sdk/commit-cvm-provision"},{"title":"updateCvmEnvs","href":"/phala-cloud/references/cloud-js-sdk/update-cvm-envs"},{"title":"updateDockerCompose","href":"/phala-cloud/references/cloud-js-sdk/update-docker-compose"},{"title":"watchCvmState","href":"/phala-cloud/references/cloud-js-sdk/watch-cvm-state"},{"title":"Apps","href":"/phala-cloud/references/cloud-js-sdk/apps"},{"title":"Workspaces","href":"/phala-cloud/references/cloud-js-sdk/workspaces"},{"title":"KMS","href":"/phala-cloud/references/cloud-js-sdk/kms"},{"title":"SSH Keys","href":"/phala-cloud/references/cloud-js-sdk/ssh-keys"},{"title":"Nodes \u0026 Instance Types","href":"/phala-cloud/references/cloud-js-sdk/nodes-and-instance-types"},{"title":"getAppEnvEncryptPubKey","href":"/phala-cloud/references/cloud-js-sdk/get-app-env-encrypt-pubkey"},{"title":"deployAppAuth","href":"/phala-cloud/references/cloud-js-sdk/deploy-app-auth"},{"title":"addComposeHash","href":"/phala-cloud/references/cloud-js-sdk/add-compose-hash"},{"title":"Schema Reference","href":"/phala-cloud/references/cloud-js-sdk/schema-reference"},{"title":"Error Handling","href":"/phala-cloud/references/cloud-js-sdk/error-handling"},{"title":"API Versioning","href":"/phala-cloud/references/cloud-js-sdk/api-versioning"},{"title":"Changelog","href":"/phala-cloud/references/cloud-js-sdk/changelog"}]},{"group":"Python SDK","pages":[{"title":"Cloud Python SDK","href":"/phala-cloud/references/cloud-python-sdk/overview"},{"title":"Authentication","href":"/phala-cloud/references/cloud-python-sdk/authentication"},{"title":"CVM Lifecycle","href":"/phala-cloud/references/cloud-python-sdk/cvm-lifecycle"},{"title":"CVM Configuration","href":"/phala-cloud/references/cloud-python-sdk/cvm-configuration"},{"title":"Apps","href":"/phala-cloud/references/cloud-python-sdk/apps"},{"title":"Workspaces","href":"/phala-cloud/references/cloud-python-sdk/workspaces"},{"title":"KMS","href":"/phala-cloud/references/cloud-python-sdk/kms"},{"title":"SSH Keys","href":"/phala-cloud/references/cloud-python-sdk/ssh-keys"},{"title":"Error Handling","href":"/phala-cloud/references/cloud-python-sdk/error-handling"},{"title":"Changelog","href":"/phala-cloud/references/cloud-python-sdk/changelog"}]},{"group":"Go SDK","pages":[{"title":"Cloud Go SDK","href":"/phala-cloud/references/cloud-go-sdk/overview"},{"title":"Authentication","href":"/phala-cloud/references/cloud-go-sdk/authentication"},{"title":"CVM Lifecycle","href":"/phala-cloud/references/cloud-go-sdk/cvm-lifecycle"},{"title":"CVM Configuration","href":"/phala-cloud/references/cloud-go-sdk/cvm-configuration"},{"title":"Watch CVM State","href":"/phala-cloud/references/cloud-go-sdk/watch-cvm-state"},{"title":"Apps","href":"/phala-cloud/references/cloud-go-sdk/apps"},{"title":"Workspaces","href":"/phala-cloud/references/cloud-go-sdk/workspaces"},{"title":"KMS","href":"/phala-cloud/references/cloud-go-sdk/kms"},{"title":"SSH Keys","href":"/phala-cloud/references/cloud-go-sdk/ssh-keys"},{"title":"Error Handling","href":"/phala-cloud/references/cloud-go-sdk/error-handling"},{"title":"Changelog","href":"/phala-cloud/references/cloud-go-sdk/changelog"}]},{"group":"Terraform Provider","pages":[{"title":"Terraform Provider","href":"/phala-cloud/references/terraform-provider/overview"},{"title":"phala_app Resource","href":"/phala-cloud/references/terraform-provider/app-resource"},{"title":"phala_cvm_power Resource","href":"/phala-cloud/references/terraform-provider/cvm-power"},{"title":"phala_ssh_key Resource","href":"/phala-cloud/references/terraform-provider/ssh-key"},{"title":"Data Sources","href":"/phala-cloud/references/terraform-provider/data-sources"},{"title":"Examples","href":"/phala-cloud/references/terraform-provider/examples"},{"title":"Changelog","href":"/phala-cloud/references/terraform-provider/changelog"}]},{"title":"Error Codes","href":"/phala-cloud/references/error-codes"},{"title":"Webhooks","href":"/phala-cloud/references/webhooks"}]},{"group":"Successful Cases","pages":[{"title":"Overview","href":"/phala-cloud/cases/overview"},{"title":"Building confidential AI","href":"/phala-cloud/cases/tee_with_ai"},{"title":"2FA for FHE/MPC Systems","href":"/phala-cloud/cases/tee_with_fhe_and_mpc"},{"title":"Private Proving with TEE","href":"/phala-cloud/cases/tee_with_zk_and_zkrollup"},{"title":"Cases Explorer","href":"/phala-cloud/cases/best-practices-and-successful-case"}]},{"title":"FAQ","href":"/phala-cloud/faqs"},{"title":"What's New","href":"/phala-cloud/changelog"},{"title":"Get Support","href":"/phala-cloud/support"}]}]},{"tab":"Private AI","icon":"shield-check","pages":[{"title":"Private AI","href":"/phala-cloud/confidential-ai/overview"}]},{"tab":"dstack","icon":"terminal","pages":[{"title":"dstack","href":"/dstack/overview"}]},{"tab":"dstack Cloud","icon":"server","pages":[{"title":"dstack Cloud","href":"/dstack-cloud/overview"}]},{"tab":"Network","icon":"network","pages":[{"title":"Network","href":"/network"}]}]},"basePath":"","title":"Phala Cloud Documentation — Private AI on TEE","buildId":"dpl_8LJbrAiZvr1K98WQNZXCyY5AvT34","deploymentId":"dpl_8LJbrAiZvr1K98WQNZXCyY5AvT34","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-i2a3QZ8E.js","utils-ChLwp8m0.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-DRktVTDc.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-CA2pEs4T.js","snippetPresets-ClQ6XrKD.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-Ct_Lv36y.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-Cn2PYw9e.js","shallow-rkyymjXQ.js","getApiPlaygroundDisplay-BB9vkXtE.js","CodeSnippet-Bm5RU7m1.js","CodeSnippets-BgU9Deuz.js","Page-BUDYNlhG.js","getPastedJson-BD-6NNum.js","icon-8Z6tud2e.js","MethodPill-Tuzr4g3V.js","DuplicateIcon-0ceWFYhN.js","createIcon-FBXow_ST.js","DynamicMarkdown-CD8713Yy.js","SectionHeading-7zgzQbH-.js","axios-vUo_bRtp.js","Markdown-D7Ofw1oz.js","clsx-eKJ4rcii.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-CwjSCXIK.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-9EK5IAXV.js"]}