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

Request

Route

PUT /v2/user_provided_service_instances/87576ce3-7ae7-4739-b3f2-e77aea1e84ac

Body

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"}
{
  "credentials": {
    "somekey": "somenewvalue"
  }
}

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE1MSIsImVtYWlsIjoiZW1haWwtMTE4QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTQ0NTE2MTZ9.63xsWQN6Y51TNUOebHzyB7OyBKHORe1r_WUku2_tkWo
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/user_provided_service_instances/87576ce3-7ae7-4739-b3f2-e77aea1e84ac" -d '{
  "credentials": {
    "somekey": "somenewvalue"
  }
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE1MSIsImVtYWlsIjoiZW1haWwtMTE4QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTQ0NTE2MTZ9.63xsWQN6Y51TNUOebHzyB7OyBKHORe1r_WUku2_tkWo" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "87576ce3-7ae7-4739-b3f2-e77aea1e84ac",
    "url": "/v2/user_provided_service_instances/87576ce3-7ae7-4739-b3f2-e77aea1e84ac",
    "created_at": "2016-01-26T22:20:16Z",
    "updated_at": "2016-01-26T22:20:16Z"
  },
  "entity": {
    "name": "name-641",
    "credentials": {
      "somekey": "somenewvalue"
    },
    "space_guid": "7d1311aa-52c1-4d4a-91bc-02bea3215f47",
    "type": "user_provided_service_instance",
    "syslog_drain_url": "https://foo.com/url-32",
    "route_service_url": null,
    "space_url": "/v2/spaces/7d1311aa-52c1-4d4a-91bc-02bea3215f47",
    "service_bindings_url": "/v2/user_provided_service_instances/87576ce3-7ae7-4739-b3f2-e77aea1e84ac/service_bindings",
    "routes_url": "/v2/user_provided_service_instances/87576ce3-7ae7-4739-b3f2-e77aea1e84ac/routes"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 
Content-Length: 822
X-Content-Type-Options: nosniff