pydo.addons.create()

Generated on 3 Aug 2026 from pydo version v0.40.0

Usage

client.addons.create(
    body={
        "app_slug": "example-app",
        "plan_slug": "basic_plan",
        "name": "my-resource-01",
        ...,
    },
)
Returns JSONRaises HttpResponseError

Description

To create an add-on resource, send a POST request to /v2/add-ons/saas with required parameters. Some add-ons require additional metadata to be provided in the request body. To find out what metadata is required for a specific add-on, send a GET request to /v2/add-ons/apps/{app_slug}/metadata.

Parameters

app_slug string required

Example: example-app

The slug identifier for the application associated with the resource.

plan_slug string required

Example: basic_plan

The slug identifier for the plan associated with the resource.

name string required

Example: my-resource-01

The name of the addon resource.

metadata array of objects required

Metadata associated with the resource, set by the user. Metadata expected varies per app, and can be verified with a GET request to "/v2/add-ons/apps/{app_slug}/metadata"

Show child properties
name string required

Example: property_name

The name of the metadata item to be set.

value object required

Example: example_value

The value to be set for the metadata item, which can be a string or boolean.

linked_droplet_id integer optional

Example: 12345678

ID of the droplet to be linked to this resource, if applicable.

fleet_uuid string optional

Example: f1234567-89ab-cdef-0123-456789abcdef01

UUID of the fleet/project to which this resource will belong.

Request Sample

Show Request Sample
import os
from pydo import Client

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

req = {
  "app_slug": "example-app",
  "plan_slug": "basic_plan",
  "name": "my-resource-01",
  "metadata": [],
  "linked_droplet_id": 12345678,
  "fleet_uuid": "f1234567-89ab-cdef-0123-456789abcdef01"
}

resp = client.addons.create(body=req)

Response Example

Show Response Example
{
  "resource": {
    "uuid": "123e4567-e89b-12d3-a456-426614174000",
    "name": "my-resource-01",
    "state": "provisioned",
    "app_name": "Example App",
    "app_slug": "example_app",
    "plan_name": "Basic Plan",
    "plan_slug": "basic_plan",
    "plan_price_per_month": 10,
    "has_config": true,
    "metadata": [],
    "sso_url": "https://example.com/sso",
    "message": "Resource is provisioned successfully."
  }
}

More Information

See /v2/add-ons/saas in the API reference for additional detail on responses, headers, parameters, and more.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.