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.eyJ1c2VyX2lkIjoidWFhLWlkLTMxOSIsImVtYWlsIjoiZW1haWwtMjQwQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjIzMjM1NTN9.EZGkBLxb5o8PQ6aKixidpddgVxLPpb0CvndiljheO9M Host: example.org Cookie:
GET /v2/security_groups
curl "https://api.[your-domain.com]/v2/security_groups" -X GET \ -H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTMxOSIsImVtYWlsIjoiZW1haWwtMjQwQHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MjIzMjM1NTN9.EZGkBLxb5o8PQ6aKixidpddgVxLPpb0CvndiljheO9M" \ -H "Host: example.org" \ -H "Cookie: "
Content-Type: application/json;charset=utf-8 X-VCAP-Request-ID: 4d9727cd-afef-45c0-be37-f60b2c7f3fcb Content-Length: 2948 X-Content-Type-Options: nosniff
200 OK
{ "total_results": 5, "total_pages": 1, "prev_url": null, "next_url": null, "resources": [ { "metadata": { "guid": "0b01769e-6e56-486e-8368-8f682cb707cc", "url": "/v2/security_groups/0b01769e-6e56-486e-8368-8f682cb707cc", "created_at": "2015-01-20T01:52:15+00:00", "updated_at": null }, "entity": { "name": "dummy1", "rules": [ ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/0b01769e-6e56-486e-8368-8f682cb707cc/spaces" } }, { "metadata": { "guid": "5ed0a8d0-d78a-425f-913d-dcc482522fa8", "url": "/v2/security_groups/5ed0a8d0-d78a-425f-913d-dcc482522fa8", "created_at": "2015-01-20T01:52:15+00:00", "updated_at": null }, "entity": { "name": "dummy2", "rules": [ ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/5ed0a8d0-d78a-425f-913d-dcc482522fa8/spaces" } }, { "metadata": { "guid": "7dd4c86f-61a7-47fc-916b-e9d3addda095", "url": "/v2/security_groups/7dd4c86f-61a7-47fc-916b-e9d3addda095", "created_at": "2015-01-20T01:52:33+00:00", "updated_at": null }, "entity": { "name": "name-1897", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/7dd4c86f-61a7-47fc-916b-e9d3addda095/spaces" } }, { "metadata": { "guid": "b2382961-8e1d-4327-a85c-7a92f8c883dd", "url": "/v2/security_groups/b2382961-8e1d-4327-a85c-7a92f8c883dd", "created_at": "2015-01-20T01:52:33+00:00", "updated_at": null }, "entity": { "name": "name-1898", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/b2382961-8e1d-4327-a85c-7a92f8c883dd/spaces" } }, { "metadata": { "guid": "7a05d6e0-e8b1-4357-bb96-2d6c8b70a759", "url": "/v2/security_groups/7a05d6e0-e8b1-4357-bb96-2d6c8b70a759", "created_at": "2015-01-20T01:52:33+00:00", "updated_at": null }, "entity": { "name": "name-1899", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/7a05d6e0-e8b1-4357-bb96-2d6c8b70a759/spaces" } } ] }