Home
Version 3
Private Domains API

Private Domains API

List all Private Domains

GET /v2/private_domains

Fields

Name Description Default Valid Values Example Values
guid The guid of the domain.
name The name of the domain.
  • example.com
  • foo.example.com
owning_organization_guid The organization that owns the domain. If not specified, the domain is shared.

Parameters

Name Description Valid Values Example Values
q Parameters used to filter the result set.
Format queries as <filter><op><value>
Valid ops: : >= <= < > IN
Valid filters: name
  • q=filter:value
  • q=filter>value
  • q=filter IN a,b,c
page Page of results to fetch
results-per-page Number of results per page
order-direction Order of the results: asc (default) or desc
inline-relations-depth 0 - don't inline any relations and return URLs. Otherwise, inline to depth N.
orphan-relations 0 - de-duplicate object entries in response
exclude-relations comma-delimited list of relations to drop from response
include-relations comma-delimited list of the only relations to include in response

Request

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI5NyIsImVtYWlsIjoiZW1haWwtMjAwQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjQxMzczNzN9.2Iyr--7kszG0P1N8pD0QBHBOm9ZZqz47WFskQzO-ym8
Host: example.org
Cookie: 

Route

GET /v2/private_domains

cURL

curl "https://api.[your-domain.com]/v2/private_domains" -X GET \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI5NyIsImVtYWlsIjoiZW1haWwtMjAwQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjQxMzczNzN9.2Iyr--7kszG0P1N8pD0QBHBOm9ZZqz47WFskQzO-ym8" \
	-H "Host: example.org" \
	-H "Cookie: "

Response

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 6ad69b80-224b-4e3d-a69c-da56f3637be8
Content-Length: 2015
X-Content-Type-Options: nosniff

Status

200 OK

Body

{
  "total_results": 4,
  "total_pages": 1,
  "prev_url": null,
  "next_url": null,
  "resources": [
    {
      "metadata": {
        "guid": "62ba2eca-a653-4c6f-b513-6ed03f3cca31",
        "url": "/v2/private_domains/62ba2eca-a653-4c6f-b513-6ed03f3cca31",
        "created_at": "2015-02-10T01:42:41Z",
        "updated_at": null
      },
      "entity": {
        "name": "vcap.me",
        "owning_organization_guid": "5898818d-1720-436f-af1c-5ccda838a249",
        "owning_organization_url": "/v2/organizations/5898818d-1720-436f-af1c-5ccda838a249"
      }
    },
    {
      "metadata": {
        "guid": "f7d1d852-1df3-42fd-9318-920e61b6d1f8",
        "url": "/v2/private_domains/f7d1d852-1df3-42fd-9318-920e61b6d1f8",
        "created_at": "2015-02-10T01:42:53Z",
        "updated_at": null
      },
      "entity": {
        "name": "domain-36.example.com",
        "owning_organization_guid": "6569facb-5f22-4b31-a0cc-a300d628ae9a",
        "owning_organization_url": "/v2/organizations/6569facb-5f22-4b31-a0cc-a300d628ae9a"
      }
    },
    {
      "metadata": {
        "guid": "aa41cd72-b3cf-484f-b5d7-e36131c3f134",
        "url": "/v2/private_domains/aa41cd72-b3cf-484f-b5d7-e36131c3f134",
        "created_at": "2015-02-10T01:42:53Z",
        "updated_at": null
      },
      "entity": {
        "name": "domain-37.example.com",
        "owning_organization_guid": "9872223b-2582-40ae-be62-fa4a58412eb9",
        "owning_organization_url": "/v2/organizations/9872223b-2582-40ae-be62-fa4a58412eb9"
      }
    },
    {
      "metadata": {
        "guid": "1691efaf-5816-42ec-919f-64d8a0152b29",
        "url": "/v2/private_domains/1691efaf-5816-42ec-919f-64d8a0152b29",
        "created_at": "2015-02-10T01:42:53Z",
        "updated_at": null
      },
      "entity": {
        "name": "domain-38.example.com",
        "owning_organization_guid": "e07a978b-5bc4-47a2-a976-765c6ac47308",
        "owning_organization_url": "/v2/organizations/e07a978b-5bc4-47a2-a976-765c6ac47308"
      }
    }
  ]
}