Payins allow you to accept fiat-to-crypto payments from customers. This guide walks you through creating and managing payins for different payment methods and regions.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/blindpaylabs/blindpay-node/llms.txt
Use this file to discover all available pages before exploring further.
Overview
A payin converts fiat currency to stablecoins and deposits them to a blockchain wallet. The flow involves:- Creating a receiver (customer)
- Creating a blockchain wallet for the receiver
- Getting a quote for the payin
- Creating the payin
- Customer sends fiat payment
- BlindPay converts and transfers stablecoins
Prerequisites
Before creating a payin, you need:- A BlindPay instance ID and API key
- A receiver with completed KYC
- A blockchain wallet registered for the receiver
Payins support multiple payment methods including PIX (Brazil), ACH/Wire (USA), SPEI (Mexico), PSE (Colombia), and Transfers (Argentina).
Step 1: Create a Payin Quote
Get the quote
First, create a quote to get the exchange rate and fees:
Quotes expire after a set time. The
expires_at field contains a Unix timestamp.Understand the quote response
The quote response includes:
id: Quote ID to use when creating the payinsender_amount: Total fiat amount the customer must payreceiver_amount: Stablecoins that will be receivedcommercial_quotation: Market exchange rateblindpay_quotation: BlindPay’s exchange rate (includes fees)flat_fee: Fixed fee in stablecoinsexpires_at: Unix timestamp when quote expires
Step 2: Create the Payin
Step 3: Track Payin Status
Understand tracking stages
Payins go through multiple tracking stages:
- tracking_transaction: Customer’s fiat payment received
- tracking_payment: Converting fiat to stablecoins
- tracking_complete: Stablecoins sent to blockchain wallet
- tracking_partner_fee: Partner fee payment (if applicable)
step: Current step status (on_hold,processing,complete)completed_at: Timestamp when this stage completed
Step 4: Handle Different Payment Methods
Listing Payins
Retrieve all payins with optional filtering:Public Tracking
Allow customers to track their payin without authentication:The
getTrack endpoint uses a different endpoint (/e/payins/:id) and can be called without authentication, making it safe to use in client-side applications.Error Handling
Best Practices
- Quote Management: Create quotes just before displaying to users to minimize expiration risk
- Fee Transparency: Clearly display whether
cover_feesis true/false and show total cost - Status Updates: Use webhooks for real-time updates instead of polling
- Payment Instructions: Display clear, localized payment instructions for each method
- Timeout Handling: Set reasonable timeouts and notify users if payment isn’t received
- Public Tracking: Share the
getTrackendpoint with customers for self-service tracking
Next Steps
- Set up webhook verification to receive real-time updates
- Learn about virtual accounts for recurring payins
- Explore blockchain wallets for managing destinations