Home
Version 3
Apps (Experimental) API

Apps (Experimental) API

Filters Apps by guids, names, spaces, and organizations

GET /v3/apps

Request

Route

GET /v3/apps?names=my_app1&space_guids=faa20d65-25fe-44c2-9e48-5a5fcb73c89b%2C75f31155-20aa-4b07-8f0c-959ee78b50db%2Cd19524c8-a0c8-4151-81a6-ed09bda01441&page=1&per_page=2&order_by=-created_at

Parameters

Name Description Valid Values Example Values
names Names of apps to filter by
  • array of strings
  • names=name1,name2
space_guids Spaces to filter by
  • array of strings
  • space_guids=space_guid1,space_guid2
organization_guids Organizations to filter by
  • array of strings
  • organization_guids=org_guid1,org_guid2
guids App guids to filter by
  • array of strings
  • guid=guid1,guid2
page Page to display
  • >= 1
per_page Number of results per page
  • 1 - 5000
order_by Value to sort by. Prepend with "+" or "-" to change sort direction to ascending or descending, respectively.
  • created_at, updated_at
names: my_app1
space_guids: faa20d65-25fe-44c2-9e48-5a5fcb73c89b,75f31155-20aa-4b07-8f0c-959ee78b50db,d19524c8-a0c8-4151-81a6-ed09bda01441
page: 1
per_page: 2
order_by: -created_at

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTUiLCJlbWFpbCI6ImVtYWlsLTRAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQ1NjQ1MjIyMH0.5DuuH3FIg-TG3XKB5YdTT4FTtDP7zvUTWxoyGfujUo8
Host: example.org
Cookie: 

cURL

curl "https://api.[your-domain.com]/v3/apps?names=my_app1&space_guids=faa20d65-25fe-44c2-9e48-5a5fcb73c89b%2C75f31155-20aa-4b07-8f0c-959ee78b50db%2Cd19524c8-a0c8-4151-81a6-ed09bda01441&page=1&per_page=2&order_by=-created_at" -X GET \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTUiLCJlbWFpbCI6ImVtYWlsLTRAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQ1NjQ1MjIyMH0.5DuuH3FIg-TG3XKB5YdTT4FTtDP7zvUTWxoyGfujUo8" \
	-H "Host: example.org" \
	-H "Cookie: "

Response

Status

200 OK

Body

{
  "pagination": {
    "total_results": 3,
    "first": {
      "href": "/v3/apps?names=my_app1&order_by=-created_at&page=1&per_page=2&space_guids=faa20d65-25fe-44c2-9e48-5a5fcb73c89b%2C75f31155-20aa-4b07-8f0c-959ee78b50db%2Cd19524c8-a0c8-4151-81a6-ed09bda01441"
    },
    "last": {
      "href": "/v3/apps?names=my_app1&order_by=-created_at&page=2&per_page=2&space_guids=faa20d65-25fe-44c2-9e48-5a5fcb73c89b%2C75f31155-20aa-4b07-8f0c-959ee78b50db%2Cd19524c8-a0c8-4151-81a6-ed09bda01441"
    },
    "next": {
      "href": "/v3/apps?names=my_app1&order_by=-created_at&page=2&per_page=2&space_guids=faa20d65-25fe-44c2-9e48-5a5fcb73c89b%2C75f31155-20aa-4b07-8f0c-959ee78b50db%2Cd19524c8-a0c8-4151-81a6-ed09bda01441"
    },
    "previous": null
  },
  "resources": [
    {
      "guid": "guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c",
      "name": "my_app1",
      "desired_state": "STOPPED",
      "total_desired_instances": 0,
      "created_at": "2016-02-19T02:03:39Z",
      "updated_at": null,
      "lifecycle": {
        "type": "buildpack",
        "data": {
          "buildpack": "name-49",
          "stack": "name-50"
        }
      },
      "environment_variables": {

      },
      "links": {
        "self": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c"
        },
        "space": {
          "href": "/v2/spaces/faa20d65-25fe-44c2-9e48-5a5fcb73c89b"
        },
        "processes": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/processes"
        },
        "route_mappings": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/route_mappings"
        },
        "packages": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/packages"
        },
        "droplets": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/droplets"
        },
        "tasks": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/tasks"
        },
        "start": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/start",
          "method": "PUT"
        },
        "stop": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/stop",
          "method": "PUT"
        },
        "assign_current_droplet": {
          "href": "/v3/apps/guid-518b1376-c53b-4f17-81d5-fe9b9c4f1d9c/current_droplet",
          "method": "PUT"
        }
      }
    },
    {
      "guid": "guid-149691c9-8c65-4958-95f1-a09739770085",
      "name": "my_app1",
      "desired_state": "STOPPED",
      "total_desired_instances": 0,
      "created_at": "2016-02-19T02:03:39Z",
      "updated_at": null,
      "lifecycle": {
        "type": "buildpack",
        "data": {
          "buildpack": "name-51",
          "stack": "name-52"
        }
      },
      "environment_variables": {

      },
      "links": {
        "self": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085"
        },
        "space": {
          "href": "/v2/spaces/d19524c8-a0c8-4151-81a6-ed09bda01441"
        },
        "processes": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/processes"
        },
        "route_mappings": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/route_mappings"
        },
        "packages": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/packages"
        },
        "droplets": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/droplets"
        },
        "tasks": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/tasks"
        },
        "start": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/start",
          "method": "PUT"
        },
        "stop": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/stop",
          "method": "PUT"
        },
        "assign_current_droplet": {
          "href": "/v3/apps/guid-149691c9-8c65-4958-95f1-a09739770085/current_droplet",
          "method": "PUT"
        }
      }
    }
  ]
}

Headers

X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
Content-Type: application/json; charset=utf-8
X-Runtime: 0.013183
Content-Length: 4074