Plastic Card's module API

Last updated: June 1st, 2020

Service Methods

The GPS PAY API services provide only such types of transactions to be implemented for 3rd Party Companies (Merchants) on their Side (Web Site or APP’s) for their customer to running transaction out of BGIpay Web Site System. 3rd Party Companies (Merchants) must Supply the IP addresses from where will send the API Request.
Service URL:
Development:
https://test.bgpay.me/APIMerchantServices/”servicemethodrequest”
Live:
https://gpspay.io/APIMerchantServices/”servicemethodrequest”

ALL THE CODE EXAMPLES WHERE DOING ON DEVELOPMENT ENVIROMENT!

Useful Tip:

You can use this online HTML entity encoder/decoder to generate your code examples.

Plastic_Card/Balance
This Method is used to request plastic Plastic Card balance.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/plastic_card/balance?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&
ReqCardNumber=4601380366668888 HTTP/1.1
Host: test.bgpay.me                                                                      
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location --request GET 'https://test.bgpay.me/APIMerchantServices/plastic_card/balance?
ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqCardNumber=4601380366668888' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0,
    "Balance": "$23.02"
}
                                                                                    
                                    
Plastic_Card/Cards
This Method is used to GET registered Customer's Plastic Cards.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/plastic_card/cards?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqCHolderID=155 HTTP/1.1
Host: test.bgpay.me                                                                      
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location --request GET 'https://test.bgpay.me/APIMerchantServices/plastic_card/cards?
ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqCHolderID=155' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "Cards": [
        {
            "CardNo": "4601380360045132",
            "HolderName": "PEDRO PEREZ"
        },
        {
            "CardNo": "4601380360045100",
            "HolderName": "JUAN SANCHEZ"
        },
        {
            "CardNo": "4601380360045122",
            "HolderName": "Mauricio Perez"
        }
    ]
}
                                                                                    
                                    
Plastic_Card/Trans
This Method is used to request Plastic Card transactions.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/plastic_card/trans?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&
ReqCardNumber=4601380366668888&ReqStartDate=01/01/2023&ReqEndDate=06/30/2023 HTTP/1.1
Host: test.bgpay.me
                 
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location --request GET 'https://test.bgpay.me/APIMerchantServices/plastic_card/trans?
ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqCardNumber=4601380366668888&ReqStartDate=01/01/2023&ReqEndDate=06/30/2023' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0,
    "Transacciones": [
        {
            "ID": 1,
            "Reference": "49727302",
            "Description": "LOCATEL CARICUAO (FARMACICARACAS      VE",
            "Inserted": "06/01/2023",
            "Debit": "4.01",
            "Credit": "0"
        },
        {
            "ID": 2,
            "Reference": "68336330",
            "Description": "PAYU PAGOSONLINE         11001BOGOTA  CO",
            "Inserted": "05/12/2023",
            "Debit": "59.89",
            "Credit": "0"
        },
        {
            "ID": 3,
            "Reference": "39237",
            "Description": "teller_payment_cardCREDITO A       GT",
            "Inserted": "04/12/2023",
            "Debit": "0",
            "Credit": "60.00"
        },
    ]
}
                                                                                    
                                    
Plastic_Card/Purchase
This Method is used to get paid with GPS PAY Plastic Card on Merchants.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/plastic_card/purchase?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&
ReqMMerchantID=184&ReqCardNumber=4601380366668888&ReqAmount=10 HTTP/1.1
Host: test.bgpay.me
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location --request GET 'https://test.bgpay.me/APIMerchantServices/plastic_card/purchase?
ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqMMerchantID=184&ReqCardNumber=4601380366668888&ReqAmount=10' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0,
    "Balance": "$25.00",
    "AuthNo": "012365"
}
                                                                                    
                                    
Plastic_Card/fund
This Method is used to load money from Customer's GPS PAY Account to his/her Plastic Card.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/plastic_card/fund?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqCardNumberTo=49158307017611154
&ReqExpDate=1125&ReqAmount=1&ReqCardNumber=6058151555412255&ReqPIN=2574 HTTP/1.1
Host: test.bgpay.me
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location --request GET 'https://test.bgpay.me/APIMerchantServices/plastic_card/fund?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqCardNumberTo=49158307017611154
&ReqExpDate=1125&ReqAmount=1&ReqCardNumber=6058151555412255&ReqPIN=2574' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0,
    "Balance": "$33.55",
    "AuthNo": "146928"
}
                                                                                    
                                    
VisaPlastic_Card/fund
This Method is used to load money to Customer's Visa Plastic Card.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/visaplastic_card/fund/?ReqMerchantID=230&ReqToken=0p3v4eTrZovawOKF&ReqCHolderID=449
&ReqVisaCardNo=4219730020069929&ReqAmount=100 HTTP/1.1
Host: test.bgpay.me
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location 'https://test.bgpay.me/APIMerchantServices/visaplastic_card/fund/?ReqMerchantID=230&ReqToken=0p3v4eTrZovawOKF
&ReqCHolderID=449&ReqVisaCardNo=4219730020069929&ReqAmount=100' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0,
    "Amount": 100,
    "Fee": 0,
    "Total": 100,
    "AuthNo": 005027
}
                                                                                    
                                    
Plastic_Card/Activate
This Method is used to Activate a new Plastic Card to a Customer.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/plastic_card/activate?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx&ReqCHolderID=155&
ReqCardNumber=4601380360074133&ReqExpDate=1125 HTTP/1.1
Host: test.bgpay.me
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location --request GET 'https://test.bgpay.me/APIMerchantServices/plastic_card/activate?ReqMerchantID=154&
ReqToken=i0mQHBMqDxa0UNgx&ReqCHolderID=155&ReqCardNumber=4601380360074133&ReqExpDate=1125' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0
}
                                                                                    
                                    
VisaPlastic_Card/Activate
This Method is used to Activate a new VISA Plastic Card to a Customer.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/visaplastic_card/activate/?ReqMerchantID=230&ReqToken=0p3v4eTrZovawOKF&ReqCHolderID=449&ReqVisaCardNo=4219730020069929 HTTP/1.1
Host: test.bgpay.me
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location 'https://test.bgpay.me/APIMerchantServices/visaplastic_card/activate/?ReqMerchantID=230&ReqToken=0p3v4eTrZovawOKF
&ReqCHolderID=449&ReqVisaCardNo=4219730020069929' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0,
    "AuthNo": 005026
}
                                                                                    
                                    
Plastic_Card/MerBalance
This Method is used to get the Plastic Card Wallet Balance.
<!HTTP CODE EXAMPLE REQUEST>
GET /APIMerchantServices/plastic_card/MerBalance?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx HTTP/1.1
Host: test.bgpay.me                                                                                                                                     
                                                                                        
                                        
<!cURL CODE EXAMPLE REQUEST>
curl --location --request GET 'https://test.bgpay.me/APIMerchantServices/plastic_card/MerBalance?ReqMerchantID=154&ReqToken=i0mQHBMqDxa0UNgx' \

                                    
<!JSON CODE EXAMPLE RESPONSE>
{
    "ErrorCode": 0,
    "Balance":"$100.91"
}
                                                                                    
                                    

