Skip to main content
PATCH
/
api
/
v1
/
plans
/
{plan_id}
Update Plan
curl --request PATCH \
  --url https://api.example.com/api/v1/plans/{plan_id} \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <x-api-key>' \
  --data '
{
  "name": "<string>",
  "amount": 123,
  "currency": "<string>",
  "interval_count": 123,
  "trial_period_days": 123,
  "is_active": true
}
'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "name": "<string>",
  "amount": 123,
  "currency": "<string>",
  "interval": "<string>",
  "interval_count": 123,
  "trial_period_days": 123,
  "is_active": true,
  "created_at": "2023-11-07T05:31:56Z"
}

Headers

x-api-key
string
required

Path Parameters

plan_id
string
required

Body

application/json
name
string | null
amount
number | null
currency
string | null
interval
enum<string> | null
Available options:
DAILY,
WEEKLY,
MONTHLY,
YEARLY
interval_count
integer | null
trial_period_days
integer | null
is_active
boolean | null

Response

Successful Response

id
string<uuid>
required
name
string
required
amount
number
required
currency
string
required
interval
string
required
interval_count
integer
required
trial_period_days
integer | null
required
is_active
boolean
required
created_at
string<date-time>
required