Externally Managed Recurring Billing

👍

Check our Reference Materials for more details about a payment connector.

Externally-managed recurring billing means that a subscription is created and managed outside of Cleeng, for example inside either a given payment gateway or the Broadcaster’s billing engine.

It is then gateway-specific how to notify the connector about successful/failed payment attempts or subscription status changes (e.g. new payment, refund, or subscription termination).

How to set up listeners in the connector to receive status change notifications?

A listener is an endpoint in the connector to which payment gateway notifications are sent.

You need to create an endpoint and register its URL within the payment gateway so that notifications will be sent there. You might create one endpoint for all notifications or one endpoint for each message type, depending on what a payment gateway allows.

After a gateway notification is received by the connector it must call appropriate Payment API endpoints to notify Cleeng about the changes. For example, if a notification about a successful payment capture is received by the connector, it should call POST /3.1/payments to create a captured payment.

Externally-Managed Recurring Billing - Capture ProcessExternally-Managed Recurring Billing - Capture Process

Externally-Managed Recurring Billing - Capture Process

For smooth integration, Cleeng should be informed about the following:

  • New payments (authorisation and capture) - using POST /3.1/payments or PATCH /3.1/payments with appropriate statuses
  • Subscription status changes in a payment gateway, especially those that result in the user not having access to content (e.g. termination of subscription - using POST /3.1/wrappers/terminate_subscription)
  • Rejected payments - using POST /3.1/payments or PATCH /3.1/payments with "rejected" status
  • Refunds.

📘

Note

It is important that notifications are set up in such a way that all the events that happen on the payment gateway are also registered at Cleeng.


Did this page help you?