Skip to main content
POST
/
subscriptions
/
{subscription_id}
/
pause
Subscription - Pause Subscription
curl --request POST \
  --url https://sandbox.hyperswitch.io/subscriptions/{subscription_id}/pause \
  --header 'Content-Type: application/json' \
  --header 'X-Profile-Id: <x-profile-id>' \
  --header 'api-key: <api-key>' \
  --data '{
  "pause_option": "immediately"
}'
{
  "id": "<string>",
  "status": "active",
  "merchant_reference_id": "<string>",
  "profile_id": "<string>",
  "merchant_id": "<string>",
  "customer_id": "<string>",
  "paused_at": "<string>"
}

Authorizations

api-key
string
header
required

Use the API key created under your merchant account from the HyperSwitch dashboard. API key is used to authenticate API requests from your merchant server only. Don't expose this key on a website or embed it in a mobile application.

Headers

X-Profile-Id
string
required

Profile ID for authentication

Path Parameters

subscription_id
string
required

The unique identifier for the subscription

Body

application/json

Request payload for pausing a subscription.

pause_option
enum<string>
Available options:
immediately,
end_of_term,
specific_date
pause_at
string | null

Optional date when the subscription should be paused (if not provided, pauses immediately)

Response

Subscription paused successfully

Response payload returned after successfully pausing a subscription.

id
string
required

A type for subscription_id that can be used for subscription ids

status
enum<string>
required

Possible states of a subscription lifecycle.

  • Created: Subscription was created but not yet activated.
  • Active: Subscription is currently active.
  • InActive: Subscription is inactive.
  • Pending: Subscription is pending activation.
  • Trial: Subscription is in a trial period.
  • Paused: Subscription is paused.
  • Unpaid: Subscription is unpaid.
  • Onetime: Subscription is a one-time payment.
  • Cancelled: Subscription has been cancelled.
  • Failed: Subscription has failed.
Available options:
active,
created,
in_active,
pending,
trial,
paused,
unpaid,
onetime,
cancelled,
failed
profile_id
string
required

A type for profile_id that can be used for business profile ids

merchant_id
string
required

A type for merchant_id that can be used for merchant ids

customer_id
string
required

A type for customer_id that can be used for customer ids

merchant_reference_id
string | null

Merchant specific Unique identifier.

paused_at
string | null

Date when the subscription was paused