Create a Service Broker
POST /v2/service_brokers
Request
Route
POST /v2/service_brokers
Body
Name |
Description |
Default |
Valid Values |
Example Values |
name
|
The name of the service broker.
|
|
|
|
broker_url
|
The URL of the service broker.
|
|
|
- https://broker.example.com
|
auth_username
|
The username with which to authenticate against the service broker.
|
|
|
|
auth_password
|
The password with which to authenticate against the service broker.
|
|
|
|
space_guid
|
Guid of a space the broker is scoped to. Space developers are able to create service brokers scoped to a space.
|
|
|
|
{
"name": "service-broker-name",
"broker_url": "https://broker.example.com",
"auth_username": "admin",
"auth_password": "secretpassw0rd"
}
Headers
cURL
curl "https://api.[your-domain.com]/v2/service_brokers" -d '{
"name": "service-broker-name",
"broker_url": "https://broker.example.com",
"auth_username": "admin",
"auth_password": "secretpassw0rd"
}' -X POST \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE5IiwiZW1haWwiOiJlbWFpbC0xOUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDY2MDA4ODgyfQ.VGIbxLR2RnxwzI2ZJlMQ-qwFjJHgafBGz09oHK--tYk" \
-H "Host: example.org" \
-H "Content-Type: application/json" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "36931aaf-62a7-4019-a708-0e9abf7e7a8f",
"created_at": "2016-06-08T16:41:22Z",
"updated_at": "2016-06-08T16:41:26Z",
"url": "/v2/service_brokers/36931aaf-62a7-4019-a708-0e9abf7e7a8f"
},
"entity": {
"name": "service-broker-name",
"broker_url": "https://broker.example.com",
"auth_username": "admin",
"space_guid": null
}
}
Headers