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 |
|
|
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.eyJ1c2VyX2lkIjoidWFhLWlkLTczIiwiZW1haWwiOiJlbWFpbC00NEBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI0MzEwMTIyfQ._7fgwt9qQvoJF5qQN3NQCj6rITZQrGK2-FKXR2gILhY Host: example.org Cookie:
GET /v2/security_groups
curl "https://api.[your-domain.com]/v2/security_groups" -X GET \ -H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTczIiwiZW1haWwiOiJlbWFpbC00NEBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDI0MzEwMTIyfQ._7fgwt9qQvoJF5qQN3NQCj6rITZQrGK2-FKXR2gILhY" \ -H "Host: example.org" \ -H "Cookie: "
Content-Type: application/json;charset=utf-8 X-VCAP-Request-ID: 7341503c-c191-4b35-9fa9-c3e6d8eeac65 Content-Length: 2920 X-Content-Type-Options: nosniff
200 OK
{ "total_results": 5, "total_pages": 1, "prev_url": null, "next_url": null, "resources": [ { "metadata": { "guid": "479b592b-f278-430f-9745-624de4c93fd8", "url": "/v2/security_groups/479b592b-f278-430f-9745-624de4c93fd8", "created_at": "2015-02-12T01:41:57Z", "updated_at": null }, "entity": { "name": "dummy1", "rules": [ ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/479b592b-f278-430f-9745-624de4c93fd8/spaces" } }, { "metadata": { "guid": "df1bffcc-a4d9-43c2-a194-40a4e15c2cc2", "url": "/v2/security_groups/df1bffcc-a4d9-43c2-a194-40a4e15c2cc2", "created_at": "2015-02-12T01:41:57Z", "updated_at": null }, "entity": { "name": "dummy2", "rules": [ ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/df1bffcc-a4d9-43c2-a194-40a4e15c2cc2/spaces" } }, { "metadata": { "guid": "389347c2-22d7-4bd5-986b-1d70c7ee72eb", "url": "/v2/security_groups/389347c2-22d7-4bd5-986b-1d70c7ee72eb", "created_at": "2015-02-12T01:42:02Z", "updated_at": null }, "entity": { "name": "name-269", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/389347c2-22d7-4bd5-986b-1d70c7ee72eb/spaces" } }, { "metadata": { "guid": "d3b0d73c-256e-4da8-a037-dd72d1af68a1", "url": "/v2/security_groups/d3b0d73c-256e-4da8-a037-dd72d1af68a1", "created_at": "2015-02-12T01:42:02Z", "updated_at": null }, "entity": { "name": "name-270", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/d3b0d73c-256e-4da8-a037-dd72d1af68a1/spaces" } }, { "metadata": { "guid": "46d83844-022b-407f-b68f-08331666716f", "url": "/v2/security_groups/46d83844-022b-407f-b68f-08331666716f", "created_at": "2015-02-12T01:42:02Z", "updated_at": null }, "entity": { "name": "name-271", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/46d83844-022b-407f-b68f-08331666716f/spaces" } } ] }