Authorization header with a BASIC prefix (note the trailing space between BASIC and the key).
This page covers Sandbox setup and your first call. For exhaustive environment, status code, and error schema details, see the Reference page.
Prerequisites
Before you start, you should have:- A Meld account. If you do not have one, contact your Meld representative to get onboarded.
- An API key for Sandbox. API keys are issued by Meld and are environment-specific (Sandbox keys do not work in Production, and vice versa). Work with your Meld contact to obtain your key.
- A way to make HTTP requests from a backend. This guide uses
curl, but any HTTP client works. Calls must originate from your backend, not from a browser or mobile app.
Environments
Meld offers separate Sandbox and Production environments with separate API keys and separate data.| Environment | API Base URL | Purpose |
|---|---|---|
| Sandbox | https://api-sb.meld.io | Build and test. No real funds move. |
| Production | https://api.meld.io | Live traffic. Real customers, real funds. |
Always begin integration in Sandbox. Switch the base URL and swap in your Production API key when you are ready to go live.
Quick Start
Follow these five steps to make your first authenticated call.Step 1 — Get your Sandbox API key
Reach out to your Meld contact to obtain your Sandbox API key. Treat it like a password.Step 2 — Store the API key as an environment variable
In your shell:Step 3 — Construct the Authorization header
Meld expects the BASIC scheme followed by your raw API key (not a base64-encoded user:password pair like HTTP Basic Auth — Meld uses the BASIC keyword with the key value directly).
The header format is:
sk_sb_abc123xyz, the header is:
Step 4 — Make your first request
Pick any GET endpoint from the API Reference. Send the request against the Sandbox base URL with yourAuthorization header.
Example request:
Replace
<ENDPOINT> with the path of the endpoint you are calling. Refer to the API Reference for exact paths, methods, query parameters, and request bodies.Step 5 — Handle errors
If the response status code is400 or higher, Meld returns a structured error payload. See API Error Schema in the Reference page for the full shape.
A common first-call failure is 401 Unauthorized:
| Status | Meaning | What to check |
|---|---|---|
| 400 | Bad Request | Inspect errors for which field is invalid. |
| 403 | Forbidden | Your key is valid but does not have permission for this resource. |
| 404 | Not Found | Verify the endpoint path and resource ID. |
| 422 | Validation Failed | Inspect errors for the failing field(s). |
| 429 | Too Many Requests | Back off and retry. Reduce request rate. |
| 500 | Server Error | Retry with backoff. If persistent, share requestId with support. |
Security
Meld does not require IP or CORS allowlisting — authentication is solely via theAuthorization header. However:
- Always call Meld from your backend. Direct calls from a browser or mobile app expose your API key.
- Treat your API key like a password. Use a secrets manager, restrict access to your backend, and rotate keys if exposure is suspected.
- Authenticate your own frontend to your backend before letting it trigger Meld calls, and reject unauthorized callers.
Postman collection
Public Postman WorkspaceMeld offers public Postman collections for our core endpoints to help you get started. Use it alongside this documentation to explore Meld’s API surface.The Postman workspace is available here.
Dates
All Meld dates and timestamps returned via the API are in UTC and formatted using ISO 8601 (for example,
2024-01-19T20:32:30.784928Z).Next steps
- Browse the API Reference for the full list of endpoints.
- Review the Reference page for status codes, error schema, and security details.
- Pick a product to integrate — see Meld’s products.