GET /v2/security_groups
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.eyJ1c2VyX2lkIjoidWFhLWlkLTM4NiIsImVtYWlsIjoiZW1haWwtMjU0QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDQyNjA2NTV9.Kk520NpAZpUuMVpFQhQwYP2urxgTubQ9OZ5X8OVYsoI Host: example.org Cookie:
curl "https://api.[your-domain.com]/v2/security_groups" -X GET \ -H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTM4NiIsImVtYWlsIjoiZW1haWwtMjU0QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDQyNjA2NTV9.Kk520NpAZpUuMVpFQhQwYP2urxgTubQ9OZ5X8OVYsoI" \ -H "Host: example.org" \ -H "Cookie: "
200 OK
{ "total_results": 5, "total_pages": 1, "prev_url": null, "next_url": null, "resources": [ { "metadata": { "guid": "41cc6e75-33f7-4e65-8574-08b1afffadcd", "url": "/v2/security_groups/41cc6e75-33f7-4e65-8574-08b1afffadcd", "created_at": "2015-09-30T23:30:49Z", "updated_at": null }, "entity": { "name": "dummy1", "rules": [ ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/41cc6e75-33f7-4e65-8574-08b1afffadcd/spaces" } }, { "metadata": { "guid": "63c8b319-478c-4853-9d2a-25dfbf627318", "url": "/v2/security_groups/63c8b319-478c-4853-9d2a-25dfbf627318", "created_at": "2015-09-30T23:30:49Z", "updated_at": null }, "entity": { "name": "dummy2", "rules": [ ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/63c8b319-478c-4853-9d2a-25dfbf627318/spaces" } }, { "metadata": { "guid": "3c9f6147-17e6-4b0e-8e28-6f6b49a9ceee", "url": "/v2/security_groups/3c9f6147-17e6-4b0e-8e28-6f6b49a9ceee", "created_at": "2015-09-30T23:30:55Z", "updated_at": null }, "entity": { "name": "name-1915", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/3c9f6147-17e6-4b0e-8e28-6f6b49a9ceee/spaces" } }, { "metadata": { "guid": "b6f7b8ea-813c-4fdf-b254-7f48ca1b4bb5", "url": "/v2/security_groups/b6f7b8ea-813c-4fdf-b254-7f48ca1b4bb5", "created_at": "2015-09-30T23:30:55Z", "updated_at": null }, "entity": { "name": "name-1916", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/b6f7b8ea-813c-4fdf-b254-7f48ca1b4bb5/spaces" } }, { "metadata": { "guid": "d98d84da-0277-418c-bcca-186ccdf480dd", "url": "/v2/security_groups/d98d84da-0277-418c-bcca-186ccdf480dd", "created_at": "2015-09-30T23:30:55Z", "updated_at": null }, "entity": { "name": "name-1917", "rules": [ { "protocol": "udp", "ports": "8080", "destination": "198.41.191.47/1" } ], "running_default": false, "staging_default": false, "spaces_url": "/v2/security_groups/d98d84da-0277-418c-bcca-186ccdf480dd/spaces" } } ] }
Content-Type: application/json;charset=utf-8 X-VCAP-Request-ID: e0c1e0f8-35ba-4ab6-927e-31d23a1bb9e9 Content-Length: 2923 X-Content-Type-Options: nosniff