/api/v1/employee. Authenticated endpoints
require the employee bearer token in the Authorization header:
Access & blocking
An employee’s access is automatically blocked — login is refused and every authenticated call returns403 — whenever:
- the employee’s own status is
suspendedorterminated; or - the owning customer is banned; or
- the owning user account is suspended.
{ "message": "Owning user account is suspended." }.
The employee’s organisation must also be enabled for Business Spend Cards:
the owning business must be approved by Yativo, and the employee’s customer
must hold an approved faster_payments endorsement (see the Corporate Card
Integration guide). Until both are true, every authenticated call returns
403 with Your organisation is not enabled for Business Spend Cards.
Login itself still succeeds, so show this message rather than treating it
as a login failure.
Authentication (magic link / OTP)
Passwordless login: the employee requests a one-time code by email, then exchanges it for a bearer token.Request a login code
XXXX-XXXX (for example 7KQ2-M9PT). The response is always the same
whether or not the email matches a real employee (so the endpoint can’t be
used to discover who is an employee):
Exchange the code for a token
O, I and L are read as 0, 1 and 1. Codes:
- expire 10 minutes after they are issued;
- work once: requesting a new code replaces the old one;
- allow 5 wrong attempts, after which the code is cancelled and the
employee must request a new one (
429Too many incorrect attempts. Please request a new login code.).
The one-time login code is invalid or has expired.
Current employee
Log out
Card balance
available_balance as the amount the employee can spend.
ledger_balance also includes card payments that haven’t settled yet.
has_cardholder is false until the employee’s first card is issued. If
balance_unavailable is true, the figures may be incomplete; retry
shortly.
Cards
Full lifecycle management, scoped to the employee’s own cards. A card is referenced by itscard_id (the opaque id returned in card responses).
The account that owns the employee’s customer can also see and manage every
one of these cards, including viewing full card details, through the Corporate
Card API (/api/v1/corporate-card/employees/cards and
/api/v1/spend/cards/{card_id}/widget-token).
List my cards
status. Returns a paginated list of the employee’s cards.
Get a card
View full card details (secure widget)
data.iframe as an <iframe src> or open it in a new tab. The link is
short-lived — request a new one each time
the card details are shown. Sensitive card data never passes through your
servers.
Create a card
card_type is optional (Virtual or Physical, default Virtual). The card
is always issued to the authenticated employee under their own customer — no
customer_id/employee_id is accepted from the client. Card issuance follows
the platform’s standard eligibility and KYC rules.
Card fees are paid by the employee’s organisation, not the employee. An
employee’s first virtual card is free; further virtual cards and every
physical card carry a fee. If the organisation’s balance can’t cover it, the
request returns 402 and no card is issued. Deleted cards still count, so
deleting a card and creating a new one is not free.
Freeze / unfreeze a card
action is suspend (freeze) or activate (unfreeze). Terminating a card is
done through the delete endpoint below.
Update spend limits
Set / change PIN
Delete a card
Transactions, memos & invoices
The employee sees the transaction history for their own cards and can attach a memo (note) and/or one or more invoices to each transaction.List my transactions
status, card_id. Each transaction includes notes_count
and invoices_count.
Get a transaction
notes and invoices.
Add a memo (note)
Delete a memo
Attach an invoice
invoice file. Allowed types: jpg, jpeg,
png, pdf; max 10 MB. Every file is virus-scanned before it is stored;
files that fail the scan are rejected with 422. The file is stored privately
(never at a public address). The response includes a url for downloading the
stored invoice through the endpoint below.
Download an invoice
Content-Disposition: attachment),
with the content type detected from the file itself.
Delete an invoice
Private documents (KYC, selfie)
Document links on the employee (selfie_image, and gov_id_image_url,
payslip_url, proof_of_address_url on kyc) are private Yativo links of the
form https://<api-host>/files/private/.... They open with the employee’s
bearer token. To show one in an <img> tag or open it in a new tab, exchange
it for a 15-minute signed link:
404.
Errors
Errors follow the same envelope used across the API:401 (missing/invalid token), 402 (the organisation’s
balance can’t cover a card fee), 403 (blocked employee, or the organisation
isn’t enabled for Business Spend Cards), 404 (a card/transaction/note/invoice
that isn’t the employee’s), 422 (validation or a rejected upload).
