This page provides the list of events and associated payloads for the Payment microservice.
List of Events
SL.# | NAME | DESCRIPTION | PUBLISH LOCATION | ROUTING KEY | DURABILITY | PAYLOAD TYPE |
1 | Provider Master Created | This event is triggered when the provider master is created. | Topic: PaymentMsgTopic | providermaster.created | false | ProviderMaster |
2 | Provider Master Updated | This event is triggered when the provider master is updated. | Topic: PaymentMsgTopic | providermaster.updated | false | ProviderMaster |
3 | Collection Provider Created | This event is triggered when the collection provider is created. | Topic: PaymentMsgTopic | collectionprovider.created | false | CollectionProvider |
4 | Collection Provider Updated | This event is triggered when the collection provider is updated. | Topic: PaymentMsgTopic | collectionprovider.updated | false | CollectionProvider |
5 | Payment Created | This event is triggered when the payment is created. | Topic: PaymentMsgTopic | payment.created | false | Payment |
6 | Payment Updated | This event is triggered when the payment is updated. | Topic: PaymentMsgTopic | payment.updated | false | Payment |
7 | Payment Item Created | This event is triggered when the payment item is created. | Topic: PaymentMsgTopic | paymentitem.created | false | PaymentItem |
8 | Payment Item Updated | This event is triggered when the payment item is updated. | Topic: PaymentMsgTopic | paymentitem.updated | false | PaymentItem |
9 | Transaction Created | This event is triggered when the transaction is created. | Topic: PaymentMsgTopic | transaction.created | false | Transaction |
10 | Payment Bulk Transaction Request | Payment service is subscribed to the provided event to charge, refund, or authorize the payment. When the order has to be authorized with the payment given by the user, either charge for the order or refund the amount to the user if the order is canceled, deleted, or returned. | Queue: bulkTransactionRequestQueue | bulkTransactionRequestQueue | true | BulkTransactionRequestQueue |
Payload Models
Below are payloads for the Payment microservice.
ProviderMaster
PROPERTY | TYPE | DESCRIPTION | EXAMPLE |
name | String | Indicates the name of the event. | PROVIDERMASTER_CREATED, PROVIDERMASTER_UPDATED |
providerMaster.providerMasterId | Integer | Indicates the unique ID of the provider master. | 1 |
providerMaster.name | String | Indicates the name of the created or updated provider master. | provider1 |
providerMaster.currencyType | String | Indicates the currency type of the provider master. | CASH/NONCASH |
providerMaster.processorClassName | String | Indicates the class name, which implements the payment processor. | com.skava.payment.processor.DefaultPaymentProcessor |
CollectionProvider
PROPERTY | TYPE | DESCRIPTION | EXAMPLE |
name | String | Indicates the name of the event. | COLLECTIONPROVIDER_CREATED, COLLECTIONPROVIDER_UPDATED |
collectionProviderId | Integer | Indicates the unique ID of the collection provider. | 1 |
providerMasterId | Integer | Indicates the unique ID of the provider Master. | 1 |
Payment
PROPERTY | TYPE | DESCRIPTION | EXAMPLE |
name | String | Indicates the name of the transaction. | PAYMENT_CREATED, PAYMENT_UPDATED |
payment.paymentId | Integer | Indicates the unique ID of the payment. | 1 |
payment.paymentType | String | Indicates the type of the payment. | CREDITCARD |
payment.status | String | Indicates the status of the created or updated payment. | ACTIVE |
payment.profileId | String | Indicates the unique ID of the profile. It can be ID of the user or account. | 1 |
payment.profiletype | String | Indicates the type of the profile. | USER/ACCOUNT |
PaymentItem
PROPERTY | TYPE | DESCRIPTION | EXAMPLE |
name | String | Indicates the name of the event. | PAYMENTITEM_CREATED, PAYMENTITEM_UPDATED |
paymentItem.paymenItemtId | String | Indicates the unique ID of the payment item. | 1 |
paymentItem.paymentId | String | Indicates the unique ID of the payment. | 1 |
paymentItem.providerId | String | Indicates the unique ID of the provider. | 1 |
paymentItem.currencyCode | String | Indicates the currency code. | USD |
paymentItem.value | BigDecimal | Refers to the actual amount, currency, or points of a payment item. | 100 |
Transaction
PROPERTY | TYPE | DESCRIPTION | EXAMPLE |
name | String | Indicates the name of the event. | TRANSACTION_CREATED |
transaction.transactionId | Integer | Indicates the unique ID of the transaction. | 1 |
transaction.value | Integer | Refers to the actual amount, currency, or points of a transaction. | 100 |
transaction.transactionType | String | Indicates the currency type of the provider master. | CASH |
transaction.status | String | Indicates the status of the transaction. | SUCCESS |
transaction.responseCode | String | Refers to the response code from the third-party service. | 200 |
transaction.responseMessage | String | Refers to the response message from the third-party service. | SUCCESS |
transaction.paymentItemId | String | Indicates the unique ID of the payment item. | 1 |
BulkTransactionRequestQueue
PROPERTY | TYPE | DESCRIPTION | EXAMPLE |
transactions[].value | long | Refers to the actual amount, currency, or points of a transaction. | 1000 |
transactions[].type | String | Refers to the type of a transaction. The possible values are PREAUTH, AUTH, CANCELAUTH, CHARGE, REFUND and CREDIT. | REFUND |
transactions[].properties[].name | String | Specifies the custom property name of the property. | It is a charge transaction |
transactions[].properties[].value | String | Specifies the custom property value of the name. | 1000 |
transactions[].paymentItemId | String | Indicates the ID of the payment item. | p1 |
transactions[].id | String | Indicates the ID of the transaction. | p1 |
transactions[].status | String | Indicates the status of the transaction. | CHARGE |
transactions[].responseCode | String | Refers to the response code from the third-party service. | 200 |
transactions[].responseMessage | String | Refers to the response message from the third-party service. | Success |
transactions[].createdBy | String | Indicates the user, who has created the transaction. | p1 |
transactions[].createdTime | long | Indicates the timestamp (in milliseconds), when the transaction is created. | 1548328965 |
allOrNone | boolean | Indicates whether all the transactions have to be processed or not. | true |
Revision History
2019-05-20 | Mary – Updated to a new table tool.
2019-05-07 | PLK – Minor copyedit.
2019-04-11 | MA – Content updated for April 2019 release.
2019-01-23 | PLK – Content uploaded.