Background Processes
Create background process
Create a new background process from a template.
Processing mode: <small><code>async</code></small>
post/orgs/{organization}/servers/{server}/background-processes
Request
- Base URLhttps://forge.laravel.com/api
- AuthOAuth 2Authorization codehttps://forge.laravel.com/oauth/authorizeToken URLhttps://forge.laravel.com/oauth/tokenScopesserver:create-daemons
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
organizationstring required
The organization slug
serverinteger required
The server ID
Request body
Example request
{
"name": "Custom command runner",
"site_id": 12345,
"command": "php artisan custom:command",
"user": "forge",
"directory": "/home/forge/my-site.com/current/",
"processes": 1,
"startsecs": 10,
"stopwaitsecs": 10,
"stopsignal": "SIGTERM"
}Response
BackgroundProcessResource
Example response
{
"data": {
"attributes": {
"command": "php artisan queue:work database",
"user": "forge",
"directory": "/home/forge/forge.laravel.com",
"processes": 3,
"status": "running",
"created_at": "2025-07-29T09:00:00Z"
}
}
}Changes
No recorded changes to this operation across all 1 revision of this API.