---
title: "Create App Hosting Deployment"
method: POST
path: "/deployments/app-hosting"
tags: ["deployments"]
---

# Create App Hosting Deployment

`POST /deployments/app-hosting`

## Request

- Base URL: `https://api.mengi.cloud` (the document declares no server; this is the origin it was published from)
- URL: `https://api.mengi.cloud/deployments/app-hosting`
- Auth: none declared

Create a deployment on App Hosting infrastructure.

Each App Hosting deployment gets its own vCluster running on the shared
host cluster infrastructure. This provides isolated Kubernetes environments
with minimal resource overhead.

This will:
1. Pick the best available location for the geographic region
2. Create a vCluster (tier=SHARED) for this deployment
3. Trigger app-hosting job to provision vCluster + deploy the app

## Request body

- AppHostingDeploymentCreate: Request for creating an App Hosting deployment on shared infrastructure.
  - `geographic_region` string, required
  - `deployment_name` string, required
  - `app_type` string
  - `config` object, nullable
  - `cpu_request` number, nullable
  - `memory_request_mb` integer, nullable
  - `replicas` integer, nullable
  - `container_port` integer, nullable
  - `environment_variables` unknown[], nullable
    - unknown
  - `docker_image` string, nullable
  - `storage_size_gb` integer, nullable
  - `volumes` VolumeConfig[], nullable
    - `path` string, required
    - `sizeGb` integer
    - `purpose` string, nullable
  - `run_as_uid` integer, nullable
  - `deployment_type` string
  - `helm_repo_url` string, nullable
  - `helm_chart_name` string, nullable
  - `helm_chart_version` string, nullable
  - `custom_values_yaml` string, nullable
  - `image_update_strategy` string, nullable
  - `image_update_constraint` string, nullable
  - `image_allow_tags` string, nullable
  - `image_ignore_tags` string, nullable
  - `kubernetes_version` string, nullable

## Response `201`

Successful Response

- DeploymentResponse
  - `id` string, uuid, required
  - `user_id` string, uuid, required
  - `organization_id` string, uuid, nullable
  - `cluster_id` string, uuid, required
  - `name` string, required
  - `app_type` 'web_app' | 'api' | 'database' | 'static_site' | 'container' | 'helm', required
  - `status` 'pending' | 'provisioning' | 'promoting' | 'running' | 'stopped' | 'failed' | 'error' | 'migrating' | 'deleting', required
  - `config` object, nullable
  - `values_yaml` string, nullable
  - `git_path` string, nullable
  - `endpoint_url` string, nullable
  - `error_message` string, nullable
  - `cpu_request` number, nullable
  - `memory_request_mb` integer, nullable
  - `replicas` integer, nullable
  - `container_port` integer, nullable
  - `storage_size_gb` integer, nullable
  - `command` string[], nullable
  - `args` string[], nullable
  - `deployment_type` string, nullable
  - `helm_repo_url` string, nullable
  - `helm_chart_name` string, nullable
  - `helm_chart_version` string, nullable
  - `custom_values_yaml` string, nullable
  - `image_update_strategy` string, nullable
  - `image_update_constraint` string, nullable
  - `image_allow_tags` string, nullable
  - `image_ignore_tags` string, nullable
  - `is_adopted` boolean
  - `source_namespace` string, nullable
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `provider` string, nullable
  - `region` string, nullable
  - `cluster_status` string, nullable
  - `cluster_error` string, nullable

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/mengi/apis/mengi-cloud.md) · [All operations](https://skmtc.dev/mengi/apis/mengi-cloud/llms.txt) · [OpenAPI document](https://skmtc.dev/mengi/apis/mengi-cloud/revisions/4ae9b375cdbb?raw)
