@mojaloop/dfsp-transfer
v0.20.26
Published
DFSP Transfer service
Downloads
20
Keywords
Readme
Transfer service API
This service contains information about transfers, invoices and invoice notifications. It is used to hold the following data:
- Invoices when they are created by merchants;
- Invoice notifications when they are sent from merchant's DFSP to the client's DFSP;
- Invoice types;
- Invoice statuses;
- Invoice payments;
Invoice types can be one of the following:
- Standard - Standard invoices;
- Pending - Not assigned one-time invoice;
- Product - Not assigned multy-payer invoice;
- CashOut - Cash out invoices;
Invoice statuses are as follow:
- executed - Invoice has been executed by customer;
- approved - Invoice has been approved by customer;
- pending - Invoice is pending;
- rejected - Invoice has been rejected by customer;
- cancelled - Invoice has been cancelled by merchant;
Transfer service has exposed the following private API calls in two spaces - [bulk] and [transfer]:
Add batch
URL
/rpc/bulk/batch/addMethod
POSTData Params
Required
name [string] - Batch nameactorId [string] - Actor idfileName [string] - File nameoriginalFileName [string] - Original file name
Success Response
- Code: 200
Content
batchId [number] - Batch idname [string] - Batch namebatchStatusId [number] - Batch status idactorId [string] - Actor id
- Code: 200
Content
Edit batch
URL
/rpc/bulk/batch/editMethod
POSTData Params
Required
actorId [string] - Actor idbatchId [number] - Batch Id
Optional
account [string] - AccountstartDate [date] - Batch start dateexpirationDate [date] - Batch expiration datename [string] - Batch namebatchStatusId [number] - Batch status idbatchInfo [string] - Batch infouploadInfo [string] - Upload infofileName [string] - Batch file nameoriginalFileName [string] - Batch original file namevalidatedAt [date] - Batch validation date
Success Response
- Code: 200
Content
batchId [number] - Batch Idaccount [string] - AccountstartDate [date] - Batch start dateexpirationDate [date] - Batch expiration datename [string] - Batch namebatchStatusId [number] - Batch status idbatchInfo [string] - Batch infouploadInfo [string] - Upload infoactorId [string] - Actor idfileName [string] - Batch file nameoriginalFileName [string] - Batch original file namevalidatedAt [date] - Batch validation date
- Code: 200
Content
Fetch batch
URL
/rpc/bulk/batch/fetchMethod
POSTData Params
Optional
actorId [string] - Actor idname [string] - Batch namebatchStatusId [number] - Batch status idfromDate [date] - From datetoDate [date] - To date
Note: 'fromDate' and 'toDate' are related to the creation date of the batch. They are not related to the 'startDate' and 'expirationDate' of the batch.
Success Response
- Code: 200
Content
batchId [number] - Batch Idaccount [string] - AccountstartDate [date] - Batch start dateexpirationDate [date] - Batch expiration datename [string] - Batch namebatchStatusId [number] - Batch status idbatchInfo [string] - Batch infouploadInfo [string] - Upload infoactorId [string] - Actor idfileName [string] - Batch file nameoriginalFileName [string] - Batch original file namevalidatedAt [date] - Batch validation date
- Code: 200
Content
Get batch
URL
/rpc/bulk/batch/getMethod
POSTData Params
Required
batchId [number] - Batch id
Success Response
- Code: 200
Content
batchId [number] - Batch Idname [string] - Batch nameaccount [string] - AccountstartDate [date] - Batch start dateexpirationDate [date] - Batch expiration datebatchStatusId [number] - Batch status idactorId [string] - Actor idinfo [string] - Batch infofileName [string] - Batch file nameoriginalFileName [string] - Batch original file namecreatedAt [date] - Batch create datestatus [string] - Batch statusupdateAd [date] - Batch update datepaymentsCount [number] - Batch payments count
- Code: 200
Content
Process batch
URL
/rpc/bulk/batch/processMethod
POSTData Params
Required
batchId [number] - Batch idactorId [string] - Actor idstartDate [date] - Batch start dateexpirationDate [date] - Batch expiration dateaccount [string] - Account
Success Response
- Code: 200
Content
queued [number] - Count of the payments added in the queue
- Code: 200
Content
Batch ready
URL
/rpc/bulk/batch/readyMethod
POSTData Params
Required
batchId [number] - Batch idactorId [string] - Actor id
Success Response
- Code: 200
Content
batchId [number] - Batch Idaccount [string] - AccountstartDate [date] - Batch start dateexpirationDate [date] - Batch expiration datename [string] - Batch namebatchStatusId [number] - Batch status idbatchInfo [string] - Batch infouploadInfo [string] - Upload infoactorId [string] - Actor idfileName [string] - Batch file nameoriginalFileName [string] - Batch original file namevalidatedAt [date] - Batch validation date
- Code: 200
Content
Batch revert status
URL
/rpc/bulk/batch/revertStatusMethod
POSTData Params
Required
batchId [number] - Batch idactorId [string] - Actor idpartial [boolean] - Is it one payment checked or whole batch
Success Response
- Code: 200
Content
batchId [number] - Batch Idaccount [string] - AccountstartDate [date] - Batch start dateexpirationDate [date] - Batch expiration datename [string] - Batch namebatchStatusId [number] - Batch status idbatchInfo [string] - Batch infouploadInfo [string] - Upload infoactorId [string] - Actor idfileName [string] - Batch file nameoriginalFileName [string] - Batch original file namevalidatedAt [date] - Batch validation date
- Code: 200
Content
Fetch batch status
URL
/rpc/bulk/batchStatus/fetchMethod
POSTData Params
Required NONE
Success Response
- Code: 200
Content
key [number] - Status keyname [string] - Status namedescription [string] - Status description
- Code: 200
Content
Add payments
URL
/rpc/bulk/payment/addMethod
POSTData Params
Required
actorId [string] - Actor idpayments [json] - json containing list with paymentsbatchId [number] - Batch id
Note
payments should have the following fields icluded:
sequenceNumber [number] - Sequence numberidentifier [string] - User's identifierfirstName [string] - User's first namelastName [string] - User's last namedob [date] - Date of birthnationalId [string] - National Idamount [number] - Amount
Success Response
- Code: 200
Content
insertedRows [number] - Count of inserted payments
- Code: 200
Content
Edit payments
URL
/rpc/bulk/payment/addMethod
POSTData Params
Required
actorId [string] - Actor idpayments [json] - json containing list with payments
Note
payments should have the following fields icluded:
paymentId [number] - Payment idbatchId [number] - Batch idsequenceNumber [number] - Sequence numberidentifier [string] - User's identifierfirstName [string] - User's first namelastName [string] - User's last namedob [date] - Date of birthnationalId [string] - National Idamount [number] - Amountinfo [string] - Payment infopayee [json] - Payee info
Success Response
- Code: 200
Content
payments [json] - json with the edited payments
- Code: 200
Content
Fetch payments
URL
/rpc/bulk/payment/fetchMethod
POSTData Params
Optional
paymentId [number array] - Array with payment idsbatchId [number] - Batch idnationalId [string] - Batch idpaymentStatusId [number array] - Array with payment status idsfromDate [date] - From datetoDate [date] - To datesequenceNumber [number] - Sequence numbername [string] - Batch namepageSize [number] - Page sizepageNumber [number] - Page number
Success Response
- Code: 200
Content
data [json] - Result set from the searchpagination [json] - json with the following fields included'pageNumber'- Requested page number'pageSize'- Returned payments from the result set for this page'pagesTotal'- Returned count of pages from the result set'recordsTotal'- Total count of payments matched from search
- Code: 200
Content
Get payment
URL
/rpc/bulk/payment/getMethod
POSTData Params
Required
paymentId [number] - Array with payment ids
Success Response
- Code: 200
Content
paymentId [number] - Payment idbatchId [number] - Batch idsequenceNumber [number] - Sequence numberidentifier [string] - User's identifierfirstName [string] - User's first namelastName [string] - User's last namedob [date] - User's date of birthnationalId [string] - User's national idamount [number] - Transfer amountpaymentStatusId [number] - Payment status idinfo [string] - Payment infopayee [json] - Payee dataname [string] - Batch namecreatedAt [date] - Payment's created at dateupdatedAt [date] - Payment's updated at dateaccount [string] - Batch accountstartDate [date] - Batch's start dateexpirationDate [date] - Batch's expiration dateactorId [string] - Actor id
- Code: 200
Content
Get payments for processing
URL
/rpc/bulk/payment/getForProcessingMethod
POSTData Params
Required
count [number] - Number of payments to be returned. Default is set to 100
Success Response
- Code: 200
Content
paymentId [number] - Payment idbatchId [number] - Batch idsequenceNumber [number] - Sequence numberidentifier [string] - User's identifierfirstName [string] - User's first namelastName [string] - User's last namedob [date] - User's date of birthnationalId [string] - User's national idamount [number] - Transfer amountpaymentStatusId [number] - Payment status idinfo [string] - Payment infocreatedAt [date] - Payment's created at dateupdatedAt [date] - Payment's updated at date
- Code: 200
Content
Pre-process payment
URL
/rpc/bulk/payment/preProcessMethod
POSTData Params
Required
paymentId [number] - Payment id
Success Response
- Code: 200
Content
paymentId [number] - Payment idbatchId [number] - Batch idsequenceNumber [number] - Sequence numberidentifier [string] - User's identifierfirstName [string] - User's first namelastName [string] - User's last namedob [date] - User's date of birthnationalId [string] - User's national idamount [number] - Transfer amountpaymentStatusId [number] - Payment status idinfo [string] - Payment infopayee [json] - Payee dataname [string] - Batch namecreatedAt [date] - Payment's created at dateupdatedAt [date] - Payment's updated at dateaccount [string] - Batch accountstartDate [date] - Batch's start dateexpirationDate [date] - Batch's expiration dateactorId [string] - Actor id
- Code: 200
Content
Process payment
URL
/rpc/bulk/payment/processMethod
POSTData Params
Required
paymentId [number] - Payment idactorId [string] - Actor iderror [string] - Error message
Success Response
- Code: 200
Content
paymentId [number] - Payment idbatchId [number] - Batch idsequenceNumber [number] - Sequence numberidentifier [string] - User's identifierfirstName [string] - User's first namelastName [string] - User's last namedob [date] - User's date of birthnationalId [string] - User's national idamount [number] - Transfer amountpaymentStatusId [number] - Payment status idinfo [string] - Payment infopayee [json] - Payee dataname [string] - Batch namecreatedAt [date] - Payment's created at dateupdatedAt [date] - Payment's updated at dateaccount [string] - Batch accountstartDate [date] - Batch's start dateexpirationDate [date] - Batch's expiration dateactorId [string] - Actor id
- Code: 200
Content
Fetch payment statuses
URL
/rpc/bulk/paymentStatus/fetchMethod
POSTData Params
Required
NONE
Success Response
- Code: 200
Content
key [number] - Payment status keyname [string] - Payment status namedescription [string] - Payment status description
- Code: 200
Content
Add invoice notification
URL
/rpc/transfer/invoiceNotification/addMethod
POSTData Params
Required
invoiceUrl [string] - Invoice URLidentifier [string] - Identifiermemo [string] - Invoice memo
Success Response
- Code: 200
Content
invoiceNotificationId [number] - Invoice notification idinvoiceUrl [string] - Invoice URLidentifier [string] - Identifierstatus [string] - Invoice statusmemo [string] - Invoice memo
- Code: 200
Content
Cancel invoice notification
URL
/rpc/transfer/invoiceNotification/cancelMethod
POSTData Params
Required
invoiceUrl [string] - Invoice URL
Success Response
- Code: 200
Content
invoiceNotificationId [number] - Invoice notification idinvoiceUrl [string] - Invoice URLidentifier [string] - Identifierstatus [string] - Invoice statusmemo [string] - Invoice memo
- Code: 200
Content
Edit invoice notification
URL
/rpc/transfer/invoiceNotification/editMethod
POSTData Params
Required
invoiceNotificationId [number] - Invoice notification idinvoiceNotificationStatusId [number] - Invoice notification status id
Success Response
- Code: 200
Content
invoiceNotificationId [number] - Invoice notification idinvoiceUrl [string] - Invoice URLidentifier [string] - Identifierstatus [string] - Invoice statusmemo [string] - Invoice memo
- Code: 200
Content
Execute invoice notification
URL
/rpc/transfer/invoiceNotification/executeMethod
POSTData Params
Required
invoiceNotificationId [number] - Invoice notification id
Success Response
- Code: 200
Content
invoiceNotificationId [number] - Invoice notification idinvoiceUrl [string] - Invoice URLidentifier [string] - Identifierstatus [string] - Invoice statusmemo [string] - Invoice memo
- Code: 200
Content
Fetch invoice notification
URL
/rpc/transfer/invoiceNotification/fetchMethod
POSTData Params
Required
identifier [string] - Identifierstatus [string] - Invoice notification id
Success Response
- Code: 200
Content
invoiceNotificationId [number] - Invoice notification idinvoiceUrl [string] - Invoice URLidentifier [string] - Identifierstatus [string] - Invoice statusmemo [string] - Invoice memo
- Code: 200
Content
Get invoice notification
URL
/rpc/transfer/invoiceNotification/getMethod
POSTData Params
Required
invoiceNotificationId [number] - Invoice notification id
Success Response
- Code: 200
Content
invoiceNotificationId [number] - Invoice notification idinvoiceUrl [string] - Invoice URLidentifier [string] - Identifierstatus [string] - Invoice statusmemo [string] - Invoice memo
- Code: 200
Content
Reject invoice notification
URL
/rpc/transfer/invoiceNotification/rejectMethod
POSTData Params
Required
invoiceNotificationId [number] - Invoice notification id
Success Response
- Code: 200
Content
invoiceNotificationId [number] - Invoice notification idinvoiceUrl [string] - Invoice URLidentifier [string] - Identifierstatus [string] - Invoice statusmemo [string] - Invoice memo
- Code: 200
Content
Invoice add
URL
/rpc/transfer/invoice/addMethod
POSTData Params
Required
account [string] - Accountname [string] - NamecurrencyCode [string] - Currency codeamount [number] - AmountmerchantIdentifier [string] - Merchant identifieridentifier [string] - Client identifierinvoiceType [string] - Invoice typeinvoiceInfo [string] - Invoice info
Success Response
- Code: 200
Content
type [string] - Invoice typeinvoiceId [number] - Invoice idaccount [string] - Accountname [string] - NamecurrencyCode [string] - Currency codecurrencySymbol [string] - Currency symbolamount [number] - Amountstatus [string] - Invoice statusinvoiceType [string] - Invoice typemerchantIdentifier [string] - Merchant identifierinvoiceInfo [string] - Invoice info
- Code: 200
Content
Invoice cancel
URL
/rpc/transfer/invoice/cancelMethod
POSTData Params
Required
invoiceId [number] - Invoice id
Success Response
- Code: 200
Content
type [string] - Invoice typeinvoiceId [number] - Invoice idaccount [string] - Accountname [string] - NamecurrencyCode [string] - Currency codecurrencySymbol [string] - Currency symbolamount [number] - Amountstatus [string] - Invoice statusinvoiceType [string] - Invoice typemerchantIdentifier [string] - Merchant identifierinvoiceInfo [string] - Invoice info
- Code: 200
Content
Invoice edit
URL
/rpc/transfer/invoice/editMethod
POSTData Params
Required
invoiceId [number] - Invoice idinvoiceStatusId [number] - Invoice status id
Success Response
- Code: 200
Content
type [string] - Invoice typeinvoiceId [number] - Invoice idaccount [string] - Accountname [string] - NamecurrencyCode [string] - Currency codecurrencySymbol [string] - Currency symbolamount [number] - Amountstatus [string] - Invoice statusinvoiceType [string] - Invoice typemerchantIdentifier [string] - Merchant identifierinvoiceInfo [string] - Invoice info
- Code: 200
Content
Invoice execute
URL
/rpc/transfer/invoice/editMethod
POSTData Params
Required
invoiceId [number] - Invoice ididentifier [string] - Identifier
Success Response
- Code: 200
Content
type [string] - Invoice typeinvoiceId [number] - Invoice idaccount [string] - Accountname [string] - NamecurrencyCode [string] - Currency codecurrencySymbol [string] - Currency symbolamount [number] - Amountstatus [string] - Invoice statusinvoiceType [string] - Invoice typemerchantIdentifier [string] - Merchant identifierinvoiceInfo [string] - Invoice info
- Code: 200
Content
Invoice fetch
URL
/rpc/transfer/invoice/fetchMethod
POSTData Params
Optional
merchantIdentifier [string] - Merchant identifieraccount [string] - Accountstatus [string array] - Array with invoice statusesinvoiceType [string array] - Array with invoice types
Success Response
- Code: 200
Content
type [string] - Invoice typeinvoiceId [number] - Invoice idaccount [string] - Accountname [string] - NamecurrencyCode [string] - Currency codecurrencySymbol [string] - Currency symbolamount [number] - Amountstatus [string] - Invoice statusinvoiceType [string] - Invoice typemerchantIdentifier [string] - Merchant identifierinvoiceInfo [string] - Invoice info
- Code: 200
Content
Invoice get
URL
/rpc/transfer/invoice/getMethod
POSTData Params
Optional
invoiceId [number] - Invoice id
Success Response
- Code: 200
Content
type [string] - Invoice typeinvoiceId [number] - Invoice idaccount [string] - Accountname [string] - NamecurrencyCode [string] - Currency codecurrencySymbol [string] - Currency symbolamount [number] - Amountstatus [string] - Invoice statusinvoiceType [string] - Invoice typemerchantIdentifier [string] - Merchant identifierinvoiceInfo [string] - Invoice info
- Code: 200
Content
Invoice reject
URL
/rpc/transfer/invoice/rejectMethod
POSTData Params
Optional
invoiceId [number] - Invoice id
Success Response
- Code: 200
Content
type [string] - Invoice typeinvoiceId [number] - Invoice idaccount [string] - Accountname [string] - NamecurrencyCode [string] - Currency codecurrencySymbol [string] - Currency symbolamount [number] - Amountstatus [string] - Invoice statusinvoiceType [string] - Invoice typemerchantIdentifier [string] - Merchant identifierinvoiceInfo [string] - Invoice info
- Code: 200
Content
Invoice payer add
URL
/rpc/transfer/invoicePayer/addMethod
POSTData Params
Optional
invoiceId [number] - Invoice ididentifier [string] - Identifier
Success Response
- Code: 200
Content
invoicePayerId [number] - Invoice payer idinvoiceId [number] - Invoice ididentifier [string] - IdentifiercreatedAt [date] - Created at date
- Code: 200
Content
Invoice payer fetch
URL
/rpc/transfer/invoicePayer/fetchMethod
POSTData Params
Optional
invoiceId [number] - Invoice idpaid [boolean] - Paid
Success Response
- Code: 200
Content
invoicePayerId [number] - Invoice payer idinvoiceId [number] - Invoice ididentifier [string] - IdentifiercreatedAt [date] - Created at date
- Code: 200
Content
Invoice payer get
URL
/rpc/transfer/invoicePayer/getMethod
POSTData Params
Optional
invoicePayerId [number] - Invoice payer id
Success Response
- Code: 200
Content
invoicePayerId [number] - Invoice payer idinvoiceId [number] - Invoice ididentifier [string] - IdentifiercreatedAt [date] - Created at date
- Code: 200
Content
Transfer push execute
URL
/rpc/transfer/push/executeMethod
POSTData Params
Optional
sourceAccount [string] - Source accountreceiver [string] - ReceiverdestinationAmount [number] - Destination amountcurrency [string] - Currency codefee [number] - Fee amountmemo [string] - Transaction memo
Success Response
- Code: 200
Content
id [string] - Payment idaddress [string] - AddressdestinationAmount [number] - Destination amountsourceAmount [number] - Source amountsourceAccount [string] - Source accountexpiresAt [date] - Expiration datecondition [string] - Conditionfulfillment [string] - Fulfillmentstatus [string] - Status
- Code: 200
Content
