WavePayby T3raTech

API reference

Subscriptions, instalments and refunds

Recurring charges, buy-now-pay-later schedules and refunds.

POST/v2/internal/subscriptions

Open a subscription (flag: recurring; test keys always)

Authentication: Merchant key in x-wavepay-service-key

Parameters

NameInRequiredType
Idempotency-Keyheaderyesstring

Body (JSON)

FieldTypeRequired
productIdstringyes
planIdstringyes
providerpaynow | paynow-mobile | paypalyes
emailstringyes
phonestringno
externalSubjectstringyes
collectionautomatic | invoice_and_remindno
methodstringno

Responses

StatusMeaning
201OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/subscriptions \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"productId":"…","planId":"…","provider":"paynow","email":"…","phone":"…","externalSubject":"…","collection":"automatic","method":"…"}'
GET/v2/internal/subscriptions

List this merchant's subscriptions

Authentication: Merchant key in x-wavepay-service-key

Responses

StatusMeaning
200OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX GET https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/subscriptions \
  -H 'x-wavepay-service-key: mk_live_…'
POST/v2/internal/subscriptions/cancel

Cancel a subscription now or at period end

Authentication: Merchant key in x-wavepay-service-key

Body (JSON)

FieldTypeRequired
idstringyes
atPeriodEndbooleanno

Responses

StatusMeaning
200OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/subscriptions/cancel \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"id":"…","atPeriodEnd":true}'
POST/v2/internal/bnpl

Start buy-now-pay-later (flag: bnpl; test keys always)

Authentication: Merchant key in x-wavepay-service-key

Parameters

NameInRequiredType
Idempotency-Keyheaderyesstring

Body (JSON)

FieldTypeRequired
productIdstringyes
planIdstringyes
providerpaynow | paypalyes
emailstringyes
externalSubjectstringyes
instalmentsintegeryes
depositMinorintegerno
intervalDaysintegerno

Responses

StatusMeaning
201OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/bnpl \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"productId":"…","planId":"…","provider":"paynow","email":"…","externalSubject":"…","instalments":0,"depositMinor":0,"intervalDays":0}'
GET/v2/internal/bnpl

List this merchant's BNPL plans

Authentication: Merchant key in x-wavepay-service-key

Responses

StatusMeaning
200OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX GET https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/bnpl \
  -H 'x-wavepay-service-key: mk_live_…'
POST/v2/internal/bnpl/cancel

Cancel a BNPL plan

Authentication: Merchant key in x-wavepay-service-key

Body (JSON)

FieldTypeRequired
idstringyes

Responses

StatusMeaning
200OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/bnpl/cancel \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"id":"…"}'
POST/v2/internal/refunds

Refund a settled payment (flag: refunds; test keys always)

Authentication: Merchant key in x-wavepay-service-key

Parameters

NameInRequiredType
Idempotency-Keyheaderyesstring

Body (JSON)

FieldTypeRequired
referencestringyes
amountMinorintegerno
reasonstringno
revokeAccessbooleanno

Responses

StatusMeaning
201OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/refunds \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"reference":"…","amountMinor":0,"reason":"…","revokeAccess":true}'
POST/v2/test/billing/run

Run the billing engine as if advanceDays had passed (mk_test_ keys only)

Authentication: None (public)

Body (JSON)

FieldTypeRequired
advanceDaysintegerno

Responses

StatusMeaning
200OK
403FEATURE_DISABLED (flag off for live money) or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/test/billing/run \
  -H 'content-type: application/json' \
  -d '{"advanceDays":0}'
POST/v2/internal/subscriptions/pause

Pause a subscription: keeps paid access, stops the next renewal (also at 2Checkout)

Authentication: Merchant key in x-wavepay-service-key

Body (JSON)

FieldTypeRequired
idstringyes

Responses

StatusMeaning
200OK
403FEATURE_DISABLED or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/subscriptions/pause \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"id":"…"}'
POST/v2/internal/subscriptions/resume

Resume a paused subscription

Authentication: Merchant key in x-wavepay-service-key

Body (JSON)

FieldTypeRequired
idstringyes

Responses

StatusMeaning
200OK
403FEATURE_DISABLED or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/subscriptions/resume \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"id":"…"}'
POST/v2/internal/subscriptions/price

Change what the next renewals cost (also at 2Checkout)

Authentication: Merchant key in x-wavepay-service-key

Body (JSON)

FieldTypeRequired
idstringyes
amountMinorintegeryes

Responses

StatusMeaning
200OK
403FEATURE_DISABLED or MERCHANT_SCOPE

Example

curl -sX POST https://t3rnel-wavepay-production.t3ratech.workers.dev/v2/internal/subscriptions/price \
  -H 'x-wavepay-service-key: mk_live_…' \
  -H 'content-type: application/json' \
  -d '{"id":"…","amountMinor":0}'