Getsonar

SONAR API

KYB company lookup and due-diligence API. The public API is under /v1: send the key as X-API-Key or Authorization: Bearer sk-sonar-...; guide and changelog at…

Finance & banking#business

Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.

Overview

KYB company lookup and due-diligence API. The public API is under /v1: send the key as X-API-Key or Authorization: Bearer sk-sonar-...; guide and changelog at https://getsonar.report/developers. The /api routes serve the SONAR web app.

Endpoints 95

profiles

  • GETList Available Products/api/profiles/productsProduct types this user may pick (product selector). T1.2: non-admins get the public products only; admins also get the frozen ones, marked visibility:…
  • GETList Industries/api/profiles/industriesReturn industry configuration for the frontend (selector + module toggles).
  • GETList Profiles/api/profilesList all profiles for the authenticated user.
  • POSTCreate Profile/api/profilesCreate a new profile.
  • GETGet Profile/api/profiles/:profile_idGet a single profile with its competitors.
  • PUTUpdate Profile/api/profiles/:profile_idUpdate a profile.
  • DELETEDelete Profile/api/profiles/:profile_idDelete a profile and all associated data.
  • POSTDetect Industry/api/profiles/detect_industryClassify a company's industry from its website using Claude Haiku. The LLM is constrained to picking a key from INDUSTRY_MODULES — it cannot hallucinate a new…

products

  • GETGet Products/api/productsReturn the product registry as this user sees it.

competitors

  • GETList Competitors/api/profiles/:profile_id/competitorsList all competitors for a profile.
  • POSTAdd Competitor/api/profiles/:profile_id/competitorsAdd a competitor to a profile (max 20 for regular users, unlimited for admins).
  • PUTUpdate Competitor/api/competitors/:competitor_idUpdate a competitor.
  • DELETEDelete Competitor/api/competitors/:competitor_idDelete a competitor.
  • POSTImport From Excel Preview/api/competitors/import-previewParse an Excel/CSV file WITHOUT writing to the DB. Used by the New-Screening form so a user can upload a competitor list before the screening profile exists.…
  • POSTImport From Excel/api/profiles/:profile_id/competitors/importImport competitors from an Excel file. Replaces existing competitors.
  • POSTDiscover Competitors Preview/api/competitors/discover-previewAI-suggest 5 competitors/accounts WITHOUT a saved profile. Used by the New-Screening form (and the embedded onboarding wizard) before the profile exists. Pure…
  • POSTDiscover Competitors/api/profiles/:profile_id/competitors/discoverUse AI to suggest 5 direct competitors based on the company profile. Body is optional; when present, exclude_names is merged into the DB-persisted competitor…

