Home
Version 3
Processes (Experimental) API

Processes (Experimental) API

Updating a Process

PATCH /v3/processes/:guid

Request

Route

PATCH /v3/processes/e3cccff7-3bd7-40a5-a4b5-b3cc1069af32

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": "89e9689a-5e4f-4371-a231-d2eb039818a9",
  "stack_guid": "c5e8574e-9164-4ad1-8fd9-63f618970d30",
  "state": "STARTED",
  "command": "X",
  "buildpack": "another-buildpack",
  "health_check_timeout": 70,
  "environment_json": {
    "foo": "bar"
  },
  "type": "worker"
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTIzOSIsImVtYWlsIjoiZW1haWwtMTcxQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjU5NDg2Njl9.G-5kUGH5NYednkHuuQV6hKyUSN_X1NBJYulFS_s1BJY
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v3/processes/e3cccff7-3bd7-40a5-a4b5-b3cc1069af32" -d '{
  "memory": 2555,
  "instances": 2,
  "disk_quota": 2048,
  "space_guid": "89e9689a-5e4f-4371-a231-d2eb039818a9",
  "stack_guid": "c5e8574e-9164-4ad1-8fd9-63f618970d30",
  "state": "STARTED",
  "command": "X",
  "buildpack": "another-buildpack",
  "health_check_timeout": 70,
  "environment_json": {
    "foo": "bar"
  },
  "type": "worker"
}' -X PATCH \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTIzOSIsImVtYWlsIjoiZW1haWwtMTcxQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjU5NDg2Njl9.G-5kUGH5NYednkHuuQV6hKyUSN_X1NBJYulFS_s1BJY" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

200 OK

Body

{
  "guid": "e3cccff7-3bd7-40a5-a4b5-b3cc1069af32",
  "type": "worker",
  "command": "X"
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: d5ede415-3fcf-41cb-908e-647b6ede9681
Content-Length: 90
X-Content-Type-Options: nosniff