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.eyJ1c2VyX2lkIjoidWFhLWlkLTQyNiIsImVtYWlsIjoiZW1haWwtMjk1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTg4NTU2ODl9.23E1wWdTHcI760gN_vEFpluUbNcKCF8k0_X0nVe4jfA
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.eyJ1c2VyX2lkIjoidWFhLWlkLTQyNiIsImVtYWlsIjoiZW1haWwtMjk1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NTg4NTU2ODl9.23E1wWdTHcI760gN_vEFpluUbNcKCF8k0_X0nVe4jfA" \
	-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-07c8a7aa-beb2-4940-9afe-0be42c2a6d66",
      "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-2396",
          "stack": "name-2397"
        }
      },
      "environment_variables": {
        "magic": "beautiful"
      },
      "links": {
        "self": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66"
        },
        "space": {
          "href": "/v2/spaces/1e9ab435-c477-41dd-bc5d-6d825f790c70"
        },
        "processes": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/processes"
        },
        "route_mappings": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/route_mappings"
        },
        "packages": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/packages"
        },
        "droplets": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/droplets"
        },
        "tasks": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/tasks"
        },
        "start": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/start",
          "method": "PUT"
        },
        "stop": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/stop",
          "method": "PUT"
        },
        "assign_current_droplet": {
          "href": "/v3/apps/guid-07c8a7aa-beb2-4940-9afe-0be42c2a6d66/current_droplet",
          "method": "PUT"
        }
      }
    },
    {
      "guid": "guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8",
      "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-2394",
          "stack": "name-2395"
        }
      },
      "environment_variables": {

      },
      "links": {
        "self": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8"
        },
        "space": {
          "href": "/v2/spaces/1e9ab435-c477-41dd-bc5d-6d825f790c70"
        },
        "processes": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/processes"
        },
        "route_mappings": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/route_mappings"
        },
        "packages": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/packages"
        },
        "droplets": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/droplets"
        },
        "tasks": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/tasks"
        },
        "start": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/start",
          "method": "PUT"
        },
        "stop": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/stop",
          "method": "PUT"
        },
        "assign_current_droplet": {
          "href": "/v3/apps/guid-02b4ec9b-94c7-4468-9c23-4e906191a0f8/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.015369
Content-Length: 3687