Home
Version 3
User Provided Service Instances API

User Provided Service Instances API

Updating a User Provided Service Instance

PUT /v2/user_provided_service_instances/:guid

Fields

Name Description Default Valid Values Example Values
name A name for the service instance
  • my-user-provided-instance
syslog_drain_url The url for the syslog_drain to direct to
  • syslog://example.com
credentials A hash that can be used to store credentials
  • {:somekey=>"somevalue"}

Request

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI2NiIsImVtYWlsIjoiZW1haWwtMjA3QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjI5OTA4Nzl9._b-7UCOh_0il6PxVyjKe18HhmCAQG5_LL8dRGH35jwE
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

Route

PUT /v2/user_provided_service_instances/cdd8f2ee-32d3-4f73-ae29-214b4ac6fe85

Body

{
  "credentials": {
    "somekey": "somenewvalue"
  }
}

cURL

curl "https://api.[your-domain.com]/v2/user_provided_service_instances/cdd8f2ee-32d3-4f73-ae29-214b4ac6fe85" -d '{
  "credentials": {
    "somekey": "somenewvalue"
  }
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI2NiIsImVtYWlsIjoiZW1haWwtMjA3QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjI5OTA4Nzl9._b-7UCOh_0il6PxVyjKe18HhmCAQG5_LL8dRGH35jwE" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 17dcc991-6185-4b98-922f-b5b20a388c98
Content-Length: 691
X-Content-Type-Options: nosniff

Status

201 Created

Body

{
  "metadata": {
    "guid": "cdd8f2ee-32d3-4f73-ae29-214b4ac6fe85",
    "url": "/v2/user_provided_service_instances/cdd8f2ee-32d3-4f73-ae29-214b4ac6fe85",
    "created_at": "2015-01-27T19:14:39Z",
    "updated_at": "2015-01-27T19:14:39Z"
  },
  "entity": {
    "name": "name-1588",
    "credentials": {
      "somekey": "somenewvalue"
    },
    "space_guid": "e880e8f5-9942-47b8-8cfb-15b1cce6750c",
    "type": "user_provided_service_instance",
    "syslog_drain_url": "https://foo.com/url-97",
    "space_url": "/v2/spaces/e880e8f5-9942-47b8-8cfb-15b1cce6750c",
    "service_bindings_url": "/v2/user_provided_service_instances/cdd8f2ee-32d3-4f73-ae29-214b4ac6fe85/service_bindings"
  }
}