v6

latestOpenAPI 3.1.02026-07-311856741.1 MB
products
public

Update Product

Update a product.

Scopes: products:write

patch/v1/products/{id}

Path parameters

idstring uuid4 required

The product ID.

Request body

metadataobject

Key-value object allowing you to store additional information.

The key must be a string with a maximum length of 40 characters. The value must be either:

  • A string with a maximum length of 500 characters
  • An integer
  • A floating-point number
  • A boolean

You can store up to 50 key-value pairs.

trial_interval'day' | 'week' | 'month' | 'year'
trial_interval_countinteger nullable

The number of interval units for the trial period.

namestring nullable

The name of the product.

descriptionstring nullable

The description of the product.

recurring_interval'day' | 'week' | 'month' | 'year'
recurring_interval_countinteger nullable

Number of interval units of the subscription. If this is set to 1 the charge will happen every interval (e.g. every month), if set to 2 it will be every other month, and so on. Once set, it can't be changed.**

is_archivedboolean nullable

Whether the product is archived. If true, the product won't be available for purchase anymore. Existing customers will still have access to their benefits, and subscriptions will continue normally.

visibility'draft' | 'private' | 'public'
mediasstring[] nullable

List of file IDs. Each one must be on the same organization as the product, of type product_media and correctly uploaded.

Response

Product updated.

idstring uuid4 required

The ID of the object.

created_atstring date-time required

Creation timestamp of the object.

modified_atstring date-time nullable required

Last modification timestamp of the object.

trial_interval'day' | 'week' | 'month' | 'year' required
trial_interval_countinteger nullable required

The number of interval units for the trial period.

namestring required

The name of the product.

descriptionstring nullable required

The description of the product.

visibility'draft' | 'private' | 'public' required
recurring_interval'day' | 'week' | 'month' | 'year' required
recurring_interval_countinteger nullable required

Number of interval units of the subscription. If this is set to 1 the charge will happen every interval (e.g. every month), if set to 2 it will be every other month, and so on. None for one-time products.

meter_interval'day' | 'week' | 'month' | 'year' required
meter_interval_countinteger nullable required

Number of meter interval units. None when no meter cycle is set.

is_recurringboolean required

Whether the product is a subscription.

is_archivedboolean required

Whether the product is archived and no longer available.

organization_idstring uuid4 required

The ID of the organization owning the product.

metadataMetadataOutputType required

Example response

{
  "benefits": [
    {
      "properties": {
        "repository_owner": "polarsource",
        "repository_name": "private_repo"
      }
    }
  ],
  "attached_custom_fields": [
    {
      "custom_field": {
        "organization_id": "1dbfc517-0bbf-4301-9ba8-555ca42b9737"
      }
    }
  ]
}