Tables

The information about the Parameters in the Methods Request are showing in the Tables below.

SWIFT OUTPUT PARAMETERS
# Field Name DataType Size Description
1 Description A/N 30 Description of transaction, ties back to the requestcode
2 Reference A/N 40 Retrieval reference number associated to transaction
3 Amt money 8 amount of transaction; This is a signed field (i.e. negative values have a negative sign) If value return = 0, transaction has no impact to purse
4 Inserted datetime 8 date/time it was inserted to FIS data base
2 Merchant A/N 300 For non-POS transactions, will reflect the source description used for the transaction (ex: Manual Batch Loader, Direct Access Settlement, A2A User Source Description, etc.)
3 AuthCode A/N 6 Autorization code for POS purchase...0 is a decline or not authorized transaction
Request Parameters
# Parameter Name Type Description
1 ReqMerchantID Numeric The “MerchantID” is the primary account identifier
2 ReqToken String The token that is provided by BestGlobalPayments to the merchant for merchant identification.
3 CFirstName String Customer’s First name
4 CLastName String Customer’s Last name
5 PhoneNumber String Customer's cellular phone number (Numbers only)
6 CProvinceID String Customer’s Province or State Address
7 CCountryID String The Id of the country (USA, GTM, VEN, etc)
8 CCityID String Customer’s City Address.
9 CAddress String Customer’s Postal Address.
10 CSIN String The ID number as it appears on the customer identification (ONLY 9 DIGITS)
11 ReqCHolderID String The Account/card Holder ID Number
12 ReqPassword String Customer’s PIN Password
13 ZipCode String Customer’s ZIP Postal Code Address
14 ReqAmount String Amount to load account/card
15 CardTypeID String VVC (Plastic Card) or VMC (MasterCard
16 ReqStrTotal String Amount to transfer to other Account/Card
17 ReqEndDate String A string representing the end date to pull the card’s transactions in the following format MM/DD/YYYY. The system will return all transactions that happen within the previous 31 days from this end date.
18 ReqCardNumber String The Plastic Debit Card Number(only 16 digits)
18 ReqCardNumberTo String The Plastic Debit Card Number(only 16 digits) to transfer funds