Skip to main content
GET
/
v2
/
capacities
List capacities
curl --request GET \
  --url https://api.sfcompute.com/v2/capacities \
  --header 'Authorization: Bearer <token>'
{
  "object": "list",
  "has_more": true,
  "data": [
    {
      "object": "capacity",
      "id": "<string>",
      "name": "<string>",
      "zones": [
        "richmond"
      ],
      "allocation_schedule": {
        "total": [
          {
            "effective_at": 1738972800,
            "node_allocation": 123
          }
        ],
        "by_zone": {}
      },
      "created_at": 1738972800
    }
  ],
  "cursor": "capc_gqXR7s0Kj5mHvE2wNpLc4Q"
}

Authorizations

Authorization
string
header
required

Create an API token using sf tokens create or at https://sfcompute.com/account/api-keys.

Query Parameters

id
string[]

Filter by capacity ID or name (repeatable).

An ID or name identifying this resource.

Pattern: (cap_[0-9a-zA-Z_-]{1,21}) | ([a-zA-Z0-9][a-zA-Z0-9._-]{0,254})
limit
integer<u-int32>
default:50
Required range: 1 <= x <= 200
starting_after
string

Set to the response's cursor to fetch the next page.

Pattern: ^capc_[A-Za-z0-9_-]+$
Example:

"capc_gqXR7s0Kj5mHvE2wNpLc4Q"

ending_before
string

Set to the response's cursor to fetch the previous page.

Pattern: ^capc_[A-Za-z0-9_-]+$
Example:

"capc_gqXR7s0Kj5mHvE2wNpLc4Q"

Response

Paginated list of capacities.

object
string
default:list
required
Allowed value: "list"
has_more
boolean
required
data
object[]
required
cursor
null | string

Pass as starting_after or ending_before to paginate.

Pattern: ^capc_[A-Za-z0-9_-]+$
Example:

"capc_gqXR7s0Kj5mHvE2wNpLc4Q"