Skip to content

API reference

Everything the application does happens through this REST API - the web interface is a client of it, with no privileged back channels. The specification below is generated from the same commit as the running release, so it is never a version behind the platform it describes.

The running platform does not serve the specification itself: /api/v1/docs, /api/v1/redoc and /api/v1/openapi.json are disabled in production deliberately, and this page is where the schema is published instead.

Authentication is cookie-based for browsers and API-key based for programmatic clients. All endpoints are tenant-scoped: requests resolve the workspace from the subdomain they are addressed to. The operator console that runs the platform itself is not part of this API and is not listed here.

API keys

An administrator creates keys under Administration > People & access > API Keys. A key belongs to one workspace and calls it at that workspace's own address:

curl https://<workspace>.1494labs.com/api/v1/funds \
  -H "X-API-Key: jns_live_<key id>.<secret>"

Authorization: Bearer jns_live_... is accepted as well.

  • Shown once. The full key appears only when it is created. Store it in a secret manager; it cannot be displayed again.
  • Scopes. A key carries the permissions chosen for it, never more than the person who created it holds, and it loses any its creator later loses.
  • Expiry. A key expires one year after creation unless a shorter date is set; the longest allowed is two years.
  • Rotation and revocation. A key can be rotated (a new secret, the old one refused) or revoked from the same page, one key or every key a person created. Revocation takes effect within a minute.
  • Audit. Every change a key makes is recorded against that key in the audit trail.
  • Leaks. Treat a key like a password: keep it out of source code, logs and tickets. Anything that looks like jns_live_... and is not meant to be there should be revoked.