reports

  • POSTGenerate Report/api/reports/profiles/:profile_id/generateTrigger a new report generation. Returns immediately with report_id. 503 + Retry-After when the report queue is unavailable.
  • GETGet Report Status/api/reports/:report_id/statusPoll report generation status. Phase K3 surfaces step + pct while status == running so the frontend can show real-time progress.
  • GETList Reports/api/reportsList reports for the authenticated user, optionally filtered by profile. Cancelled reports are excluded — once a user cancels a screening they don't want it…
  • GETGet Report/api/reports/:report_idGet full report data (JSON content + metadata).
  • DELETEDelete Report/api/reports/:report_idDelete a report (only if completed or failed).
  • GETGet My Usage/api/reports/usage/meGet current user's credit usage statistics.
  • POSTCancel Report/api/reports/:report_id/cancelCancel a pending OR running report and refund its quota. Phase Y — previously this endpoint only accepted status=pending, so users couldn't cancel an…
  • GETDownload Report Pdf/api/reports/:report_id/pdfGet a signed URL for downloading the report PDF.
  • GETPreview Branded Pdf/api/reports/:report_id/pdf/brand-previewThe owner's brand kit on this KYB report, as PDF bytes for the in-app preview. Not entitled to white-label: every page carries a "PREVIEW" mark (the clean…
  • POSTShare Report/api/reports/:report_id/shareCreate or return a shareable link token for a report. The token is 32 bytes (~256-bit) URL-safe random and expires after expires_in_days (default 90, max…
  • DELETEUnshare Report/api/reports/:report_id/shareRevoke sharing for a report by clearing the share token.
  • POSTRun Scheduled Reports/api/reports/cron/run-scheduledTriggered by Render Cron Job. Finds due schedules and generates reports. Protected by X-Cron-Secret header matching CRON_SECRET env var with constant-time…

user

  • GETGet User Settings/api/user/settings
  • PUTUpdate User Settings/api/user/settings
  • POSTSend Contact Message/api/user/contact

schedules

  • GETGet Schedule/api/schedules/:profile_idGet the schedule for a profile.
  • PUTUpsert Schedule/api/schedules/:profile_idCreate or update a schedule for a profile.
  • DELETEDisable Schedule/api/schedules/:profile_idDisable (not delete) the schedule for a profile.

webhooks

  • POSTUser Signup/api/webhooks/user-signupCalled by Supabase Auth Hook when a new user confirms their account. Supabase → Authentication → Hooks → "Send email" or custom hook. Set the Authorization…

screenings

  • POSTRun Screening/api/screenings/runRun a new KYB screening for a single company. Returns immediately. 503 + Retry-After when the report queue is unavailable.
  • GETList Screenings/api/screenings?profile_id=stringList all screenings for a KYB workspace.
  • GETGet Screening/api/screenings/:screening_idGet a single screening detail.
  • POSTRescreen/api/screenings/:screening_id/rescreenRe-run a screening for the same company. Creates a new report.

company-search

  • POSTCompany Search Route/api/company-search

shared

  • GETGet Shared Report/api/shared/:share_tokenPublic endpoint — fetch a shared report by its share token. No auth required.
  • GETGet Shared Report Pdf/api/shared/:share_token/pdfPublic endpoint — get a signed PDF download URL for a shared report. No auth required.

account

  • GETGet Account/api/accountCurrent balance + lifetime totals + pricing reference for the UI.
  • GETGet Transactions/api/account/transactionsPaginated transaction history for the current user. Returns up to 200 rows per page (clamped server-side). Most-recent first.
  • POSTCreate Topup Intent/api/account/topup-intentCreate a Stripe Checkout session (mode=payment) for a one-shot balance top-up. Returns a checkout_url the frontend can redirect to; on success Stripe sends…

me

  • DELETEDelete My Account/api/mePermanently delete the caller's account, reports, PDFs and screenings.

billing

  • GETGet Plan/api/billing/planReturn the current subscription state for the Settings Plan card. Always 200; absence of a subscription is conveyed via plan: "free". Frontend renders an…
  • GETGet Report Cost/api/billing/report-costWhat the user's next web report costs, without taking anything: mode (admin | free | subscription | overage | payg | past_due), price_cents from the balance,…
  • POSTCreate Checkout Session/api/billing/checkoutCreate a Stripe Checkout session for a subscription upgrade. Body: plan: "team" | "agency" (pricing v2; Pulse / Pro are not sold) billing: "monthly" |…
  • POSTCreate Portal Session/api/billing/portalReturn a Stripe Customer Portal URL for the current user. The portal lets users update card, change plan, or cancel — Stripe drives the whole flow.
  • POSTStripe Webhook/api/billing/webhookStripe webhook receiver — Phase V hardened. Decision tree: 1. Signature missing/invalid → 400 (Stripe won't retry; correct). 2. Idempotency hit → 200 (already…

brand

  • GETGet Brand/api/brand
  • PUTUpdate Brand/api/brand
  • PUTUpload Logo/api/brand/logo
  • DELETEDelete Logo/api/brand/logo

observability

  • POSTReport Client Error/api/client-errors
  • POSTRecord Landing/api/landing
  • POSTRecord Signup Source/api/signup-source
  • POSTRecord Funnel Signup/api/funnel/signupTool-to-report funnel: a new account reached the pre-filled new-screening form (signup_completed_with_prefill). Counted once per account, only within an hour…

public-tools

  • POSTVat Check/api/public/tools/vat-check
  • POSTUk Company Lookup/api/public/tools/uk-company-lookup
  • POSTCompany Lookup/api/public/tools/company-lookup
  • POSTFunnel Event/api/public/funnel-eventCount one arrival on /login from a "Run a full KYB check" CTA.

pseo-public

  • GETGet Pseo Page/check/:jurisdiction/:slugPhase P7 — serve a published pSEO page from Supabase Storage. Status semantics: 200 — page found, in the sitemap (not thin, a registry jurisdiction) and both…
  • GETGet Pseo Country Index/check/:jurisdictionPhase P7 — paginated country index page (50 per page). These index pages are themselves SEO assets — long-tail queries like "uk kyb companies" land here.
  • GETGet Pseo Root Index/checkCross-jurisdiction root index. Lists each jurisdiction with its page count + a link to the country index.
  • GETGet Sitemap Index/sitemap.xmlPhase P4 — sitemap index, lists all per-country sitemaps. Note: in production, the static frontend file at frontend/public/sitemap.xml shadows this route…
  • GETGet Pseo Sitemap Index/sitemap-pseo.xmlPhase P4 — pSEO sitemap-index. Lives at a separate path from the static /sitemap.xml (which is the frontend marketing sitemap) so both can coexist. Referenced…
  • GETGet Per Country Sitemap/sitemap-:jurisdiction.xmlPhase P4 — per-country sitemap. URLs for that jurisdiction.
  • GETGet Robots/robots.txtPhase P4 — robots.txt: allow /check, block /admin + /api except /api/pseo/forget (needs to be reachable for GDPR submissions).
  • GETGet Forget Mode/api/pseo/forget/modeHow a submission is verified, so the form can say what happens before the user submits: verification is manual (a person reviews it, no email is sent) or…
  • POSTSubmit Forget Request/api/pseo/forgetPublic GDPR Article 17 submission endpoint. Manual mode (no email provider, the launch default): 1. Validate the page URL maps to an existing pseo_pages row…
  • GETConfirm Forget Request/api/pseo/forget/confirm?token=stringPhase AB6 — user clicks the confirmation link from the email. On valid token: Mark forget_request status='confirmed', confirmed_at=NOW() Set…

agents

  • POSTCreate Findings/v1/agents/:agent_type/findingsRun OSINT collectors for an agent type and return structured findings. The collection runs on the queue worker, never in the web process (R8). Waits up to…
  • GETGet Findings/v1/agents/findings/:job_idPoll a /findings job: 200 with the findings (same body as the POST), 202 while it runs (Retry-After), 500 PROCESSING_FAILED when it failed (a paid call was…
  • POSTCreate Run/v1/agents/:agent_type/runSubmit an async report run with full Claude analysis. Returns immediately with a run_id. Poll GET /v1/agents/{type}/run/{id} for results. 503 + Retry-After…
  • GETGet Run/v1/agents/:agent_type/run/:run_idPoll for async run status and results. Phase AD3 follow-up (2026-05-09) — Bug 2 from MCP integration test: Claude Desktop's MCP client hit "HTTP failed" 5…
  • POSTShare Run/v1/agents/:agent_type/run/:run_id/shareCreate a public share link for a completed KYB run of this API key. Anyone with share_url can open the report, no key needed; it shows what the report page…
  • DELETEUnshare Run/v1/agents/:agent_type/run/:run_id/shareRevoke the run's share link: the URL answers 404 from now on. 204 also when the run had no link. 404 NOT_FOUND for an unknown or another key's run.

companies

  • POSTLookup Company/v1/companies/lookupRegistered companies named company_name (or numbered registration_number) in country. Case, punctuation, accents and the spelling of the legal form are set…
  • GETGet Lookup/v1/companies/lookup/:request_idThe answer a lookup gave, by its request_id: the same body, for an audit trail. Any key of the same account can read it. 404 NOT_FOUND otherwise. Free.
  • DELETEDelete Lookup/v1/companies/lookup/:request_idDelete the stored answer of one lookup (K4, deletion on request) and blank the name / number on its usage row. GET on the same request_id is 404 afterwards.…
  • DELETEDelete Lookups/v1/companies/lookupsDelete every stored lookup answer of the account (all its keys) and blank the company name / number on its lookup and officers usage rows (K4). Without this,…
  • GETCompany Officers/v1/companies/:country/:registration_number/officersThe officers of the company numbered registration_number in country (GB, CZ, SK, NO, FR), read live from its register: name, role, person or company,…

auth

  • GETList Keys/v1/auth/keysList all API keys of the signed-in user (web app session, not an API key).
  • POSTCreate Key/v1/auth/keysCreate a new API key for the signed-in user. Authenticated with the web app session (Authorization: Bearer <Supabase access token>), not with an API key. The…
  • DELETERevoke Key/v1/auth/keys/:key_idRevoke (deactivate) an API key (web app session, not an API key).

meta

  • GETGet Coverage/v1/coverageCountries, fields, live / index and refresh age, generated from the registry catalog.
  • GETGet Limits/v1/limitsThe rate limits the API enforces.

usage

  • GETGet Usage/v1/usageGet usage statistics + free-trial + pre-paid balance for the calling key. A new account's first call is free (any endpoint type). After that, /v1/agents/*…
  • GETExport Usage/v1/usage/exportEvery API call of this account (all its keys) with what it was charged, for reconciliation. Usage rows are kept 90 days; at most 10,000 rows per export…
  • GETHealth/healthLiveness probe — the process is alive and accepting HTTP. Never fails unless the Python process is dead. Render's healthcheck is pointed here: a Supabase blip…
  • GETHealth Deps/health/depsReadiness probe — can we actually serve end-to-end? Pings Supabase with a cheap 1-row select. Returns 503 if Supabase is unreachable so dashboards and…
  • GETHealth Queue/health/queueJob queue probe (T1.7): 200 with the number of active (queued + running) jobs when the queue database answers, 503 when it doesn't.

API details

Authentication
An API key in the X-API-Key header
A bearer token in the Authorization header
Operations
95 operations on 80 pathsGET 44POST 34DELETE 11PUT 6
Main resources
reports 12pseo-public 10competitors 8profiles 8agents 6billing 5companies 5brand 4observability 4public-tools 4
Response formats
application/json text/html text/plain
Description format
OpenAPI 3.1.0, API version 1.0.0

How to test the SONAR API in Swastik Codes

  1. Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
  2. Fork it into your workspaceChoose a workspace. You get your own copy of the SONAR API collection, without the publisher's secrets.
  3. Add your credentialsThis API uses an API key in the X-API-Key header. Add yours in the collection's variables or an environment; the requests already reference it.
  4. Send a requestPick an endpoint, for example “List Available Products” (GET /api/profiles/products), and press Send. Check the response, add tests and run the whole collection with the runner.

Frequently asked questions

What is the SONAR API?

KYB company lookup and due-diligence API. The public API is under /v1: send the key as X-API-Key or Authorization: Bearer sk-sonar-...; guide and changelog at… It is listed under Finance & banking and has 95 endpoints.

Who publishes the SONAR API?

It is listed from Getsonar's public API description (an OpenAPI document), not published by Getsonar on Swastik Codes. Anyone who controls getsonar.report can claim the profile by adding a DNS TXT record.

How do I authenticate with the SONAR API?

It accepts 2 methods: an API key in the X-API-Key header; A bearer token in the Authorization header.

How many endpoints does the SONAR API have?

95 operations on 80 paths (44 GET, 34 POST, 11 DELETE, 6 PUT). The largest groups are reports, pseo-public, competitors, profiles.

Is forking the SONAR API free?

Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.

Suggest an API

Tell us which public API is missing. We check it, then add it here with its endpoints when it has an OpenAPI (Swagger) description.