Home
Version 3
Apps (Experimental) API

Apps (Experimental) API

Updating an App

PATCH /v3/apps/:guid

Request

Route

PATCH /v3/apps/guid-fdc5ed20-9b94-4f15-b2c6-377c11bb8eb4

Parameters

Name Description Valid Values Example Values
name Name of the App
desired_droplet_guid GUID of the Droplet to be used for the App

Body

Name Description Default Valid Values Example Values
{
  "name": "new_name",
  "desired_droplet_guid": "guid-b6d197c7-f265-4931-b086-80552b9160de"
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE5IiwiZW1haWwiOiJlbWFpbC0xOUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIucmVhZCIsImNsb3VkX2NvbnRyb2xsZXIud3JpdGUiXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI2MTg3NzM1fQ.rSurGwZ1iO1OetaG2sKd9MGeA0jfahqzeoLg-5ypCIc
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v3/apps/guid-fdc5ed20-9b94-4f15-b2c6-377c11bb8eb4" -d '{
  "name": "new_name",
  "desired_droplet_guid": "guid-b6d197c7-f265-4931-b086-80552b9160de"
}' -X PATCH \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE5IiwiZW1haWwiOiJlbWFpbC0xOUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIucmVhZCIsImNsb3VkX2NvbnRyb2xsZXIud3JpdGUiXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI2MTg3NzM1fQ.rSurGwZ1iO1OetaG2sKd9MGeA0jfahqzeoLg-5ypCIc" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

200 OK

Body

{
  "guid": "guid-fdc5ed20-9b94-4f15-b2c6-377c11bb8eb4",
  "name": "new_name",
  "_links": {
    "self": {
      "href": "/v3/apps/guid-fdc5ed20-9b94-4f15-b2c6-377c11bb8eb4"
    },
    "processes": {
      "href": "/v3/apps/guid-fdc5ed20-9b94-4f15-b2c6-377c11bb8eb4/processes"
    },
    "packages": {
      "href": "/v3/apps/guid-fdc5ed20-9b94-4f15-b2c6-377c11bb8eb4/packages"
    },
    "space": {
      "href": "/v2/spaces/01cc1d09-9062-44ca-b683-e282bb350295"
    },
    "desired_droplet": {
      "href": "/v3/droplets/guid-b6d197c7-f265-4931-b086-80552b9160de"
    }
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 03c6106c-4be5-4c60-95c7-b4f33230c113
Content-Length: 578
X-Content-Type-Options: nosniff