Home
Version 3
Routes API

Routes API

Associate App with the Route

PUT /v2/routes/:guid/apps/:app_guid

Request

Route

PUT /v2/routes/6f7f1c2e-a277-4daa-999a-3fca6c49d63c/apps/53d8ae50-65a2-48de-958a-5ee5e4468ec3

Body

Name Description Default Valid Values Example Values
guid The guid of the route.

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTgiLCJlbWFpbCI6ImVtYWlsLThAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQyNzMyMzk1NX0.FMJObYj_Dl8U9G42Q34jfd7VNTSaYY1UmuMR35WPMsk
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/routes/6f7f1c2e-a277-4daa-999a-3fca6c49d63c/apps/53d8ae50-65a2-48de-958a-5ee5e4468ec3" -d '' -X PUT \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTgiLCJlbWFpbCI6ImVtYWlsLThAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQyNzMyMzk1NX0.FMJObYj_Dl8U9G42Q34jfd7VNTSaYY1UmuMR35WPMsk" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "6f7f1c2e-a277-4daa-999a-3fca6c49d63c",
    "url": "/v2/routes/6f7f1c2e-a277-4daa-999a-3fca6c49d63c",
    "created_at": "2015-03-18T22:52:35Z",
    "updated_at": null
  },
  "entity": {
    "host": "host-7",
    "domain_guid": "b9054418-fea7-46e8-a819-5eba5e41832d",
    "space_guid": "066a662d-f520-4ca1-b983-b3db36fdb3da",
    "domain_url": "/v2/domains/b9054418-fea7-46e8-a819-5eba5e41832d",
    "space_url": "/v2/spaces/066a662d-f520-4ca1-b983-b3db36fdb3da",
    "apps_url": "/v2/routes/6f7f1c2e-a277-4daa-999a-3fca6c49d63c/apps"
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 0851a593-63fc-4431-9986-2d1d4fd75a6c
Content-Length: 569
X-Content-Type-Options: nosniff