Associate Route with the App
PUT /v2/apps/:guid/routes/:route_guid
Request
Route
PUT /v2/apps/6b026602-ca51-4767-9ff9-1198b0641af9/routes/1d33d7a1-7f17-4888-8fee-cbb87acd9e1a
Parameters
Name |
Description |
Valid Values |
Example Values |
guid
|
The guid of the App
|
|
|
route_guid
|
The guid of the route
|
|
|
Headers
cURL
curl "https://api.[your-domain.com]/v2/apps/6b026602-ca51-4767-9ff9-1198b0641af9/routes/1d33d7a1-7f17-4888-8fee-cbb87acd9e1a" -d '' -X PUT \
-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTkxIiwiZW1haWwiOiJlbWFpbC01OEBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDQ5NTMxNTEyfQ.D-rRXSohTFpmvU0yz7V3-i1MxLlqqsCEKmnRrzrYlj8" \
-H "Host: example.org" \
-H "Content-Type: application/x-www-form-urlencoded" \
-H "Cookie: "
Response
Status
201 Created
Body
{
"metadata": {
"guid": "6b026602-ca51-4767-9ff9-1198b0641af9",
"url": "/v2/apps/6b026602-ca51-4767-9ff9-1198b0641af9",
"created_at": "2015-11-30T23:38:31Z",
"updated_at": "2015-11-30T23:38:31Z"
},
"entity": {
"name": "name-308",
"production": false,
"space_guid": "f80583b0-83a7-4e58-bf6d-95e4ed4602da",
"stack_guid": "3334f62b-2404-451c-8e68-461f22361ad6",
"buildpack": null,
"detected_buildpack": null,
"environment_json": null,
"memory": 1024,
"instances": 1,
"disk_quota": 1024,
"state": "STOPPED",
"version": "58fb948f-96e6-449f-b78d-c5f413eb9002",
"command": null,
"console": false,
"debug": null,
"staging_task_id": null,
"package_state": "PENDING",
"health_check_type": "port",
"health_check_timeout": null,
"staging_failed_reason": null,
"staging_failed_description": null,
"diego": false,
"docker_image": null,
"package_updated_at": "2015-11-30T23:38:31Z",
"detected_start_command": "",
"enable_ssh": true,
"docker_credentials_json": {
"redacted_message": "[PRIVATE DATA HIDDEN]"
},
"ports": null,
"space_url": "/v2/spaces/f80583b0-83a7-4e58-bf6d-95e4ed4602da",
"stack_url": "/v2/stacks/3334f62b-2404-451c-8e68-461f22361ad6",
"events_url": "/v2/apps/6b026602-ca51-4767-9ff9-1198b0641af9/events",
"service_bindings_url": "/v2/apps/6b026602-ca51-4767-9ff9-1198b0641af9/service_bindings",
"routes_url": "/v2/apps/6b026602-ca51-4767-9ff9-1198b0641af9/routes"
}
}
Headers