Estonian Accounting / Developer Portal

Developer Portal

Build integrations with the Estonian Accounting API

Base URL

https://api.accounting.ee

All API requests start from this base URL. The OpenAPI 3.1 specification is also available.

Monetary Values

All monetary amounts are in EUR cents (integers). Example: 12345 = 123.45 EUR.

Pagination

List endpoints accept page (1-based) and pageSize (default 50, max 200) query parameters.

Authentication

API Key

Create an API key at Settings > API Keys. Use Bearer authentication:

Authorization: Bearer eak_your_api_key_here

API keys are prefixed with eak_ and have configurable permissions.

Session-based (Web App)

The web application uses session cookies (auth_session) set during POST /auth/login.

API Playground

Test API requests directly from here. Logged-in users can send requests with their session.

Log in to use the playground

Log in
cURL
curl -X GET "https://api.accounting.ee/health" \
  -H "Authorization: Bearer eak_your_key_here" \
  -H "Content-Type: application/json"

Webhooks

Events

Webhooks are sent when specific events occur. Configure them at Settings > Webhooks.

invoice.finalized Invoice finalized
invoice.paid Invoice paid
purchase.finalized Purchase finalized
bank_transaction.imported Bank transaction imported
payment.received Payment received

Signature Verification

const crypto = require("crypto");

function verifyWebhook(payload, signature, secret) {
  const expected = crypto
    .createHmac("sha256", secret)
    .update(payload)
    .digest("hex");
  return crypto.timingSafeEqual(
    Buffer.from(signature),
    Buffer.from(expected)
  );
}

Code Examples

Copy-paste code examples for common operations.

List Invoices

curl -X GET "https://api.accounting.ee/companies/{companyId}/invoices" \
  -H "Authorization: Bearer eak_your_key_here" \
  -H "Content-Type: application/json"

Create Invoice

curl -X POST "https://api.accounting.ee/companies/{companyId}/invoices" \
  -H "Authorization: Bearer eak_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{
  "example": "value"
}'

List Customers

curl -X GET "https://api.accounting.ee/companies/{companyId}/customers" \
  -H "Authorization: Bearer eak_your_key_here" \
  -H "Content-Type: application/json"

Bank Transactions

curl -X GET "https://api.accounting.ee/companies/{companyId}/bank-transactions" \
  -H "Authorization: Bearer eak_your_key_here" \
  -H "Content-Type: application/json"

Rate Limits

CategoryLimitWindowKey
General300 req1 minPer user
Write (POST/PUT/PATCH/DELETE)60 req1 minPer user
Reports10 req1 minPer user
Uploads20 req1 minPer user
Search120 req1 minPer user
Webhooks100 req1 minPer company
Auth20 req1 minPer IP
Playground10 req1 minPer user

Rate limit headers: X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset, Retry-After

Error Codes

CodeMeaning
400Bad Request - check parameters
401Unauthorized - missing or expired token
403Forbidden - insufficient permissions
404Not Found
409Conflict - resource already exists
422Business rule violation
429Too Many Requests - rate limited
500Internal Server Error

Response format:

{
  "error": "VALIDATION_ERROR",
  "code": 400,
  "message": "Invalid request parameters",
  "details": { "field": ["must be a valid email"] },
  "requestId": "req_abc123"
}

Endpoints

Loading...