Home
Version 3
Service Plans API

Service Plans API

Updating a Service Plan

PUT /v2/service_plans

Request

Route

PUT /v2/service_plans/42e9e31f-13d0-4f5a-810c-6d1588736d86

Body

Name Description Default Valid Values Example Values
guid The guid of the service plan
public A boolean describing that the plan is visible to the all users true
{
  "public": false
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE3IiwiZW1haWwiOiJlbWFpbC0xN0Bzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDUzODM3MjUzfQ.lBbK4MgYBFJ66h6dpeZV_eubtqiWCygIvdMgZBBRHec
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/service_plans/42e9e31f-13d0-4f5a-810c-6d1588736d86" -d '{
  "public": false
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE3IiwiZW1haWwiOiJlbWFpbC0xN0Bzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDUzODM3MjUzfQ.lBbK4MgYBFJ66h6dpeZV_eubtqiWCygIvdMgZBBRHec" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "42e9e31f-13d0-4f5a-810c-6d1588736d86",
    "url": "/v2/service_plans/42e9e31f-13d0-4f5a-810c-6d1588736d86",
    "created_at": "2016-01-19T19:40:53Z",
    "updated_at": "2016-01-19T19:40:53Z"
  },
  "entity": {
    "name": "name-17",
    "free": false,
    "description": "desc-6",
    "service_guid": "a263b7c5-fb3e-4cdf-84ea-4d3ae4c3173e",
    "extra": null,
    "unique_id": "c93513d3-94ab-49a4-8a2d-f5c7bfb397ae",
    "public": false,
    "active": true,
    "service_url": "/v2/services/a263b7c5-fb3e-4cdf-84ea-4d3ae4c3173e",
    "service_instances_url": "/v2/service_plans/42e9e31f-13d0-4f5a-810c-6d1588736d86/service_instances"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 
Content-Length: 670
X-Content-Type-Options: nosniff