Learn about PayNow, a real time payment network popular in Singapore. #
PayNow is a real-time payment network in Singapore managed by the Association Bank of Singapore (ABS) and overseen by the Monetary Authority of Singapore (MAS). It enables both consumers and businesses to register for the service using various identifiers such as their mobile number, Singapore NRIC/FIN, UEN business registration number, or Virtual Payment Address (VPA for NFI accounts, which includes eWallets). Once registered, users can easily transfer SGD funds from one bank or e-wallet account to another within Singapore through the FAST network. FAST is a regulated and standardized payment rails system that ensures seamless interoperability between different payment providers.
Caractéristiques #
Traitement des devises | SGD |
---|---|
Devises de règlement | USD |
Montant minimum de la transaction | 1 THB |
Montant maximum de la transaction | 5 000 THB |
Remboursements | ✅ |
Remboursements partiels | ✅ |
Remboursement partiel multiple | ✅ |
Répétition de la dette | ❌ |
Flux de paiement #
Méthode d'intégration #
Valeurs de l'énumération des méthodes de paiement : paynow
There are two integration methods for PayNow
- API directe
- Sortie de caisse
Direct API #
Comment s'intégrer #
Pour une intégration API directe, vous pouvez créer un PaymentIntent et obtenir l'url en une seule étape. Voici la démonstration de la création d'une intention de paiement :
Créez un PaymentIntent sur votre serveur et indiquez le montant à collecter ainsi qu'une devise prise en charge.
Notably, For Paynow, you also need to collect the customer’s nom
, pays
et courriel
en payment_method_data.billing_details
.
Si vous disposez déjà d'une intégration Payment Intents, ajoutez bank_transfer_uk
à la liste des types de méthodes de paiement.
Demande Créer un PaymentIntent
{
"amount":1000,
"currency":"SGD",
"payment_method_data" : {
"type":"paynow",
"billing_details":{
"address": {
"country": "SG"
},
"name": "Tom Elis",
"email": "1231536GF41@Gmail.com"
}
},
"description": "product description",
"quantity": 2,
"return_url":"https://your.website"
}
Réponse
{
"id": "pi_1686226704999120896",
"object": "payment_intent",
"created": 1690862750000,
"livemode": true,
"currency": "SGD",
"amount": 1000,
"status": "requires_action",
"description": "product description",
"quantity": 2,
"client_secret": "pi_1686226704999120896_secret_nz79AKtKGcxWr2gUxEsFXrM1",
"next_action": {
"type": "paynow_handle_redirect",
"paynow_handle_redirect": {
"url": "https://pay.tazapay.com/marketplace/paymentdetails/0Pq7kWaNrGrjxYiaqsfchBD3bR0K4obPc7W4EtdSmt6y9BHpRLFBYdPzUWx59sHR"
}
},
"payment_method_types": [
"paynow"
],
"confirmation_method": "automatic",
"return_url": "https://your.website",
"payment_method": "pm_1686226704869097472",
"capture_method": "automatic"
}
Sortie de caisse #
Créer une session #
Demande Créer une session
{
"cancel_url": "www.wooshpay.com",
"mode": "payment",
"success_url": "https://wooshpay.com/",
"payment_method_types":["paynow"],
"line_items": [
{
"price_data": {
"currency": "SGD",
"unit_amount": 10000000,
"nickname": "apple",
"product_data": {
"name": "apple"
},
"billing_scheme": "testscheme",
"lookup_key": "test_lookup_key"
},
"quantity": 1
}
]
}
Réponse
{
"id": "cs_1686257953583136768",
"object": "checkout.session",
"created": 1690870200000,
"livemode": false,
"currency": "SGD",
"customer": "",
"mode": "payment",
"status": "open",
"url": "https://checkouttest.wooshpay.com/pay/cs_test_1686257953583136768?key=cGtfdGVzdF9OVEUyTlRjNU5ESXpNalUxTXpNME56ZzVNVE14T2pNemIxTTJhVVZrTmtOdmFsWlBSRTFuVFc1SVREaFljREUyT0RReE1Ua3lNamd6TVRR",
"cancel_url": "www.wooshpay.com",
"line_items": {
"object": "list",
"data": [
{
"id": "li_1686257953620885504",
"object": "item",
"currency": "SGD",
"description": "apple",
"price": {
"id": "price_1686257953633468416",
"object": "price",
"created": 1690870200000,
"livemode": false,
"active": false,
"currency": "SGD",
"nickname": "apple",
"product": {
"id": "prod_1686257953646051328",
"object": "product",
"created": 1690870200000,
"livemode": false,
"active": false,
"name": "apple",
"updated": 1690870200000
},
"type": "one_time",
"unit_amount": 10000000,
"billing_scheme": "per_unit",
"lookup_key": "test_lookup_key"
},
"quantity": 1,
"amount_subtotal": 10000000,
"amount_total": 10000000
}
]
},
"payment_intent": "pi_1686257953868349440",
"payment_method_types": [
"paynow"
],
"payment_status": "unpaid",
"success_url": "https://wooshpay.com/",
"amount_subtotal": 10000000,
"amount_total": 10000000,
"billing_address_collection": "auto",
"expires_at": 1690956599952,
"payment_link": "",
"client_secret": "pi_1686257953868349440_secret_BKuEOd8kJq0cxvZszocDlfjb"
}
Prochaine étape #
Vous pouvez ajouter d'autres fonctionnalités à votre intégration en fonction de vos besoins.
Créer un Webhook #
Écoutez les événements sur votre compte WooshPay afin que votre intégration puisse déclencher automatiquement des réactions. Créez un webhook qui se concentre principalement sur enabled_events et url.
Créer un remboursement #
Créez un remboursement pour restituer des fonds à votre client. Vous pouvez également effectuer des remboursements partiels, mais ils ne sont pas pris en charge par toutes les méthodes de paiement. Un remboursement partiel consiste à ne rembourser qu'une partie du montant de la transaction initiale.