Browse Source

Inbound Api Document

master
Dinesh 4 months ago
parent
commit
14a53a0165
  1. 910
      InboundApi/InboundAPIIME_London.docx
  2. 11
      Thirdparty/SendMN/Credentail.txt
  3. 1256
      Thirdparty/SendMN/Full_SMN_InboundAPI_Documentation_2.0.0.pdf

910
InboundApi/InboundAPIIME_London.docx

@ -0,0 +1,910 @@
Inbound API
Technical Document for IME London Remittance
Revision History
Version Number
Change Reference and Summary
Author
Revised Date
1.0.0
Created
Dinesh Guragain
2024/03/09
2.0.0
Modified
Contents
Contents
1. Flowchart of inbound process 4
2. Authentication 6
3. Generate Signature 9
4. HTTP Header 11
5. Get Code 12
6. Get Bank 14
7. Exchange Rate 16
8. Create transaction 18
9. Transaction Status 22
Flowchart of inbound process
List of methods declared in web service
No.
API
Method
Description
1
Authentication
authenticate
This method gives an IME London Core System session which is to be used to invoke other
methods. It's a mandatory function.
2
GetCode
getCode
This method is used to get the list of Source of Fund , Purpose of Remittance, Id Type, Relationship, Occupation, Country, and Payment Type.
3
CalculateExRate
calculateExRate
This method is used to request the exchange rate.
5
sendRemittance
SendRemitance
Send new transaction information to IME London
6
getRemittanceStatus
getRemittanceStatus
This method gives the details status of transaction
Authentication
This method gives an IME session which is to be used to invoke other methods. It's a mandatory function.
Method
URL
GET
/api/authenticate
HTTP Request Header
Header
Description
AgentId
Id of Partner
Example
Request Parameter Authorization
Parameter
Type
Description
Mandatory
Username
String
Username of partner
M
Password
String
Password of partner
M
Request Example
Response Example:
{
"responseCode": 100,
"responseMessage": "Success.",
"data": {
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJVc2VyTmFtZSI6Imtld2FscmFqIiwiQWdlbnRJZCI6IjM5NDM5MiIsIlNlc3Npb25JZGVudGlmaWVyIjoiMTAwNDAyNWItY2ZhNy00MjkxLTgwODEtMThiZDJhNWQyMTg5IiwiZXhwIjoxNzExMzU0OTI5LCJpc3MiOiJJTTNVayIsImF1ZCI6IiFNM1VuMXQzREshbkdkMG1VJDNScyJ9.i-NOVrABvTouDRB67m56_Zi2csWMLi0r-slyGqTp3PE",
"tokenType": "Bearer",
"expiresIn": 1800,
"sessionIdentifier": "1004025b-cfa7-4291-8081-18bd2a5d2189"
}
}
Generate Signature
When you create a signature for a request, it's essential to combine the parameters sent by the request and then hash the resulting symbol. To illustrate this process, we've prepared the following example:
Suppose you have a request with the following parameters: Parameter 1: APPId
Parameter 2: SecurityKey
Parameter 3: Nonce
Parameter 4: Timestamp
AppId
Partner Appid
SecurityKey
Partner security key
Nonce
This function creates a random 4-byte array using cryptographic methods and converts it into an 8-character hexadecimal string, ensuring each character represents 4 bits. If the resulting string is shorter than 8 characters, it adds leading zeros. The function then returns this 8-character hexadecimal nonce, suitable for cryptographic purposes.
Example
Timestamp
This function retrieves the current timestamp in seconds since the Unix epoch (January 1, 1970) in Coordinated Universal Time (UTC). It achieves this by calculating the difference between the current time and the Unix epoch, represented as a TimeSpan object. Then, it converts this time difference into total seconds and returns it as a long integer, providing a precise representation of the current time for various applications such as timestamping events or generating unique identifiers
Example
To generate a signature for this request, you would follow these steps:
Combine the parameters into a single string, maintaining the order: listString = APPID: SecurityKey: Nonce: Timestamp
Apply the GenerateHMAC hash function to the combined string, resulting in a unique hash: signature = GetMd5Hash( listString )
HTTP Header
All the HTTP request and response headers shall contain the followings elements:
Parameter
Type
Description
Mandatory
Content-Type
application/json
The Content-Type is defined as [RFC 7213
M
Authorization
String
Generated token from Authentication request
M
Signature
String
Username of partner
M
Example:
Get Code
This method is used to get the list of Source of Fund, Purpose of Remittance, Id Type, Relationship, Occupation, Country, and Payment Type.
URL
Method
URL
POST
/api/v1/Remit/getCode
This method contains following input parameters
Request Parameters:-
Parameter
Type
Description
Mandatory
partnerSessionId
String
partnerSessionId of partner
M
Request Example:
{
"partnerSessionId": "PARTNER-XXX-SESSION-ID1"
}
Response Example:
{
"responseCode": 100,
"responseMessage": "API Called successfully",
"data": {
"sourceOfFund": [
{
"id": "11416",
"text": "Business Income"
}
],
"purposeOfRemittance": [
{
"id": "11411",
"text": "Birthday Gift"
}
],
"idType": [
{
"id": "11168",
"text": "Biometric Residence Permit"
}
],
"country": [
{
"id": "12",
"text": "Australia",
"countryCode": "AU",
"isoApha3": "AUS"
}
],
"paymentType": [
{
"id": "2",
"text": "Bank Deposit",
"code": "BD"
}
],
Get Bank
This method is used to get the list of active bank names.
URL
Method
URL
POST
/api/v1/Remit/getBank
This method contains following input parameters
Request Parameters:-
Parameter
Type
Max
Length
Description
Mandatory
partnerSessionId
String
15
partnerSessionId of partner
M
countryid
String
10
Countryid of payout country
M
Request Example:
{
"partnerSessionId": "PARTNER-XXX-SESSION-ID1",
"countryId": "16"
}
Resonse Example:
{
"responseCode": 100,
"responseMessage": "API Called successfully",
"data": {
"countryId": null,
"bank": [
{
"id": "446",
"text": "AB BANK"
},
{
"id": "436",
"text": "AGRANI BANK"
},
{
"id": "475",
"text": "WOORI BANK"
}
],
Exchange Rate
This method is used to request the exchange rate for particular payout country. The send partner will provide the Sending Country Code, Sending Currency Code, Payout Country Code, Payout Currency Code, and Payout Type Code.
URL
Method
URL
POST
/api/v1/Remit/calculateExRate
This method contains the following input parameters
Request Parameters:-
Parameter
Type
Description
Mandatory
partnersessionId
String
Partner session Id of partner
M
sendingCountryCode
String
Code of sending country
M
sendingCurrencyCode
String
Currency code of sending country
M
payoutCountryCode
String
Code of payout country
M
payoutCurrencyCode
String
Currency code of payout country
M
collectionAmount
String
Amount of sending country
M
payoutAmount
String
Amount of receiving country
M
payoutTypeCode
String
Payout type code (getCode)
M
calcBy
String
C - Calculation by Sending amount and response total Payout amount after Deducting service charge
P - Calculation by Payout Amount and response total collection amount in
Sending Currency including Service Charge
M
Request Example:
{
"partnerSessionId": "PARTNER-XXX-SESSION-ID1",
"sendingCountryCode": "UK",
"sendingCurrencyCode": "GBP",
"payoutCountryCode": "NP",
"payoutCurrencyCode": "NPR",
"collectionAmount": "5000",
"payoutAmount": "0",
"payoutTypeCode": "CP",
"calcBy": "C"
}
Response Example
{
"responseCode": 100,
"responseMessage": "Success",
"data": {
"serviceCharge": "01.00",
"exRate": "165.0800",
"payoutCurrencyCode": "NPR",
"currDecimal": "0",
"collectionAmount": "5,000.00",
"transferAmount": "4,999.00",
"payoutAmount": "825,234.00"
}
}
Create transaction
This method initiates new transaction to the payout agent. It's a mandatory function.
Method
URL
POST
/api/v1/Remit/sendRemittance
Request Parameters
Parameter Group
Parameter
Type
Max
Length
Description
Mandatory
partnersessionId
String
15
Session Id of partner
M
Ss
d
Sender
Details
senderFirstName
String
20
First name of sender
M
senderMiddleName
String
20
Middle name of sender
O
senderLastName
String
20
Last name of sender
M
senderDOB
string
8
Date of Borth of Sender
M
senderIdType
String
15
Id type of sender. From the getCode (IdType) .
M
senderIdNumber
String
20
Id number of the sender
M
senderIdIssueDate
String
8
ID issue date of sender.
M
senderIdValidDate
String
8
ID valid date of sender
M
senderMobile
String
15
Mobile number of sender
M
senderEmail
String
25
Email address of sender
M
senderNativeCountryCode
string
3
Native country cod of sender
M
senderCity
string
15
City of sender
O
senderAddress
String
20
Address of sender
M
Receiver Details
receiverFirstName
String
20
First name of beneficiary
M
receiverMiddleName
String
20
Middle name of beneficiary
O
receiverLastName
String
20
Last name of beneficiary
M
receiverIdType
String
15
Id Type of beneficiary
O
receiverIdNo
String
20
Id Number of beneficiary
O
receiverIdIssue
String
8
Id issue date of beneficiary
O
receiverIdValid
string
8
Id valid of beneficiary
O
receiverMobile
String
15
Mobile number of beneficiaries
O
receiverCity
String
15
City of receiver
receiverAddress
String
20
Receiver's address
M
receiverEmail
String
20
Email address of receiver
O
receiverAccountNo
String
Receiver bank account number. Required when payment method is "Bank Deposit".
O
sendingCountryCode
String
3
Country code of sending country
M
payoutCountryCode
string
3
Country code of receiving country
M
payoutTypeCode
String
2
Payout type code. From the getCode(paymentType) i.e BD
M
payoutBankCode
String
10
Payout bank code. Required when payment method is "Bank Deposit".
O
Remittance
Details
payoutBranchCodce
String
10
Payout branch code. Required when payment method is "Bank Deposit".
O
remittancePurpose
String
2
Purpose of remittance. From the getCode(paymentType)
M
sourceOfFund
string
2
Source of fund. From the getCode(paymentType)
M
Relationship
String
2
Relationship of receiver. From the getCode(paymentType)
M
Occupation
String
2
Occupation. From the getCode(paymentType)
M
calcBy
String
1
C - Calculation by Sending amount and response total Payout amount after Deducting service charge
P - Calculation by Payout Amount and response total collection amount in
Sending Currency including Service Charge
M
payoutCurrencyCode
string
3
Currency code of receiving country
M
sendingCurrencyCode
String
3
Currency code of sending country
M
collectionAmount
String
10
Sending Amount
M
transferAmount
String
10
Receiving amount
M
partnerTransactionId
String
10
Transaction Id of partner
M
Request example:
{
"partnerSessionId": "SADASD234432SDDSA",
"remitSenderDetails": {
"senderFirstName": "John",
"senderMiddleName": "",
"senderLastName": "Doe",
"senderDOB": "2000-10-01",
"senderIdType": "10997",
"senderIdNo": "1414",
"senderIdIssuedDate": "2022-01-01",
"senderIdValidDate": "2030-01-01",
"senderMobile": "082122892292",
"senderNativeCountryCode": "NP",
"senderCity": "London",
"senderAddress": "London, UK",
"senderEmail": "John2000@gmail.COM",
"senderGender": "M"
},
"remitReceiverDetails": {
"receiverFirstName": "John",
"receiverMiddleName": "",
"receiverLastName": "Doe",
"receiverIdType": "10997",
"receiverIdNo": "19281982",
"receiverIdIssued": "",
"receiverIdValid": "",
"receiverMobile": "9861572883",
"receiverCity": "KATHMANDU",
"receiverAddress": "KOTESHWOR-32, KATHMANDU, NEPAL",
"receiverAccountNo": "526598989",
"receiverEmail": "john2000@gmail.COM"
},
"remittanceDetails": {
"sendingCountryCode": "GB",
"payoutCountryCode": "NP",
"payoutTypeCode": "CP",
"payoutBankCode": "",
"payoutBankBranchCode": "",
"payoutCurrencyCode": "NPR",
"sendingCurrencyCode": "GBP",
"collectionAmount": "10",
"transferAmount": "1675.50",
"payoutAmount": "438580.00",
"serviceCharge": "3",
"exchangeRate": "167.55",
"remittancePurpose": "1290",
"sourceOfFund": "1120",
"relationship": "1239",
"occupation": "19182",
"calcBy": "C"
},
"partnerTransactionId": "22222222211"
}
Response example:
{ "responseCode": 100,
"responseMessage": "Transaction is successful!",
"data": {
"imeControlNo": "779112042164",
"partnerTransactionId": "22222222211",
"status": "Hold",
"collectionAmount": "10",
"transferAmount": "1675.50",
"payoutAmount": "438580.00",
"exRate": "167.55"
}
}
Transaction Status
This method is used to get the (current) status of the transaction. The send partner will provide the Transaction no or imeControlNo with login credentials.
Method
URL
POST
/api/v1/Remit/getRemittanceStatus
Parameter
Type
Description
Mandatory
partnerSessionId
String
partnerSessionId of partner
M
partnerTransactionId
String
Transaction id of transaction
M
imeControlNo
String
Control Number of transaction
M
Request example:
{
"partnerSessionId": "PARTNER-XXX-SESSION-ID1",
"imeControlNo": "779206107142",
"partnerTransactionId": ""
}
Response example:
{
"responseCode": 100,
"responseMessage": "Success",
"data": {
"imeControlNo": "779206107142",
"status": "Hold",
"message": "Transaction is waiting for approval!"
}
}
List ResponseCode
Response Code
Status
100
Success
101
Failed

11
Thirdparty/SendMN/Credentail.txt

@ -0,0 +1,11 @@
Also the UAT credentials
URL: http://dev-server-sendmn.eastus.cloudapp.azure.com/api
Username: IME Agent
Agentcode: MGO394732
API key: n2PmKhD1V5IwRdDT5pMeOS/x+W4PH3L4nRxvnCoyVhE=

1256
Thirdparty/SendMN/Full_SMN_InboundAPI_Documentation_2.0.0.pdf
File diff suppressed because it is too large
View File

Loading…
Cancel
Save