SA-starpago-en
    SA-starpago-en
    • Access Guidelines
    • Accessory Code Table
    • Signature Example
    • Solutions to common problems with signatures
    • Indonesia - BankCodes Table
    • Thailand - BankCodes Table
    • Pakistan - BankCodes Table
    • Philippines - BankCodes Table
    • Bengal - BankCodes Table
    • payin
      • Pakistan - Create payin
        POST
      • Thailand - Create payin
        POST
      • Philippines - Create payin
        POST
      • Bengal - Create payin
        POST
      • Payment Order Query
        GET
    • payout
      • Pakistan - Create payout
        POST
      • Thailand - Create payout
        POST
      • Philippines - Create payout
        POST
      • Bengal - Create payout
        POST
      • Payout Order Query
        GET
    • account
      • Balance Query
        GET
    • webhook
      • payin webhook
      • payout webhook

    Signature Example

    Signature Algorithm sha256
    if:
    appId: af37752d8bfc9c23ce9a39e6cf44d135
    appSecret: daa153d25c25c3736b474a91aeaa7fa7
    params for payin
    {
      "appId": "af37752d8bfc9c23ce9a39e6cf44d135",
      "merOrderNo": "4085_12200315",
      "notifyUrl": "https://19fb-15-164-4-252.ngrok-free.app/Payin/Callback/StarPagoPayTHB/4085",
      "currency": "THB",
      "amount": "100",
      "payMethod": "PROMPTPAY",
      "extra": {
        "accountName": "NGUYEN TIEN HUY",
        "accountNo": "123456123456",
        "bankCode": "TMB",
        "email": "StarPago@gmail.com",
        "mobile": "0123445677"
      },
      "return_url": "/",
      "attach": "StarPago",
    }
    
    string for sign
    Sort by the Unicode of key. Then concatenate the parameters in the form of key1=value1&key2=value2&key3=value3. The same applies to the parameters in extra.
    amount=100&appId=af37752d8bfc9c23ce9a39e6cf44d135&attach=StarPago&currency=THB&extra=accountName=NGUYEN TIEN HUY&accountNo=123456123456&bankCode=TMB&email=StarPago@gmail.com&mobile=0123445677&merOrderNo=4085_12200315&notifyUrl=https://19fb-15-164-4-252.ngrok-free.app/Payin/Callback/StarPagoPayTHB/4085&payMethod=PROMPTPAY&return_url=/&key=daa153d25c25c3736b474a91aeaa7fa7
    got sign: e751a90689e87ffdbc3025d9e37825f11ed76742e9d1316c0cfbac6313c580aa
    add sign to params
    {
      "appId": "af37752d8bfc9c23ce9a39e6cf44d135",
      "merOrderNo": "4085_12200315",
      "notifyUrl": "https://19fb-15-164-4-252.ngrok-free.app/Payin/Callback/StarPagoPayTHB/4085",
      "currency": "THB",
      "amount": "100",
      "payMethod": "PROMPTPAY",
      "extra": {
        "accountName": "NGUYEN TIEN HUY",
        "accountNo": "123456123456",
        "bankCode": "TMB",
        "email": "StarPago@gmail.com",
        "mobile": "0123445677"
      },
      "return_url": "/",
      "attach": "StarPago",
      "sign": "e751a90689e87ffdbc3025d9e37825f11ed76742e9d1316c0cfbac6313c580aa",
    }

    Demo#

    Java#

    php#

    NodeJs#

    Golang#

    Modified at 2025-01-08 10:56:30
    Previous
    Accessory Code Table
    Next
    Solutions to common problems with signatures
    Built with