Create an Automatic Recurring Recharge
Perform this task to configure MATRIXX Engine to automatically recharge a prepaid actual currency balance based on a recurring cycle. You can configure automatic recurring recharge for billing cycles and purchased item cycles.
Before you begin
You must register a payment method for the subscriber on the account that is associated with the request-only payment gateway. The subscriber's default payment method for system initiated charges must use the registered payment method.
Procedure
-
Configure the ActiveMQ (JMS) properties in the
/opt/mtx/conf/payment-service.yaml file.
For example:
spring: activemq: brokerUrl: ${jms.url:failover:(tcp://127.0.0.1:61616)} user: ${jms.username:guest} password: ${jms.password:guest} pool: enabled: true payment: gateway: #Request Only Payment Gateway requestonly: configs: default: queue: payment_request_only_gateway format: json
-
During system configuration, answer the questions in Active MQ Questions.
Table 1. Active MQ Questions Question Default The ActiveMQ message handler ID. For more than one ActiveMQ message handler, separate each message handler ID with a semi-colon(;). For example, enter the following: payments;notification create_config.info question: ActiveMQ Gateway:ActiveMQ Group <groupId>:Session <sessionId>:What are your message handler IDs?
For each message handler ID, you must define the producer type.
payments;notification The ActiveMQ message producer destination type. create_config.info question: ActiveMQ Gateway:ActiveMQ Group <groupId>:Session <sessionId>:MessageHandler <messageHandlerId>:What is the producer's type?
Possible producer type values are:- queue
- topic
For each ActiveMQ producer, you must specify the producer destination type.
queue The ActiveMQ message producer destination name. create_config.info question: ActiveMQ Gateway:ActiveMQ Group <groupId>:Session <sessionId>:MessageHandler <messageHandlerId>:What is the producer's name?
Note: This must match the name specified for the Integration Framework in mtx_notifier_camel.yaml.fromEngineProducer The ActiveMQ consumer destination type. create_config.info question: ActiveMQ Gateway:ActiveMQ Group <groupId>:Session <sessionId>:MessageHandler <messageHandlerId>:What is the consumer's type?
Possible consumer type values are:- queue
- topic
queue The ActiveMQ consumer destination name. create_config.info question: ActiveMQ Gateway:ActiveMQ Group <groupId>:Session <sessionId>:MessageHandler <messageHandlerId>:What is the consumer's name?
Note: This must match the name specified for the Integration Framework mtx_notifier_camel.yaml.fromEngineConsumer -
During system configuration, answer the following Recurring Recharge Questions.
Table 2. Recurring Recharge Questions Question Default Sets the amount of time prior to the start of a cycle period to submit an automatic recharge request. If the answer is 0, this feature is disabled. create_config.info question: Global:How long (in minutes) prior to the start of a cycle period should an automatic recharge request be submitted?
Note: If you set the recurring recharge time far in advance of the time that recurring processing occurs, it is possible that an event can occur that uses the funds from the recharge before recurring processing occurs. This causes recurring processing to fail.0 Sets the time range that determines the cycles with recurring charges that will be aggregated so that only one recharge request is submitted. If the answer is 0, only recurring charges due for cycles with exactly the same start time are aggregated.
create_config.info question: Global:What is the time range (in minutes) to aggregate all charges due during automatic recurring recharge processing?
0 Sets whether the current balance amount of all prepaid currency balance instances that are of the same class as the prepaid main balance are deducted from the recurring amount. create_config.info question: Global:Should the current balance amount of all prepaid currency balance instances that are of the same class as the prepaid main balance be deducted from the recurring amount during automatic recurring recharge processing (y/n)?
If the answer is
n
, the following question is asked.n Sets whether the current balance amount of prepaid actual currency balance instances that are of the same class as the prepaid main balance should be deducted from the recurring amount. create_config.info question: Global:Should the current balance amount of prepaid actual currency balance instances that are of the same class as the prepaid main balance be deducted from the recurring amount during automatic recurring recharge processing (y/n)?
If the answer is
n
, the following question is asked.n Determines whether the current prepaid main balance amount should be deducted from the recurring amount. create_config.info question: Global:Should the current prepaid main balance amount be deducted from the recurring amount during automatic recurring recharge processing (y/n)?
n -
Specify a payment method for system-initiated charges for the
subscriber or group using the following payment SubMan APIs.
- MtxRequestSubscriberAddPaymentMethod
- MtxRequestSubscriberModifyPaymentMethod
- MtxRequestGroupAddPaymentMethod
- MtxRequestGroupModifyPaymentMethod
When you add a payment method, you must set the
paymentGatewayOneTimeToken
field. -
(Optional) Set a default system payment method using the
PaymentMethod APIs.
When adding or modifying a payment method, set the
IsSysDefault
totrue
.