MACH
MACH is a QR code based payment method used in Chile. Provided by a digital bank that was established as a subsidiary of Banco Bci, MACH is a prepaid, free digital account. It functions as a digital wallet by enabling customers to pay for physical or digital transactions using their smartphones. Customers can finish the payment within the MACH app by scanning a QR Code after choosing this payment option on the checkout page.
The Paysafe Payments API supports MACH via SafetyPay as a payment instrument for iGaming and Crypto Merchants in Chile.
Features
MACH:
- Allows you to accept payments from unbanked customers.
- Provides instant payment confirmation.
- Has no chargebacks risks.
- Has over 3 million users in Chile.
Setup Requirements
To create accounts in both the sandbox and production environments:
- Send your details to it_integrations@safetypay.com
You will receive access to a Portal where you will be able to access the following keys:- Merchant Secret Key
- Merchant Signature Key
- Share these details with us to create your API Key. You will use this API key in your API calls.
Your account manager will help to guide you through this process.
Certification Requirements
You are required to go through a certification process to support Safetypay Express as a payment method.
The Paysafe integration team will share the certification requirements with you.
Transaction Types
Paysafe supports the following transaction type:
- Payments - used to transfer money from a customer's bank account to your merchant account. After successful payment, you credit the customer's wallet.
Minimum amount: No minimum amount
Maximum amount: CLP 500,000
Processing currency: CLP
Settlement currency: USD
NOTE: CLP has no minor currency unit. However, when you send an API request, you must send the amount with a 2 decimal shift - this is to maintain consistency across all payments methods, as a 2 decimal shift is standard in the Paysafe Payments API. When you want to process the amount of 123 in CLP for example, you must send the amount as 12300 in your API request.
Typical Scenarios
To process a payment request using MACH as the payment type:
-
Create a Payment Handle with the following parameter settings:
transactionType: PAYMENT
paymentType: MACH -
Redirect the customer to the SafetyPay redirect URL so that they can generate a payment code.
The status of the Payment Handle will change to PAYABLE - you will be notified of this status change via your configured webhooks. -
Use the paymentHandleToken returned in the response to process the Payment request.
The payment will have a status of PROCESSING until the customer has made the payment.
You will receive a Payment Completed notification via webhooks when the customer successfully completes the payment.
If you don't receive webhooks, you can use a GET call to query the transaction status. However, we recommend that you avoid constant polling of the API.
See Webhooks and GET calls for more information.
Return links
- After the customer has been redirected to SafetyPay Express, you will receive a Payment Handle Payable webhook. When you make a /payments call, you will get a payment status of either Processing, Completed or Failed.
- After the customer completes the transaction at Safetypay Express, the customer will be redirected to your return link. You can check the status of the /payments response and redirect the customer to your relevant page depending on the payment status:
Payment status | Description |
---|---|
PROCESSING | The transaction is not complete and is in progress. It does not mean that the transaction has failed. You will get a COMPLETED or FAILED webhook for this transaction at a later stage when you will be able to update the transaction status at your end. |
COMPLETED | The customer has successfully completed the transaction at the SafetyPay end. |
FAILED | The payment has expired at the SafetyPay end. |
APIs to use
Code Examples
{
"amount": 500,
"currencyCode": "CLP",
"dupCheck": true,
"liveMode": true,
"merchantRefNum": "32e74478-37a3-46ac-ba2f-019b8c057432",
"transactionType": "PAYMENT",
"paymentExpiryMinutes":15,
"accountId": "1002495250",
"paymentType": "MACH",
"profile": {
"email": "CLMACH0212_01@gmail.com"
},
"returnLinks": [
{
"rel": "default",
"href": "http://www.amazon.ca"
}
]
}
{
"id": "8fc01ce1-469e-423d-b232-d915fd0c0158",
"paymentType": "MACH",
"paymentHandleToken": "PHivZQUor3tAMihh",
"merchantRefNum": "7f9ecf57-f82a-47cd-89cd-d67369b53b9b",
"currencyCode": "CLP",
"txnTime": "2023-03-14T05:18:09Z",
"customerIp": "213.208.158.220",
"status": "INITIATED",
"links": [
{
"rel": "redirect_payment",
"href": "https://api.test.paysafe.com/alternatepayments/v1/redirect?accountId=1002495250&paymentHandleId=8fc01ce1-469e-423d-b232-d915fd0c0158&token=eyJhbGciOiJIUzI1NiJ9.eyJhY2QiOiIxMDAyNDk1MjUwIiwicHlkIjoiOGZjMDFjZTEtNDY5ZS00MjNkLWIyMzItZDkxNWZkMGMwMTU4IiwiZXhwIjoxNjc4NzcyODkxfQ.ojD3jqncSz372DTaaA9tCow6LQmY3bTese0To5_vf5M"
}
],
"liveMode": false,
"simulator": "EXTERNAL",
"usage": "SINGLE_USE",
"action": "REDIRECT",
"executionMode": "SYNCHRONOUS",
"amount": 500,
"timeToLiveSeconds": 898,
"gatewayResponse": {
"operationId": "0123073466297397",
"id": "b0c70d4c-3f90-4fd9-be0e-393fcac48528",
"processor": "SAFETYPAY"
},
"returnLinks": [
{
"rel": "default",
"href": "http://www.amazon.ca"
}
],
"transactionType": "PAYMENT",
"gatewayReconciliationId": "b0c70d4c-3f90-4fd9-be0e-393fcac48528",
"updatedTime": "2023-03-14T05:18:11Z",
"statusTime": "2023-03-14T05:18:11Z",
"paymentExpiryMinutes":15,
"profile": {
"email": "CLMACH0212_01@gmail.com"
}
}
Payment request
MACH payment request using the paymentHandleToken received in the Payment Handle response:
{
"merchantRefNum": "32a2cb08-9167-403c-a5e3-e850cb97a462",
"amount": 500,
"currencyCode": "CLP",
"dupCheck": true,
"settleWithAuth": true,
"paymentHandleToken": "PHivZQUor3tAMihh"
}
{
"id": "bed02d59-6723-44fe-9149-9b0cb98245fd",
"paymentType": "MACH",
"paymentHandleToken": "PHivZQUor3tAMihh",
"merchantRefNum": "01440e1d-325f-4f84-a539-85b3e918e78e",
"currencyCode": "CLP",
"settleWithAuth": true,
"dupCheck": true,
"txnTime": "2023-03-14T05:18:09Z",
"customerIp": "213.208.158.220",
"status": "PROCESSING",
"gatewayReconciliationId": "b0c70d4c-3f90-4fd9-be0e-393fcac48528",
"amount": 500,
"availableToRefund": 0,
"consumerIp": "213.208.158.220",
"liveMode": false,
"simulator": "EXTERNAL",
"updatedTime": "2023-03-14T05:19:30Z",
"statusTime": "2023-03-14T05:19:30Z",
"gatewayResponse": {
"operationId": "0123073466297397",
"id": "b0c70d4c-3f90-4fd9-be0e-393fcac48528",
"processor": "SAFETYPAY",
"status": "101"
},
"availableToSettle": 0,
"profile": {
"email": "CLMACH0212_01@gmail.com"
},
"settlements": {
"amount": 500,
"txnTime": "2023-03-14T05:18:09.000+0000",
"availableToRefund": 0,
"merchantRefNum": "01440e1d-325f-4f84-a539-85b3e918e78e",
"id": "bed02d59-6723-44fe-9149-9b0cb98245fd",
"status": "PROCESSING"
}
}
Testing Instructions
Country | currencyCode | countryCode | Instructions |
---|---|---|---|
Chile | CLP | CL |
--------------
|