Create a console link
LiveServed by the v1 API in development with the same checks as production; production opens on the same contract. The capabilities from before v1 keep running in production at the path your account team gives you.
Creates a link that opens the merchant's own console without a heru login: its invoices, the KPIs of the month and an accountant report with CSV. Give it to the merchant from your back office. The link can be opened as many times as needed until expires_at (a day by default). Each call creates a new link and revokes the merchant's previous ones, so repeating the request does not return the same link and needs no Idempotency-Key. url is null in an environment that has no console configured. Answers 409 when the merchant is closed.
Needs the merchants:console scope.
oauth2 merchants:consoleAuthorizationBearer <token>OAuth 2.0 client credentials. Exchange your client_id and client_secret at /oauth/token of the environment for a bearer token valid for one hour. The playground of every operation asks for your own client and keeps it in your browser tab only.
Scope: merchants:console
id*stringThe merchant id.
^mer_[0-7][0-9a-hjkmnp-tv-z]{25}$Created
application/json- response
url*|Page hosted by heru where the merchant sees its console. null when the environment has no console configured.
uriexpires_at*stringWhen the link stops working.
date-timecurl -X POST 'https://api.dev.b2b.heru.app/v1/merchants/mer_01m4xnvf23ecb963n48h2j9vxz/console-link'{ "url": "https://api.dev.b2b.heru.app/dashboard/m/EXAMPLE-NOT-A-REAL-TOKEN", "expires_at": "2026-10-28T17:02:41.219Z"}Create an onboardingPOST
Creates a new onboarding link for the merchant, valid for 7 days. Any previous link stops working. Use it when the first link expired, or when the CSD is about to expire (`csd_expiring`) and the merchant must upload the new one. The current onboarding always comes in `onboarding` when you get the merchant. Answers `409` when the merchant is active and its CSD is not expiring. Needs the `merchants:write` scope.
Create a chargePOST
Call it when a card payment is approved, with what was sold and its VAT. If you only know the amount, leave `items` out and the invoice uses the merchant's `default_item`. Returns a single-use link and its QR that you show on the terminal or print on the receipt. The customer opens the link, enters their tax data, we validate it with the SAT and stamp the invoice immediately, with no action from the merchant. Needs the `charges:write` scope.