Skip to content

Update the payment method on a subscription

PUT
/api/subscriptions/{id}/payment-method
curl --request PUT \
--url https://api.usegro.co/api/subscriptions/example/payment-method \
--header 'Content-Type: application/json' \
--data '{ "payment_method_id": "example" }'

Switches the subscription’s payment method to one of the customer’s existing Shopify payment methods. The new payment method must already exist on the customer in Shopify (use the available list returned by GET /payment-method).

id
required
string
Media typeapplication/json
object
payment_method_id
required

ID of the customer’s Shopify payment method to switch to

string

Example generated

{
"payment_method_id": "example"
}

Payment method updated

Media typeapplication/json
object
success
required
boolean

Example generated

{
"success": true
}

Invalid request — missing payment_method_id, no Shopify contract, or update failed

Media typeapplication/json

Example

{
"error": "Payment method ID is required"
}