Pause a recurring payment.
POST
/v1/recurring-payments/{reference}/pause
const url = 'https://api.ridleypay.com/v1/recurring-payments/WOO-SUB-456/pause';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.ridleypay.com/v1/recurring-payments/WOO-SUB-456/pause \ --header 'Authorization: Bearer <token>'Temporarily pauses billing. No charges will be made until resumed.
Authorizations
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”reference
required
string
The recurring payment reference.
Example
WOO-SUB-456Responses
Section titled “ Responses ”Paused
Media typeapplication/json
object
data
object
id
string
type
string
attributes
object
reference
string
status
string
links
object
self
string
meta
object
message
string
Example
{ "data": { "id": "1", "type": "recurring-payments", "attributes": { "reference": "WOO-SUB-456", "status": "paused" }, "links": { "self": "https://pay.example.com/api/v1/recurring-payments/WOO-SUB-456" } }, "meta": { "message": "Recurring payment paused." }}Not found
Media typeapplication/json
object
errors
Array<object>
object
status
string
title
string
detail
string
Example
{ "errors": [ { "status": "404", "title": "Not Found", "detail": "Recurring payment not found." } ]}Cannot pause
Media typeapplication/json
object
errors
Array<object>
object
status
string
title
string
detail
string
Example
{ "errors": [ { "status": "422", "title": "Unprocessable Entity", "detail": "Only active or suspended recurring payments can be paused." } ]}