Home
Version 3
Service Plans API

Service Plans API

Updating a Service Plan (deprecated)

PUT /v2/service_plans

Request

Route

PUT /v2/service_plans/32a7e6d3-9022-4f86-9619-a58f01736b8f

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": "2eef04c5-0b7b-4f51-92a3-94a149c9345d"
}

Headers

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

cURL

curl "https://api.[your-domain.com]/v2/service_plans/32a7e6d3-9022-4f86-9619-a58f01736b8f" -d '{
  "name": "100mb",
  "free": true,
  "description": "Let\u0027s you put data in your database!",
  "service_guid": "2eef04c5-0b7b-4f51-92a3-94a149c9345d"
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQ2MiIsImVtYWlsIjoiZW1haWwtMzMwQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDQyNjA2NjV9.2e0bilDd3A4cUM3fTvtAtxCiI4pmwyLIWk7hYyMY3Lw" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "32a7e6d3-9022-4f86-9619-a58f01736b8f",
    "url": "/v2/service_plans/32a7e6d3-9022-4f86-9619-a58f01736b8f",
    "created_at": "2015-09-30T23:31:05Z",
    "updated_at": "2015-09-30T23:31:05Z"
  },
  "entity": {
    "name": "100mb",
    "free": true,
    "description": "Let's you put data in your database!",
    "service_guid": "2eef04c5-0b7b-4f51-92a3-94a149c9345d",
    "extra": null,
    "unique_id": "db7ad3b8-aa45-46bc-8f0c-c967e625a903",
    "public": true,
    "active": true,
    "service_url": "/v2/services/2eef04c5-0b7b-4f51-92a3-94a149c9345d",
    "service_instances_url": "/v2/service_plans/32a7e6d3-9022-4f86-9619-a58f01736b8f/service_instances"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: d9f04830-a9a0-4a78-8876-057f357aa478
Content-Length: 696
X-Content-Type-Options: nosniff