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/1dd0011a-1f62-45f6-87d8-b96160e06611

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

cURL

curl "https://api.[your-domain.com]/v2/user_provided_service_instances/1dd0011a-1f62-45f6-87d8-b96160e06611" -d '{
  "credentials": {
    "somekey": "somenewvalue"
  }
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQwNiIsImVtYWlsIjoiZW1haWwtMzAyQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MzM5ODExMjN9.Y96NlxFxbgvMmar1ArjOsy0_Ykt9e4GX0_Uj6qWwAbo" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "1dd0011a-1f62-45f6-87d8-b96160e06611",
    "url": "/v2/user_provided_service_instances/1dd0011a-1f62-45f6-87d8-b96160e06611",
    "created_at": "2015-06-04T00:05:23Z",
    "updated_at": "2015-06-04T00:05:23Z"
  },
  "entity": {
    "name": "name-2280",
    "credentials": {
      "somekey": "somenewvalue"
    },
    "space_guid": "fab8f541-2d13-404d-bc8d-fc2f6470f118",
    "type": "user_provided_service_instance",
    "syslog_drain_url": "https://foo.com/url-93",
    "space_url": "/v2/spaces/fab8f541-2d13-404d-bc8d-fc2f6470f118",
    "service_bindings_url": "/v2/user_provided_service_instances/1dd0011a-1f62-45f6-87d8-b96160e06611/service_bindings"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 25145c99-3d3a-4d21-8b3a-a5594a0e7594
Content-Length: 691
X-Content-Type-Options: nosniff