Update a Route
PUT /v2/routes/:guid
Request
Route
PUT /v2/routes/11640704-d5ef-406e-815b-aa8b90c822ac
Body
Name |
Description |
Default |
Valid Values |
Example Values |
guid
|
The guid of the route.
|
|
|
|
domain_guid
|
The guid of the associated domain
|
|
|
- guid-6904b9a2-8dd2-411c-b589-a8f71d8ec4e1
|
space_guid
|
The guid of the associated space
|
|
|
- guid-e704fa17-c238-4676-bd9a-05ec888a9593
|
host
|
The host portion of the route
|
|
|
|
{
"host": "new_host"
}
Headers
cURL
curl "https://api.[your-domain.com]/v2/routes/11640704-d5ef-406e-815b-aa8b90c822ac" -d '{
"host": "new_host"
}' -X PUT \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQzIiwiZW1haWwiOiJlbWFpbC00MUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI2NjMzODk3fQ.w-5WMeF0kE9pgTbbBLYq9tiEdIvr6P5nsx9kDDcHPLg" \
-H "Host: example.org" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "11640704-d5ef-406e-815b-aa8b90c822ac",
"url": "/v2/routes/11640704-d5ef-406e-815b-aa8b90c822ac",
"created_at": "2015-03-10T23:11:37Z",
"updated_at": "2015-03-10T23:11:37Z"
},
"entity": {
"host": "new_host",
"domain_guid": "dfa7cbc4-cf51-4a4b-950d-aaf5c9ad5a2b",
"space_guid": "874eecfd-5b34-47b4-84e6-757a723ebc31",
"domain_url": "/v2/domains/dfa7cbc4-cf51-4a4b-950d-aaf5c9ad5a2b",
"space_url": "/v2/spaces/874eecfd-5b34-47b4-84e6-757a723ebc31",
"apps_url": "/v2/routes/11640704-d5ef-406e-815b-aa8b90c822ac/apps"
}
}
Headers