---
title: "Deploy from a connected GitHub repo"
method: POST
path: "/client/apps/github"
tags: ["Apps"]
---

# Deploy from a connected GitHub repo

`POST /client/apps/github`

## Request

- Base URL: `https://api.roar-ai.com`
- URL: `https://api.roar-ai.com/client/apps/github`
- Auth: HTTP bearer

The private-repo counterpart to `POST /client/apps`: deploys a repo reachable through your installed GitHub App. Returns 202 with the app, its web service and the queued deployment. Requires `apps:deploy`.

`databaseEnabled` and a `DATABASE_URL` of your own in `env` are mutually exclusive: when Roar provides the database it sets `DATABASE_URL` itself.

`deployOnPush` (boolean, default `true`) sets whether a push to `branch` deploys the app automatically.

A repository we can read and already know cannot build is refused with 400 before anything is created: with several apps and no `rootDir`, the message lists the folders `rootDir` can take. A repo we cannot tell how to START is refused the same way unless `startCommand` (one line, at most 300 characters — the same rule as the Build settings start command) says how; it is stored as that build setting, and an obviously unfinished command (a bare `node`, one ending in a folder, an unclosed quote) is refused. The body is strict: a field this route does not take is a 400, never silently ignored. `GET /client/github/build-check` asks the same question first.

## Response `202`

Deploy started

## Other responses

- `400`: GitHub not connected, a DATABASE_URL of your own alongside a Roar database, or a repository that cannot build as it stands
- `403`: Key lacks apps:deploy

---

[API](https://skmtc.dev/roar-ai/apis/roar-ai-api.md) · [All operations](https://skmtc.dev/roar-ai/apis/roar-ai-api/llms.txt) · [OpenAPI document](https://skmtc.dev/roar-ai/apis/roar-ai-api/revisions/37e4d0d5a7fe?raw)
