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/7b2c968e-c4e2-4558-ae0e-08276e7c4d1c

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

cURL

curl "https://api.[your-domain.com]/v2/user_provided_service_instances/7b2c968e-c4e2-4558-ae0e-08276e7c4d1c" -d '{
  "credentials": {
    "somekey": "somenewvalue"
  }
}' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTM4IiwiZW1haWwiOiJlbWFpbC0zOEBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI2MTg3NzM4fQ.W5KnQ-j7XmnfsNlZsx425GLFpOTJemzzUcygNL8l1l0" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "7b2c968e-c4e2-4558-ae0e-08276e7c4d1c",
    "url": "/v2/user_provided_service_instances/7b2c968e-c4e2-4558-ae0e-08276e7c4d1c",
    "created_at": "2015-03-05T19:15:38Z",
    "updated_at": "2015-03-05T19:15:38Z"
  },
  "entity": {
    "name": "name-201",
    "credentials": {
      "somekey": "somenewvalue"
    },
    "space_guid": "4cd9497e-bd4a-432d-95ed-667bdb74e5b3",
    "type": "user_provided_service_instance",
    "syslog_drain_url": "https://foo.com/url-18",
    "space_url": "/v2/spaces/4cd9497e-bd4a-432d-95ed-667bdb74e5b3",
    "service_bindings_url": "/v2/user_provided_service_instances/7b2c968e-c4e2-4558-ae0e-08276e7c4d1c/service_bindings"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 8c80c3bb-ee7b-4868-8b27-84ceac1dd097
Content-Length: 690
X-Content-Type-Options: nosniff