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": "1ff1bf83-a321-4dcb-a517-beb1c7d13520",
"name": "name-1866"
}
Headers
cURL
curl "https://api.[your-domain.com]/v2/service_keys" -d '{
"service_instance_guid": "1ff1bf83-a321-4dcb-a517-beb1c7d13520",
"name": "name-1866"
}' -X POST \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI2MCIsImVtYWlsIjoiZW1haWwtMjA2QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MzI3NzQ5OTR9.qnHk6GpC4ju6fEjUk6acOxz3NnR6EvM7ecAqvTL2P7w" \
-H "Host: example.org" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "ed5ed94c-5616-4c8f-b29d-0223f614850a",
"url": "/v2/service_keys/ed5ed94c-5616-4c8f-b29d-0223f614850a",
"created_at": "2015-05-21T01:03:14Z",
"updated_at": null
},
"entity": {
"name": "name-1866",
"service_instance_guid": "1ff1bf83-a321-4dcb-a517-beb1c7d13520",
"credentials": {
"creds-key-468": "creds-val-468"
},
"service_instance_url": "/v2/service_instances/1ff1bf83-a321-4dcb-a517-beb1c7d13520"
}
}
Headers