---
title: "Create background process"
method: POST
path: "/orgs/{organization}/servers/{server}/background-processes"
tags: ["Background Processes"]
---

# Create background process

`POST /orgs/{organization}/servers/{server}/background-processes`

Create a new background process from a template.

Processing mode: <small><code>async</code></small>

## Path parameters

- `organization` string, required
- `server` integer, required

## Request body

- CreateBackgroundProcessRequest
  - `name` string, required — The name of the background process.
  - `site_id` integer — The site to associate the background process with.
  - `command` string, required — The command to run.
  - `user` 'root' | 'forge', required — The user to run the background process as.
  - `directory` string, nullable — The directory to run the background process from.
  - `processes` integer, required — The number of processes to run.
  - `startsecs` integer — The number of seconds to wait before starting the process.
  - `stopwaitsecs` integer — The number of seconds to wait before stopping the process.
  - `stopsignal` string, nullable — The signal to send to stop the process.

## Response `202`

`BackgroundProcessResource`

## Other responses

- `403` — Authorization error
- `404` — Not found
- `422` — Validation error

---

[API](https://skmtc.dev/mfullbrook/apis/forge.md) · [All operations](https://skmtc.dev/mfullbrook/apis/forge/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/mfullbrook/forge/revisions/24ad66d99f93/schema)
