Home
Version 3
Service Plans API

Service Plans API

Updating a Service Plan (deprecated)

PUT /v2/service_plans

Request

Route

PUT /v2/service_plans/0e0a1325-4733-4527-9a67-a99d833121d3

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": "2b6e0f8c-d1f3-4395-a6d1-1dbfc25258a6"
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQ0NiIsImVtYWlsIjoiZW1haWwtMzE0QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDI2MDE1NTN9.aKvDo5DhjCJrSnMnCgVUlngFVs04r-aUbabIVq5klAw
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/service_plans/0e0a1325-4733-4527-9a67-a99d833121d3" -d '{
  "name": "100mb",
  "free": true,
  "description": "Let\u0027s you put data in your database!",
  "service_guid": "2b6e0f8c-d1f3-4395-a6d1-1dbfc25258a6"
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQ0NiIsImVtYWlsIjoiZW1haWwtMzE0QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDI2MDE1NTN9.aKvDo5DhjCJrSnMnCgVUlngFVs04r-aUbabIVq5klAw" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "0e0a1325-4733-4527-9a67-a99d833121d3",
    "url": "/v2/service_plans/0e0a1325-4733-4527-9a67-a99d833121d3",
    "created_at": "2015-09-11T18:39:13Z",
    "updated_at": "2015-09-11T18:39:13Z"
  },
  "entity": {
    "name": "100mb",
    "free": true,
    "description": "Let's you put data in your database!",
    "service_guid": "2b6e0f8c-d1f3-4395-a6d1-1dbfc25258a6",
    "extra": null,
    "unique_id": "bab87a69-f507-49e1-b754-5e1419e24591",
    "public": true,
    "active": true,
    "service_url": "/v2/services/2b6e0f8c-d1f3-4395-a6d1-1dbfc25258a6",
    "service_instances_url": "/v2/service_plans/0e0a1325-4733-4527-9a67-a99d833121d3/service_instances"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: f85c2ecb-f286-4e18-82ba-43c75db66b4f
Content-Length: 696
X-Content-Type-Options: nosniff