WooshPay OpenAPI
Product DocumentAPI ReferenceJS SDK ReferenceSaaS Platform Integration
Product DocumentAPI ReferenceJS SDK ReferenceSaaS Platform Integration
Back to WooshPay Website
  1. Bank redirects
  • Online payments
    • Quick Start
    • Integration overview
    • Wooshpay JS SDK
    • Wooshpay Checkout
    • Wooshpay Direct API
    • Payment Link
    • Authorize and capture
    • Build subscriptions integration
    • Testing cards
  • After the payment
    • Payouts
    • Webhook
    • Check the webhook signatures
    • 校验webhook签名
  • Add more payment methods
    • Supported payment method
    • Cards
    • Wallets
      • Alipay
      • Alipay HK
      • Apple Pay
      • Google Pay
      • Wechat Pay
      • 微信支付
      • Kakao Pay
      • DANA
      • Boost
      • Grabpay
      • Mcash
      • Touch'n Go
      • ShopeePay
      • UnionPay
      • 9Pay
      • OVO
      • GCash
      • TrueMoney
    • Bank redirects
      • Bancontact
      • BPI
      • Trustly
      • EPS
      • Giropay
      • iDEAL
      • Przelewy24
      • FPX
    • Buy Now Pay Later
      • Klarna
    • Bank Debits
      • Sepa Direct Debit
    • Bank Transfer
      • Bank Transfer in Europe
      • Bank Transfer in United Kingdom
      • Bank Transfer in Indonesia
    • QR Payments
      • QRIS
      • PromptPay
    • Real-time payments
      • PIX
      • PayNow
      • UPI
      • SPEI
  • More payment scenarios
    • Set up future payments
    • Save payment method during payment
  • SaaS platform integration
    • Shopify Plugin
    • Shopastro 星盘
    • WooCommerce
    • Shoplazza 店匠
    • Shopline Plugin
    • Sage Connection
  • Resources
    • Supported currencies
  1. Bank redirects

BPI

The Bank of the Philippine Islands is a universal bank in the Philippines. It is the first bank in both the Philippines and Southeast Asia . It is the fourth largest bank in terms of assets, the second largest bank in terms of market capitalization , and one of the most profitable banks in the Philippines.

Features#

Processing currenciesPHP
Settlement currenciesGBP,USD,EUR,HKD
Minimum transaction amount1 PHP
Maximum transaction amountNo Transaction Limit
Refunds✅
Partial Refunds✅
Multiple partial refund❌
Chargeback❌

Integration Method#

Payment method enumeration values: bpi
There is integration method for BPI
1.
Direct API
2.
Checkout

Direct API#

How to integration#

For direct API integration, you can create a PaymentIntent and get url in only one step. The following is the demo of creating payment intent:
Create a PaymentIntent
A PaymentIntent is an object that represents your intent to collect payment from your customer and tracks the lifecycle of the payment process. Create a PaymentIntent on your server and specify the amount to collect and a supported currency. If you have an existing Payment Intents integration, add bpi to the list of payment method types.
Request Create a PaymentIntent
{
    "amount":200,
    "currency":"PHP",
    "confirm":true,
    "payment_method_options":{
        "bpi":{
            "terminal_type":"WEB"
        }
    },
    "payment_method_data" : {
        "type":"bpi"
    },
    "return_url":"https://wooshpay.com"
}
Response
{
    "id": "pi_1760510659914629120",
    "object": "payment_intent",
    "created": 1708573425000,
    "livemode": false,
    "currency": "PHP",
    "amount": 200,
    "status": "requires_action",
    "client_secret": "pi_1760510659914629120_secret_tGWOOrEjkw78eVmbVdloC5ue",
    "next_action": {
        "type": "bpi_handle_redirect",
        "bpi_handle_redirect": {
            "url": "https://XXXXXXXXXXXXXXX"
        }
    },
    "payment_method_types": [
        "bpi"
    ],
    "confirmation_method": "automatic",
    "payment_method_options": {
        "bpi": {
            "terminal_type": "WEB"
        }
    },
    "return_url": "https://wooshpay.com",
    "payment_method": "pm_1760510659805577216",
    "capture_method": "automatic"
}

