Create a Service Key
POST /v2/service_keys
Request
Route
POST /v2/service_keys
Body
Name |
Description |
Default |
Valid Values |
Example Values |
service_instance_guid
|
The guid of the service instance for which to create service key
|
|
|
|
name
|
The name of the service key
|
|
|
|
parameters
|
Arbitrary parameters to pass along to the service broker. Must be a JSON object
|
|
|
|
{
"service_instance_guid": "6db5b6ad-93a7-4d3c-a83b-5bcca54b878f",
"name": "name-1854"
}
Headers
cURL
curl "https://api.[your-domain.com]/v2/service_keys" -d '{
"service_instance_guid": "6db5b6ad-93a7-4d3c-a83b-5bcca54b878f",
"name": "name-1854"
}' -X POST \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE5MyIsImVtYWlsIjoiZW1haWwtMTU0QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTg1OTk0NDB9.Uw2q4pkimvF2a0WBeDKu4grYdBMBjIoh-JQR32hLsJg" \
-H "Host: example.org" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "f7861ca2-1f84-42b5-8c93-53a9e8fe65c4",
"url": "/v2/service_keys/f7861ca2-1f84-42b5-8c93-53a9e8fe65c4",
"created_at": "2016-03-14T22:30:40Z",
"updated_at": null
},
"entity": {
"name": "name-1854",
"service_instance_guid": "6db5b6ad-93a7-4d3c-a83b-5bcca54b878f",
"credentials": {
"creds-key-57": "creds-val-57"
},
"service_instance_url": "/v2/service_instances/6db5b6ad-93a7-4d3c-a83b-5bcca54b878f"
}
}
Headers