LocalRamp API Documentation
  • Introduction
  • Getting Started
  • Crypto On-ramp
    • Overview
    • Widget Pop-up
    • Full-page checkout
    • Get Limits
    • Get Supported currencies
    • Get Quote
    • List Payment Methods
    • Get Transaction State
  • CRYPTO OFF-RAMP
    • Overview
    • Direct API Sell
      • Instant Sell
      • Get Transaction State
      • Get Limits
      • Get Supported Currencies
      • Get Supported Payment Methods
      • Get Supported Banks
      • Get Crypto Balance
      • Get Rates
      • Verify Bank Account
    • Widget Sell
      • Full-page checkout
      • Widget Pop-up
      • Get Limits
      • Get Quote
      • Get Supported currencies
      • Get Supported Payment Methods
      • Get Transaction State
  • PAYMENTS ON-RAMP
    • Overview
    • Full-page checkout
    • Widget Pop-up
    • White-Label API (Direct Charge)
    • Rates and Fees
    • Get Limits
    • Get Supported Currencies
    • Get Supported Payment Method
    • Withdraw crypto
    • Verify crypto withdrawal
    • Verify transaction
    • Get USDT balance
    • KYC
      • BVN Verification
      • Send OTP
  • Institutional Onramp (>$100k)
    • Overview
    • Initiate transaction
    • Complete transaction
    • Fetch transation
    • Exchange Rate
  • CRYPTO SWAPS
    • Overview
    • Instant Swap
    • Get Transaction State
    • Get Limits
    • Get Supported Currencies
    • Get Rates
  • Webhooks
    • Introduction
    • Verification
    • Events
  • TEST INTEGRATION
    • Simulate Webhooks
      • Fiat received (onramp)
      • Crypto Sent (onramp)
      • Sell completed (offramp)
      • Swap completed
    • Demo transaction
      • Example Completed Buy
      • Example Completed Sell (Bank Account)
      • Example Completed Sell (Mobile Money)
      • Example Completed Swap
Powered by GitBook
On this page
  1. Webhooks

Events

Event request data

For now, LocalRamp only sends webhooks on five events

  1. When the customer sends fiat for a buy or payment transaction - buy.fiat_received

  2. When LocalRamp sends the crypto equivalent to the wallet address - buy.crypto_sent

  3. When a sell transaction is successfully completed - sell.completed

  4. When a sell transaction fails - sell.failed

  5. When a swap transaction is successfully completed - swap.completed

  6. When a coin deposit arrives for a widget sell transaction - sell.initiated

The webhook request body will look like

{
  "event_type": "buy.fiat_received",
  "reference": "myTransactionReference",
  "sent_amount": "12991.32",
  "sender_currency": "NGN"
}
{
  "event_type": "buy.crypto_sent",
  "reference": "myTransactionReference",
  "received_amount": "0.0116196",
  "receiver_currency": "ETH_ETH",
  "txid": "<txID>"
}
{
  "event_type": "sell.completed",
  "tx_ext_reference": "myUniqueRef",
  "reference": "SELL_KYZSHIEMOqPg",
  "from_currency": "LTC",
  "to_currency": "NGN",
  "to_amount": "1158.96",
  "type": "widget" //"widget" or "api"
}
{
  "event_type": "sell.failed",
  "tx_ext_reference": "myUniqueRef",
  "reference": "SELL_KYZSHIEMOqPg",
  "from_currency": "USDT",
  "to_currency": "NGN",
  "to_amount": "1158.96",
  "type": "widget" //"widget" or "api"
}
{
  "event_type": "swap.completed",
  "reference": "SWAP_ukS6sPUx9sx7V1qE",
  "from_currency": "BNB",
  "to_currency": "USDT",
  "to_amount": "1.98"
}
{
    "event_type": "sell.initiated",
    "reference": "SELL_KYZSHIEMOqPg",
    "from_currency": "BTC",
    "to_currency": "GHS",
    "from_amount": "0.1234"
}

If LocalRamp does not get a 2xx response, we'll retry the endpoint every 30 minutes for 2 hours before we give up.

PreviousVerificationNextSimulate Webhooks

Last updated 10 months ago