Digital Ocean Sizes API

The sizes objects represent different packages of hardware resources that can be used for Droplets. When a Droplet is created, a size must be selected so that the correct resources can be allocated. Each size represents a plan that bundles together specific sets of resources. This includes the amount of RAM, the number of virtual CPUs, disk space, and transfer. The size object also includes the pricing details and the regions that the size is available in.

Operations 1

GET /v2/sizes List All Droplet Sizes #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/digital-ocean-sizes-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

digital-ocean-sizes-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: DigitalOcean Sizes API
  version: '2.0'
  description: '# Introduction


    The DigitalOcean API allows you to manage Droplets and resources within the

    DigitalOcean cloud in a simple, programmatic way using conventional HTTP requests.'
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
  contact:
    name: DigitalOcean API Team
    email: api-engineering@digitalocean.com
  termsOfService: https://www.digitalocean.com/legal/terms-of-service-agreement/
servers:
- url: https://api.digitalocean.com
  description: production
security:
- bearer_auth: []
tags:
- name: Sizes
  description: 'The sizes objects represent different packages of hardware resources that

    can be used for Droplets. When a Droplet is created, a size must be

    selected so that the correct resources can be allocated.


    Each size represents a plan that bundles together specific sets of

    resources. This includes the amount of RAM, the number of virtual CPUs,

    disk space, and transfer. The size object also includes the pricing

    details and the regions that the size is available in.'
paths:
  /v2/sizes:
    get:
      operationId: sizes_list
      summary: List All Droplet Sizes
      description: 'To list all of available Droplet sizes, send a GET request to `/v2/sizes`.

        The response will be a JSON object with a key called `sizes`. The value of this will be an array of `size` objects each of which contain the standard size attributes.'
      tags:
      - Sizes
      parameters:
      - $ref: '#/components/parameters/per_page'
      - $ref: '#/components/parameters/page'
      responses:
        '200':
          $ref: '#/components/responses/all_sizes'
        '401':
          $ref: '#/components/responses/unauthorized'
        '429':
          $ref: '#/components/responses/too_many_requests'
        '500':
          $ref: '#/components/responses/server_error'
        default:
          $ref: '#/components/responses/unexpected_error'
      x-codeSamples:
      - lang: cURL
        source: "curl -X GET \\\n  -H \"Content-Type: application/json\" \\\n  -H \"Authorization: Bearer $DIGITALOCEAN_TOKEN\" \\\n  \"https://api.digitalocean.com/v2/sizes\" "
      - lang: Go
        source: "import (\n    \"context\"\n    \"os\"\n\n    \"github.com/digitalocean/godo\"\n)\n\nfunc main() {\n    token := os.Getenv(\"DIGITALOCEAN_TOKEN\")\n\n    client := godo.NewFromToken(token)\n    ctx := context.TODO()\n\n    opt := &godo.ListOptions{\n        Page:    1,\n        PerPage: 200,\n    }\n\n    sizes, _, err := client.Sizes.List(ctx, opt)\n}"
      - lang: Ruby
        source: 'require ''droplet_kit''

          token = ENV[''DIGITALOCEAN_TOKEN'']

          client = DropletKit::Client.new(access_token: token)


          sizes = client.sizes.all

          sizes.each'
      - lang: Python
        source: 'import os

          from pydo import Client


          client = Client(token=os.environ.get("DIGITALOCEAN_TOKEN"))


          resp = client.sizes.list()'
      security:
      - bearer_auth:
        - sizes:read
