Skip to content

List members

client.GPUDroplets.Autoscale.ListMembers(ctx, autoscalePoolID, query) (*GPUDropletAutoscaleListMembersResponse, error)
get/v2/droplets/autoscale/{autoscale_pool_id}/members

To list the Droplets in an autoscale pool, send a GET request to /v2/droplets/autoscale/$AUTOSCALE_POOL_ID/members.

The response body will be a JSON object with a key of droplets. This will be set to an array containing information about each of the Droplets in the autoscale pool.

ParametersExpand Collapse
autoscalePoolID string
query GPUDropletAutoscaleListMembersParams
Page param.Field[int64]optional

Which 'page' of paginated results to return.

minimum1
PerPage param.Field[int64]optional

Number of items returned per page

minimum1
maximum200
ReturnsExpand Collapse
type GPUDropletAutoscaleListMembersResponse struct{…}

Information about the response itself.

Total int64optional

Number of objects returned by the request.

Droplets []GPUDropletAutoscaleListMembersResponseDropletoptional
CreatedAt Time

The creation time of the Droplet in ISO8601 combined date and time format.

formatdate-time
CurrentUtilization GPUDropletAutoscaleListMembersResponseDropletsCurrentUtilization
CPU float64optional

The CPU utilization average of the individual Droplet.

formatfloat
Memory float64optional

The memory utilization average of the individual Droplet.

formatfloat
DropletID int64

The unique identifier of the Droplet.

HealthStatus string

The health status of the Droplet.

Status GPUDropletAutoscaleListMembersResponseDropletsStatus

The power status of the Droplet.

Accepts one of the following:
const GPUDropletAutoscaleListMembersResponseDropletsStatusProvisioning GPUDropletAutoscaleListMembersResponseDropletsStatus = "provisioning"
const GPUDropletAutoscaleListMembersResponseDropletsStatusActive GPUDropletAutoscaleListMembersResponseDropletsStatus = "active"
const GPUDropletAutoscaleListMembersResponseDropletsStatusDeleting GPUDropletAutoscaleListMembersResponseDropletsStatus = "deleting"
const GPUDropletAutoscaleListMembersResponseDropletsStatusOff GPUDropletAutoscaleListMembersResponseDropletsStatus = "off"
UpdatedAt Time

The last updated time of the Droplet in ISO8601 combined date and time format.

formatdate-time
Accepts one of the following:
List members
package main

import (
  "context"
  "fmt"

  "github.com/stainless-sdks/-go"
  "github.com/stainless-sdks/-go/option"
)

func main() {
  client := gradient.NewClient(
    option.WithAccessToken("My Access Token"),
  )
  response, err := client.GPUDroplets.Autoscale.ListMembers(
    context.TODO(),
    "0d3db13e-a604-4944-9827-7ec2642d32ac",
    gradient.GPUDropletAutoscaleListMembersParams{

    },
  )
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", response.Meta)
}
{
  "droplets": [
    {
      "droplet_id": 123456,
      "created_at": "2020-11-19T20:27:18Z",
      "updated_at": "2020-12-01T00:42:16Z",
      "health_status": "healthy",
      "status": "active",
      "current_utilization": {
        "memory": 0.3588531587713522,
        "cpu": 0.0007338008770232183
      }
    }
  ],
  "links": {
    "pages": null
  },
  "meta": {
    "total": 1
  }
}
Returns Examples
{
  "droplets": [
    {
      "droplet_id": 123456,
      "created_at": "2020-11-19T20:27:18Z",
      "updated_at": "2020-12-01T00:42:16Z",
      "health_status": "healthy",
      "status": "active",
      "current_utilization": {
        "memory": 0.3588531587713522,
        "cpu": 0.0007338008770232183
      }
    }
  ],
  "links": {
    "pages": null
  },
  "meta": {
    "total": 1
  }
}