Checkout#

Payment flow#

1.
Customer selects BPI from the list of payment methods available and clicks on the Pay botton
59f44d46-e526-4140-bd4e-d65c24eb0766.png
1.
Customers will be redirected to BPI login page
2.
The Customers completes payment within BPI
3.
Payment succeeds and the client is redirected back to the page you designated

Create a Session#

Request
{
    "cancel_url": "www.wooshpay.com",
    "mode": "payment",
    "success_url": "https://wooshpay.com/",
    "payment_method_types": [
        "bpi"
    ],
    "line_items": [
        {
            "price_data": {
                "currency": "PHP",
                "unit_amount": 20000,
                "nickname": "apple",
                "product_data": {
                    "name": "apple",
                    "description": "very delicious",
                    "url": "www.wooshpay.com"
                },
                "billing_scheme": "testscheme",
                "lookup_key": "test_lookup_key"
            },
            "quantity": 1
        }
    ]
}
Response
{
    "id": "cs_1760509695786745856",
    "object": "checkout.session",
    "created": 1708573195000,
    "livemode": false,
    "currency": "PHP",
    "customer": "",
    "mode": "payment",
    "status": "open",
    "url": "https://checkouttest.wooshpay.com/pay/cs_test_1760509695786745856?key=cGtfdGVzdF9OVEUyTmpnMU1EZ3dORFV6T1RZNE1EYzJPREF4T205T2EzcGpOMDQzVTJkWVdFODRWVmhHWm1GNGNUaHZUVEUyT0RZMk16Z3lPVFl6TWpV",
    "cancel_url": "www.wooshpay.com",
    "line_items": {
        "object": "list",
        "data": [
            {
                "id": "li_1760509696038404096",
                "object": "item",
                "currency": "PHP",
                "description": "apple",
                "price": {
                    "id": "price_1760509696063569920",
                    "object": "price",
                    "created": 1708573195000,
                    "livemode": false,
                    "active": false,
                    "currency": "PHP",
                    "metadata": {
                        "key1": "value1",
                        "key2": "value2"
                    },
                    "nickname": "apple",
                    "product": {
                        "id": "prod_1760509696109707264",
                        "object": "product",
                        "created": 1708573195000,
                        "livemode": false,
                        "active": false,
                        "description": "very delicious",
                        "metadata": {
                            "key1": "value1",
                            "key2": "value2"
                        },
                        "name": "apple",
                        "url": "www.wooshpay.com",
                        "updated": 1708573195000
                    },
                    "type": "one_time",
                    "unit_amount": 20000,
                    "billing_scheme": "per_unit",
                    "lookup_key": "test_lookup_key"
                },
                "quantity": 1,
                "amount_subtotal": 20000,
                "amount_total": 20000
            }
        ]
    },
    "payment_intent": "pi_1760509699062497280",
    "payment_method_types": [
        "bpi"
    ],
    "payment_status": "unpaid",
    "success_url": "https://wooshpay.com/",
    "amount_subtotal": 20000,
    "amount_total": 20000,
    "billing_address_collection": "auto",
    "expires_at": 1708659594825,
    "payment_link": "",
    "client_secret": "pi_1760509699062497280_secret_Te6RNLDlf7EwAR14EARVxUSU",
    "customer_creation": "if_required"
}

Next step#

You can add more features to your integration as needed

Webhook#

Listen to events on your WooshPay account so your integration can automatically trigger reactions. Create a webhook that mainly focuses on enabled_events and url.

Refund#

Create a refund to repay funds to your customer. You can also perform partial refunds, but not every payment method supports them. A partial refund is when you refund only part of the original transaction amount.
Modified at 2024-03-11 02:03:52
Previous
Bancontact
Next
Trustly
Built with