---
title: "Update a tariff subscription"
method: PATCH
path: "/api/v1/external/tariff-subscriptions/{subscriptionId}"
tags: ["Tariff Subscriptions"]
---

# Update a tariff subscription

`PATCH /api/v1/external/tariff-subscriptions/{subscriptionId}`

## Request

- Base URL: `https://api.wove.com`
- URL: `https://api.wove.com/api/v1/external/tariff-subscriptions/{subscriptionId}`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/wove/apis/wove-external-api/docs/api/v1/external/tariff-subscriptions/:subscriptionId/patch.ts> (a function with typed inputs; its response is checked against the schema)

## Request body

- UpdateTariffSubscriptionRequest
  - `originCountries` string[]: Added origins are baselined without a notification; removed origins are dropped.
  - `notifyOn` 'effective' | 'scheduled' | 'both'
  - `lookaheadDays` integer
  - `componentValues` object, nullable: Changing it re-baselines every origin without a notification. Null clears it.
  - `includeTreatments` boolean
  - `isActive` boolean

## Response `200`

Subscription updated

- object
  - `success` boolean
  - `data` TariffSubscription
    - `id` string
    - `hsCode` string
    - `destinationCountry` 'US' | 'CA' | 'AU'
    - `originCountries` string[]
    - `notifyOn` 'effective' | 'scheduled' | 'both'
    - `lookaheadDays` integer
    - `componentValues` object, nullable
    - `includeTreatments` boolean
    - `webhookId` string
    - `isActive` boolean
    - `status` 'baselining' | 'active' | 'paused' | 'webhook_disabled': `baselining` until the starting treatment of every origin is recorded (usually seconds). `webhook_disabled` when the webhook was turned off after 10 failed deliveries in a row spanning more than 24 hours; re-enable it and everything since the last delivery is sent on the next evaluation.
    - `lastEvaluatedAt` string, date-time, nullable
    - `lastNotifiedAt` string, date-time, nullable
    - `nextEvaluationAt` string, date-time, nullable
    - `createdAt` string, date-time
    - `updatedAt` string, date-time

## Other responses

- `404`: Subscription not found

---

[API](https://skmtc.dev/wove/apis/wove-external-api.md) - [All operations](https://skmtc.dev/wove/apis/wove-external-api/llms.txt) - [OpenAPI document](https://skmtc.dev/wove/apis/wove-external-api/revisions/37290e267e07?raw)
