Home
Version 3
Service Plans API

Service Plans API

Updating a Service Plan (deprecated)

PUT /v2/service_plans

Request

Route

PUT /v2/service_plans/1be80561-a72e-4521-b88b-2bf46d462e9f

Body

Name Description Default Valid Values Example Values
guid The guid of the service plan
name The name of the service plan
  • 100mb
free A boolean describing if the service plan is free
  • true
  • false
description A description of the service plan
  • Let's you put data in your database!
extra A JSON string with additional data about the plan
  • {"cost": "$2.00"}
unique_id A guid for the service plan in the service broker (not the same as the cloud controller guid)
public A boolean describing that the plan is visible to the all users true
service_guid The guid of the related service
  • deadbeef
active A boolean that determines whether plans can be used to create new instances.
  • true
  • false
{
  "name": "100mb",
  "free": true,
  "description": "Let's you put data in your database!",
  "service_guid": "92ed6737-e256-40b5-b8ee-b86d025b2935"
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI2NyIsImVtYWlsIjoiZW1haWwtMTkzQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDE2NjI2MDl9.2NXr1snnXcI7A2STGhfbddonaSKUqxzv_hoXQbiXA_A
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/service_plans/1be80561-a72e-4521-b88b-2bf46d462e9f" -d '{
  "name": "100mb",
  "free": true,
  "description": "Let\u0027s you put data in your database!",
  "service_guid": "92ed6737-e256-40b5-b8ee-b86d025b2935"
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI2NyIsImVtYWlsIjoiZW1haWwtMTkzQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDE2NjI2MDl9.2NXr1snnXcI7A2STGhfbddonaSKUqxzv_hoXQbiXA_A" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "1be80561-a72e-4521-b88b-2bf46d462e9f",
    "url": "/v2/service_plans/1be80561-a72e-4521-b88b-2bf46d462e9f",
    "created_at": "2015-08-31T21:50:09Z",
    "updated_at": "2015-08-31T21:50:09Z"
  },
  "entity": {
    "name": "100mb",
    "free": true,
    "description": "Let's you put data in your database!",
    "service_guid": "92ed6737-e256-40b5-b8ee-b86d025b2935",
    "extra": null,
    "unique_id": "edd75abc-02d9-4fbc-b8f1-4649186daa0a",
    "public": true,
    "active": true,
    "service_url": "/v2/services/92ed6737-e256-40b5-b8ee-b86d025b2935",
    "service_instances_url": "/v2/service_plans/1be80561-a72e-4521-b88b-2bf46d462e9f/service_instances"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 23e70746-e1de-415b-a2b8-01bb5695814d
Content-Length: 696
X-Content-Type-Options: nosniff