Quick Start
Accept your first crypto payment in under 5 minutes. This guide walks you through setting up your account, configuring your payment preferences, and processing a payment.
Check supported assets first
What you'll need
Before you start integrating, you need to set up a few things in the NodeRails Dashboard:
- A NodeRails account with a verified email address.
- A connected wallet where you want to receive payments. This is the wallet funds will settle to after the timelock period.
- An App created in the dashboard. Each app gets its own API keys, webhook endpoints, and payment configuration.
- Chains and tokens selected. You need to choose which blockchains and tokens you want to accept payments in. This is configured per app in the dashboard.
Override chains and tokens per request
1. Create your account and app
Sign up at the NodeRails Dashboard and verify your email. Then:
- Connect your merchant wallet (this is where your settled funds go).
- Create a new App from the dashboard.
- Select which chains and tokens you want to accept for this app.
2. Get your API keys
Navigate to Apps → Your App → API Keys in the dashboard. You'll need two pieces of information:
- App ID: Your app's unique identifier (UUID)
- Secret Key: Starts with
nr_live_sk_ornr_test_sk_
Keep your secret key safe
nr_*_pk_) are for client-side use, but the SDK requires a secret key.API Key format
API keys follow the format nr_<env>_<type>_<random>:
| Key | Environment | Type |
|---|---|---|
nr_live_sk_... | Production | Secret |
nr_test_sk_... | Test | Secret |
nr_live_pk_... | Production | Public |
nr_test_pk_... | Test | Public |
Chains and tokens naming
When working with the NodeRails API or SDK, chains and tokens follow a specific naming convention you should be aware of.
Chains
Chains are identified by their chain ID, the same numeric ID you use everywhere else in the blockchain ecosystem. For example:
| Chain | Chain ID |
|---|---|
| Ethereum Mainnet | 1 |
| Polygon | 137 |
| Arbitrum One | 42161 |
| Base | 8453 |
| Optimism | 10 |
| Sepolia (testnet) | 11155111 |
When you pass allowedChains in the API, you pass an array of these numeric IDs.
Tokens
Tokens are identified using a token key in the format SYMBOL-chainId. This combines the token symbol with the chain it lives on. For example:
| Token | Token Key |
|---|---|
| USDC on Ethereum | USDC-1 |
| USDC on Base | USDC-8453 |
| USDT on Arbitrum | USDT-42161 |
| ETH on Ethereum | ETH-1 |
| USDC on Sepolia | USDC-11155111 |
This format ensures there's no ambiguity. USDC on Ethereum and USDC on Base are different tokens at different contract addresses, so they have different token keys.
Where to find available tokens
allowedTokens, you can pass either token keys (USDC-8453) for a specific chain, or just the symbol (USDC) to allow that token on all enabled chains.3. Install the SDK
Or with your preferred package manager:
4. Initialize the client
5. Create a checkout session
A checkout session creates a hosted payment page where your customer can select their blockchain and token, connect their wallet, and complete the payment.
By default, the checkout page shows the chains and tokens you configured for your app. You can override them for a specific session:
6. Handle the webhook
After the customer completes payment, NodeRails sends a payment.captured event to your webhook endpoint once funds are taken from the customer's wallet and locked in escrow on-chain. This is your signal to fulfill the order:
Register your webhook
noderails.webhookEndpoints.create({ url: '...', events: ['payment.captured'] })