API reference

Getting started

Take mobile money and card payments on your website in four steps.

  1. 1

    Create your account and business

    Sign up, confirm your email and set up two-step sign-in. Each business has its own keys, payments and payouts.

  2. 2

    Get your secret key

    Settings → API keys & webhooks → Generate. It is shown once: store it in your server’s environment variables. Never put it in browser or app code.

  3. 3

    Create a checkout session from your server

    Send the amount (in pesewas) and your order reference. You get a checkout_url: send the customer there to pay with MoMo or card.

  4. 4

    Confirm on your server, then deliver

    When the payment.success webhook arrives, check the signature and that the amount and merchant_reference match your order. Only then fulfil the order.

Base URL

All requests go to https://api.brightsecuretech.com. Live and test are chosen by the key you use: bst_live_… or bst_test_….

Test mode

Test keys never move real money. While test mode is being connected on the live servers, test payments may be refused with acquirer_not_configured.