Update a one-time product’s content. If the content has changed, a new immutable version is created automatically. If the content is identical to the current version, no new version is created.
POST /v1/actions/onetime-product/update-product
Authentication: API Key
Use the Update Status endpoint to change a product’s status (active/inactive). This endpoint is for content updates only.
Request Body
| Field | Type | Required | Description |
|---|
id | string | Yes | Product ID (Short ID format PROD_xxx) |
name | string | Yes | Updated product name |
description | string | No | Updated description |
prices | object | Yes | Updated multi-currency pricing map |
media | array | No | Updated media items |
successUrl | string | No | Updated redirect URL |
metadata | object | No | Updated custom metadata |
For the prices and media object formats, see Create Product.
Example Request
const { product } = await client.onetimeProducts.update({
id: "PROD_3kF9mNpQrStUvWxYz1A2bC",
name: "Premium Template Pack v2",
description: "75 premium design templates — expanded collection.",
prices: {
USD: { amount: 5900, taxIncluded: false, taxCategory: TaxCategory.DigitalGoods },
EUR: { amount: 5500, taxIncluded: true, taxCategory: TaxCategory.DigitalGoods },
},
successUrl: "https://example.com/thank-you",
});
Success Response (200)
{
"data": {
"id": "PROD_3kF9mNpQrStUvWxYz1A2bC",
"storeId": "STO_2aUyqjCzEIiEcYMKj7TZtw",
"prodVersionId": null,
"testVersionId": "PROD_8eH5iKlMnOpQrStUvWxYz2",
"prodStatus": "inactive",
"testStatus": "active",
"createdAt": "2026-01-15T10:30:00.000Z",
"updatedAt": "2026-01-15T11:00:00.000Z",
"version": {
"id": "PROD_8eH5iKlMnOpQrStUvWxYz2",
"productId": "PROD_3kF9mNpQrStUvWxYz1A2bC",
"versionNumber": 2,
"name": "Premium Template Pack v2",
"description": "75 premium design templates — expanded collection.",
"prices": {
"USD": { "amount": 5900, "taxIncluded": false, "taxCategory": "digital_goods" },
"EUR": { "amount": 5500, "taxIncluded": true, "taxCategory": "digital_goods" }
},
"media": [],
"successUrl": "https://example.com/thank-you",
"metadata": null,
"createdAt": "2026-01-15T11:00:00.000Z"
}
}
}
Response Fields
Same as Create Product response.
Product versions are immutable. Existing orders retain their original version. New purchases always use the latest version. If the submitted content is identical to the current version, no new version is created and the existing version is returned.
Error Responses
| Status | Error | Description |
|---|
| 400 | Missing required field: id | id not provided |
| 400 | Missing required field: name | name not provided |
| 400 | Prices must not be empty | prices is missing or an empty object |
| 400 | No version in current environment | Product has no version in the current environment (test/prod) |
| 404 | Product not found | Product does not exist or is not accessible |