Skip to main content

Secrets API Reference

The Secret Manager API provides programmatic access to secret lists and their key-value pairs. Secrets can be used during VM provisioning with the cloud-init option. For portal-based usage, see Managing Secrets.

Secret Lists

Secret lists are containers that hold key-value pairs.

Retrieve All Secret Lists

  • GET /api/secrets/lists

Fetches all available secret lists.

Retrieve a Specific Secret List

  • GET /api/secrets/lists/{secretList}

Retrieves a specific secret list by its name.

Create a New Secret List

  • POST /api/secrets/lists

Creates a new empty secret list. No payload required.

Update an Existing Secret List

  • POST /api/secrets/lists/{secretList}

Updates the name of an existing secret list. List names must be unique across the account.

{
"name": "new name"
}

Delete an Existing Secret List

  • DELETE /api/secrets/lists/{secretList}

Removes a specific secret list.

Secret List Values

Secret list values are the individual key-value pairs stored within a list.

Retrieve All Values Across All Lists

  • GET /api/secrets/all-values

Fetches all values across all secret lists.

Retrieve All Values for a Specific List

  • GET /api/secrets/lists/{secretList}/values

Fetches all values stored within a specific secret list.

Retrieve a Specific Value

  • GET /api/secrets/lists/{secretList}/values/{secretListValue}

Fetches a specific secret value within a secret list.

Create a New Secret Value

  • POST /api/secrets/lists/{secretList}/values

Adds a new key-value pair to a secret list. Secret keys must be unique across the account.

{
"secret_key": "new key",
"secret_value": "new value"
}

Update an Existing Value

  • POST /api/secrets/lists/{secretList}/values/{secretListValue}

Updates an existing secret value within a list.

Delete an Existing Value

  • DELETE /api/secrets/lists/{secretList}/values/{secretListValue}

Removes a specific secret value from a list.

Usage Guide

  • Creating a list — use POST /api/secrets/lists without a payload to create an empty list.

  • Adding a secret value — use POST /api/secrets/lists/{secretList}/values with a JSON payload containing secret_key and secret_value.

  • Updating a secret value — use POST /api/secrets/lists/{secretList}/values/{secretListValue} to modify an existing key-value pair.

  • Referencing in cloud-init — when deploying a virtual server, reference a secret in your cloud-init script using the template syntax. For example, if you have a secret called API_KEY:

    KEY=${{secret.API_KEY}}

Need Help?

Contact support@netactuate.com or open a support ticket from the portal.