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.eyJ1c2VyX2lkIjoidWFhLWlkLTExNSIsImVtYWlsIjoiZW1haWwtODVAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQyMjMyMzUzN30.Jyo_x15asqZzEDivZ0FuKk5PK5Qr8VJ_wK2oaKbm4vA
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

Route

PUT /v2/user_provided_service_instances/36d15a67-5441-44e9-8b17-73b2f4b5d47e

Body

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

cURL

curl "https://api.[your-domain.com]/v2/user_provided_service_instances/36d15a67-5441-44e9-8b17-73b2f4b5d47e" -d '{
  "credentials": {
    "somekey": "somenewvalue"
  }
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTExNSIsImVtYWlsIjoiZW1haWwtODVAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQyMjMyMzUzN30.Jyo_x15asqZzEDivZ0FuKk5PK5Qr8VJ_wK2oaKbm4vA" \
	-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: e083c380-8f8a-4fb5-a844-a2d5a87ce980
Content-Length: 700
X-Content-Type-Options: nosniff

Status

201 Created

Body

{
  "metadata": {
    "guid": "36d15a67-5441-44e9-8b17-73b2f4b5d47e",
    "url": "/v2/user_provided_service_instances/36d15a67-5441-44e9-8b17-73b2f4b5d47e",
    "created_at": "2015-01-20T01:52:17+00:00",
    "updated_at": "2015-01-20T01:52:17+00:00"
  },
  "entity": {
    "name": "name-451",
    "credentials": {
      "somekey": "somenewvalue"
    },
    "space_guid": "1d2f77d6-2296-4b2b-8363-ea530d21c76a",
    "type": "user_provided_service_instance",
    "syslog_drain_url": "https://foo.com/url-26",
    "space_url": "/v2/spaces/1d2f77d6-2296-4b2b-8363-ea530d21c76a",
    "service_bindings_url": "/v2/user_provided_service_instances/36d15a67-5441-44e9-8b17-73b2f4b5d47e/service_bindings"
  }
}