Overview
Garna lets a partner move money to creators and employees from its own backend, and lets a
third-party application read Garna user data on the user's behalf. Both use OAuth2 tokens issued by
POST /oauth/token, but they are different flows with different tokens — pick the right one before you
write any code.
Endpoint families
| Family | Base path | What it is for | Token |
|---|---|---|---|
| OAuth | /oauth |
Issuing tokens, the authorization code flow, public client details | None — or the credentials themselves |
| Payouts | /payments/v2 |
Paying out to creators and employees, checking payout status, exporting transactions | Partner |
| Payout requests | /payment-requests/v1 |
Payout calculation, single requests and batches, payment methods and payout templates | Partner |
| System users | /payment-requests/v1/users |
Provisioning your own end users, verifying them, their payout templates and money | Partner |
| User data | /oauth/user, /oauth/employee-invitations, /oauth/company |
Reading channels, balance and common data of a Garna user from a third-party app | User, with scopes |
| Legacy payouts | /payments |
Kept for existing integrations. New integrations use /payments/v2 |
Partner |
The six families are the six groups under Endpoints in the sidebar, in the same order.
Note the base paths: they are not prefixed with /api. Note also that OAuth and User data share the
/oauth prefix while being different things — one issues tokens, the other spends them.
Response envelopes
There is no single envelope across the API, so check this before writing a parser. Partner endpoints:
| Body | Endpoints |
|---|---|
data with an object |
payouts and their status (/payments/v2/payout, /payments/v2/status, legacy /payments, /payments/debit), single, bulk, /payment-requests/v1/status, /payment-requests/v1/payout/{id}, template create and read, and every system user endpoint that answers with a body except its calculate |
data with an array |
/payments/v2/company/positions, both payment-methods listings |
data with an object keyed by field name |
both payment-methods/fields endpoints |
data plus links and meta |
the two template listings — the only paginated endpoints |
| the object itself, no envelope | /payments/v2/employee-payments, and both calculate endpoints — /payment-requests/v1/calculate and /payment-requests/v1/users/{uid}/calculate |
| no body | both DELETE template endpoints — 204 |
| a CSV file | /payments/v2/transactions/export |
Where a row says "both", the pair is the company's own endpoint under /payment-requests/v1 and its
counterpart for a system user under /payment-requests/v1/users/{uid} — the two carry the same shape.
User endpoints under /oauth split the same way; their table is in
Reading user data.
Words this documentation uses
Several things here are one letter apart in name and completely different in meaning, so the documentation keeps to these terms and does not use synonyms for them.
| Term | What it is |
|---|---|
| company wallet | Your wallet, the one money leaves. Never passed directly — it is resolved from region and currency |
| recipient wallet | A wallet inside Garna that money arrives at, identified by its number |
| payment method | A way to pay out — card, bank transfer, and so on (payment_method_id). Each has its own set of recipient fields |
| payout template | Recipient details stored for one payment method (template_id), reused instead of repeating them |
| payout | A transfer created through /payments/v2 (or legacy /payments) straight to recipient wallets |
| payout request | What you create through /payment-requests/v1, carrying your request_id and a template |
| payment request | The withdrawal that appears in Garna once a payout request is processed — the payment_request field in responses |
| batch | A group of payout requests sent with POST /payment-requests/v1/bulk. Its members are called entries |
| system user | An account you provision for one of your own end users (uid). It cannot sign in, gets no notifications from us, and holds its own balance you fund and pay out |
One name is unavoidably overloaded: responses of /payment-requests/v1 carry a field called payout,
and that is not a payout in the sense above. It is the record grouping your requests — one per single
request, one per batch — and its id is what GET /payment-requests/v1/payout/{id} takes.
Base URL
Every path in this documentation is relative to the host you are reading it on: your integration talks to the host you were onboarded on, and that is the one these paths belong to. The API Reference page is pre-filled with the current host, so requests you send from there go to the right place.
Authentication in short
Partner integrations (payouts, payout requests) request a token with the partner grant type:
curl -X POST "$BASE_URL/oauth/token" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{
"grant_type": "partner",
"client_id": "<your client id>",
"client_secret": "<your client secret>"
}'
The token is valid for 180 minutes and is sent as Authorization: Bearer <token>. The OAuth client
must belong to a company account; a token issued for a personal account is rejected with 403.
partner is the grant type for payouts — no other one is supported for them, whatever a generic OAuth2
client library offers by default.
Third-party applications acting for a user go through the authorization code flow (/oauth/authorize)
and receive a token limited by scopes. Scope-protected endpoints live under /oauth/user,
/oauth/employee-invitations and /oauth/company.
Partner endpoints do not check scopes — access is decided by the client and its company account. Both flows are described step by step in Authentication.
Rate limits
/payments/* and /oauth/* share one bucket of 300 requests per minute per IP address — not per
client, and not per endpoint family.
Under /payment-requests/* reading is not limited, and every endpoint that changes something is capped
at 60 requests per minute, counted per OAuth client and per IP address. The counters are shared by
purpose rather than by path: creating and deleting payout templates share one, and single, bulk and a
system user's fund and payout share another — so two jobs on the same counter split those 60 between
them. Over the limit the answer is 429 with Retry-After. The full breakdown is in
System users.
Assume these numbers everywhere. Build the retry-and-backoff path against them rather than against the largest burst an environment happens to let through — the two are not the same thing.
Language of responses
The language depends on the path prefix, and the two halves behave differently:
| Endpoints | Language |
|---|---|
/payments*, /payment-requests* |
Always English. Accept-Language and ?lang are ignored |
/oauth* |
Follows Accept-Language, and ?lang overrides it |
So on partner endpoints translated values — payment method names, payment method field titles, CSV column
headings — always come back in English, and a value with no English translation comes back null rather
than in another language. On the user endpoints under /oauth, validation messages come back in the
language your client asked for: HTTP libraries and proxies set Accept-Language on their own, so pin it
explicitly if you parse or display those texts.
Errors
Failures come in three shapes, and the one that catches integrators out arrives with a success code:
- Rejected payout — HTTP 2xx. A payout that fails business validation still answers
201on creation (200on a status lookup), withstatus: 3(error) and a numeric code inerr_msg— for example3000when the company balance is below the requested amount, or11000when the company wallet is missing. Never read a 2xx as "money moved": always inspectstatusanderr_msg. - Authentication and permission — HTTP 401 / 403. A missing, malformed or expired token gives
{"message": "Unauthenticated."}with no numeric code. Codes appear once the token is accepted:{"message": "1000"}when no account is bound to the client,{"message": "2000"}when that account is not a company. The code sits inmessage, as a string. - Validation — HTTP 422. Standard shape:
{"message": ..., "errors": {"<field>": ["..."]}}.
Send Accept: application/json on every request your backend makes — without it, errors are rendered as an
HTML page. The one exception is GET /oauth/authorize, which is browser navigation and answers 401 if
you ask it for JSON.
Seven endpoints answer 201: POST /payments/v2/payout, POST /payments, POST /payments/debit,
both template creations, POST /payment-requests/v1/users and POST /payment-requests/v1/users/{uid}/fund. Everything else answers 200 — including POST /payment-requests/v1/single, POST /payment-requests/v1/bulk, POST /payment-requests/v1/users/{uid}/payout and POST /oauth/employee-invitations, which also create
records. Provisioning a system user answers 200 as well when the email already belongs to one of yours:
the record was not created this time. The code follows how the response is built, not whether something
was created, so treat the list above as the whole rule and match any 2xx as success rather than 200
exactly.
Payouts under /payments* carry status 1 process, 2 success, 3 error. Under
/payment-requests/v1 the same word means other things — Errors has the full table.
Partner endpoints answer with the shapes above and nothing more — never rely on stack traces or debug payloads being present.
Where to go next
The guides explain the flows; the endpoint pages under Endpoints in the sidebar carry the exact schemas, with ready-to-run snippets in cURL, JavaScript, Python and PHP for every call.
- Authentication — both token flows end to end, with the checks the server performs
- Errors — the three failure shapes and the full code reference
- Payouts and transfers — paying wallets and employees through
/payments/v2 - Methods and templates — dynamic recipient fields and reusable templates
- Single and bulk requests — payout requests through templates
- System users — provisioning your own end users and paying them
- Reading user data — profile, channels, balance and company data of a user
- Scopes — what a user token can read
- Endpoints: OAuth · Payouts · Payout requests · System users · User data · Legacy payouts
- API Reference — the same schemas in an OpenAPI browser you can send requests from, pre-filled with the host you are on