Name | Description | Default | Valid Values | Example Values |
---|
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, organization_guid, developer_guid, app_guid |
|
|
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 |
|
|
Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTYzIiwiZW1haWwiOiJlbWFpbC00NEBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDE5OTg5OTYzfQ.QBbYWa29o5zyNs9Fhdww2XjABffvWUDEccQIZarpjzw Host: example.org Cookie:
GET /v2/spaces
curl "https://api.[your-domain.com]/v2/spaces" -X GET \ -H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTYzIiwiZW1haWwiOiJlbWFpbC00NEBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDE5OTg5OTYzfQ.QBbYWa29o5zyNs9Fhdww2XjABffvWUDEccQIZarpjzw" \ -H "Host: example.org" \ -H "Cookie: "
Content-Type: application/json;charset=utf-8 X-VCAP-Request-ID: 02149c33-865b-4a10-9e9e-e5240e4e7c2f Content-Length: 1462 X-Content-Type-Options: nosniff
200 OK
{ "total_results": 1, "total_pages": 1, "prev_url": null, "next_url": null, "resources": [ { "metadata": { "guid": "3479d869-b69a-44ce-b1cc-ebb5b053de61", "url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61", "created_at": "2014-12-24T01:39:23+00:00", "updated_at": null }, "entity": { "name": "name-123", "organization_guid": "6c781fb3-660e-4913-8700-3ec8bb0b86a4", "space_quota_definition_guid": null, "organization_url": "/v2/organizations/6c781fb3-660e-4913-8700-3ec8bb0b86a4", "developers_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/developers", "managers_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/managers", "auditors_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/auditors", "apps_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/apps", "routes_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/routes", "domains_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/domains", "service_instances_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/service_instances", "app_events_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/app_events", "events_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/events", "security_groups_url": "/v2/spaces/3479d869-b69a-44ce-b1cc-ebb5b053de61/security_groups" } } ] }