v51

latestOpenAPI 3.0.0Apache 2.0raw.githubusercontent.com2026-08-011534301009.2 KB
Product Catalog

Update add-on assignment for plan

Update add-on assignment for plan.

put/api/v1/plans/{planId}/addons/{planAddonId}

Path parameters

planIdstring required
Example:01G65Z755AFWAKHE12NY0CQ9FH
planAddonIdstring required
Example:01G65Z755AFWAKHE12NY0CQ9FH

Request body

metadataMetadata

Set of key-value pairs. Metadata can be used to store additional information about a resource.

fromPlanPhasestring required

The key of the plan phase from the add-on becomes available for purchase.

maxQuantityinteger

The maximum number of times the add-on can be purchased for the plan. It is not applicable for add-ons with single instance type.

Example request

{
  "metadata": {
    "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
  }
}

Response

The request has succeeded.

createdAtstring date-time required

Timestamp of when the resource was created.

updatedAtstring date-time required

Timestamp of when the resource was last updated.

deletedAtstring date-time

Timestamp of when the resource was permanently deleted.

annotationsAnnotations

Set of key-value pairs managed by the system. Cannot be modified by user.

metadataMetadata

Set of key-value pairs. Metadata can be used to store additional information about a resource.

fromPlanPhasestring required

The key of the plan phase from the add-on becomes available for purchase.

maxQuantityinteger

The maximum number of times the add-on can be purchased for the plan. It is not applicable for add-ons with single instance type.

Example response

{
  "createdAt": "2024-01-01T01:01:01.001Z",
  "updatedAt": "2024-01-01T01:01:01.001Z",
  "deletedAt": "2024-01-01T01:01:01.001Z",
  "annotations": {
    "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
  },
  "metadata": {
    "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
  },
  "addon": {
    "id": "01G65Z755AFWAKHE12NY0CQ9FH",
    "metadata": {
      "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
    },
    "createdAt": "2024-01-01T01:01:01.001Z",
    "updatedAt": "2024-01-01T01:01:01.001Z",
    "deletedAt": "2024-01-01T01:01:01.001Z",
    "annotations": {
      "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
    },
    "currency": "USD",
    "effectiveFrom": "2023-01-01T01:01:01.001Z",
    "effectiveTo": "2023-01-01T01:01:01.001Z",
    "rateCards": [
      {
        "metadata": {
          "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
        },
        "entitlementTemplate": {
          "metadata": {
            "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
          }
        },
        "taxConfig": {
          "stripe": {
            "code": "txcd_10000000"
          },
          "taxCodeId": "01G65Z755AFWAKHE12NY0CQ9FH"
        },
        "discounts": {
          "percentage": {
            "percentage": 50
          }
        }
      }
    ],
    "validationErrors": [
      {
        "field": "addons/pro/ratecards/token/featureKey",
        "code": "invalid_feature_key",
        "message": "not found feature by key",
        "attributes": {
          "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
        }
      }
    ]
  },
  "validationErrors": [
    {
      "field": "addons/pro/ratecards/token/featureKey",
      "code": "invalid_feature_key",
      "message": "not found feature by key",
      "attributes": {
        "externalId": "019142cc-a016-796a-8113-1a942fecd26d"
      }
    }
  ]
}