components:
  schemas:
    meta_properties:
      type: object
      description: Information about the response itself.
      properties:
        total:
          description: Number of objects returned by the request.
          type: integer
          example: 1
    link_to_last_page:
      type: object
      properties:
        last:
          description: URI of the last page of the results.
          type: string
          example: https://api.digitalocean.com/v2/images?page=2
    gpu_info:
      type: object
      description: An object containing information about the GPU capabilities of Droplets created with this size.
      properties:
        count:
          type: integer
          description: The number of GPUs allocated to the Droplet.
          example: 1
        model:
          type: string
          description: The model of the GPU.
          example: nvidia_h100
        vram:
          type: object
          properties:
            amount:
              type: integer
              description: The amount of VRAM allocated to the GPU.
              example: 25
            unit:
              type: string
              description: The unit of measure for the VRAM.
              example: gib
    error:
      type: object
      properties:
        id:
          description: A short identifier corresponding to the HTTP status code returned. For  example, the ID for a response returning a 404 status code would be "not_found."
          type: string
          example: not_found
        message:
          description: A message providing additional information about the error, including  details to help resolve it when possible.
          type: string
          example: The resource you were accessing could not be found.
        request_id:
          description: Optionally, some endpoints may include a request ID that should be  provided when reporting bugs or opening support tickets to help  identify the issue.
          type: string
          example: 4d9d8375-3c56-4925-a3e7-eb137fed17e9
      required:
      - id
      - message
    backward_links:
      allOf:
      - $ref: '#/components/schemas/link_to_first_page'
      - $ref: '#/components/schemas/link_to_prev_page'
    size:
      type: object
      properties:
        slug:
          type: string
          example: s-1vcpu-1gb
          description: A human-readable string that is used to uniquely identify each size.
        memory:
          type: integer
          multipleOf: 8
          minimum: 8
          example: 1024
          description: The amount of RAM allocated to Droplets created of this size. The value is represented in megabytes.
        vcpus:
          type: integer
          example: 1
          description: The number of CPUs allocated to Droplets of this size.
        disk:
          type: integer
          example: 25
          description: The amount of disk space set aside for Droplets of this size. The value is represented in gigabytes.
        transfer:
          type: number
          format: float
          example: 1
          description: The amount of transfer bandwidth that is available for Droplets created in this size. This only counts traffic on the public interface. The value is given in terabytes.
        price_monthly:
          type: number
          format: float
          example: 5
          description: This attribute describes the monthly cost of this Droplet size if the Droplet is kept for an entire month. The value is measured in US dollars.
        price_hourly:
          type: number
          format: float
          example: 0.00743999984115362
          description: This describes the price of the Droplet size as measured hourly. The value is measured in US dollars.
        regions:
          type: array
          items:
            type: string
          example:
          - ams2
          - ams3
          - blr1
          - fra1
          - lon1
          - nyc1
          - nyc2
          - nyc3
          - sfo1
          - sfo2
          - sfo3
          - sgp1
          - tor1
          description: An array containing the region slugs where this size is available for Droplet creates.
        available:
          type: boolean
          default: true
          example: true
          description: This is a boolean value that represents whether new Droplets can be created with this size.
        description:
          type: string
          example: Basic
          description: 'A string describing the class of Droplets created from this size. For example: Basic, General Purpose, CPU-Optimized, Memory-Optimized, or Storage-Optimized.'
        disk_info:
          type: array
          description: An array of objects containing information about the disks available to Droplets created with this size.
          items:
            $ref: '#/components/schemas/disk_info'
        gpu_info:
          $ref: '#/components/schemas/gpu_info'
      required:
      - available
      - disk
      - memory
      - price_hourly
      - price_monthly
      - regions
      - slug
      - transfer
      - vcpus
      - description
    meta:
      type: object
      properties:
        meta:
          allOf:
          - $ref: '#/components/schemas/meta_properties'
          - required:
            - total
      required:
      - meta
    link_to_next_page:
      type: object
      properties:
        next:
          description: URI of the next page of the results.
          type: string
          example: https://api.digitalocean.com/v2/images?page=2
    disk_info:
      type: object
      properties:
        type:
          type: string
          enum:
          - local
          - scratch
          description: The type of disk. All Droplets contain a `local` disk. Additionally, GPU Droplets can also have a `scratch` disk for non-persistent data.
          example: local
        size:
          type: object
          properties:
            amount:
              type: integer
              description: The amount of space allocated to the disk.
              example: 25
            unit:
              type: string
              description: The unit of measure for the disk size.
              example: gib
    pagination:
      type: object
      properties:
        links:
          $ref: '#/components/schemas/page_links'
    link_to_prev_page:
      type: object
      properties:
        prev:
          description: URI of the previous page of the results.
          type: string
          example: https://api.digitalocean.com/v2/images?page=1
    link_to_first_page:
      type: object
      properties:
        first:
          description: URI of the first page of the results.
          type: string
          example: https://api.digitalocean.com/v2/images?page=1
    forward_links:
      allOf:
      - $ref: '#/components/schemas/link_to_last_page'
      - $ref: '#/components/schemas/link_to_next_page'
    page_links:
      type: object
      properties:
        pages:
          anyOf:
          - $ref: '#/components/schemas/forward_links'
          - $ref: '#/components/schemas/backward_links'
          - {}
          example:
            pages:
              first: https://api.digitalocean.com/v2/account/keys?page=1
              prev: https://api.digitalocean.com/v2/account/keys?page=2
  responses:
    unexpected_error:
      description: Unexpected error
      headers:
        ratelimit-limit:
          $ref: '#/components/headers/ratelimit-limit'
        ratelimit-remaining:
          $ref: '#/components/headers/ratelimit-remaining'
        ratelimit-reset:
          $ref: '#/components/headers/ratelimit-reset'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          example:
            id: example_error
            message: some error message
    all_sizes:
      description: A JSON object with a key called `sizes`. The value of this will be an array of `size` objects each of which contain the standard size attributes.
      headers:
        ratelimit-limit:
          $ref: '#/components/headers/ratelimit-limit'
        ratelimit-remaining:
          $ref: '#/components/headers/ratelimit-remaining'
        ratelimit-reset:
          $ref: '#/components/headers/ratelimit-reset'
      content:
        application/json:
          schema:
            allOf:
            - type: object
              properties:
                sizes:
                  type: array
                  items:
                    $ref: '#/components/schemas/size'
              required:
              - sizes
            - $ref: '#/components/schemas/pagination'
            - $ref: '#/components/schemas/meta'
            example:
              sizes:
              - slug: s-1vcpu-1gb
                memory: 1024
                vcpus: 1
                disk: 25
                transfer: 1
                price_monthly: 5
                price_hourly: 0.00743999984115362
                regions:
                - ams2
                - ams3
                - blr1
                - fra1
                - lon1
                - nyc1
                - nyc2
                - nyc3
                - sfo1
                - sfo2
                - sfo3
                - sgp1
                - tor1
                available: true
                description: Basic
                disk_info:
                - type: local
                  size:
                    amount: 25
                    unit: gib
              links:
                pages:
                  last: https://api.digitalocean.com/v2/sizes?page=64&per_page=1
                  next: https://api.digitalocean.com/v2/sizes?page=2&per_page=1
              meta:
                total: 64
    too_many_requests:
      description: API Rate limit exceeded
      headers:
        ratelimit-limit:
          $ref: '#/components/headers/ratelimit-limit'
        ratelimit-remaining:
          $ref: '#/components/headers/ratelimit-remaining'
        ratelimit-reset:
          $ref: '#/components/headers/ratelimit-reset'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          example:
            id: too_many_requests
            message: API Rate limit exceeded.
    unauthorized:
      description: Unauthorized
      headers:
        ratelimit-limit:
          $ref: '#/components/headers/ratelimit-limit'
        ratelimit-remaining:
          $ref: '#/components/headers/ratelimit-remaining'
        ratelimit-reset:
          $ref: '#/components/headers/ratelimit-reset'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          example:
            id: unauthorized
            message: Unable to authenticate you.
    server_error:
      description: Server error.
      headers:
        ratelimit-limit:
          $ref: '#/components/headers/ratelimit-limit'
        ratelimit-remaining:
          $ref: '#/components/headers/ratelimit-remaining'
        ratelimit-reset:
          $ref: '#/components/headers/ratelimit-reset'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          example:
            id: server_error
            message: Unexpected server-side error
  parameters:
    per_page:
      in: query
      name: per_page
      required: false
      description: Number of items returned per page
      schema:
        type: integer
        minimum: 1
        default: 20
        maximum: 200
      example: 2
    page:
      in: query
      name: page
      required: false
      description: Which 'page' of paginated results to return.
      schema:
        type: integer
        minimum: 1
        default: 1
      example: 1
  headers:
    ratelimit-reset:
      schema:
        type: integer
      example: 1444931833
      description: The time when the oldest request will expire. The value is given in Unix epoch time. See https://developers.digitalocean.com/documentation/v2/#rate-limit for information about how requests expire.
    ratelimit-remaining:
      schema:
        type: integer
      example: 4816
      description: The number of requests in your hourly quota that remain before you hit your request limit. See https://developers.digitalocean.com/documentation/v2/#rate-limit for information about how requests expire.
    ratelimit-limit:
      schema:
        type: integer
      example: 5000
      description: The default limit on number of requests that can be made per hour and per minute. Current rate limits are 5000 requests per hour and 250 requests per minute.
  securitySchemes:
    bearer_auth:
      type: http
      scheme: bearer
      description: '## OAuth Authentication


        In order to interact with the DigitalOcean API, you or your application must

        authenticate.


        The DigitalOcean API handles this through OAuth, an open standard for

        authorization. OAuth allows you to delegate access to your account.

        Scopes can be used to grant full access, read-only access, or access to

        a specific set of endpoints.


        You can generate an OAuth token by visiting the [Apps & API](https://cloud.digitalocean.com/account/api/tokens)

        section of the DigitalOcean control panel for your account.


        An OAuth token functions as a complete authentication request. In effect, it

        acts as a substitute for a username and password pair.


        Because of this, it is absolutely **essential** that you keep your OAuth

        tokens secure. In fact, upon generation, the web interface will only display

        each token a single time in order to prevent the token from being compromised.


        DigitalOcean access tokens begin with an identifiable prefix in order to

        distinguish them from other similar tokens.


        - `dop_v1_` for personal access tokens generated in the control panel

        - `doo_v1_` for tokens generated by applications using [the OAuth flow](https://docs.digitalocean.com/reference/api/oauth-api/)

        - `dor_v1_` for OAuth refresh tokens


        ### Scopes


        Scopes act like permissions assigned to an API token. These permissions

        determine what actions the token can perform. You can create API

        tokens that grant read-only access, full access, or limited access to

        specific endpoints by using custom scopes.


        Generally, scopes are designed to match HTTP verbs and common CRUD

        operations (Create, Read, Update, Delete).


        | HTTP Verb | CRUD Operation | Scope |

        |---|---|---|

        | GET | Read | `<resource>:read` |

        | POST | Create | `<resource>:create` |

        | PUT/PATCH | Update | `<resource>:update` |

        | DELETE | Delete | `<resource>:delete` |


        For example, creating a new Droplet by making a `POST` request to the

        `/v2/droplets` endpoint requires the `droplet:create` scope while

        listing Droplets by making a `GET` request to the `/v2/droplets`

        endpoint requires the `droplet:read` scope.


        Each endpoint below specifies which scope is required to access it when

        using custom scopes.


        ### How to Authenticate with OAuth


        In order to make an authenticated request, include a bearer-type

        `Authorization` header containing your OAuth token. All requests must be

        made over HTTPS.


        ### Authenticate with a Bearer Authorization Header


        ```

        curl -X $HTTP_METHOD -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" "https://api.digitalocean.com/v2/$OBJECT"

        ```

        '