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.eyJ1c2VyX2lkIjoidWFhLWlkLTI0NSIsImVtYWlsIjoiZW1haWwtMTY2QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0Mjk2NjQxNDR9.Yy4b8CMf-l6nZpjm5Xswxu61ji1wcQd7EY_MZTXWtp8 Host: example.org Cookie:
curl "https://api.[your-domain.com]/v2/apps" -X GET \ -H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTI0NSIsImVtYWlsIjoiZW1haWwtMTY2QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0Mjk2NjQxNDR9.Yy4b8CMf-l6nZpjm5Xswxu61ji1wcQd7EY_MZTXWtp8" \ -H "Host: example.org" \ -H "Cookie: "
200 OK
{ "total_results": 3, "total_pages": 1, "prev_url": null, "next_url": null, "resources": [ { "metadata": { "guid": "898a649e-d346-4483-b686-8b80aa5839cb", "url": "/v2/apps/898a649e-d346-4483-b686-8b80aa5839cb", "created_at": "2015-04-15T00:55:43Z", "updated_at": "2015-04-15T00:55:43Z" }, "entity": { "name": "name-1595", "production": false, "space_guid": "514cdc09-4380-49a3-9446-f5253e87cd0a", "stack_guid": "89daf147-1d0d-4e25-983b-c415b36b8d7e", "buildpack": null, "detected_buildpack": null, "environment_json": null, "memory": 1024, "instances": 1, "disk_quota": 1024, "state": "STOPPED", "version": "eb9a7cc1-ec15-499c-93e7-fd275677a6bd", "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-04-15T00:55:43Z", "detected_start_command": "", "space_url": "/v2/spaces/514cdc09-4380-49a3-9446-f5253e87cd0a", "stack_url": "/v2/stacks/89daf147-1d0d-4e25-983b-c415b36b8d7e", "events_url": "/v2/apps/898a649e-d346-4483-b686-8b80aa5839cb/events", "service_bindings_url": "/v2/apps/898a649e-d346-4483-b686-8b80aa5839cb/service_bindings", "routes_url": "/v2/apps/898a649e-d346-4483-b686-8b80aa5839cb/routes" } }, { "metadata": { "guid": "a299286e-c50c-46bd-b0e5-af3c1c422581", "url": "/v2/apps/a299286e-c50c-46bd-b0e5-af3c1c422581", "created_at": "2015-04-15T00:55:43Z", "updated_at": "2015-04-15T00:55:43Z" }, "entity": { "name": "name-1590", "production": false, "space_guid": "e3484b05-4ce3-488a-bcad-94125c1ce8fe", "stack_guid": "9488ae32-10c8-4519-a3a3-069956c38a6c", "buildpack": null, "detected_buildpack": null, "environment_json": null, "memory": 1024, "instances": 1, "disk_quota": 1024, "state": "STOPPED", "version": "90c22894-7d58-4888-923c-9fe95be1d09b", "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-04-15T00:55:43Z", "detected_start_command": "", "space_url": "/v2/spaces/e3484b05-4ce3-488a-bcad-94125c1ce8fe", "stack_url": "/v2/stacks/9488ae32-10c8-4519-a3a3-069956c38a6c", "events_url": "/v2/apps/a299286e-c50c-46bd-b0e5-af3c1c422581/events", "service_bindings_url": "/v2/apps/a299286e-c50c-46bd-b0e5-af3c1c422581/service_bindings", "routes_url": "/v2/apps/a299286e-c50c-46bd-b0e5-af3c1c422581/routes" } }, { "metadata": { "guid": "c9f3cea1-da89-4ce1-95ca-c2691eec340f", "url": "/v2/apps/c9f3cea1-da89-4ce1-95ca-c2691eec340f", "created_at": "2015-04-15T00:55:43Z", "updated_at": "2015-04-15T00:55:43Z" }, "entity": { "name": "name-1600", "production": false, "space_guid": "42fb2b3a-a36e-4ba2-9087-79a8574d48ec", "stack_guid": "bf3a9f70-aefd-49c6-87c4-d51c075be73f", "buildpack": null, "detected_buildpack": null, "environment_json": null, "memory": 1024, "instances": 1, "disk_quota": 1024, "state": "STOPPED", "version": "4955e4d4-df3a-4126-8e7d-d9c88eed5597", "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-04-15T00:55:44Z", "detected_start_command": "", "space_url": "/v2/spaces/42fb2b3a-a36e-4ba2-9087-79a8574d48ec", "stack_url": "/v2/stacks/bf3a9f70-aefd-49c6-87c4-d51c075be73f", "events_url": "/v2/apps/c9f3cea1-da89-4ce1-95ca-c2691eec340f/events", "service_bindings_url": "/v2/apps/c9f3cea1-da89-4ce1-95ca-c2691eec340f/service_bindings", "routes_url": "/v2/apps/c9f3cea1-da89-4ce1-95ca-c2691eec340f/routes" } } ] }
Content-Type: application/json;charset=utf-8 X-VCAP-Request-ID: 0cf835cb-a18d-409b-bc26-d809154ea1da Content-Length: 4668 X-Content-Type-Options: nosniff