Home
Version 3
Processes (Experimental) API

Processes (Experimental) API

Updating a Process

PATCH /v3/processes/:guid

Request

Route

PATCH /v3/processes/117de254-c658-4c09-85a3-0c38cde313b6

Parameters

Name Description Valid Values Example Values
memory Amount of memory (MB) allocated to each instance
instances Number of instances
disk_quota Amount of disk space (MB) allocated to each instance
space_guid Guid of associated Space
stack_guid Guid of associated Stack
state Desired state of process
command Start command for process
buildpack Buildpack used to stage process
health_check_timeout Health check timeout for process
docker_image Name of docker image containing process
environment_json JSON key-value pairs for ENV variables
type Type of the process

Body

Name Description Default Valid Values Example Values
{
  "memory": 2555,
  "instances": 2,
  "disk_quota": 2048,
  "space_guid": "e27dac5f-8208-40ad-9d0f-f80e72b5eca1",
  "stack_guid": "48b6b3eb-9fa9-4c43-ad46-69bef645c117",
  "state": "STARTED",
  "command": "X",
  "buildpack": "another-buildpack",
  "health_check_timeout": 70,
  "environment_json": {
    "foo": "bar"
  },
  "type": "worker"
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI5MyIsImVtYWlsIjoiZW1haWwtMjI0QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjczMjM5NzJ9.uZ-svymIfCDKSueirWUskgNTJ0CF3YFroaEowjbwZnc
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v3/processes/117de254-c658-4c09-85a3-0c38cde313b6" -d '{
  "memory": 2555,
  "instances": 2,
  "disk_quota": 2048,
  "space_guid": "e27dac5f-8208-40ad-9d0f-f80e72b5eca1",
  "stack_guid": "48b6b3eb-9fa9-4c43-ad46-69bef645c117",
  "state": "STARTED",
  "command": "X",
  "buildpack": "another-buildpack",
  "health_check_timeout": 70,
  "environment_json": {
    "foo": "bar"
  },
  "type": "worker"
}' -X PATCH \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI5MyIsImVtYWlsIjoiZW1haWwtMjI0QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjczMjM5NzJ9.uZ-svymIfCDKSueirWUskgNTJ0CF3YFroaEowjbwZnc" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

200 OK

Body

{
  "guid": "117de254-c658-4c09-85a3-0c38cde313b6",
  "type": "worker",
  "command": "X"
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 87dc95c0-8863-4026-88ee-65559e9c7402
Content-Length: 90
X-Content-Type-Options: nosniff