Home
Version 3
Droplets (Experimental) API

Droplets (Experimental) API

List all Droplets

GET /v3/droplets

Request

Route

GET /v3/droplets?page=1&per_page=2

Parameters

Name Description Valid Values Example Values
page Page to display
  • >= 1
per_page Number of results per page
  • 1-5000
page: 1
per_page: 2

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTIyNyIsImVtYWlsIjoiZW1haWwtMTQ1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0MzY4Mjk3ODh9.2qCqgYNgNTjh75a7WaTV0pExyY83wHbLTEla95IfSd0
Host: example.org
Cookie: 

cURL

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

Response

Status

200 OK

Body

{
  "pagination": {
    "total_results": 2,
    "first": {
      "href": "/v3/droplets?page=1&per_page=2"
    },
    "last": {
      "href": "/v3/droplets?page=1&per_page=2"
    },
    "next": null,
    "previous": null
  },
  "resources": [
    {
      "guid": "guid-d8a856b5-bd4f-44bb-9021-83fae1ad81a8",
      "state": "STAGING",
      "hash": null,
      "buildpack": "name-1561",
      "failure_reason": null,
      "detected_start_command": null,
      "procfile": null,
      "environment_variables": {
        "yuu": "huuu"
      },
      "created_at": "2015-07-06T23:23:08Z",
      "updated_at": null,
      "_links": {
        "self": {
          "href": "/v3/droplets/guid-d8a856b5-bd4f-44bb-9021-83fae1ad81a8"
        },
        "package": {
          "href": "/v3/packages/guid-9129b47b-ee4a-4e87-9b9e-9a9c57cb8ad5"
        },
        "app": {
          "href": "/v3/apps/guid-8d53c0fc-3a7c-48b2-95f3-ab02dda4aa1c"
        },
        "buildpack": {
          "href": "/v2/buildpacks/c2a9a4ff-9ea6-48c0-ae87-6ec450a2027d"
        }
      }
    },
    {
      "guid": "guid-f6b6474a-20c0-4bf9-8f51-5f0c1b0894f1",
      "state": "STAGED",
      "hash": "my-hash",
      "buildpack": "https://github.com/cloudfoundry/my-buildpack.git",
      "failure_reason": null,
      "detected_start_command": null,
      "procfile": null,
      "environment_variables": {

      },
      "created_at": "2015-07-06T23:23:08Z",
      "updated_at": null,
      "_links": {
        "self": {
          "href": "/v3/droplets/guid-f6b6474a-20c0-4bf9-8f51-5f0c1b0894f1"
        },
        "package": {
          "href": "/v3/packages/guid-9129b47b-ee4a-4e87-9b9e-9a9c57cb8ad5"
        },
        "app": {
          "href": "/v3/apps/guid-8d53c0fc-3a7c-48b2-95f3-ab02dda4aa1c"
        },
        "assign_current_droplet": {
          "href": "/v3/apps/guid-8d53c0fc-3a7c-48b2-95f3-ab02dda4aa1c/current_droplet",
          "method": "PUT"
        }
      }
    }
  ]
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: 5a0e3687-8345-46c5-8590-85011d88eb6e
Content-Length: 1957
X-Content-Type-Options: nosniff