---
title: "Edit a product"
description: "Name/desc/kind/code/active."
canonical_url: "https://twominutebilling.com/help/developers/api-reference/catalog/edit-a-product"
---
# Edit a product

> Name/desc/kind/code/active.

<api-operation method="PATCH" path="/v1/businesses/{biz}/products/{prod}">
<template v-slot:docs="">

## Path parameters

<table>
<thead>
  <tr>
    <th>
      Parameter
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Required
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        biz
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      <strong>
        yes
      </strong>
    </td>
    
    <td>
      Business id (biz_…)
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        prod
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      <strong>
        yes
      </strong>
    </td>
    
    <td>
      The product's id (a slug id, e.g. <code>
        pro
      </code>
      
      ).
    </td>
  </tr>
</tbody>
</table>

## Headers

<table>
<thead>
  <tr>
    <th>
      Parameter
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Required
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        Idempotency-Key
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      Safely retry writes — repeats return the original response. If a write FAILED after it had already taken effect, that failure is what repeats: the key is spent, and a new attempt needs a new key.
    </td>
  </tr>
</tbody>
</table>

## Body

The request body is **required**.

<table>
<thead>
  <tr>
    <th>
      Field
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Required
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        tax_code
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      HSN/SAC classification (India GST). Falls back to the business default_tax_code when null.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        name
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      The product's name.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        description
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      The product's description.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        kind
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      Whether the product is a plan, an addon or a one-time charge. One of <code>
        plan
      </code>
      
      , <code>
        addon
      </code>
      
      , <code>
        charge
      </code>
      
      .
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        code
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      The product's code, unique within the business.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        enabled_for_checkout
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      Stored only: no checkout reads it yet, so it changes nothing.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        enabled_in_portal
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      Stored only: the customer portal does not read it yet, so it changes nothing.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        redirect_url
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      Where hosted checkout sends the buyer after paying, when the checkout or payment link names no redirect of its own (the plan's product, else the first item's). javascript:, data:, vbscript:, file: and blob: are refused. Send "" to clear.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        addon_applies_to_all
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      For an addon: true if it can attach to every plan.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        product_group
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      Move the product to a different group
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        active
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      false to archive, true to restore
    </td>
  </tr>
</tbody>
</table>

## Response

<table>
<thead>
  <tr>
    <th>
      Field
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        tax_code
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      HSN/SAC classification (India GST). Falls back to the business default_tax_code when null.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        object
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The object type.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        id
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The product's id (<code>
        pro
      </code>
      
      ).
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        product_group
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The id of the product group this product is in (a slug id, e.g. <code>
        default
      </code>
      
      ), or null.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        kind
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      Whether the product is a plan, an addon or a one-time charge. One of <code>
        plan
      </code>
      
      , <code>
        addon
      </code>
      
      , <code>
        charge
      </code>
      
      .
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        code
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The product's code, unique within the business.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        name
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The product's name.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        description
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The product's description.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        image_url
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The product's image. Set with <code>
        POST …/products/{prod}/image
      </code>
      
      .
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        enabled_for_checkout
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      Stored only: no checkout reads it yet, so it changes nothing.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        enabled_in_portal
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      Stored only: the customer portal does not read it yet, so it changes nothing.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        redirect_url
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      Where hosted checkout sends the buyer after paying, when the checkout or payment link names no redirect of its own (the plan's product, else the first item's). javascript:, data:, vbscript:, file: and blob: are refused. Send "" to clear.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        addon_applies_to_all
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      For an addon: true if it can attach to every plan.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        active
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      True if the product is active.
    </td>
  </tr>
</tbody>
</table>

## Status codes

<table>
<thead>
  <tr>
    <th>
      Status
    </th>
    
    <th>
      Meaning
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        200
      </code>
    </td>
    
    <td>
      Success
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        404
      </code>
    </td>
    
    <td>
      No such product
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        409
      </code>
    </td>
    
    <td>
      Idempotency-Key conflict — the key is already in flight, or was reused with a different request payload.
    </td>
  </tr>
</tbody>
</table>
</template>

<template v-slot:request="">

```bash [Request]
curl -X PATCH "$TMBILLING_URL/v1/businesses/biz_XXXXXXXXXXXX01/products/pro" \
  -H "Authorization: Bearer $TMBILLING_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Pro",
    "description": "Everything a growing team needs."
  }'
```

</template>

<template v-slot:response="">
<code-group>

```json [200 OK]
{
  "tax_code": "998314",
  "object": "product",
  "id": "pro",
  "product_group": "default",
  "kind": "plan",
  "code": "welcome-10",
  "name": "Pro",
  "description": "Everything a growing team needs.",
  "image_url": "https://example.com/webhooks/billing",
  "enabled_for_checkout": false,
  "enabled_in_portal": false,
  "redirect_url": "https://example.com/thanks",
  "addon_applies_to_all": false,
  "active": false
}
```

```json [404 Not Found]
{
  "error": {
    "type": "invalid_request_error",
    "message": "No such product"
  }
}
```

```json [409 Conflict]
{
  "error": {
    "type": "idempotency_error",
    "message": "Idempotency-Key conflict — the key is already in flight, or was reused with a different request payload."
  }
}
```

</code-group>
</template>
</api-operation>


## Sitemap

See the full [sitemap](https://twominutebilling.com/sitemap.md) for all pages.
