GET /v2/apps
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, space_guid, organization_guid, diego, stack_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 |
|
|
Name | Description | Default | Valid Values | Example Values |
---|---|---|---|---|
name | The name of the app. |
|
|
|
memory | The amount of memory each instance should have. In megabytes. |
|
|
|
instances | The number of instances of the app to run. To ensure optimal availability, ensure there are at least 2 instances. |
|
|
|
disk_quota | The maximum amount of disk available to an instance of an app. In megabytes. |
|
|
|
space_guid | The guid of the associated space. |
|
|
|
stack_guid | The guid of the associated stack. | Uses the default system stack. |
|
|
state | The current desired state of the app. One of STOPPED or STARTED. | STOPPED |
|
|
detected_start_command | The command detected by the buildpack during staging. |
|
|
|
command | The command to start an app after it is staged, maximum length: 4096 (e.g. 'rails s -p $PORT' or 'java com.org.Server $PORT'). |
|
|
|
buildpack | Buildpack to build the app. 3 options: a) Blank means autodetection; b) A Git Url pointing to a buildpack; c) Name of an installed buildpack. |
|
|
|
health_check_type | Type of health check to perform. | port |
|
|
health_check_timeout | Timeout for health checking of an staged app when starting up |
|
|
|
diego | Use diego to stage and to run when available | false |
|
|
docker_image | Name of the Docker image containing the app |
|
|
|
environment_json | Key/value pairs of all the environment variables to run in your app. Does not include any system or service variables. |
|
|
|
production | Deprecated. | true |
|
|
console | Open the console port for the app (at $CONSOLE_PORT). | false |
|
|
debug | Open the debug port for the app (at $DEBUG_PORT). | false |
|
|
Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTkyIiwiZW1haWwiOiJlbWFpbC05MUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDMyMzEzNjEwfQ.B4gNFsNcgr4yHjb1JHzTiByhppoG-JmyktnLplzmgPc Host: example.org Cookie:
curl "https://api.[your-domain.com]/v2/apps" -X GET \ -H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTkyIiwiZW1haWwiOiJlbWFpbC05MUBzb21lZG9tYWluLmNvbSIsInNjb3BlIjpbImNsb3VkX2NvbnRyb2xsZXIuYWRtaW4iXSwiYXVkIjpbImNsb3VkX2NvbnRyb2xsZXIiXSwiZXhwIjoxNDMyMzEzNjEwfQ.B4gNFsNcgr4yHjb1JHzTiByhppoG-JmyktnLplzmgPc" \ -H "Host: example.org" \ -H "Cookie: "
200 OK
{ "total_results": 3, "total_pages": 1, "prev_url": null, "next_url": null, "resources": [ { "metadata": { "guid": "72780ddb-ef4a-4388-b49a-806b945f19de", "url": "/v2/apps/72780ddb-ef4a-4388-b49a-806b945f19de", "created_at": "2015-05-15T16:53:30Z", "updated_at": "2015-05-15T16:53:30Z" }, "entity": { "name": "name-492", "production": false, "space_guid": "ae4c7a65-1903-4f89-8713-efac35cfb27f", "stack_guid": "16843859-158a-48ae-80ca-5b51474d7b05", "buildpack": null, "detected_buildpack": null, "environment_json": null, "memory": 1024, "instances": 1, "disk_quota": 1024, "state": "STOPPED", "version": "8f5e20ca-78a4-4d5f-ba91-2afdd8329f43", "command": null, "console": false, "debug": null, "staging_task_id": null, "package_state": "PENDING", "health_check_type": "port", "health_check_timeout": null, "staging_failed_reason": null, "diego": false, "docker_image": null, "package_updated_at": "2015-05-15T16:53:30Z", "detected_start_command": "", "enable_ssh": true, "space_url": "/v2/spaces/ae4c7a65-1903-4f89-8713-efac35cfb27f", "stack_url": "/v2/stacks/16843859-158a-48ae-80ca-5b51474d7b05", "events_url": "/v2/apps/72780ddb-ef4a-4388-b49a-806b945f19de/events", "service_bindings_url": "/v2/apps/72780ddb-ef4a-4388-b49a-806b945f19de/service_bindings", "routes_url": "/v2/apps/72780ddb-ef4a-4388-b49a-806b945f19de/routes" } }, { "metadata": { "guid": "b0eb4bfc-aabc-4f79-b5ef-7735d08eea84", "url": "/v2/apps/b0eb4bfc-aabc-4f79-b5ef-7735d08eea84", "created_at": "2015-05-15T16:53:30Z", "updated_at": "2015-05-15T16:53:30Z" }, "entity": { "name": "name-482", "production": false, "space_guid": "2c589ef4-c21e-47e5-8c00-916db42a687d", "stack_guid": "63d5496e-2738-4e6a-a592-b209dda883ad", "buildpack": null, "detected_buildpack": null, "environment_json": null, "memory": 1024, "instances": 1, "disk_quota": 1024, "state": "STOPPED", "version": "908466ca-7d30-4d28-806e-6cb27ca46376", "command": null, "console": false, "debug": null, "staging_task_id": null, "package_state": "PENDING", "health_check_type": "port", "health_check_timeout": null, "staging_failed_reason": null, "diego": false, "docker_image": null, "package_updated_at": "2015-05-15T16:53:30Z", "detected_start_command": "", "enable_ssh": true, "space_url": "/v2/spaces/2c589ef4-c21e-47e5-8c00-916db42a687d", "stack_url": "/v2/stacks/63d5496e-2738-4e6a-a592-b209dda883ad", "events_url": "/v2/apps/b0eb4bfc-aabc-4f79-b5ef-7735d08eea84/events", "service_bindings_url": "/v2/apps/b0eb4bfc-aabc-4f79-b5ef-7735d08eea84/service_bindings", "routes_url": "/v2/apps/b0eb4bfc-aabc-4f79-b5ef-7735d08eea84/routes" } }, { "metadata": { "guid": "d856a0d3-9626-442c-890d-ab2f15eca113", "url": "/v2/apps/d856a0d3-9626-442c-890d-ab2f15eca113", "created_at": "2015-05-15T16:53:30Z", "updated_at": "2015-05-15T16:53:30Z" }, "entity": { "name": "name-487", "production": false, "space_guid": "9733c7d7-d6d3-491d-9d48-2eec246a9a0b", "stack_guid": "9a32b636-9536-4c85-bb28-0dac2f6baeaf", "buildpack": null, "detected_buildpack": null, "environment_json": null, "memory": 1024, "instances": 1, "disk_quota": 1024, "state": "STOPPED", "version": "f30b6728-fa15-4fd3-8928-804a91e6cc44", "command": null, "console": false, "debug": null, "staging_task_id": null, "package_state": "PENDING", "health_check_type": "port", "health_check_timeout": null, "staging_failed_reason": null, "diego": false, "docker_image": null, "package_updated_at": "2015-05-15T16:53:30Z", "detected_start_command": "", "enable_ssh": true, "space_url": "/v2/spaces/9733c7d7-d6d3-491d-9d48-2eec246a9a0b", "stack_url": "/v2/stacks/9a32b636-9536-4c85-bb28-0dac2f6baeaf", "events_url": "/v2/apps/d856a0d3-9626-442c-890d-ab2f15eca113/events", "service_bindings_url": "/v2/apps/d856a0d3-9626-442c-890d-ab2f15eca113/service_bindings", "routes_url": "/v2/apps/d856a0d3-9626-442c-890d-ab2f15eca113/routes" } } ] }
Content-Type: application/json;charset=utf-8 X-VCAP-Request-ID: a2c456e6-ff85-439c-9db6-71d087452729 Content-Length: 4749 X-Content-Type-Options: nosniff