Home
Version 3
Apps (Experimental) API

Apps (Experimental) API

List all Apps

GET /v3/apps

Request

Route

GET /v3/apps?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
page: 1
per_page: 2
order_by: -created_at

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTIyNyIsImVtYWlsIjoiZW1haWwtMTg4QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTg1OTk0NDN9.Eeo_nIeowC2v3oVUYoRd7oC7lu2hNZXOBV8qCrjF5I0
Host: example.org
Cookie: 

cURL

curl "https://api.[your-domain.com]/v3/apps?page=1&per_page=2&order_by=-created_at" -X GET \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTIyNyIsImVtYWlsIjoiZW1haWwtMTg4QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTg1OTk0NDN9.Eeo_nIeowC2v3oVUYoRd7oC7lu2hNZXOBV8qCrjF5I0" \
	-H "Host: example.org" \
	-H "Cookie: "

Response

Status

200 OK

Body

{
  "pagination": {
    "total_results": 3,
    "first": {
      "href": "/v3/apps?order_by=-created_at&page=1&per_page=2"
    },
    "last": {
      "href": "/v3/apps?order_by=-created_at&page=2&per_page=2"
    },
    "next": {
      "href": "/v3/apps?order_by=-created_at&page=2&per_page=2"
    },
    "previous": null
  },
  "resources": [
    {
      "guid": "guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa",
      "name": "my_app3",
      "desired_state": "STOPPED",
      "total_desired_instances": 0,
      "created_at": "1970-01-01T00:00:03Z",
      "updated_at": null,
      "lifecycle": {
        "type": "buildpack",
        "data": {
          "buildpack": "name-2031",
          "stack": "name-2032"
        }
      },
      "environment_variables": {
        "magic": "beautiful"
      },
      "links": {
        "self": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa"
        },
        "space": {
          "href": "/v2/spaces/03299ee0-729d-4d6e-afce-837dfea77c03"
        },
        "processes": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/processes"
        },
        "route_mappings": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/route_mappings"
        },
        "packages": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/packages"
        },
        "droplets": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/droplets"
        },
        "tasks": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/tasks"
        },
        "start": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/start",
          "method": "PUT"
        },
        "stop": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/stop",
          "method": "PUT"
        },
        "assign_current_droplet": {
          "href": "/v3/apps/guid-c4c146f2-be33-44bf-aae1-9b92b5cb3caa/current_droplet",
          "method": "PUT"
        }
      }
    },
    {
      "guid": "guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f",
      "name": "my_app2",
      "desired_state": "STOPPED",
      "total_desired_instances": 0,
      "created_at": "1970-01-01T00:00:02Z",
      "updated_at": null,
      "lifecycle": {
        "type": "buildpack",
        "data": {
          "buildpack": "name-2029",
          "stack": "name-2030"
        }
      },
      "environment_variables": {

      },
      "links": {
        "self": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f"
        },
        "space": {
          "href": "/v2/spaces/03299ee0-729d-4d6e-afce-837dfea77c03"
        },
        "processes": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/processes"
        },
        "route_mappings": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/route_mappings"
        },
        "packages": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/packages"
        },
        "droplets": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/droplets"
        },
        "tasks": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/tasks"
        },
        "start": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/start",
          "method": "PUT"
        },
        "stop": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/stop",
          "method": "PUT"
        },
        "assign_current_droplet": {
          "href": "/v3/apps/guid-3f1e1808-94a0-4826-9ed4-d6f0ffc3852f/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.016501
Content-Length: 3687