Skip to main content
This section has two API reference layers:
  • Generated API Reference is powered by the live HEVN OpenAPI schema from https://api.hevn.finance/openapi.json and enables Mintlify’s endpoint pages, request examples, and interactive API Playground.
  • CLI wrapper notes live in the CLI tab and document the REST endpoints that the current CLI calls through src/hevn_cli/api/*.

Base URL

The generated OpenAPI reference uses:
https://api.hevn.finance
The CLI builds requests from the configured API base URL:
https://api.hevn.finance/api/v1
The base URL can be selected through HEVN_ENV, saved login config, or HEVN_BASE_URL.
export HEVN_ENV=prod
export HEVN_BASE_URL=https://api.hevn.finance/api/v1

API clients

ClientSourceAuth modeUsed for
AppApisrc/hevn_cli/api/app.pyHEVN API keyAccount, profile, contacts, invoices, contracts, banks, cards, quotes, transactions
McpApisrc/hevn_cli/api/mcp.pySame HEVN API keyBalance, API-key introspection, and app-scoped transfers
PublicApisrc/hevn_cli/api/public.pyPublicFX rates and public invoices

Request behavior

All requests:
  • send Accept: application/json,
  • send the configured API key for authenticated clients,
  • use a 60 second HTTP timeout,
  • send query parameters only when their values are not None,
  • parse non-empty responses as JSON,
  • raise a CLI HevnError for HTTP status codes >= 400.
When --debug or HEVN_DEBUG=1 is enabled, error output can include the generated curl command. Mutating HTTP methods (POST, PUT, PATCH, DELETE) are intercepted by --dry-run / HEVN_DRY_RUN=1 before the network call is made.

Common response handling

The CLI does not enforce a shared backend response schema across endpoints. It passes backend JSON through to command formatters and wraps --json / --yaml command output in a CLI envelope. For integration code, use the endpoint-specific objects returned by the backend and treat fields shown in command output as convenience projections rather than exhaustive schemas.

Endpoint index

Authentication

Header modes, login config, and idempotency headers.