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

# Deploy an app

> Ship a Node.js, Bun, or Python app with the Hyze Cloud API.

Use the Apps API when you want deployments from CI/CD, internal tooling, or your own control panel.

## Choose a deployment source

<CardGroup cols={2}>
  <Card title="ZIP upload" icon="file-zipper" href="#deploy-from-a-zip">
    Best for build artifacts generated by CI.
  </Card>

  <Card title="GitHub repository" icon="github" href="#deploy-from-github">
    Best when Hyze Cloud should pull source from a connected repository.
  </Card>
</CardGroup>

## Deploy from a ZIP

<Steps>
  <Step title="Package your app">
    Create a ZIP with the files Hyze Cloud should run. Include your app entrypoint and dependency manifest.
  </Step>

  <Step title="Send the deploy request">
    ```bash theme={"system"}
    curl -X POST https://api.hyzecloud.com/api/apps/deploy \
      -H "Authorization: Bearer hyze_your_key" \
      -F "file=@app.zip" \
      -F "name=my-api" \
      -F "runtime=node" \
      -F "memoryMB=512" \
      -F "exposePort=3000"
    ```

    `startupCommand` is optional. Omit it (or pass `auto`) so Hyze detects the right start command. Override only when needed: `-F "startupCommand=node server.js"`.
  </Step>

  <Step title="Watch logs">
    ```bash theme={"system"}
    curl "https://api.hyzecloud.com/api/apps/app_001/logs?tail=200&timestamps=true" \
      -H "Authorization: Bearer hyze_your_key"
    ```
  </Step>
</Steps>

## Deploy from GitHub

Use [`POST /api/apps/deploy-from-repo`](/api-reference/apps#deploy-from-github-repo) after connecting GitHub in the Dashboard.

```json theme={"system"}
{
  "name": "my-api",
  "runtime": "node",
  "memoryMB": 512,
  "exposePort": 3000,
  "autoDeploy": true,
  "repository": {
    "id": "repo_001",
    "owner": "hyzecloud",
    "name": "my-api",
    "branch": "main"
  }
}
```

<Tip>
  Set `autoDeploy` to `true` when you want Hyze Cloud to redeploy after pushes to the selected branch.
  Omit `startupCommand` (or set `"auto"`) unless you need a custom start command.
</Tip>

## Runtime checklist

| Runtime  | Auto detect                         | Notes                                             |
| -------- | ----------------------------------- | ------------------------------------------------- |
| `node`   | Yes (API, static site, Vite, Next…) | Expose the same port your server listens on.      |
| `bun`    | Yes                                 | Keep the lockfile in your artifact when possible. |
| `python` | Yes                                 | Include your dependency file in the ZIP.          |

Optional override examples: `node server.js`, `bun run start`, `python main.py`.

## Related endpoints

<CardGroup cols={2}>
  <Card title="Apps reference" icon="cube" href="/api-reference/apps">
    Deployment, lifecycle, logs, settings, and build history.
  </Card>

  <Card title="App backups" icon="box-archive" href="/api-reference/apps-backups">
    Create, restore, download, and delete app backups.
  </Card>
</CardGroup>
