# Finic docs: full text > Finic is infrastructure for fraud, abuse, risk and compliance decisions, with one API at https://api.finic.ai. Each decision has its own endpoint, POST /v1/score/{use_case} (account opening, account takeover, payments, payouts, scams, sanctions screening, merchant monitoring and more): send what you know in a context object, as text, JSON or CSV, and get a score from 0 (lowest risk) to 1000 (highest) with the yes/no questions behind it, for $0.002 to $0.10 a call. Custom scoring models (POST /v1/score) are calibrated to your own labeled outcomes; POST /v1/ask answers your own questions about a case with calibrated probabilities; Identify tells people from AI agents and bots on your site; KYB keeps and screens business records. Agents connect over MCP at https://api.finic.ai/mcp. # Finic documentation (/) **Finic** is infrastructure for fraud, abuse, risk and compliance decisions: whether to open an account, let a login through, accept a payment, send a payout, trust a visitor, detect a bot, or onboard a business. Score any request from 0 to 1000 with its reasons, ask Finic's model your own questions, tell people from AI agents, and verify businesses, all with one API key. Each request works on the data you already have, sent as text, JSON or CSV, with no model to train first. Every answer comes with its reasons, so you can explain a decision to a customer, a partner bank or an auditor. Get a key at [app.finic.ai](https://app.finic.ai), or let your AI agent set Finic up for you over [MCP](/agent-quickstart). ## Products [#products] ### Scores [#scores] Get a risk score from 0, the lowest risk, to 1000, the highest, with the yes/no questions behind it. ### Models [#models] Call Finic's model directly, for decisions that a score doesn't cover. ### Identify [#identify] Know who, or what, is on your site and calling your servers. ### Know Your Business [#know-your-business] Onboard businesses and merchants, and keep checking them. ### Platform [#platform] Connect Finic to your systems and your AI tools. ## Which product do I need? [#which-product-do-i-need] | You want to | Use | | ---------------------------------------------------------------------------------------------------------------------- | ------------------------------------------- | | Score a sign-up, login, payment, payout, claim or other common decision | A [scoring endpoint](/score-api) | | Score a decision of your own, calibrated to your outcomes | A [custom scoring model](/score-model) | | Get answers to your own questions about a case, such as "is this account takeover?" and "which team should review it?" | The [Grayson API](/grayson-api) | | Tell people from AI agents and bots on your website | [Bot detection](/identify) | | Check whether a request really comes from the AI agent it claims to be | [Agent verification](/identify/lookup) | | Verify a business before you onboard it | [Business verification](/kyb/verifications) | | Keep screening the merchants you have onboarded | [Merchant monitoring](/kyb/monitoring) | | React to KYB results in your own systems | [Webhooks](/webhooks) | | Let an AI agent set Finic up and use it for you | [MCP](/agent-quickstart) | ## Your first score [#your-first-score] One call, with what you know about the request. Here, a payment: ```bash title="Score a payment" curl https://api.finic.ai/v1/score/payment \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "order": { "id": "ord_88213", "items": [{ "name": "iPhone 16 Pro", "quantity": 3, "unit_price_usd": 1199 }], "total_usd": 3597, "shipping_method": "express" }, "customer": { "created": "2026-11-23", "previous_orders": 0, "email_verified": false }, "billing_address": { "city": "Toronto", "region": "ON", "country": "CA" }, "shipping_address": { "line1": "1396 NW 82nd Ave", "line2": "Unit 4411", "city": "Doral", "region": "FL", "country": "US" } } }' ``` ```json title="200 OK" { "score": 871, "questions": [ { "text": "Does the shipping address look like a reshipper or freight forwarder?", "probability": 0.94 }, { "text": "Is the order unusually large for a new account?", "probability": 0.9 }, { "text": "Do the card and the shipping address point to different countries?", "probability": 0.88 }, { "text": "Are the items easy to resell?", "probability": 0.83 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` The [Developer quickstart](/quickstart) takes you from an API key to acting on a score. ## What every product shares [#what-every-product-shares] * **One API key.** Create keys in the Finic app under [API keys](https://app.finic.ai/keys), and send one as `Authorization: Bearer gsk_…`. See [Authentication](/authentication). * **One credit balance.** Every paid call is charged to your organization's credit, on every plan, and errors are free. See [Pricing](/pricing). * **One error format.** Every error has a `type`, a `message` and, when a field is at fault, a `param`. See [Errors](/reference#errors). * **A request id for every call.** Each response has an `X-Request-Id` header. Log it: support asks for it. * **The Finic app.** See every request with its result and reasons under Events, and manage keys, members, billing and data retention at [app.finic.ai](https://app.finic.ai). Finic runs on [Kairos](https://github.com/finic-ai/kairos), our open-source decision engine. ## Start here [#start-here] # Developer quickstart (/quickstart) The API takes JSON over HTTPS, so any HTTP client works; there's no SDK. Working in an AI agent instead? See the [Agent quickstart](/agent-quickstart). ### Get an API key [#get-an-api-key] Sign up or sign in at [app.finic.ai](https://app.finic.ai), and create a key under [API keys](https://app.finic.ai/keys). It starts with `gsk_` and is shown once. Keep it in an environment variable: ```bash export FINIC_API_KEY=gsk_… ``` A new organization starts with free credit, so you can try every endpoint before you pay. See [Pricing](/pricing). ### Score a sign-up [#score-a-sign-up] Pick the [scoring endpoint](/score-api) for your decision, and send what you know about the request in a `context` object. Each field can be text, JSON or CSV, and most fields are optional. Here, a sign-up for [account opening](/score-api/endpoints/account-opening): ```bash curl https://api.finic.ai/v1/score/account_opening \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "email": "xk92.bnq@proton.me", "address": "8 The Green, Suite A, Dover, DE 19901", "ip": { "address": "198.51.100.23", "country": "DE", "is_vpn": true, "is_datacenter": true }, "device": { "os": "Android 14", "model": "sdk_gphone64_x86_64", "is_emulator": true, "signups_last_hour": 3 } } }' ``` ### Read the score [#read-the-score] ```json title="200 OK" { "score": 912, "questions": [ { "text": "Does the email address look machine-generated?", "probability": 0.93 }, { "text": "Is the sign-up coming from an emulator or a virtual device?", "probability": 0.91 }, { "text": "Has this device been used for other recent sign-ups?", "probability": 0.88 }, { "text": "Does the address look like a registered-agent or mail-forwarding address?", "probability": 0.84 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the reasons behind it: each yes/no question with the probability that the answer is yes. ### Act on it [#act-on-it] Compare the score with thresholds you choose. For example: | Score | Action | | ----------- | ------------------------------ | | Under 300 | Open the account | | 300 to 599 | Ask for a document or a selfie | | 600 to 849 | Hold for an analyst | | 850 or more | Refuse the sign-up | Every call is in the Finic app under Events, with its context, score and reasons, so you can check your thresholds against real traffic. Log the `X-Request-Id` header of every response; support asks for it. Errors have one format: see [Errors](/reference#errors). ## In Python and TypeScript [#in-python-and-typescript] ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/account_opening", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={"context": {"email": "xk92.bnq@proton.me", "address": "8 The Green, Suite A, Dover, DE 19901"}}, timeout=30, ) if not response.ok: error = response.json()["error"] raise RuntimeError(f"{response.status_code} {error['type']}: {error['message']}") print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/account_opening", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { email: "xk92.bnq@proton.me", address: "8 The Green, Suite A, Dover, DE 19901" }, }), }); if (!response.ok) { const { error } = await response.json(); throw new Error(`${response.status} ${error.type}: ${error.message}`); } const { score } = await response.json(); ``` ## Next [#next] # Agent quickstart (/agent-quickstart) Finic's MCP server is: ```text https://api.finic.ai/mcp ``` Add it to your AI app as a custom connector. The first time your agent uses it, it shows you a sign-in link: sign in to Finic or create an account there, approve access, and your app gets its token automatically. Your agent never sees a key. ## Add the connector [#add-the-connector] In claude.ai, Claude Desktop or Cowork, open [Customize → Connectors](https://claude.ai/customize/connectors), choose **+ Add → Add custom connector**, name it **Finic**, enter `https://api.finic.ai/mcp` and add it. Then choose **Connect** and sign in. On Team and Enterprise plans, an owner adds it once under [Organization settings → Connectors](https://claude.ai/admin-settings/connectors) (**Add → Custom → Web**); each member then chooses **Connect** under Customize → Connectors. Open [Settings → Connectors](https://chatgpt.com/#settings/Connectors), then **Advanced**, and turn on **Developer mode**. Choose **Create**, name it **Finic**, enter `https://api.finic.ai/mcp`, choose **OAuth** and create it. Developer mode needs a paid plan; on Business and Enterprise, a workspace admin may need to allow it first. Add to Cursor Or add it to `~/.cursor/mcp.json`: ```json title="mcp.json" { "mcpServers": { "finic": { "url": "https://api.finic.ai/mcp" } } } ``` Cursor opens your browser to sign in when it connects. Add to VS Code Or run **MCP: Add Server** from the Command Palette, choose **HTTP** and enter `https://api.finic.ai/mcp`. VS Code opens your browser to sign in. ```bash claude mcp add --transport http finic https://api.finic.ai/mcp ``` Then run `/mcp`, select `finic` and choose **Authenticate**. Add `--scope user` to use it in every project. ```bash codex mcp add finic --url https://api.finic.ai/mcp codex mcp login finic ``` Any client that supports remote MCP servers (Streamable HTTP) with OAuth works with just the URL. For a client that can't sign in, use [`/mcp/keys`](/mcp/sign-up), or send an API key as `Authorization: Bearer gsk_…` to `/mcp`. ## Then ask your agent [#then-ask-your-agent] > Set up Finic for me. > Use Finic to test whether it can catch the chargebacks in `payments.csv`. > Ask Finic whether this case looks like account takeover: a login from a new device abroad, a password reset, then a $4,900 wire to a new payee six minutes later. ## How agents use Finic [#how-agents-use-finic] 1. **Call [`get_quickstart_skill`](/mcp/get-quickstart-skill) first.** It returns a skill that walks the agent through setup with you: data retention, your test data, your use case, testing Finic's accuracy and going live. 2. **Questions work out of the box.** [`ask`](/mcp/ask) answers questions about any case right away. 3. **Scores need a scoring model.** [`create_model`](/mcp/create-scoring-model) creates one from labeled records (your data, or sample data the agent generates to try it out), waited for with [`get_job_status`](/mcp/get-job-status), or from just a description of the decision, which you then [`calibrate`](/mcp/calibrate) with labeled records or give your own questions with [`add_questions`](/mcp/add-questions). Then call [`score`](/mcp/score). Calibrate it again with fresh labeled records as you learn more. [`list_models`](/mcp/list-scoring-models) shows the scoring models already created, and [`update_model`](/mcp/update-scoring-model) renames, re-describes or archives one. 4. **Identify needs a site.** [`create_site`](/mcp/sites) returns a script tag for your pages; the agent can add it to your code. Each visit is then a session, read with [`list_sessions`](/mcp/sessions): who the visitor is (a person, an AI agent or automation), how sure Finic is, and whether the browser has been seen before. Every tool, its price and how its errors come back are in the [MCP reference](/mcp). Signed-in apps are listed in the Finic app under [API keys](https://app.finic.ai/keys), where you can sign them out; see [Authentication](/authentication#mcp-sign-in). # Authentication (/authentication) ## API keys [#api-keys] Send an API key as a bearer token on every API request: ```http POST /v1/score HTTP/1.1 Host: api.finic.ai Authorization: Bearer gsk_… ``` Create keys in the Finic app under [API keys](https://app.finic.ai/keys). A key starts with `gsk_` and is shown once, when you create it; if you lose it, create a new one. Each key expires after the time you choose: 1 hour, 1 day, 7 days, 30 days (the default), 90 days, 1 year or never. Keys belong to your organization, and Usage in the Finic app is broken down by key, so use one key per service and environment. * **Keep keys server-side,** in environment variables or a secrets manager. Never put one in browser or mobile code, or in source control. Don't log the `Authorization` header. * **Rotate without downtime:** create a new key, deploy it, check under Usage that the old one has stopped receiving requests, then revoke it under [API keys](https://app.finic.ai/keys). A missing, unknown, revoked or expired key gets `401 authentication_error`. ## MCP sign-in [#mcp-sign-in] [`https://api.finic.ai/mcp`](/agent-quickstart) uses OAuth, so agents never handle a key: 1. The first time an agent connects, your AI client (Claude, ChatGPT, Cursor or another) shows you a sign-in link to Finic. 2. You sign in, or create an account there (email and password, or Google), and approve access for one of your organizations. Only approve if you're connecting that client right now. 3. You're sent back to the client, which receives its token automatically and renews it. After 90 days without use, you sign in again. Each signed-in client is listed in the Finic app under [API keys](https://app.finic.ai/keys) as its name followed by "(sign-in)". Its calls count toward that organization's usage, credit and rate limits. Choose **Sign out** there to disconnect it. `/mcp` also accepts an API key as `Authorization: Bearer gsk_…`, for scripts and CI. For clients that can't sign in or send headers, [`/mcp/keys`](/mcp/sign-up) has a link-and-key flow: you approve an API key, and the agent receives it. ### For MCP client developers [#for-mcp-client-developers] `/mcp` follows MCP's authorization spec (OAuth 2.1): * **Discovery:** an unauthenticated request gets `401` with `WWW-Authenticate: Bearer resource_metadata="https://api.finic.ai/.well-known/oauth-protected-resource/mcp", scope="decide"`. * **Authorization server:** `https://portal.finic.ai`, metadata at `/.well-known/oauth-authorization-server`. * **Registration:** client ID metadata documents, or dynamic client registration (RFC 7591). * **Requests:** authorization code with PKCE (`S256` only), resource `https://api.finic.ai/mcp`, scope `decide`. * **Tokens:** access tokens last 1 hour; refresh tokens last 90 days and are replaced on each use. ## The docs' playground [#the-docs-playground] The API reference pages' playground sends real requests. If you're signed in to the [Finic Portal](https://portal.finic.ai) in the same browser, they use your session: requests run against your current organization and are billed like any API request. Otherwise, paste an API key; it's kept in that browser tab only. # Pricing (/pricing) Every call is paid from your organization's credit, on every plan. A plan adds credit each month and unlocks more features. Only successful calls are charged: errors, including `429 rate_limited`, are free. ## Plans [#plans] | Plan | Price | Credit | Custom scoring models | Data retention | | ---------- | ------------ | --------------------------------- | --------------------- | ------------------------- | | Free | $0 | $5 of credit to start, once | None | 365 days | | Starter | $99 a month | $125 of usage included each month | 5 | 365 days | | Growth | $199 a month | $300 of usage included each month | 20 | Your choice, down to zero | | Enterprise | Custom | Agreed with Finic | No limit | Your choice, down to zero | * **Every plan has every endpoint:** the scoring endpoints, ask, Identify and KYB. * **Included credit doesn't expire.** What you don't spend in a month stays in your balance. * **Custom scoring models** count when they aren't archived. Over your plan's limit, creating one fails with `403 plan_required`; the ones you have keep working. * Buy or change a plan in the Finic app under [Settings → Billing](https://app.finic.ai/settings/billing). Talk to [sales@finic.ai](mailto:sales@finic.ai) about Enterprise. ## Scoring endpoints [#scoring-endpoints] Each [scoring endpoint](/score-api) has a flat price per call, by how much there is to read. Two cost more, because Finic brings its own data to them. | Group | Price per call | Scoring endpoints | | --------------- | -------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | Events | $0.002 | [Account takeover](/score-api/endpoints/account-takeover), [policy abuse](/score-api/endpoints/policy-abuse), [content moderation](/score-api/endpoints/content-moderation), [bot detection](/score-api/endpoints/bot-detection), [AI token fraud](/score-api/endpoints/ai-token-fraud) | | Transactions | $0.005 | [Account opening](/score-api/endpoints/account-opening), [payments](/score-api/endpoints/payments), [payouts](/score-api/endpoints/payouts), [scam detection](/score-api/endpoints/scam-detection) | | Profiles | $0.01 | [Job applicant fraud](/score-api/endpoints/job-applicant-fraud), [customer risk rating](/score-api/endpoints/customer-risk-rating) | | Screening | $0.05 | [Sanctions screening](/score-api/endpoints/sanctions-screening): Finic checks the name against its own sanctions lists | | Merchant review | $0.10 | [Merchant monitoring](/score-api/endpoints/merchant-monitoring): Finic reads the merchant's website for you | ## Ask and custom scores [#ask-and-custom-scores] **$0.035 per million input tokens**, for [ask](/grayson-api/questions) requests and [custom scoring models](/score-model/custom-scoring-models) alike. | What | Endpoint | Price | | ----------------------------------------------------------------- | ----------------------- | ------------------------------------------------------ | | An ask request | `POST /v1/ask` | Its input tokens: about $0.0002 for a 5,000-token case | | A custom score | `POST /v1/score` | Its input tokens: usually under $0.0001 | | Create, update or delete a scoring model, or change its questions | `/v1/score/models` | Free | | Calibrate a scoring model | `POST /v1/calibrate` | Free | | Check a job | `GET /v1/jobs/{job_id}` | Free | * **An ask request's input tokens** are its data, context and questions, as the model reads them. Each response reports them in `usage.input_tokens`; up to 32,768 per request ([limits](/reference#limits)). * **A custom score's input tokens** are the record and the scoring model's own input, usually a few hundred to a couple of thousand tokens in all. * **Each request is rounded up** to a whole micro-dollar ($0.000001). Usage in the Finic app shows every request's tokens and cost. ## Identify [#identify] **$1 per 1,000 identifications**: $0.001 each. | What | Price | | --------------------------------------------------------------------------------- | ---------------------- | | A [session](/identify/quickstart): one browser's visit to a site with the snippet | $0.001, when it starts | | A [lookup](/identify/lookup): `POST /v1/identify/lookup` | $0.001 | | Later reports in a session, and reading sessions, sites and visitors | Free | * **A session is charged once,** however many pages it covers and however often you read its verdict. It lasts up to 12 hours. * **A report that's refused starts no session and costs nothing:** over a [limit](/identify/data#limits), or from a page that isn't one of the site's origins. * **A lookup is charged when it answers.** Errors are free. Its response reports `"cost_usd": "0.001"`. * **The [edge package](/identify/edge) uses both:** a lookup for a request with no session yet, then the session. ## KYB [#kyb] Storing business records is free. A [screening](/kyb/screenings) is charged by its kind when it answers, and a screening that answers nothing costs nothing. A sanctions screening costs $0.05, the same as the sanctions screening scoring endpoint. See [KYB screening prices](/kyb/screenings#prices) for every kind. ## Credit [#credit] When credit runs out, every paid call fails with `402 insufficient_credit` until an admin adds credit or the plan's next month starts. Free calls, such as creating and calibrating scoring models, still work. Identify stops too: the snippet's reports are turned away without an error, so no sessions start and nothing changes on your pages. It picks up again within a minute of credit being added. # Score API (/score-api) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json. Change that, not this file. */} Each use case has its own scoring endpoint: `POST /v1/score/{use_case}`. You send a `context` object with what you know about the request, and Finic returns a score from 0, the lowest risk, to 1000, the highest, with the yes/no questions behind it. There is no model to make first: every plan, the free plan included, has every out-of-the-box score. ```bash title="Score a sign-up" curl https://api.finic.ai/v1/score/account_opening \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "email": "xk92.bnq@proton.me", "address": "8 The Green, Suite A, Dover, DE 19901", "ip": { "address": "198.51.100.23", "country": "DE", "is_vpn": true, "is_datacenter": true }, "device": { "os": "Android 14", "model": "sdk_gphone64_x86_64", "is_emulator": true, "first_seen": "2026-11-25T14:02:11Z", "signups_last_hour": 3 } } }' ``` For a decision that is not in this list, [create your own scoring model](/score-model) from labeled examples, or ask your own questions with [ask](/grayson-api/questions). ## Identity & Accounts [#identity--accounts] | Use case | Endpoint | Price per call | | -------------------------------------------------------------------------------------------------------- | ---------------------------- | -------------- | | [Account opening](/score-api/endpoints/account-opening): Stop fake and duplicate accounts at sign-up. | `/v1/score/account_opening` | $0.005 | | [Account takeover detection](/score-api/endpoints/account-takeover): Catch takeovers before money moves. | `/v1/score/account_takeover` | $0.002 | | [Job applicant fraud](/score-api/endpoints/job-applicant-fraud): Screen out fake candidates. | `/v1/score/job_applicant` | $0.01 | ## Payments [#payments] | Use case | Endpoint | Price per call | | ------------------------------------------------------------------------------------------------------------ | ------------------- | -------------- | | [Payments and orders](/score-api/endpoints/payments): Approve good orders, stop fraud and chargebacks. | `/v1/score/payment` | $0.005 | | [Payouts and withdrawals](/score-api/endpoints/payouts): Hold risky payouts, release good ones fast. | `/v1/score/payout` | $0.005 | | [Real-time scam detection](/score-api/endpoints/scam-detection): Stop scam payments before the money leaves. | `/v1/score/scam` | $0.005 | ## KYB & Compliance [#kyb--compliance] | Use case | Endpoint | Price per call | | -------------------------------------------------------------------------------------------------------------------- | ------------------------------- | -------------- | | [Merchant monitoring](/score-api/endpoints/merchant-monitoring): Catch merchants that change after onboarding. | `/v1/score/merchant` | $0.10 | | [Customer risk rating](/score-api/endpoints/customer-risk-rating): Rate every customer, and keep the rating current. | `/v1/score/customer_risk` | $0.01 | | [Sanctions screening](/score-api/endpoints/sanctions-screening): Fewer false matches, each with a reason. | `/v1/score/sanctions_screening` | $0.05 | ## Policy & Abuse [#policy--abuse] | Use case | Endpoint | Price per call | | -------------------------------------------------------------------------------------------------------------------- | -------------------------- | -------------- | | [Policy abuse](/score-api/endpoints/policy-abuse): Stop promo, refund and return abuse. | `/v1/score/policy_abuse` | $0.002 | | [Content moderation](/score-api/endpoints/content-moderation): Decide posts, listings and messages by your policies. | `/v1/score/content` | $0.002 | | [AI agent and bot detection](/score-api/endpoints/bot-detection): Tell helpful agents from hostile bots. | `/v1/score/bot` | $0.002 | | [AI token fraud](/score-api/endpoints/ai-token-fraud): Stop free-credit farming, stolen cards and leaked keys. | `/v1/score/ai_token_fraud` | $0.002 | # Account opening (/score-api/endpoints/account-opening) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Let real customers in. Keep fake accounts out.** Score every sign-up before the account opens. Send the email, device, address and anything else you collect, and get a risk score with the reasons behind it. | Endpoint | Price | Group | | -------------------------------- | --------------- | ------------------- | | `POST /v1/score/account_opening` | $0.005 per call | Identity & Accounts | ## Request [#request] Send what you know in one `context` object. `email` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/account_opening \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "email": "xk92.bnq@proton.me", "address": "8 The Green, Suite A, Dover, DE 19901", "ip": { "address": "198.51.100.23", "country": "DE", "is_vpn": true, "is_datacenter": true }, "device": { "os": "Android 14", "model": "sdk_gphone64_x86_64", "is_emulator": true, "first_seen": "2026-11-25T14:02:11Z", "signups_last_hour": 3 } } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/account_opening", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "email": "xk92.bnq@proton.me", "address": "8 The Green, Suite A, Dover, DE 19901", "ip": { "address": "198.51.100.23", "country": "DE", "is_vpn": True, "is_datacenter": True }, "device": { "os": "Android 14", "model": "sdk_gphone64_x86_64", "is_emulator": True, "first_seen": "2026-11-25T14:02:11Z", "signups_last_hour": 3 } } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/account_opening", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "email": "xk92.bnq@proton.me", "address": "8 The Green, Suite A, Dover, DE 19901", "ip": { "address": "198.51.100.23", "country": "DE", "is_vpn": true, "is_datacenter": true }, "device": { "os": "Android 14", "model": "sdk_gphone64_x86_64", "is_emulator": true, "first_seen": "2026-11-25T14:02:11Z", "signups_last_hour": 3 } }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | --------------- | -------- | --------------------------------------------------------------------------------------------------------------------- | | `email` | Required | The email address, with anything you know about it, such as how old it is and whether you have seen it before. | | `identity` | Optional | The name, date of birth and ID details the person gave, written out. | | `phone` | Optional | The phone number, with its type and carrier if you know them. | | `address` | Optional | The address they gave, as they wrote it. | | `ip` | Optional | The IP address with what your lookup says about it: country, city and network type. An address by itself says little. | | `device` | Optional | A description of the device, not a device ID: its type, its operating system, and whether you have seen it before. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 912, "questions": [ { "text": "Does the email address look machine-generated?", "probability": 0.93 }, { "text": "Is the sign-up coming from an emulator or a virtual device?", "probability": 0.91 }, { "text": "Has this device been used for other recent sign-ups?", "probability": 0.88 }, { "text": "Does the address look like a registered-agent or mail-forwarding address?", "probability": 0.84 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Does the email address look machine-generated? 2. Is the sign-up coming from an emulator or a virtual device? 3. Has this device been used for other recent sign-ups? 4. Does the address look like a registered-agent or mail-forwarding address? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ------------------------------- | | Under 300 | Approve | Open the account. | | 300 to 599 | Step up | Ask for a document or a selfie. | | 600 to 849 | Review | Hold for an analyst. | | 850 or more | Block | Refuse the sign-up. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | ------------------------------------------------------------------------------------------------------------ | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`email`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Account takeover detection (/score-api/endpoints/account-takeover) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Spot the takeover before the money moves.** Score logins, password resets and contact changes as they happen. Describe the activity and what is normal for the account, and get a score for how likely it is that someone else is in control. | Endpoint | Price | Group | | --------------------------------- | --------------- | ------------------- | | `POST /v1/score/account_takeover` | $0.002 per call | Identity & Accounts | ## Request [#request] Send what you know in one `context` object. `activity` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/account_takeover \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "activity": [ { "at": "2026-11-25T15:02:11Z", "type": "login", "new_device": true }, { "at": "2026-11-25T15:04:40Z", "type": "password_reset" }, { "at": "2026-11-25T15:08:02Z", "type": "email_changed" }, { "at": "2026-11-25T15:09:30Z", "type": "payee_add_started" } ], "account": { "opened": "2019-04-02", "usual_login_city": "Columbus, OH", "usual_device": "iPhone 15", "email_last_changed": "2020-01-15" }, "device": { "os": "Windows 11", "browser": "Chrome 131", "seen_on_account": false }, "ip": { "address": "203.0.113.77", "city": "Lagos", "country": "NG", "network": "mobile" }, "other_context": "Customer called support at 15:30 to say they cannot log in" } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/account_takeover", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "activity": [ { "at": "2026-11-25T15:02:11Z", "type": "login", "new_device": True }, { "at": "2026-11-25T15:04:40Z", "type": "password_reset" }, { "at": "2026-11-25T15:08:02Z", "type": "email_changed" }, { "at": "2026-11-25T15:09:30Z", "type": "payee_add_started" } ], "account": { "opened": "2019-04-02", "usual_login_city": "Columbus, OH", "usual_device": "iPhone 15", "email_last_changed": "2020-01-15" }, "device": { "os": "Windows 11", "browser": "Chrome 131", "seen_on_account": False }, "ip": { "address": "203.0.113.77", "city": "Lagos", "country": "NG", "network": "mobile" }, "other_context": "Customer called support at 15:30 to say they cannot log in" } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/account_takeover", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "activity": [ { "at": "2026-11-25T15:02:11Z", "type": "login", "new_device": true }, { "at": "2026-11-25T15:04:40Z", "type": "password_reset" }, { "at": "2026-11-25T15:08:02Z", "type": "email_changed" }, { "at": "2026-11-25T15:09:30Z", "type": "payee_add_started" } ], "account": { "opened": "2019-04-02", "usual_login_city": "Columbus, OH", "usual_device": "iPhone 15", "email_last_changed": "2020-01-15" }, "device": { "os": "Windows 11", "browser": "Chrome 131", "seen_on_account": false }, "ip": { "address": "203.0.113.77", "city": "Lagos", "country": "NG", "network": "mobile" }, "other_context": "Customer called support at 15:30 to say they cannot log in" }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | --------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------- | | `activity` | Required | The session's events, in order, with timestamps. | | `account` | Optional | A description of the account, not an account ID: its age, the contact details on file, and how the customer usually signs in. | | `device` | Optional | A description of the device in use now: its type, its operating system, and whether this account has used it before. | | `ip` | Optional | The IP address with what your lookup says about it: country, city and network type. An address by itself says little. | | `next_action` | Optional | What the session is trying to do next. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 884, "questions": [ { "text": "Is this the first time the account has used this device?", "probability": 0.95 }, { "text": "Were the password and contact details changed within minutes of each other?", "probability": 0.94 }, { "text": "Is the login far from where the customer usually signs in?", "probability": 0.92 }, { "text": "Is the session about to move money or add a payee?", "probability": 0.86 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Is this the first time the account has used this device? 2. Were the password and contact details changed within minutes of each other? 3. Is the login far from where the customer usually signs in? 4. Is the session about to move money or add a payee? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | -------------------------------- | | Under 300 | Approve | Let the login or change through. | | 300 to 599 | Step up | Ask for a second factor. | | 600 to 849 | Review | Hold the change for an analyst. | | 850 or more | Block | Lock the session. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | --------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`activity`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Job applicant fraud (/score-api/endpoints/job-applicant-fraud) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Know the candidate is who they say they are.** Fake candidates use borrowed identities, copied résumés and stand-ins for interviews. Send the résumé and what you know about the application, and get a score before it reaches your hiring team. | Endpoint | Price | Group | | ------------------------------ | -------------- | ------------------- | | `POST /v1/score/job_applicant` | $0.01 per call | Identity & Accounts | ## Request [#request] Send what you know in one `context` object. `resume` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/job_applicant \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "resume": "Senior backend engineer, 9 years. Stripe 2019 to 2024, Google 2016 to 2019. BS, Stanford, 2018.", "application": { "role": "Senior Backend Engineer", "source": "job board", "applications_last_48h": 14, "same_cover_letter": true }, "location": "Austin, TX", "ip": { "address": "198.51.100.201", "proxy_type": "residential", "browser_timezone": "UTC+08:00" }, "contact": { "email_first_seen": "2026-11-20", "phone_type": "voip" }, "interview_notes": "Camera off, long pauses before answers, a second voice in the background" } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/job_applicant", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "resume": "Senior backend engineer, 9 years. Stripe 2019 to 2024, Google 2016 to 2019. BS, Stanford, 2018.", "application": { "role": "Senior Backend Engineer", "source": "job board", "applications_last_48h": 14, "same_cover_letter": True }, "location": "Austin, TX", "ip": { "address": "198.51.100.201", "proxy_type": "residential", "browser_timezone": "UTC+08:00" }, "contact": { "email_first_seen": "2026-11-20", "phone_type": "voip" }, "interview_notes": "Camera off, long pauses before answers, a second voice in the background" } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/job_applicant", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "resume": "Senior backend engineer, 9 years. Stripe 2019 to 2024, Google 2016 to 2019. BS, Stanford, 2018.", "application": { "role": "Senior Backend Engineer", "source": "job board", "applications_last_48h": 14, "same_cover_letter": true }, "location": "Austin, TX", "ip": { "address": "198.51.100.201", "proxy_type": "residential", "browser_timezone": "UTC+08:00" }, "contact": { "email_first_seen": "2026-11-20", "phone_type": "voip" }, "interview_notes": "Camera off, long pauses before answers, a second voice in the background" }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | ----------------- | -------- | --------------------------------------------------------------------------------------------------------------------- | | `resume` | Required | The full text of the résumé. | | `application` | Optional | How they applied: the role, the source, and other applications from the same person. | | `location` | Optional | Where the candidate says they live and work. | | `ip` | Optional | The IP address with what your lookup says about it: country, city and network type. An address by itself says little. | | `contact` | Optional | The email address and phone number, with their age and type if you know them. | | `interview_notes` | Optional | What interviewers saw and heard, in their words. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 889, "questions": [ { "text": "Is the applicant's network far from where they say they live?", "probability": 0.93 }, { "text": "Do the work history and education dates contradict each other?", "probability": 0.9 }, { "text": "Were the email address and phone number created recently?", "probability": 0.88 }, { "text": "Did the interview show signs of a stand-in?", "probability": 0.84 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Is the applicant's network far from where they say they live? 2. Do the work history and education dates contradict each other? 3. Were the email address and phone number created recently? 4. Did the interview show signs of a stand-in? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ---------------------------------- | | Under 300 | Approve | Move the candidate forward. | | 300 to 599 | Step up | Ask them to verify their identity. | | 600 to 849 | Review | Send to a recruiter to check. | | 850 or more | Block | Reject the application. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | ------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`resume`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Payments and orders (/score-api/endpoints/payments) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Approve more good orders. Pay for fewer chargebacks.** Score every order and payment before you fulfil it. Send the order, the customer and the addresses as you have them, and get a risk score in the same call. | Endpoint | Price | Group | | ------------------------ | --------------- | -------- | | `POST /v1/score/payment` | $0.005 per call | Payments | ## Request [#request] Send what you know in one `context` object. `order` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/payment \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "order": { "id": "ord_88213", "items": [{ "sku": "IPH16P-256", "name": "iPhone 16 Pro", "quantity": 3, "unit_price_usd": 1199 }], "total_usd": 3597, "shipping_method": "express" }, "customer": { "created": "2026-11-23", "previous_orders": 0, "email_verified": false }, "payment_method": { "brand": "visa", "funding": "credit", "issuer_country": "CA", "first_used": "2026-11-25" }, "billing_address": { "line1": "22 Maple St", "city": "Toronto", "region": "ON", "country": "CA" }, "shipping_address": { "line1": "1396 NW 82nd Ave", "line2": "Unit 4411", "city": "Doral", "region": "FL", "country": "US" }, "other_context": "Customer asked support to change the shipping address right after checkout" } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/payment", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "order": { "id": "ord_88213", "items": [{ "sku": "IPH16P-256", "name": "iPhone 16 Pro", "quantity": 3, "unit_price_usd": 1199 }], "total_usd": 3597, "shipping_method": "express" }, "customer": { "created": "2026-11-23", "previous_orders": 0, "email_verified": False }, "payment_method": { "brand": "visa", "funding": "credit", "issuer_country": "CA", "first_used": "2026-11-25" }, "billing_address": { "line1": "22 Maple St", "city": "Toronto", "region": "ON", "country": "CA" }, "shipping_address": { "line1": "1396 NW 82nd Ave", "line2": "Unit 4411", "city": "Doral", "region": "FL", "country": "US" }, "other_context": "Customer asked support to change the shipping address right after checkout" } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/payment", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "order": { "id": "ord_88213", "items": [{ "sku": "IPH16P-256", "name": "iPhone 16 Pro", "quantity": 3, "unit_price_usd": 1199 }], "total_usd": 3597, "shipping_method": "express" }, "customer": { "created": "2026-11-23", "previous_orders": 0, "email_verified": false }, "payment_method": { "brand": "visa", "funding": "credit", "issuer_country": "CA", "first_used": "2026-11-25" }, "billing_address": { "line1": "22 Maple St", "city": "Toronto", "region": "ON", "country": "CA" }, "shipping_address": { "line1": "1396 NW 82nd Ave", "line2": "Unit 4411", "city": "Doral", "region": "FL", "country": "US" }, "other_context": "Customer asked support to change the shipping address right after checkout" }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | ------------------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------ | | `order` | Required | What was bought: the items, quantities, total and delivery method. | | `customer` | Optional | A description of the customer, not a customer ID: the account's age, past orders, and the contact details on file. | | `payment_method` | Optional | A description of the card or payment method: its type, where it was issued, and how long this customer has used it. Never the card number. | | `billing_address` | Optional | The billing address, as written. | | `shipping_address` | Optional | The shipping address, as written. | | `ip` | Optional | The IP address with what your lookup says about it: country, city and network type. An address by itself says little. | | `device` | Optional | A description of the device: its type, its operating system, and whether this customer has used it before. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 871, "questions": [ { "text": "Does the shipping address look like a reshipper or freight forwarder?", "probability": 0.94 }, { "text": "Is the order unusually large for a new account?", "probability": 0.9 }, { "text": "Do the card and the shipping address point to different countries?", "probability": 0.88 }, { "text": "Are the items easy to resell?", "probability": 0.83 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Does the shipping address look like a reshipper or freight forwarder? 2. Is the order unusually large for a new account? 3. Do the card and the shipping address point to different countries? 4. Are the items easy to resell? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ------------------------------- | | Under 300 | Approve | Fulfil the order. | | 300 to 599 | Step up | Ask for 3-D Secure. | | 600 to 849 | Review | Hold fulfilment for an analyst. | | 850 or more | Block | Cancel and refund. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | ------------------------------------------------------------------------------------------------------------ | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`order`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Payouts and withdrawals (/score-api/endpoints/payouts) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Hold the risky payout. Release the rest at once.** Score withdrawals, transfers and push payments before the money leaves. Send the payout, the payee and what led up to it, and hold the risky ones. | Endpoint | Price | Group | | ----------------------- | --------------- | -------- | | `POST /v1/score/payout` | $0.005 per call | Payments | ## Request [#request] Send what you know in one `context` object. `payout` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/payout \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "payout": { "amount_usd": 3000, "type": "push_payment" }, "payee": { "added": "2026-11-25T14:55:12Z", "account_type": "personal", "same_bank": false, "paid_by_other_customers": 0 }, "account": { "opened": "2021-06-11", "balance_usd": 3150, "median_transfer_usd": 120, "largest_transfer_usd": 210 }, "recent_activity": "timestamp,event,detail\n2026-11-25T14:41:07Z,password_reset,new device\n2026-11-25T14:52:30Z,internal_transfer,2900 USD from savings\n2026-11-25T14:55:12Z,payee_added," } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/payout", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "payout": { "amount_usd": 3000, "type": "push_payment" }, "payee": { "added": "2026-11-25T14:55:12Z", "account_type": "personal", "same_bank": False, "paid_by_other_customers": 0 }, "account": { "opened": "2021-06-11", "balance_usd": 3150, "median_transfer_usd": 120, "largest_transfer_usd": 210 }, "recent_activity": "timestamp,event,detail\n2026-11-25T14:41:07Z,password_reset,new device\n2026-11-25T14:52:30Z,internal_transfer,2900 USD from savings\n2026-11-25T14:55:12Z,payee_added," } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/payout", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "payout": { "amount_usd": 3000, "type": "push_payment" }, "payee": { "added": "2026-11-25T14:55:12Z", "account_type": "personal", "same_bank": false, "paid_by_other_customers": 0 }, "account": { "opened": "2021-06-11", "balance_usd": 3150, "median_transfer_usd": 120, "largest_transfer_usd": 210 }, "recent_activity": "timestamp,event,detail\n2026-11-25T14:41:07Z,password_reset,new device\n2026-11-25T14:52:30Z,internal_transfer,2900 USD from savings\n2026-11-25T14:55:12Z,payee_added," }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | ----------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------- | | `payout` | Required | The amount, the type of payment, and how it compares with what the account usually sends. | | `payee` | Optional | A description of the payee, not a payee ID: when they were added, their bank and country, and whether other customers pay them. | | `account` | Optional | A description of the account, not an account ID: its age, its usual balance and its usual payouts. | | `recent_activity` | Optional | What happened on the account before the payout, in order, with times. | | `device` | Optional | A description of the device: its type, its operating system, and whether this account has used it before. | | `ip` | Optional | The IP address with what your lookup says about it: country, city and network type. An address by itself says little. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 951, "questions": [ { "text": "Was the payee added shortly before the payout?", "probability": 0.97 }, { "text": "Is the amount far above what the customer usually sends?", "probability": 0.92 }, { "text": "Did a password reset or a new device come just before?", "probability": 0.9 }, { "text": "Was money gathered from other accounts first?", "probability": 0.87 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Was the payee added shortly before the payout? 2. Is the amount far above what the customer usually sends? 3. Did a password reset or a new device come just before? 4. Was money gathered from other accounts first? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | -------------------------- | | Under 300 | Approve | Send the payout. | | 300 to 599 | Step up | Confirm with the customer. | | 600 to 849 | Review | Hold for an analyst. | | 850 or more | Block | Stop the payout. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | ------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`payout`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Real-time scam detection (/score-api/endpoints/scam-detection) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Stop the scam while the customer is still in the app.** In a scam, the real customer sends the money, so the login looks normal. Send the payment, the payee and what the customer says it is for, and get a score for how likely they are being scammed. | Endpoint | Price | Group | | --------------------- | --------------- | -------- | | `POST /v1/score/scam` | $0.005 per call | Payments | ## Request [#request] Send what you know in one `context` object. `payment` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/scam \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "payment": { "amount_usd": 8500, "type": "bank_transfer", "first_payment_to_payee": true }, "purpose": "Crypto investment, my advisor says the window closes today", "payee": { "account_type": "personal", "account_opened": "2026-11-04", "added": "2026-11-25" }, "customer": { "age": 71, "customer_since": 1996, "median_payment_usd": 140 }, "session": [ { "at": "2026-11-25T11:02:10Z", "event": "app_backgrounded", "count": 4 }, { "at": "2026-11-25T11:06:31Z", "event": "account_number_pasted" }, { "at": "2026-11-25T11:07:02Z", "event": "scam_warning_dismissed", "seconds_shown": 2 } ] } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/scam", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "payment": { "amount_usd": 8500, "type": "bank_transfer", "first_payment_to_payee": True }, "purpose": "Crypto investment, my advisor says the window closes today", "payee": { "account_type": "personal", "account_opened": "2026-11-04", "added": "2026-11-25" }, "customer": { "age": 71, "customer_since": 1996, "median_payment_usd": 140 }, "session": [ { "at": "2026-11-25T11:02:10Z", "event": "app_backgrounded", "count": 4 }, { "at": "2026-11-25T11:06:31Z", "event": "account_number_pasted" }, { "at": "2026-11-25T11:07:02Z", "event": "scam_warning_dismissed", "seconds_shown": 2 } ] } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/scam", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "payment": { "amount_usd": 8500, "type": "bank_transfer", "first_payment_to_payee": true }, "purpose": "Crypto investment, my advisor says the window closes today", "payee": { "account_type": "personal", "account_opened": "2026-11-04", "added": "2026-11-25" }, "customer": { "age": 71, "customer_since": 1996, "median_payment_usd": 140 }, "session": [ { "at": "2026-11-25T11:02:10Z", "event": "app_backgrounded", "count": 4 }, { "at": "2026-11-25T11:06:31Z", "event": "account_number_pasted" }, { "at": "2026-11-25T11:07:02Z", "event": "scam_warning_dismissed", "seconds_shown": 2 } ] }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | --------------- | -------- | ------------------------------------------------------------------------------------------------------------------------ | | `payment` | Required | The amount, the type of payment, and how it compares with what the customer usually sends. | | `purpose` | Optional | What the customer says the payment is for, in their own words. | | `payee` | Optional | A description of the payee, not a payee ID: when they were added, the type of account, and how long it has been open. | | `customer` | Optional | A description of the customer, not a customer ID: their age, how long they have been with you, and their usual payments. | | `session` | Optional | What the customer did in the app before paying: the session's events, in order. | | `messages` | Optional | The text of messages the customer shared or received. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 928, "questions": [ { "text": "Is this a first payment to the payee, and far above the customer's usual?", "probability": 0.96 }, { "text": "Does the stated purpose read like an investment, romance or impersonation scam?", "probability": 0.95 }, { "text": "Did the customer go past a scam warning?", "probability": 0.93 }, { "text": "Is someone else rushing the customer?", "probability": 0.91 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Is this a first payment to the payee, and far above the customer's usual? 2. Does the stated purpose read like an investment, romance or impersonation scam? 3. Did the customer go past a scam warning? 4. Is someone else rushing the customer? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ------------------------------------------ | | Under 300 | Approve | Send the payment. | | 300 to 599 | Step up | Warn the customer and ask them to confirm. | | 600 to 849 | Review | Hold the payment and call the customer. | | 850 or more | Block | Stop the payment. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | -------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`payment`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Merchant monitoring (/score-api/endpoints/merchant-monitoring) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Know when a merchant stops being the business you approved.** Send a merchant's name and website. Finic reads the site for you, compares it with what the business told you, and scores it at onboarding and again whenever you ask. | Endpoint | Price | Group | | ------------------------- | -------------- | ---------------- | | `POST /v1/score/merchant` | $0.10 per call | KYB & Compliance | ## Request [#request] Send what you know in one `context` object. `name` and `website` are required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/merchant \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "name": "Northwind Wellness LLC", "website": "https://northwindwellness.example", "declared_business": { "category": "vitamins and supplements", "mcc": "5499", "approved": "2026-03-14" }, "sales": "month,volume_usd,average_ticket_usd\n2026-09,41000,38\n2026-10,96000,120\n2026-11,372000,410", "refunds_and_chargebacks": { "chargeback_rate": 0.019, "chargeback_rate_90_days_ago": 0.002 } } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/merchant", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "name": "Northwind Wellness LLC", "website": "https://northwindwellness.example", "declared_business": { "category": "vitamins and supplements", "mcc": "5499", "approved": "2026-03-14" }, "sales": "month,volume_usd,average_ticket_usd\n2026-09,41000,38\n2026-10,96000,120\n2026-11,372000,410", "refunds_and_chargebacks": { "chargeback_rate": 0.019, "chargeback_rate_90_days_ago": 0.002 } } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/merchant", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "name": "Northwind Wellness LLC", "website": "https://northwindwellness.example", "declared_business": { "category": "vitamins and supplements", "mcc": "5499", "approved": "2026-03-14" }, "sales": "month,volume_usd,average_ticket_usd\n2026-09,41000,38\n2026-10,96000,120\n2026-11,372000,410", "refunds_and_chargebacks": { "chargeback_rate": 0.019, "chargeback_rate_90_days_ago": 0.002 } }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | ------------------------- | -------- | ----------------------------------------------------------------------------------------- | | `name` | Required | The merchant's legal or trading name. | | `website` | Required | The address of its website. Finic reads the site for you, so you don't send its contents. | | `declared_business` | Optional | What the merchant told you it sells, its category, and when you approved it. | | `sales` | Optional | Recent volume and ticket sizes, and how they have changed. | | `refunds_and_chargebacks` | Optional | Recent refunds and chargebacks, as counts or as a share of sales. | | `owners` | Optional | The owners, with their roles and what you know about their other businesses. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## What Finic adds [#what-finic-adds] Finic adds these fields to the context before it scores, so you do not send them: | Field | Description | | ----------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `website_content` | What Finic read on the merchant's website: the home page's address after redirects, its title, its description and its visible text, with up to three pages it links to on the same site (what the site sells, who runs it, and its terms), or why the site couldn't be read (for example, the domain doesn't exist). | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 838, "questions": [ { "text": "Does what the merchant sells now differ from what it described at onboarding?", "probability": 0.95 }, { "text": "Did sales grow far faster than the merchant's history?", "probability": 0.93 }, { "text": "Are chargebacks rising as a share of sales?", "probability": 0.9 }, { "text": "Does the site sell products that card networks restrict?", "probability": 0.89 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Does what the merchant sells now differ from what it described at onboarding? 2. Did sales grow far faster than the merchant's history? 3. Are chargebacks rising as a share of sales? 4. Does the site sell products that card networks restrict? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | -------------------- | | Under 300 | Approve | Keep processing. | | 300 to 599 | Step up | Ask for documents. | | 600 to 849 | Review | Hold for an analyst. | | 850 or more | Block | Pause payouts. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | ---------------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`name`, `website`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Customer risk rating (/score-api/endpoints/customer-risk-rating) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **A risk rating for every customer, kept up to date.** Rate each customer at onboarding, and again whenever something changes. Send the profile, the purpose of the account and recent activity, and get a rating with reasons you can show an auditor. | Endpoint | Price | Group | | ------------------------------ | -------------- | ---------------- | | `POST /v1/score/customer_risk` | $0.01 per call | KYB & Compliance | ## Request [#request] Send what you know in one `context` object. `customer` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/customer_risk \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "customer": { "name": "Halcyon Trading FZE", "type": "business", "industry": "general trading", "incorporated": "2025-02-10", "country": "AE" }, "owners": [{ "name": "R. Haddad", "role": "sole owner", "other_directorships": 11 }], "account_purpose": "Paying suppliers in Asia, about $50,000 a month", "source_of_funds": "Sales revenue. No financial statements provided yet.", "activity": "date,direction,amount_usd,counterparty\n2026-11-03,in,250000,Third party A\n2026-11-04,out,249500,Supplier in Hong Kong\n2026-11-10,in,400000,Third party B\n2026-11-11,out,399000,Supplier in Hong Kong" } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/customer_risk", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "customer": { "name": "Halcyon Trading FZE", "type": "business", "industry": "general trading", "incorporated": "2025-02-10", "country": "AE" }, "owners": [{ "name": "R. Haddad", "role": "sole owner", "other_directorships": 11 }], "account_purpose": "Paying suppliers in Asia, about $50,000 a month", "source_of_funds": "Sales revenue. No financial statements provided yet.", "activity": "date,direction,amount_usd,counterparty\n2026-11-03,in,250000,Third party A\n2026-11-04,out,249500,Supplier in Hong Kong\n2026-11-10,in,400000,Third party B\n2026-11-11,out,399000,Supplier in Hong Kong" } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/customer_risk", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "customer": { "name": "Halcyon Trading FZE", "type": "business", "industry": "general trading", "incorporated": "2025-02-10", "country": "AE" }, "owners": [{ "name": "R. Haddad", "role": "sole owner", "other_directorships": 11 }], "account_purpose": "Paying suppliers in Asia, about $50,000 a month", "source_of_funds": "Sales revenue. No financial statements provided yet.", "activity": "date,direction,amount_usd,counterparty\n2026-11-03,in,250000,Third party A\n2026-11-04,out,249500,Supplier in Hong Kong\n2026-11-10,in,400000,Third party B\n2026-11-11,out,399000,Supplier in Hong Kong" }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | --------------------- | -------- | ------------------------------------------------------------------------------------------------ | | `customer` | Required | A description of the person or business, not a customer ID: what they do, where, and since when. | | `owners` | Optional | The owners and controllers, with their roles and other businesses. | | `account_purpose` | Optional | What the customer says the account is for, and the volume they expect. | | `source_of_funds` | Optional | Where the customer says the money comes from, and what supports it. | | `activity` | Optional | Recent transactions, listed or summarized: amounts, counterparties and timing. | | `kyc` | Optional | What your identity and business checks found, written out. Not just pass or fail. | | `adverse_information` | Optional | The text of news or records about the customer. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 812, "questions": [ { "text": "Is the activity out of line with the stated purpose of the account?", "probability": 0.94 }, { "text": "Does money leave soon after it arrives?", "probability": 0.92 }, { "text": "Is the source of funds left unexplained?", "probability": 0.8 }, { "text": "Is this a type of business with a higher risk of money laundering?", "probability": 0.71 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Is the activity out of line with the stated purpose of the account? 2. Does money leave soon after it arrives? 3. Is the source of funds left unexplained? 4. Is this a type of business with a higher risk of money laundering? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ----------------------------- | | Under 300 | Approve | Rate as low risk. | | 300 to 599 | Step up | Ask for more information. | | 600 to 849 | Review | Send to a compliance analyst. | | 850 or more | Block | Decline or close the account. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | --------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`customer`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Sanctions screening (/score-api/endpoints/sanctions-screening) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Clear the false matches. Catch the true ones.** Send a name, and Finic checks it against its own sanctions lists and scores how likely each possible match is the same person. Analysts see the likely matches with the reason, not every similar name. | Endpoint | Price | Group | | ------------------------------------ | -------------- | ---------------- | | `POST /v1/score/sanctions_screening` | $0.05 per call | KYB & Compliance | ## Request [#request] Send what you know in one `context` object. `name` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/sanctions_screening \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "name": "Mohammed Al-Hassan", "date_of_birth": "1989-03-14", "country": { "residence": "GB", "birth": "GB", "citizenship": "GB" } } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/sanctions_screening", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "name": "Mohammed Al-Hassan", "date_of_birth": "1989-03-14", "country": { "residence": "GB", "birth": "GB", "citizenship": "GB" } } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/sanctions_screening", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "name": "Mohammed Al-Hassan", "date_of_birth": "1989-03-14", "country": { "residence": "GB", "birth": "GB", "citizenship": "GB" } }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | --------------- | -------- | --------------------------------------------------------------------------------------- | | `name` | Required | The full name you are screening, as written. | | `date_of_birth` | Optional | Their date of birth. | | `country` | Optional | Their countries of residence, birth and citizenship. | | `address` | Optional | Their address, as written. | | `payment` | Optional | A description of the payment being screened: the amount, the parties and the countries. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## What Finic adds [#what-finic-adds] Finic adds these fields to the context before it scores, so you do not send them: | Field | Description | | -------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `list_matches` | The sanctions list entries whose name or alias came closest to the name screened, closest first, from the US (OFAC SDN and Consolidated), UN Security Council, EU and UK sanctions lists (a person on several lists is an entry on each): each with its list, name, type, programs, aliases, dates and places of birth, nationalities, citizenships, the countries of its addresses, the name that matched and how closely (0 to 1). The questions compare the person with these entries. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. `matches` is only in this use case's response. ```json title="200 OK" { "score": 64, "matches": [ { "name": "AL-HASAN, Muhammad Ali", "born": "1971, Syria", "aliases": [ "Abu Ali" ] } ], "questions": [ { "text": "Do the names differ only by spelling or transliteration?", "probability": 0.92 }, { "text": "Do the countries agree?", "probability": 0.05 }, { "text": "Does an alias match?", "probability": 0.04 }, { "text": "Do the dates of birth agree?", "probability": 0.03 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Do the names differ only by spelling or transliteration? 2. Do the countries agree? 3. Does an alias match? 4. Do the dates of birth agree? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | --------------------------------------- | | Under 300 | Approve | Clear it and continue. | | 300 to 599 | Step up | Ask for a date of birth or an ID. | | 600 to 849 | Review | Hold for a compliance analyst. | | 850 or more | Block | Stop the payment or freeze the account. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | ----------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`name`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Policy abuse (/score-api/endpoints/policy-abuse) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Keep your offers for the customers they were meant for.** Promo codes, free trials, refunds and returns are abused by people who look like customers. Send the claim with the customer's history, and get a score before you honor it. | Endpoint | Price | Group | | ----------------------------- | --------------- | -------------- | | `POST /v1/score/policy_abuse` | $0.002 per call | Policy & Abuse | ## Request [#request] Send what you know in one `context` object. `claim` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/policy_abuse \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "claim": { "type": "refund", "reason": "item_not_received", "amount_usd": 240, "customer_message": "Package never showed up, I want my money back" }, "order": { "id": "1150", "items": "2 x wireless headphones", "total_usd": 240, "tracking": { "status": "delivered", "signed_by": "resident", "delivered": "2026-11-12" } }, "history": "order,total_usd,claim\n1041,89,item_not_received\n1077,310,item_not_received\n1102,45,\n1150,240,item_not_received", "customer": { "created": "2026-08-20", "linked_accounts": [{ "id": "cus_4471", "status": "closed_for_abuse" }, { "id": "cus_5120", "status": "closed_for_abuse" }] } } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/policy_abuse", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "claim": { "type": "refund", "reason": "item_not_received", "amount_usd": 240, "customer_message": "Package never showed up, I want my money back" }, "order": { "id": "1150", "items": "2 x wireless headphones", "total_usd": 240, "tracking": { "status": "delivered", "signed_by": "resident", "delivered": "2026-11-12" } }, "history": "order,total_usd,claim\n1041,89,item_not_received\n1077,310,item_not_received\n1102,45,\n1150,240,item_not_received", "customer": { "created": "2026-08-20", "linked_accounts": [{ "id": "cus_4471", "status": "closed_for_abuse" }, { "id": "cus_5120", "status": "closed_for_abuse" }] } } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/policy_abuse", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "claim": { "type": "refund", "reason": "item_not_received", "amount_usd": 240, "customer_message": "Package never showed up, I want my money back" }, "order": { "id": "1150", "items": "2 x wireless headphones", "total_usd": 240, "tracking": { "status": "delivered", "signed_by": "resident", "delivered": "2026-11-12" } }, "history": "order,total_usd,claim\n1041,89,item_not_received\n1077,310,item_not_received\n1102,45,\n1150,240,item_not_received", "customer": { "created": "2026-08-20", "linked_accounts": [{ "id": "cus_4471", "status": "closed_for_abuse" }, { "id": "cus_5120", "status": "closed_for_abuse" }] } }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | --------------- | -------- | -------------------------------------------------------------------------------------------------------------------- | | `claim` | Required | The refund, return or promotion being claimed, with the reason and the customer's own words. | | `order` | Optional | A description of the order, not an order ID: the items, the total, and what tracking shows. | | `history` | Optional | The customer's earlier orders and claims, with the reason for each claim. | | `customer` | Optional | A description of the customer, not a customer ID: the account's age, its addresses, and any links to other accounts. | | `policy` | Optional | The policy the claim falls under, written out. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 902, "questions": [ { "text": "Does the carrier show the order as delivered?", "probability": 0.96 }, { "text": "Does this customer ask for refunds far more often than is usual?", "probability": 0.93 }, { "text": "Do the earlier claims give the same reason?", "probability": 0.88 }, { "text": "Is the customer linked to accounts closed for abuse?", "probability": 0.85 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Does the carrier show the order as delivered? 2. Does this customer ask for refunds far more often than is usual? 3. Do the earlier claims give the same reason? 4. Is the customer linked to accounts closed for abuse? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ------------------ | | Under 300 | Approve | Honor the claim. | | 300 to 599 | Step up | Ask for proof. | | 600 to 849 | Review | Hold for an agent. | | 850 or more | Block | Decline the claim. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | ------------------------------------------------------------------------------------------------------------ | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`claim`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Content moderation (/score-api/endpoints/content-moderation) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Decide every post, listing and message by your own policies.** Score every post, listing and message against your policy. Send the content with the policy it should follow, and get a score for how likely it breaks it. | Endpoint | Price | Group | | ------------------------ | --------------- | -------------- | | `POST /v1/score/content` | $0.002 per call | Policy & Abuse | ## Request [#request] Send what you know in one `context` object. `content` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/content \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "content": "Message me on Telegram @fastcash88 to pay, I cannot take payment here. 50% off if you send a gift card", "policy": "No moving payment off the platform. No gift cards as payment.", "author": { "account_created": "2026-11-25", "messages_sent_today": 40, "distinct_recipients": 40, "prior_removals": 0 }, "context": { "surface": "direct_message", "listing_title": "Dell XPS 13 laptop, like new", "in_reply_to": "Is this still available?" } } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/content", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "content": "Message me on Telegram @fastcash88 to pay, I cannot take payment here. 50% off if you send a gift card", "policy": "No moving payment off the platform. No gift cards as payment.", "author": { "account_created": "2026-11-25", "messages_sent_today": 40, "distinct_recipients": 40, "prior_removals": 0 }, "context": { "surface": "direct_message", "listing_title": "Dell XPS 13 laptop, like new", "in_reply_to": "Is this still available?" } } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/content", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "content": "Message me on Telegram @fastcash88 to pay, I cannot take payment here. 50% off if you send a gift card", "policy": "No moving payment off the platform. No gift cards as payment.", "author": { "account_created": "2026-11-25", "messages_sent_today": 40, "distinct_recipients": 40, "prior_removals": 0 }, "context": { "surface": "direct_message", "listing_title": "Dell XPS 13 laptop, like new", "in_reply_to": "Is this still available?" } }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | --------------- | -------- | --------------------------------------------------------------------------------------------------------------------- | | `content` | Required | The full text of the post, listing or message. | | `policy` | Optional | The rules the content should follow, written out. Not a policy ID. | | `author` | Optional | A description of the author, not a user ID: the account's age, what they have posted before, and any earlier reports. | | `context` | Optional | Where the content appears, and the text it replies to. | | `reports` | Optional | What other users reported, in their words. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 947, "questions": [ { "text": "Does the message ask the reader to pay or talk somewhere else?", "probability": 0.97 }, { "text": "Does it ask for payment by gift card?", "probability": 0.96 }, { "text": "Is the author sending the same kind of message to many people?", "probability": 0.9 }, { "text": "Does it threaten or harass a person?", "probability": 0.02 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Does the message ask the reader to pay or talk somewhere else? 2. Does it ask for payment by gift card? 3. Is the author sending the same kind of message to many people? 4. Does it threaten or harass a person? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ---------------------------------- | | Under 300 | Approve | Publish it. | | 300 to 599 | Step up | Publish with a warning or a limit. | | 600 to 849 | Review | Hold for a moderator. | | 850 or more | Block | Remove it. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | -------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`content`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # AI agent and bot detection (/score-api/endpoints/bot-detection) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Tell the agents that work for your customers from the bots that attack them.** Some automated traffic is a customer's own agent placing an order. Some is a script testing stolen cards. Describe the session, and get a score for how likely it is automated abuse. | Endpoint | Price | Group | | -------------------- | --------------- | -------------- | | `POST /v1/score/bot` | $0.002 per call | Policy & Abuse | ## Request [#request] Send what you know in one `context` object. `session` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/bot \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "session": { "duration_seconds": 60, "checkout_attempts": 42, "distinct_cards": 42, "pointer_events": 0, "median_ms_between_actions": 140 }, "user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/126.0.0.0 Safari/537.36", "ip": { "address": "192.0.2.146", "type": "datacenter", "city": "Ashburn", "region": "VA", "sessions_today": 300 }, "account": { "signed_in": false, "checkout": "guest" }, "device": { "webdriver": true, "plugins": 0, "screen": "800x600" } } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/bot", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "session": { "duration_seconds": 60, "checkout_attempts": 42, "distinct_cards": 42, "pointer_events": 0, "median_ms_between_actions": 140 }, "user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/126.0.0.0 Safari/537.36", "ip": { "address": "192.0.2.146", "type": "datacenter", "city": "Ashburn", "region": "VA", "sessions_today": 300 }, "account": { "signed_in": False, "checkout": "guest" }, "device": { "webdriver": True, "plugins": 0, "screen": "800x600" } } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/bot", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "session": { "duration_seconds": 60, "checkout_attempts": 42, "distinct_cards": 42, "pointer_events": 0, "median_ms_between_actions": 140 }, "user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/126.0.0.0 Safari/537.36", "ip": { "address": "192.0.2.146", "type": "datacenter", "city": "Ashburn", "region": "VA", "sessions_today": 300 }, "account": { "signed_in": false, "checkout": "guest" }, "device": { "webdriver": true, "plugins": 0, "screen": "800x600" } }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | ---------------- | -------- | --------------------------------------------------------------------------------------------------------------------------- | | `session` | Required | What the session did: its events or its counts, with timings. | | `user_agent` | Optional | The full user agent string, with any client hints. | | `ip` | Optional | The IP address with what your lookup says about it: country, city and network type. An address by itself says little. | | `account` | Optional | A description of the account in use, not an account ID: its age, its history, and whether the customer has set up an agent. | | `declared_agent` | Optional | What the client says it is, if it identifies itself as an agent, and who it says it acts for. | | `device` | Optional | A description of the device: its fingerprint traits, and the other sessions seen on it. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 968, "questions": [ { "text": "Are actions arriving faster than a person could click?", "probability": 0.97 }, { "text": "Is one client trying many cards or accounts?", "probability": 0.96 }, { "text": "Does the browser report traits of an automation tool?", "probability": 0.94 }, { "text": "Is this an agent acting for a signed-in customer?", "probability": 0.04 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Are actions arriving faster than a person could click? 2. Is one client trying many cards or accounts? 3. Does the browser report traits of an automation tool? 4. Is this an agent acting for a signed-in customer? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | -------------------------------- | | Under 300 | Approve | Let the session go on. | | 300 to 599 | Step up | Show a challenge. | | 600 to 849 | Review | Flag the session for an analyst. | | 850 or more | Block | End the session. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | -------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`session`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # AI token fraud (/score-api/endpoints/ai-token-fraud) {/* Written by scripts/build-use-cases.mjs from internal/usecases/catalog.json and use-cases/site.json. Change those, not this file. */} **Stop paying for tokens that fraudsters use.** Free credits, stolen cards and leaked keys all end up as compute you pay for. Send the sign-up, top-up or jump in usage, and get a score before you grant the credits. | Endpoint | Price | Group | | ------------------------------- | --------------- | -------------- | | `POST /v1/score/ai_token_fraud` | $0.002 per call | Policy & Abuse | ## Request [#request] Send what you know in one `context` object. `activity` is required; every other field is optional. A field can hold text, JSON or CSV. ```bash curl https://api.finic.ai/v1/score/ai_token_fraud \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "context": { "activity": [ { "at": "2026-11-25T09:00:02Z", "type": "signup" }, { "at": "2026-11-25T09:04:10Z", "type": "credit_purchase", "amount_usd": 2000 }, { "at": "2026-11-25T09:05:47Z", "type": "api_keys_created", "count": 12 } ], "account": { "email_domain_registered": "2026-11-24", "lifetime_spend_usd": 0 }, "payment_method": { "brand": "mastercard", "issuer_country": "BR", "billing_zip_match": false }, "usage": "hour,requests,distinct_ips\n01:00,18200,58\n02:00,17900,61\n03:00,18400,60", "device": { "fingerprint": "fp_9c41e0", "accounts_with_free_credits": 9 } } }' ``` ```python import os import requests response = requests.post( "https://api.finic.ai/v1/score/ai_token_fraud", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, json={ "context": { "activity": [ { "at": "2026-11-25T09:00:02Z", "type": "signup" }, { "at": "2026-11-25T09:04:10Z", "type": "credit_purchase", "amount_usd": 2000 }, { "at": "2026-11-25T09:05:47Z", "type": "api_keys_created", "count": 12 } ], "account": { "email_domain_registered": "2026-11-24", "lifetime_spend_usd": 0 }, "payment_method": { "brand": "mastercard", "issuer_country": "BR", "billing_zip_match": False }, "usage": "hour,requests,distinct_ips\n01:00,18200,58\n02:00,17900,61\n03:00,18400,60", "device": { "fingerprint": "fp_9c41e0", "accounts_with_free_credits": 9 } } }, timeout=30, ) response.raise_for_status() print(response.json()["score"]) ``` ```ts const response = await fetch("https://api.finic.ai/v1/score/ai_token_fraud", { method: "POST", headers: { Authorization: `Bearer ${process.env.FINIC_API_KEY}`, "Content-Type": "application/json", }, body: JSON.stringify({ context: { "activity": [ { "at": "2026-11-25T09:00:02Z", "type": "signup" }, { "at": "2026-11-25T09:04:10Z", "type": "credit_purchase", "amount_usd": 2000 }, { "at": "2026-11-25T09:05:47Z", "type": "api_keys_created", "count": 12 } ], "account": { "email_domain_registered": "2026-11-24", "lifetime_spend_usd": 0 }, "payment_method": { "brand": "mastercard", "issuer_country": "BR", "billing_zip_match": false }, "usage": "hour,requests,distinct_ips\n01:00,18200,58\n02:00,17900,61\n03:00,18400,60", "device": { "fingerprint": "fp_9c41e0", "accounts_with_free_credits": 9 } }, }), }); const { score, questions } = await response.json(); ``` ## Fields you send [#fields-you-send] Send the details, not only an ID: an account ID tells the score nothing, but the account's age, profile and history do. Fields that are not in this list are also read. | Field | | Description | | ---------------- | -------- | --------------------------------------------------------------------------------------------------------------------------------- | | `activity` | Required | The sign-up, top-up or usage you want scored: the events, with amounts and timestamps. | | `account` | Optional | A description of the account, not an account ID: its age, its email domain, its plan and what it has spent. | | `payment_method` | Optional | A description of the card or payment method: its type, where it was issued, and whether its details agree. Never the card number. | | `usage` | Optional | How the account's keys are used: the volume, the networks the requests come from, and the hours. | | `device` | Optional | A description of the device: its fingerprint traits, and the other accounts seen on it. | | `ip` | Optional | The IP address with what your lookup says about it: country, city and network type. An address by itself says little. | | `other_context` | Optional | Any other information, structured or unstructured, that is useful for scoring. | ## Response [#response] `score` runs from 0, the lowest risk, to 1000, the highest. `questions` are the yes/no questions behind it, each with the probability that the answer is yes. ```json title="200 OK" { "score": 941, "questions": [ { "text": "Is a new account spending far more than new accounts usually do?", "probability": 0.95 }, { "text": "Is the same device behind several accounts that claimed free credits?", "probability": 0.94 }, { "text": "Do the card's details disagree with each other?", "probability": 0.89 }, { "text": "Does the usage look like access being resold?", "probability": 0.87 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` ## The questions behind the score [#the-questions-behind-the-score] 1. Is a new account spending far more than new accounts usually do? 2. Is the same device behind several accounts that claimed free credits? 3. Do the card's details disagree with each other? 4. Does the usage look like access being resold? Every organization gets the same questions for this score. To use your own questions, or to calibrate a score to your own outcomes, copy it to a [custom scoring model](/score-model) in the Finic app (Starter plan and above). ## Turn the score into an action [#turn-the-score-into-an-action] These thresholds are examples. Choose your own, and change them as you learn. | Score | Action | Example | | ----------- | ------- | ---------------------------------------- | | Under 300 | Approve | Grant the credits or serve the request. | | 300 to 599 | Step up | Ask for a card or a phone number. | | 600 to 849 | Review | Limit usage and hold for an analyst. | | 850 or more | Block | Suspend the account and revoke its keys. | ## Errors [#errors] | Status | `type` | When | | ------ | ---------------------- | --------------------------------------------------------------------------------------------------------------- | | 400 | `invalid_request` | `context` is missing, is not a JSON object, or a required field (`activity`) is empty. `param` names the field. | | 401 | `authentication_error` | The API key is missing or not valid. | | 402 | `insufficient_credit` | The organization has no credit. Add credit in the Finic app. | | 429 | `rate_limited` | Too many requests. Retry with exponential backoff. | See the [API reference](/reference) for every error and limit, and [Pricing](/pricing) for what a call costs. # Scoring models (/score-model) A scoring model rates the risk of one kind of decision, such as a payment, a sign-up or a loan application. It scores a record by asking Grayson a few yes/no questions about it and weighing the answers. Score each record with [`POST /v1/score`](/reference/score/score) and a `score_id` of your own, unique within the scoring model. Scores run from 0 (lowest risk) to 1000 (highest). Once a scoring model is calibrated, a score divided by 1,000 is about the chance the outcome is bad: about 1 in 4 records scored near 250 turn out bad. Before then, scores rank records, but their scale is an estimate. See [Calibration](/score-model/calibration). ## Creating a scoring model [#creating-a-scoring-model] Create one with [`POST /v1/score/models`](/reference/score/create-scoring-model), from either: * **Its criteria:** `name` and `criteria` (what the decision is and what a bad outcome means). It's ready at once, with no questions: add your own to start scoring, or [calibrate](/score-model/calibration) it with labeled records and Finic writes its questions. * **Labeled records:** `name` and `data`. It's calibrated from the start, in about two minutes. ```bash curl https://api.finic.ai/v1/score/models \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"name": "Card-not-present payment fraud", "criteria": "Card-not-present payments at an online store. Bad: the payment was charged back as fraud within 90 days."}' ``` Rename it, change its criteria or archive it with [`update_model`](/reference/score/update-scoring-model). ## Labeled records [#labeled-records] Labeled records are past records with `is_bad`: `true` when the outcome was bad, `false` when it was good. Send them as a JSON array of objects, or as CSV with a header row: ```csv title="labeled.csv" amount_usd,merchant_category,account_age_days,new_device,billing_country,ip_country,is_bad 2400.00,electronics,19,true,US,NG,true 58.12,grocery,1260,false,US,US,false 310.00,gift_cards,3,true,US,US,true ``` * **At least 100 rows, with 20 of each outcome.** Up to 2,000 are used; the request can be up to 2 MB, and each row up to 60,000 bytes. * **`is_bad`** is `true` or `false`, `1` or `0`, or `"yes"` or `"no"`. * **In CSV,** an empty cell is `null`, and a dotted column name such as `merchant.category` is a nested field. * **Send the fields you'll score with,** and only what was known at the time of the decision. ## Schema [#schema] A scoring model's first calibration records the fields of its labeled records and their types. Records you score are checked against them, and rejected with `400 schema_mismatch` if they differ. Send `skip_schema_validation: true` to score one anyway, or `update_schema: true` to make its fields the new schema. Until its first calibration, a scoring model takes any record. ## Questions and weights [#questions-and-weights] [`GET /v1/score/models/{model_id}`](/reference/score/get-scoring-model) lists the questions a scoring model uses, strongest first: ```json title="200 (questions only)" "questions": [ { "id": "q004", "text": "This record is a card payment. Is the IP address in a different country from the billing address?", "source": "finic", "weight": 0.91 }, { "id": "q051", "text": "Was the account opened less than a week before the payment?", "source": "user", "weight": 0.38 } ] ``` `weight` is how much a question moves the score: positive when a likely yes raises it. Before the first calibration, it's Finic's estimate. `source` is `finic` or `user`. To see the answers behind one score, send `include_questions: true` to [`POST /v1/score`](/reference/score/score). ## Changing questions [#changing-questions] Add your own yes/no questions with [`add_questions`](/reference/score/add-questions), and remove them with [`remove_question`](/reference/score/remove-question). Before a scoring model is calibrated, a question you add counts right away. After, it's tried at the next calibration, which uses it if it helps. To remove a question the calibrated score uses, calibrate with `remove_questions`. ## Weights [#weights] Each question the score uses has one weight: how far a likely yes moves the score. Positive raises it, negative lowers it, and the larger the number the more the question counts. [`get_model`](/reference/score/get-scoring-model) shows every question's weight. A weight changes in two ways: * **A calibration fits it** from your labeled records. Before the first calibration, Finic estimates it. * **You set it**, on the scoring model's page in the Finic app, with [`set_question_weight`](/reference/score/set-question-weight), or with the MCP tool of the same name: ```bash curl -X PATCH https://api.finic.ai/v1/score/models/scm_01M4XRC000RT2GZSKYPD8J86G9/questions/q002 \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"weight": 2}' ``` Whichever happened last is the weight. Setting one replaces the fitted or estimated weight and changes the score at once. Calibrating fits every weight again, including the ones you set, so set them again afterwards if you still want them. After you change a weight by hand, the accuracy a calibration reported no longer describes the score. Weights go from -10 to 10; fitted and estimated ones are mostly between -3 and 3. `0` keeps asking the question without counting its answer. A weight belongs to the scoring model, not to a score request, and the pre-made scores (`POST /v1/score/`) have fixed ones. ## Jobs [#jobs] Creating from labeled records and calibrating return `202` with a `job_id`. Each takes about two minutes. Check it with [`GET /v1/jobs/{job_id}`](/reference/score/get-job-status) every 10 seconds or so, until `complete` is `true`. See [Limits](/reference#scoring-models) for how many you can run. ## What's stored [#whats-stored] A scoring model keeps its name, criteria, schema and questions. Each score keeps its `score_id`, the score and Grayson's answers. The record you score is kept for as long as your [data retention](/grayson-api/data#data-retention) says, so you can open it under Events in the Finic app, and not at all under Zero Data Retention. The labeled records you create or calibrate with are kept, encrypted, only while their job runs, and deleted when it ends. # Calibration (/score-model/calibration) Finic's answers are calibrated: a score of 250, or a probability of 0.25, means about a 25% chance. Of records scored near 250, about 1 in 4 turn out bad; of answers near 0.8, about 8 in 10 are right. And they're calibrated to **your** distribution: * **A scoring model** is fitted to your labeled records, each time you send them. Until its first calibration, its scores rank records, but their scale is Finic's estimate, not yet your rate. * **An answer** shifts to your rates when its question carries a `base_rate`. ## Calibrate a scoring model [#calibrate-a-scoring-model] A scoring model is calibrated to the labeled records you send: past records with the fields of the records it scores, each with `is_bad`. Creating it from labeled records is its first calibration. One created from its criteria isn't calibrated until you first calibrate it ([A scoring model's first calibration](#a-scoring-models-first-calibration)). If your records have more bad outcomes than production does (say, you included every bad case you have), scores run higher than the true rate. Records still rank the same way, so thresholds chosen on your own records still work, and calibrating with a representative set corrects it. Calibrate with [`POST /v1/calibrate`](/reference/score/calibrate), sending the records in `data` (or as a file in the multipart `file` part), by the same [rules](/score-model#labeled-records) as for creating: at least 100 rows with 20 of each outcome, up to 2,000 used. Grayson answers all the scoring model's questions, and yours, for every record, and the scoring model again uses the ones that best predict the outcomes, so your questions it doesn't use are tried again. ```bash curl https://api.finic.ai/v1/calibrate \ -H "Authorization: Bearer $FINIC_API_KEY" \ -F model_id=scm_01M4XRC000RT2GZSKYPD8J86G9 \ -F file=@labeled.csv \ -F add_questions="Was the account opened less than a week before the payment?" \ -F remove_questions=q022 ``` * **It runs as a [job](/reference/score/get-job-status),** in about two minutes. Scores already returned don't change; score calls after the job completes use the updated scoring model. * **The response has `rows`,** the number of records used. * **Records must match the scoring model's [schema](/score-model#schema),** if it has one; if one doesn't, the request fails with `400 schema_mismatch`. * **Up to 10 calibrations per scoring model per day,** one at a time. * **It can add and remove questions,** with `add_questions` and `remove_questions` (repeat them in a multipart form, one per question); [`add_questions`](/reference/score/add-questions) adds them without calibrating. See [Changing questions](/score-model#changing-questions). * **The records are kept encrypted only while the job runs,** as when creating, and deleted when it ends. If maintenance interrupts the job, it runs again. ### A scoring model's first calibration [#a-scoring-models-first-calibration] A scoring model created from its criteria has only your own questions, weighed by Finic's estimates, until its first calibration. That calibration also has Finic write questions from the records, and the scoring model keeps the ones that predict best, from those and yours, as when creating from labeled records. The records give it its [schema](/score-model#schema). ### How each calibration did [#how-each-calibration-did] Each calibration, creating from labeled records included, records how the scoring model did, shown on its page in the Finic app as a precision-recall curve. It's measured on the records sent, each scored by a scoring model fit without it. ## Base rates for questions [#base-rates-for-questions] Any question can carry `base_rate`: how common each answer is in your cases. Finic then shifts that question's probabilities from their usual average to your rate. Cases keep their order, so the same cases rank highest; only the probability levels move. Use it when your rate differs from what the answers average: for example, fraud is confirmed on 0.3% of your alerts, but answers to `is_fraud` average 2%. ```json title="Questions with base rates" "questions": { "is_fraud": { "type": "noul", "instructions": "Is this payment fraudulent?", "base_rate": 0.003 }, "claim_type": { "type": "choice", "instructions": "What kind of claim is this?", "criteria": { "ato": "Account takeover", "first_party": "First-party fraud", "none": "Not fraud" }, "base_rate": { "ato": 0.1, "first_party": 0.05, "none": 0.85 } } } ``` | Type | `base_rate` | | -------------- | ------------------------------------------------------------------------------------------------------------------------------------- | | `noul` | The share of cases that are yes: a number strictly between 0 and 1 | | `choice` | Every option's key with its share, each from 0 to 1, adding up to 1 (within 0.02; scaled to exactly 1) | | `multi_choice` | Any option keys, each with the share of cases it applies to, strictly between 0 and 1, independently. Options left out aren't shifted | A share of 0 makes that answer all but impossible: use it only for answers that never happen. ### How it works [#how-it-works] * **Finic keeps a running summary of its answers** to each of your organization's questions: how they're spread, over roughly the latest 200, weighted to the most recent. Every answer updates it, with or without a base rate. * **A base rate applies once the question has 30 answers.** The answer then has `calibrated: true`; before that, `calibrated: false` and the probabilities are unchanged. Questions without `base_rate` have no `calibrated` field. * **Every answer moves by the same amount on the log-odds scale,** chosen so the recent answers average your rate (per outcome for a choice, then renormalized). An answer already at your rate is left alone. * **A question is recognized by its name, type and option keys.** Rewording the instructions or descriptions keeps its summary; renaming it, changing its type or changing its options starts a new one, which needs 30 answers again. * **Each request uses the base rate it sends,** so update it as your rates drift. ```json title="Answer" "is_fraud": { "type": "noul", "noul": 0.0041, "calibrated": true } ``` **Choosing a base rate:** measure it on your own data, on the same cases you send (if you only send alerts a rule flagged, the rate among those alerts). A rate close to the truth improves the probabilities; one several times off makes them worse than none. **What's stored:** the summary, per organization, under a one-way hash of the organization and the question's name, type and option keys. It holds only aggregates of the answers: no single answer, question text, data or base rate. Unused summaries are deleted after 180 days. **Errors:** an invalid base rate gets `400 invalid_request` with `param` `questions..base_rate`: | Cause | `message` | | ---------------------------------------- | ------------------------------------------------------------------------------------------------- | | A yes/no rate of 0 or 1, or not a number | `A yes/no question's base_rate is the share of cases that are yes, between 0 and 1 (not 0 or 1).` | | A choice's shares don't add up to 1 | `A choice's base_rate shares must add up to 1.` | | A choice's rate leaves out an option | `A choice's base_rate gives every option a share, and the shares add up to 1.` | | A key that isn't an option | `base_rate names "wire", which isn't one of the question's options.` | The playground has base rates too: turn on **Add base rate** on a question. ## Choosing thresholds [#choosing-thresholds] Finic returns probabilities, not decisions: you choose where to act. * **Choose on your own labeled records,** each cut at the time of the decision: the threshold that gives the review volume, catch rate or losses you want. Check calibration on that sample before relying on it. * **Use one threshold per action:** for example, decline a score above 800 and review above 300, or block on an answer above 0.9 and review above 0.3. * **Add base rates first.** They change the probabilities (not the order), so a threshold chosen without one catches a different share with it. * **For a choice, look at the margin:** 0.48 against 0.45 is a close call. # Build a custom scoring model (/score-model/custom-scoring-models) The [scoring endpoints](/score-api) score common decisions out of the box. For a decision of your own, create a **scoring model**: you describe the decision, calibrate it with past records labeled with how they turned out, and it scores new records from 0 to 1000 on your own fraud rates. Custom scoring models come with the Starter plan and above ([Pricing](/pricing#plans)); creating and calibrating them is free. You need an API key in `FINIC_API_KEY`; see the [Quickstart](/quickstart#get-an-api-key). For the ideas behind it, see [Scoring models](/score-model) and [Calibration](/score-model/calibration). ### Create a scoring model [#create-a-scoring-model] Name it and describe the decision: what it is, and what a bad outcome means. ```bash curl https://api.finic.ai/v1/score/models \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"name": "Card-not-present payment fraud", "criteria": "Card-not-present payments at an online store. Bad: the payment was charged back as fraud within 90 days."}' ``` ```json title="201" { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "request_id": "req_01M4Y7FASG9DB7MMWCS672J0JD" } ``` Creating is free, and it's ready at once, with no questions yet. You can also create it from labeled records in one step; see [Creating a scoring model](/score-model#creating-a-scoring-model). ### Calibrate it [#calibrate-it] Gather 100+ past records of the decision, 20+ of each outcome, with the fields you send when you score, plus `is_bad` (`true` when the outcome was bad). To try it out, use [sample-payments.csv](/examples/sample-payments.csv), 300 synthetic card payments: ```csv title="sample-payments.csv" amount_usd,merchant_category,account_age_days,new_device,billing_country,ip_country,is_bad 2400.00,electronics,19,true,US,NG,true 58.12,grocery,1260,false,US,US,false 310.00,gift_cards,3,true,US,US,true ``` ```bash curl https://api.finic.ai/v1/calibrate \ -H "Authorization: Bearer $FINIC_API_KEY" \ -F model_id=scm_01M4XRC000RT2GZSKYPD8J86G9 \ -F file=@sample-payments.csv ``` ```json title="202" { "job_id": "job_01M4XZXNCRZBPXV30MSF7RN5H3", "rows": 300, "request_id": "req_01M4YPJNK0SZGEQS0A76EEND4N" } ``` Finic writes the scoring model's questions from the records and fits them to your outcomes, for free. Rows can also go in as a JSON array in `data`. See [Labeled records](/score-model#labeled-records) for what to include. ### Wait for the job [#wait-for-the-job] Calibrating takes about two minutes. Check every 10 seconds or so until `complete` is `true`: ```bash curl https://api.finic.ai/v1/jobs/job_01M4XZXNCRZBPXV30MSF7RN5H3 -H "Authorization: Bearer $FINIC_API_KEY" ``` ```json title="200" { "job_id": "job_01M4XZXNCRZBPXV30MSF7RN5H3", "complete": true } ``` An `error` in the response says what went wrong; see [Get a job](/reference/score/get-job-status). ### Score a record [#score-a-record] Send a record with the same fields, and your own unique `score_id` for it: ```bash curl https://api.finic.ai/v1/score \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "score_id": "pay_88213", "data": {"amount_usd": 1850.0, "merchant_category": "electronics", "account_age_days": 6, "new_device": true, "billing_country": "US", "ip_country": "RO"}}' ``` ```json title="200" { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "score_id": "pay_88213", "score": 874, "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` 874 means about an 87% chance of a bad outcome: the scoring model is calibrated, so its scores are about the chance of a bad outcome, and you can choose thresholds on them. [`GET /v1/score/models/{model_id}`](/reference/score/get-scoring-model) shows its questions, and [`add_questions`](/reference/score/add-questions) adds your own. Records you score must have the fields of the calibration's records; see [Schema](/score-model#schema). Want to score before you have labeled records? [Add your own questions](/reference/score/add-questions) to the new scoring model: it scores with them right away, weighed by Finic's estimates, until you calibrate it. ### Keep it calibrated [#keep-it-calibrated] As you learn how more records turned out, calibrate again with a fresh set of labeled records, the same way. Each calibration is free and chooses again which questions to use. See [Calibration](/score-model/calibration#calibrate-a-scoring-model). Log the `X-Request-Id` header of every response; support asks for it. ## The whole flow in Python [#the-whole-flow-in-python] ```python import os import time import requests API = "https://api.finic.ai" HEADERS = {"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"} def check(r: requests.Response) -> dict: if not r.ok: e = r.json()["error"] raise RuntimeError(f"{r.status_code} {e['type']}: {e['message']} (request {r.headers.get('X-Request-Id')})") return r.json() def wait_for(job_id: str) -> None: while not (job := check(requests.get(f"{API}/v1/jobs/{job_id}", headers=HEADERS, timeout=30)))["complete"]: time.sleep(30) if "error" in job: raise RuntimeError(f"{job['error']['type']}: {job['error']['message']}") created = check(requests.post(f"{API}/v1/score/models", headers=HEADERS, timeout=60, json={"name": "Card-not-present payment fraud", "criteria": "Card-not-present payments. Bad: charged back as fraud within 90 days."})) # Fit it to your data with labeled records: with open("sample-payments.csv", "rb") as f: calibration = check(requests.post(f"{API}/v1/calibrate", headers=HEADERS, timeout=60, data={"model_id": created["model_id"]}, files={"file": f})) wait_for(calibration["job_id"]) record = {"amount_usd": 1850.0, "merchant_category": "electronics", "account_age_days": 6, "new_device": True, "billing_country": "US", "ip_country": "RO"} scored = check(requests.post(f"{API}/v1/score", headers=HEADERS, timeout=60, json={"model_id": created["model_id"], "score_id": "pay_88213", "data": record})) print(scored["score"]) ``` Every endpoint in the [API reference](/reference) has a playground that sends requests from the docs. # Grayson API (/grayson-api) **Grayson** is Finic's decision model, `grayson-1`. It reads a case, such as an alert, a payment, an application or a dispute, and answers questions about it with **probabilities**. It does not write text, rationales or summaries: every answer is a number that you can compare with a threshold, log and audit. You call Grayson directly with [`POST /v1/ask`](/reference/grayson/ask). Finic's scores use it too: | What you call | What Grayson does | | ----------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- | | [`POST /v1/ask`](/reference/grayson/ask) | Answers your own questions about one case. You write the questions. | | [`POST /v1/score/{use_case}`](/score-api) | Answers the scoring endpoint's yes/no questions. The response shows each question with its probability, and the score comes from them. | | [`POST /v1/score`](/score-model) | Answers your scoring model's questions. The score is calibrated to your labeled outcomes. | Use ask when no [scoring endpoint](/score-api) fits your decision, when you need more than one answer about a case (for example, "is this fraud?" and "which team gets it?"), or when you want to write the questions in your own words. ## Ask a question [#ask-a-question] Send the case as `data` (structured JSON), `context` (free text) or both, and name each question: ```bash curl https://api.finic.ai/v1/ask \ --header "Authorization: Bearer $FINIC_API_KEY" \ --header "Content-Type: application/json" \ --data @- <<'EOF' { "model": "grayson-1", "data": { "events": [ { "ts": "2026-09-20T02:14:09Z", "type": "login", "new_device": true }, { "ts": "2026-09-20T02:16:40Z", "type": "email_change" }, { "ts": "2026-09-20T02:21:03Z", "type": "ach_out", "amount_usd": 4900.0 } ] }, "context": "Customer called on 9/21: never changed their email, doesn't recognize the transfer.", "questions": { "ato": { "type": "noul", "instructions": "Is this account takeover?", "base_rate": 0.02 }, "route_to": { "type": "choice", "instructions": "Which team should review this case?", "criteria": { "ato": "Account security", "aml": "AML investigations", "none": "No review needed" } } } } EOF ``` ```json title="200 OK (answers only)" "answers": { "ato": { "type": "noul", "noul": 0.91, "calibrated": true }, "route_to": { "type": "choice", "choice": "ato", "confidence": 0.87, "probabilities": { "ato": 0.91, "aml": 0.04, "none": 0.05 } } } ``` A 91% chance of account takeover, at your 2% base rate: hold the transfer, and send the case to account security. The full response also has the request's `id`, the `model`, `usage.input_tokens` and the `request_id`. ## What makes Grayson's answers useful [#what-makes-graysons-answers-useful] * **Probabilities, not labels.** A `noul` (yes or no) answer is the probability of yes. A `choice` gives a probability for every option, and a `multi_choice` gives one for each option on its own. See [Questions](/grayson-api/questions). * **Calibrated.** An answer of 0.8 is right about 8 times in 10. Add a `base_rate` to a question, and its answers shift to how common the answer is in your own cases. See [Calibration](/score-model/calibration#base-rates-for-questions). * **The same request gets the same answers.** Retrying is safe, and you can test thresholds on past requests. * **Each question is answered on its own.** A question sees the case and its own text, never the other questions, so adding a question does not change the others. * **No schema.** Send records in the shape you keep them, and free text such as notes, messages and emails. See [Data & context](/grayson-api/data). ## Limits and price [#limits-and-price] | | | | ---------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | | Model | `grayson-1` | | Questions per request | 1 to 128 | | Tokens per request (`data`, `context` and questions) | Up to 32,768 | | Price | $0.035 per million input tokens: about $0.0002 for a 5,000-token case | | Data retention | As your organization and you choose, down to zero. See [Data retention](/grayson-api/data#data-retention). | See [Limits](/reference#limits) for the rate limits, and [Pricing](/pricing#ask-and-custom-scores) for how tokens are counted. ## Next [#next] # Questions (/grayson-api/questions) An [ask](/reference/grayson/ask) request asks 1 to 128 questions about one case, its [data and context](/grayson-api/data). Grayson, Finic's decision model, answers each with calibrated probabilities. Nothing is generated: no rationale or text, only probabilities. ```json "questions": { "is_fraud": { "type": "noul", "instructions": "Is this account engaged in or the victim of fraud?" }, "escalate_to": { "type": "choice", "instructions": "Which team should this alert be escalated to?", "criteria": { "ato": "Account security / ATO team", "aml": "AML investigations", "none": "No escalation needed" } } } ``` Each question's key names it, and its answer comes back under the same key. Keys and option keys match `^[A-Za-z_][A-Za-z0-9_]{0,63}$`. The model never sees them: everything it needs goes in the `instructions` and `criteria`. In a choice, the key (`ato`) comes back in the answer; the description ("Account security / ATO team") is what the model reads. ## Question types [#question-types] Every question has `type` and `instructions` (not blank). Fields that don't belong to the type are rejected. Every answer repeats its question's `type`. | Type | Use for | `criteria` | Answer | | -------------- | ---------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | | `noul` | Yes or no | Optional: `{"true": "…", "false": "…"}`, what each answer means, read after the instructions | `noul`: the probability of yes | | `choice` | Exactly one right answer: routing, next action, primary typology | 2–255 options as `key: description` | `choice`: the most likely key; `confidence`; `probabilities` per option, summing to 1 | | `multi_choice` | Any number of right answers: typologies present | As for `choice` | `multi_choice`: keys with probability 0.5 or more; `probabilities` per option, each independent | ```json title="Answers" "answers": { "is_fraud": { "type": "noul", "noul": 0.92 }, "primary_typology": { "type": "choice", "choice": "ato", "confidence": 0.85, "probabilities": { "ato": 0.88, "synthetic_id": 0.02, "mule": 0.05, "first_party": 0.03, "none": 0.02 } }, "typologies_present": { "type": "multi_choice", "multi_choice": ["ato", "mule"], "probabilities": { "ato": 0.93, "synthetic_id": 0.04, "mule": 0.61, "first_party": 0.03, "scam": 0.07 } } } ``` * **Option descriptions** must not be blank and must be unique, ignoring case and whitespace. A `null` description reads as the key with spaces for underscores (`first_party` reads "first party"), but a real description works better. * **A choice** spreads all its probability over its options, so include one for "none of these" when that can happen. If two options can both be true, use `multi_choice`: a choice has to split probability between them, and neither may reach 0.5. * **A multi\_choice** asks about each option separately. With up to 16 options, each is judged with the full list in view; with more, each on its own, like a separate `noul`. ## Confidence [#confidence] A choice's `confidence` is (K × the top probability − 1) / (K − 1) over K options: 0 when all are equally likely, 1 when one has all the probability. In the answers above, (5 × 0.88 − 1) / 4 = **0.85**. `choice` and `multi_choice` summarize the probabilities; base decisions on the probabilities themselves, unrounded. See [Choosing thresholds](/score-model/calibration#choosing-thresholds). ## Writing good questions [#writing-good-questions] * **Ask one thing.** "Is this account takeover or a scam?" is two questions: use a `choice`, or two nouls. * **Name the subject:** "the outbound ACH on September 20", not "this", when the data holds several transactions. * **Make yes mean the action:** "Should this wire be held?" thresholds more directly than "Is this wire safe to release?" * **Define your terms and standards.** "High risk: two or more of a new device, a new payee and a changed email in the last 24 hours" gets answers that follow your policy; "High risk" leaves it to the model. * **Write descriptions that stand alone:** "Hold the payment and verify the customer another way", not "Hold". * **Keep wording and order fixed.** A choice reads its options together, in the order given. Changing the wording or order can change the answers, so choose thresholds with the exact questions you run in production. * **Ask about signals directly** when you need to record why: "Did the account log in from a new device shortly before the transfer?" gives a probability you can log and show a reviewer. ## Determinism and isolation [#determinism-and-isolation] * **The same request always gets the same answers,** so retrying is safe. Any change (instructions, option order, data, context, key order) makes it a different request. Whitespace between JSON tokens in `data` doesn't matter; whitespace inside strings does. * **Each question sees only the case and its own text,** never the other questions: adding, removing or renaming one can't feed into another's answer. Numerical rounding can still move other answers slightly, under 1 percentage point on average. Requests and answers are kept only as your [data retention](/grayson-api/data#data-retention) allows. To keep them for audits, appeals or threshold tuning, store the request and response, with its `id` and `request_id`, with your own decision record. # Data & context (/grayson-api/data) An [ask](/reference/grayson/ask) request describes a case in two fields. Send either, or both: * **`data`:** structured data as JSON: account records, events, transactions, an alert, an application. A string also works, read as sent (CSV text, for example). * **`context`:** free text: analyst notes, customer messages, emails, documents. There's no schema: send records in the shape you keep them. Every question in the request is answered from the same data and context; with both, the data is read first. A record sent to [`POST /v1/score`](/reference/score/score) also goes in `data`, in the shape of the scoring model's [examples](/score-model#labeled-records). ```json "data": { "dispute": { "filed": "2026-09-21", "amount_usd": 612.40, "merchant_category": "electronics", "transaction_date": "2026-09-12" }, "authorization": { "entry_mode": "chip", "cvm": "pin_verified" } }, "context": "Cardholder called on 9/21: says the charge wasn't theirs and the card was never lost. Their son also has access to the account." ``` A blank string, or a number, boolean or `null` on its own, is rejected. An ask request with neither field fails with `400 invalid_request` (`param`: `data`). ## What to include [#what-to-include] What a reviewer would look at: * **The customer or account:** tenure, KYC and verification results, contact details and when they changed, earlier alerts. * **Recent activity:** logins, device and IP changes, profile changes, payments and transfers. * **The item under review:** the transaction, application, dispute or withdrawal, with amounts, counterparties and timestamps. * **Case notes:** rule hits, analyst notes, customer messages, usually in `context`. Only include what was known when the decision was made: when you replay past cases, cut each at the time of the decision. Leave out what can't matter: passwords, full card numbers and one-time codes never help. ## Make it readable [#make-it-readable] * **Order matters.** `data` is read as compact JSON in the key order you send. Put events in time order and keep related fields together. Python dicts and JavaScript objects keep insertion order (JavaScript moves integer-like keys such as `"2024"` first); Go's `encoding/json` sorts map keys; Java's `HashMap` has no order (`LinkedHashMap` keeps it). * **Name fields in words** (`amount_usd`, not `amt`), give units and currencies, and use ISO 8601 timestamps with `Z` or an offset. * **Expand your own codes:** `"rule": "R-417: 3 failed logins, then a password reset"`, not `"rule": "R-417"`. Text in `data` or `context` that looks like a question or an instruction is read as part of the case: question boundaries use reserved tokens no input can produce. Customer-written text, such as a dispute narrative, can go in as it is. ## Size [#size] `data`, `context` and the questions share ask's limit of 32,768 tokens per request; each response reports the total in `usage.input_tokens`. JSON is compacted first, so whitespace between keys costs nothing. Over the limit, the request fails with `413 request_too_large`, giving its size. To fit a long history, send a recent window, drop fields your questions never need, or summarize older events. See [How tokens are counted](/reference#how-tokens-are-counted). ## Data retention [#data-retention] How long Finic keeps the content of requests (data, context, questions and answers) has two layers: * **Your organization's setting,** chosen by its admins: Zero Data Retention (nothing is kept) or 7, 30, 90 or 365 days. In the Finic app, choosing it comes with the Growth plan and above; other organizations there keep requests for 365 days. Kept requests can be opened by the organization's members from Usage in the Finic app. * **Your own setting,** for your account across all your organizations. It can only make retention stricter. It covers requests you make: in the playground, and through API keys, docs sign-ins and agent sign-ins you created. A request is kept for the shorter of the two, and Zero Data Retention always wins. Choosing a shorter period deletes content already kept beyond it. Set yours in the Finic app under [Settings → Account](https://app.finic.ai/settings/account), or have your agent use [`set_data_retention`](/mcp/data-retention); admins set the organization's under Settings → Organization. The records you score are kept like any other request: for the period these settings give, and never under Zero Data Retention. The labeled records you create or calibrate a scoring model with are kept, encrypted, only while their job runs and deleted when it ends, whatever these settings; see [What's stored](/score-model#whats-stored). The [Data Processing Addendum](https://finic.ai/policies/data-processing) describes retention in full. # Identify (/identify) Identify tells your site who each visitor is: a **person, an AI agent or other automation**, which [visitor](/identify/visitors) it is from one visit to the next, and what stands out about its device and network. It is one product: a script that loads in the visitor's browser, collects signals, and uses all of them. This page helps you pick how to load it. ```json title="A verdict" { "actor": "ai_agent", "operator": "Anthropic", "product": "Claude-Agent", "verification": "network_verified", "confidence": "high", "reasons": ["agent_network"] } ``` Identify returns results only. It never blocks, challenges or slows a visitor: what to do with a verdict is your decision. See [Acting on a verdict](/identify/verdicts#acting-on-a-verdict). ## How to load it [#how-to-load-it] | | Use it when | You get | Your code | | ----------------------------------- | ----------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ------------------------------------------- | | [The snippet](/identify/quickstart) | You can add a script tag to your pages | A verdict for each browser session, read by session id | One tag, and one API call to read a session | | [The edge package](/identify/edge) | Your site runs on Cloudflare Workers, Next.js or Node | A verdict on every request, as `finic-*` request headers. The snippet is served from your own domain | A few lines of setup, no API call | * **A session also names its [visitor](/identify/visitors):** an id that stays the same when the browser comes back, with its cookies cleared or in a private window. * **A session carries [smart signals](/identify/smart-signals) too:** where the address is, Tor and VPN, a private window, a virtual machine, tampering, and a suspect score. * **For a request with no page** (an API call, a feed, a log line), the [agent lookup](/identify/lookup) says whether it's a declared AI agent or crawler, from its IP address, user agent and headers. It can't say a request is from a person: only a session can. * **The edge package uses both:** the session's verdict when the browser has one, a lookup otherwise. * **Each session and each lookup costs $0.001** from your credit: [$1 per 1,000 identifications](/pricing#identify). * **Both use your API key** (`gsk_…`, see [Authentication](/authentication)). The snippet also needs a site's public key (`gpk_…`). ## Start here [#start-here] # Identify quickstart (/identify/quickstart) After these steps your server can read, for any visitor's browser session, whether it's a person, an AI agent or other automation. You need an API key in `FINIC_API_KEY` ([get one](/quickstart#get-an-api-key)). ### Create a site [#create-a-site] A site is a public key for the snippet. `origins` lists the pages that may report under it. You can do this step in the Finic app instead: **Sites**, then **Add site**. Sessions show up under **Sessions** as pages are visited. An AI agent connected to [Finic's MCP server](/agent-quickstart) can do every step here itself, starting with [`create_site`](/mcp/sites). ```bash curl https://api.finic.ai/v1/identify/sites \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"name": "Storefront", "origins": ["https://www.example.com"]}' ``` ```json title="201" { "id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "name": "Storefront", "key": "gpk_Zk3vQ8mT1xR7bN2cYw5LpA9d", "origins": ["https://www.example.com"], "snippet": "", "created_at": "2026-12-01T17:01:52.310447Z", "request_id": "req_01M4Z1X3H2N7Q4B8D6KC9TWEFA" } ``` The `gpk_…` key is not a secret: it goes in your pages. To try it on `localhost`, leave `origins` out, or add `http://localhost:3000`. ### Paste the tag [#paste-the-tag] Put `snippet` in the `` of every page: ```html ``` It loads without blocking the page and never throws into it. [Data & privacy](/identify/data) lists what it collects, and the [Content-Security-Policy](/identify/data#content-security-policy) it needs if your site has one. ### Load a page [#load-a-page] Open a page with the tag in a browser. The snippet reports to `POST /identify/s` and gets back a session id, which it keeps in the `finic_session` cookie. In the browser console: ```js window.finic.session // "ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE" ``` If it stays `null`, look at the `POST /identify/s` request in the network tab. A `204` answer means the report wasn't taken, and its `X-Finic-Refused` header says why, such as `origin` (the page isn't one of the site's `origins`), `site` (unknown key), `rate` or `credit` (the organization is [out of credit](/pricing#credit)). ### Read the verdict [#read-the-verdict] ```bash curl https://api.finic.ai/v1/identify/sessions/ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE \ -H "Authorization: Bearer $FINIC_API_KEY" ``` ```json title="200" { "id": "ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE", "site_id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "entity_id": null, "entity_source": null, "status": "complete", "actor": "unknown", "operator": null, "product": null, "category": null, "verification": "none", "confidence": "low", "reasons": [], "network": { "type": "unknown", "provider": null, "range": null }, "ip": "198.51.100.24", "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36", "page": "https://www.example.com/checkout", "reports": 2, "created_at": "2026-12-01T17:04:11.482913Z", "updated_at": "2026-12-01T17:04:12.127540Z", "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` A page that has only just loaded is `unknown` with `low` confidence: nothing seen either way. Move the mouse or type and read it again: it becomes `human` with `human_like_input`. While DevTools is open, `reasons` also lists `devtools_protocol`, and `human` is `medium`, not `high`. Load the same page with Playwright, Puppeteer or Selenium to see `automation`. [Verdicts](/identify/verdicts) explains every field. [`GET /v1/identify/sessions`](/reference/identify/list-sessions) lists the latest sessions, without an id. ### Read it on your server [#read-it-on-your-server] The `finic_session` cookie is set on your own domain, so your server receives it with each request. Read the session when it matters (a sign-in, a checkout), since a verdict changes as the page is used. Anyone can send a cookie. Before you rely on a session, check that its `ip` and `user_agent` match the request in front of you. The [edge package](/identify/edge) does this for you and hands your server the verdict as request headers. ## Link a session to your customer [#link-a-session-to-your-customer] A session is one browser tab's visit: it doesn't know who signed in. Give it your own id for that customer or account as its `entity_id`. The quick way is from the page, once you know who it is: ```html ``` ```js // or later, such as after sign-in window.finic.identify("user_123"); ``` That id is the page's claim (`"entity_source": "browser"`): fine for finding a customer's sessions, not for a security decision. For one you can rely on, set it from your server, such as after sign-in: ```bash curl -X PATCH https://api.finic.ai/v1/identify/sessions/ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"entity_id": "user_123"}' ``` The answer is the session, with `"entity_id": "user_123"` and `"entity_source": "server"`. Its verdict doesn't change. What your server sets or clears stands: the page can't change it afterwards. To list that customer's sessions, newest first: ```bash curl "https://api.finic.ai/v1/identify/sessions?entity_id=user_123" \ -H "Authorization: Bearer $FINIC_API_KEY" ``` An entity id is any string of yours, up to 128 characters. Send `{"entity_id": null}` to clear it. See [`update_session`](/reference/identify/update-session). ## Try the agent lookup [#try-the-agent-lookup] The [lookup](/identify/lookup) needs no site or snippet: send what you saw of one request. The built-in test agent, `Finic-Test-Agent`, is verified from `192.0.2.0/24`: ```bash curl https://api.finic.ai/v1/identify/lookup \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"ip": "192.0.2.10", "user_agent": "Finic-Test-Agent"}' ``` ```json title="200 (some fields)" { "actor": "ai_agent", "operator": "Finic (test)", "product": "Finic-Test-Agent", "verification": "network_verified", "impersonated": false, "flags": ["test"], "test": true } ``` Send it from `203.0.113.9` instead and it comes back `impersonated`. # Verdicts (/identify/verdicts) After this page you can read any verdict and decide what your site does with it. A [session](/reference/identify/get-session), the [edge package's headers](/identify/edge#request-headers) and a [lookup](/identify/lookup) all use the same words. | Field | Says | | --------------------------------- | --------------------------------------------------------- | | `actor` | What the visitor is taken to be | | `operator`, `product`, `category` | Which agent, for an `ai_agent` or an impersonation of one | | `verification` | How far a claim to be an agent was checked | | `confidence` | How sure the verdict is. Sessions only | | `reasons` | What the verdict rests on, as stable codes. Sessions only | ## Actor [#actor] | `actor` | Meaning | | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `human` | The page was used the way a hand uses it, and nothing says otherwise. Only a session can say this | | `ai_agent` | A declared AI agent or crawler: it names itself in its user agent, signs its requests, or comes from its operator's published addresses | | `automation` | A script or a driven browser: an HTTP library, an automation tool, or something posing as an agent | | `unknown` | No information: nothing for it being a person, nothing against. A session on a page that has only loaded is `unknown`. So is everything a lookup can't name, people included | ## Confidence [#confidence] | `confidence` | When | In practice | | ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------- | | `high` | Proof, or a sign that doesn't happen by accident: a verified signature, the operator's own network, an impersonation, an automation tool's trace. For `human`: human-like input and nothing against it | Safe to act on | | `medium` | A claim nothing could check, or two signs that agree. For `human`: human-like input beside a weak sign such as `data_center_ip` | Act on it where a mistake is cheap | | `low` | One sign alone. For `unknown`: nothing seen either way yet, as on a page that has just loaded | A hint, not a decision. Log it | A session that showed an agent or automation with `medium` or `high` confidence keeps that verdict when later reports show less. ### Confidence score [#confidence-score] `confidence_score` is the same confidence as a number from 0 to 1, for sorting and thresholds. | `confidence` | `confidence_score` | | ------------------------------ | ------------------ | | `high` | 0.85 to 0.99 | | `medium` | 0.50 to 0.84 | | `low` | 0.01 to 0.49 | | any, when `actor` is `unknown` | 0 | Within a band, more signs that agree score higher: three signs of automation score above two. The numbers come from the same rules as the verdict and are set by hand. They aren't measured probabilities: 0.95 doesn't mean 95 sessions in 100 are right. ## Verification [#verification] | `verification` | Meaning | | ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `signed` | The request's [signature](/identify/lookup#signatures) verifies against keys the agent publishes | | `network_verified` | The address is in the IP ranges the agent's operator publishes | | `claimed` | Only the user agent says so, and nothing could check it: the operator publishes no ranges, there was no usable address, or its ranges weren't current | | `impersonated` | The user agent names an agent, but the address is in none of its operator's ranges. `actor` is `automation`; `operator` and `product` are the ones it claims | | `none` | No claim to be an agent | ## Reason codes [#reason-codes] Each code is one observable thing. "Alone" is what one sign gives with nothing else. | `reasons` | Meaning | Alone | | ------------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------- | -------------------- | | `signed_agent` | The request's signature verified | `ai_agent`, `high` | | `agent_network` | The address is in the operator's published ranges | `ai_agent`, `high` | | `agent_user_agent` | The user agent names a known agent; nothing could check it | `ai_agent`, `medium` | | `ai_browser_user_agent` | The browser's own user agent says an AI drives it (the Claude desktop app's browser) | `ai_agent`, `medium` | | `impersonation` | The user agent names an agent whose operator doesn't publish this address | `automation`, `high` | | `webdriver` | `navigator.webdriver` is true | `automation`, `high` | | `headless_user_agent` | The user agent says `HeadlessChrome` | `automation`, `high` | | `headless_browser_brand` | The browser's own brand list says `HeadlessChrome`, whatever its user agent says | `automation`, `high` | | `automation_user_agent` | The user agent names an HTTP library or automation tool | `automation`, `high` | | `playwright`, `puppeteer`, `selenium`, `chromedriver`, `phantomjs`, `nightmare`, `cypress` | That tool's own objects are on the page | `automation`, `high` | | `automation_controller` | A browser automation controller's objects are on the page | `automation`, `high` | | `webdriver_attribute` | The page's root element carries a `webdriver`, `selenium` or `driver` attribute | `automation`, `high` | | `webdriver_hidden` | `navigator.webdriver` was replaced, as tools that hide it do | `automation`, `low` | | `user_agent_mismatch` | The request's user agent differs from the one the page reports | `automation`, `low` | | `user_agent_replaced` | A Chrome user agent with none of the brand names Chrome sends beside it | `automation`, `low` | | `platform_mismatch` | The user agent names one kind of device, the browser's platform another | `automation`, `low` | | `software_renderer` | Graphics are drawn in software, as on a server with no GPU | `automation`, `low` | | `permissions_mismatch` | The browser gives two different answers about notification permission | `automation`, `low` | | `no_window` | A visible page in a window with no size | `automation`, `low` | | `viewport_emulated` | Desktop Chrome whose window is exactly the page's size: the size is being set by a tool. A developer resizing the page in DevTools can cause it | `automation`, `low` | | `casting_switched_off` | Desktop Chrome with casting off, as tools that launch Chrome leave it. A company policy can cause it | `automation`, `low` | | `no_languages` | The browser lists no languages | `automation`, `low` | | `clicks_without_pointer_travel` | Clicks land somewhere new with next to no pointer movement before them | `automation`, `low` | | `typing_faster_than_hands` | Keys arrive faster than fingers move | `automation`, `low` | | `text_without_keys` | Text appears with no key presses, or several characters at once | `automation`, `low` | | `uniform_key_timing` | Key presses at near-identical intervals | `automation`, `low` | | `synthetic_input` | A script on the page made a click or key press. Sites' own libraries do this | `unknown`, `low` | | `devtools_protocol` | The DevTools protocol is attached. Open DevTools does this too | `unknown`, `low` | | `device_emulation` | A phone's user agent on a computer, in DevTools' device mode | `unknown`, `low` | | `data_center_ip` | The address belongs to a listed cloud provider | `unknown`, `low` | | `human_like_input` | A pointer that travels at changing speed, a touch, or typing with an uneven rhythm | `human`, `high` | `synthetic_input`, `devtools_protocol`, `device_emulation` and `data_center_ip` are weak signs: alone they're listed and the session stays `unknown`, and beside human-like input they lower `human` to `medium`. Two `automation`, `low` signs together, or one with a weak sign, give `automation` with `medium` confidence. New codes will be added: ignore the ones you don't know. A verdict holds across a session's pages. Each page starts with no input, so its first report alone says nothing either way: a session that has shown a person's input stays `human` until a sign of automation shows, and one that has shown automation stays `automation`. ## Acting on a verdict [#acting-on-a-verdict] Identify never blocks or challenges anyone. Your code does, if you choose. * **Start report-only.** Log `actor`, `confidence` and `reasons` beside your own outcomes before you change what any visitor sees. * **Never treat `low` as a decision.** One sign alone can be wrong about a person. * **No information is not `human`.** `unknown`, a missing session, and the edge package's `finic-source` of `skipped` or `unavailable` all mean Identify couldn't say. `human` is said only after input a hand makes, so a page that has only loaded is `unknown`. * **Read the verdict when it matters.** It changes as the page is used: a sign-in or a checkout is a better moment than the first page load. * **Treat `claimed` as a name, not proof.** Anyone can send a user agent. `signed` and `network_verified` are checked; `impersonated` is checked and failed. ## What Identify can't tell [#what-identify-cant-tell] * An agent that drives a person's own browser the way a person would, and leaves no trace, looks like a person. * An agent that doesn't declare itself but leaves automation traces is `automation`, not `ai_agent`. * A lookup finds declared agents only, and doesn't know a home connection from a VPN. The verdict comes from written rules, one per reason code, not a trained model. Their thresholds will be tuned; the codes stay. # Visitors (/identify/visitors) After this page you can tell a returning browser from a new one, and know how far to trust the match. A visitor is one browser on one device. Every session carries its visitor's id, and the same browser gets the same id next time, also with its cookies cleared or in a private window. ```json title="In a session" { "id": "ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE", "actor": "human", "visitor_id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "visitor": { "id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "match": "fingerprint", "found": true, "confidence": "high", "confidence_score": 0.97, "sessions": 7, "first_seen_at": "2026-11-18T09:41:07.120443Z", "last_seen_at": "2026-11-30T20:15:42.004118Z" } } ``` ## Where to read it [#where-to-read-it] | | | | -------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- | | A session | `visitor_id` and `visitor` on [get\_session](/reference/identify/get-session) and [list\_sessions](/reference/identify/list-sessions) | | A request, with the [edge package](/identify/edge) | The `finic-visitor` request header | | A visitor's sessions | [list\_sessions](/reference/identify/list-sessions) with `visitor=kvi_…` | | A visitor | [get\_visitor](/reference/identify/get-visitor) | `visitor_id` is `null` on a session whose browser hasn't been identified yet. A returning browser is identified by its first report; a new one within about a second of the page loading, once its fingerprint has been read. Visitor ids are your organization's own. The same browser has the same id on all of your sites, and an unrelated id on anyone else's. ## How a visitor is matched [#how-a-visitor-is-matched] | `match` | The browser | Recognised by | | ------------- | ------------------------------------------------------------------------ | --------------------------------------------------------------------------------- | | `stored_id` | Came back with its token | The token the snippet keeps in a cookie and in `localStorage`, for up to 400 days | | `fingerprint` | Came back without it: cookies cleared, a private window, another profile | Its fingerprint, together with the address or network it comes from | | `new` | Hasn't been seen before, as far as can be told | Nothing: it gets a new id | The fingerprint is what the browser's canvas, audio stack, fonts and graphics produce, and what it says of its hardware. [Data & privacy](/identify/data#what-the-snippet-collects) lists every reading. The browser is never told its visitor id. What it keeps is a separate token, so knowing a visitor's id doesn't let anyone pass for that visitor. ## Confidence [#confidence] `visitor.confidence` is how sure it is that the session belongs to this visitor and nobody else. | `confidence` | `stored_id` | `fingerprint` | `new` | | ------------ | ----------- | --------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ | | `high` | Always | The same fingerprint, canvas included, at the same address, on a computer | A computer whose fingerprint matched no one | | `medium` | | A matching fingerprint on the same network, or one only this visitor has, from anywhere | | | `low` | | A matching fingerprint at the same address, with nothing in it that sets the device apart: a phone, most of all | A phone, or a browser that hides its fingerprint: it may have been here before | A browser matched with `low` confidence isn't given the visitor's token, so one guess doesn't become permanent. `visitor.confidence_score` is the same as a number from 0 to 1, for thresholds: how sure it is that the session was given the right visitor and not another browser's. | `match` | `confidence_score` | | ----------------------- | ------------------ | | `stored_id`, `new` | 1 | | `fingerprint`, `high` | 0.90 to 0.99 | | `fingerprint`, `medium` | 0.60 to 0.89 | | `fingerprint`, `low` | 0.30 to 0.59 | Within a band, the more of the fingerprint agreed, the higher the score. The numbers are set by hand and aren't measured probabilities. `visitor.found` is whether the visitor had been seen before this session, and `visitor.last_seen_at` when its previous session started (`null` for a new visitor). ## What it can't tell apart [#what-it-cant-tell-apart] * **Two devices of the same model, set up the same.** Their fingerprints are identical. Without a token, they are one visitor when they share an address, and each a new visitor when they don't. * **Phones and tablets.** Everyone with the model has the fingerprint. A phone without its token is matched only at the same address, with `low` confidence. * **Two profiles of one browser.** Without tokens they look the same: one visitor. * **Two browsers on one device.** Chrome and Safari on the same laptop are two visitors. * **Brave.** It changes its fingerprint every session. It is recognised by its token, and is a new visitor without one. * **Safari and Firefox private windows.** They alter canvas and audio readings. Those readings are left out there, so a match needs the same address or network. The weights and thresholds behind a match are rules, not a trained model, and they are first settings: they haven't been measured on a large population of devices. ## Turning it off [#turning-it-off] Add `data-visitor="off"` to the tag. The snippet then keeps no visitor token and takes no fingerprint, and sessions have `visitor_id: null`. Verdicts are unaffected. ```html ``` ## Forgetting a visitor [#forgetting-a-visitor] [delete\_visitor](/reference/identify/delete-visitor) deletes a visitor's fingerprint, addresses and token. A visitor that isn't seen for a year is deleted too. See [Retention](/identify/data#retention). # Smart signals (/identify/smart-signals) After this page you can read every smart signal on a session and know what each one rests on. A session says who the visitor is ([verdict](/identify/verdicts)) and which visitor it is ([visitor](/identify/visitors)). Smart signals are the rest: where its address is, and what its browser is doing that an ordinary one doesn't. They are fields of the [session](/reference/identify/get-session) itself. ```json title="In a session" { "incognito": true, "vpn": true, "vpn_confidence": "medium", "vpn_origin_timezone": "America/Toronto", "vpn_methods": { "timezone_mismatch": true }, "virtual_machine": false, "tampering": false, "tampering_details": { "anomaly_score": 0 }, "developer_tools": false, "privacy_settings": false, "ip_info": { "v4": { "address": "198.51.100.7", "geolocation": { "city_name": "Berlin", "country_code": "DE", "timezone": "Europe/Berlin" }, "asn": "64500", "asn_name": "Example Telecom", "asn_network": "198.51.100.0/24", "datacenter_result": false, "datacenter_name": null } }, "ip_blocklist": { "tor_node": false }, "velocity": { "events": { "5_minutes": 1, "1_hour": 2, "24_hours": 6 }, "distinct_ip": { "5_minutes": 1, "1_hour": 1, "24_hours": 3 }, "distinct_entity_id": { "5_minutes": 0, "1_hour": 0, "24_hours": 1 } }, "suspect_score": 8 } ``` ## The signals [#the-signals] `null` means the signal couldn't be told, which is not the same as `false`. | Field | Says | Rests on | | ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `incognito` | The browser is in a private window. `null` where the browser gives no way to tell, which includes Chrome and every browser built on it | Firefox: service workers are missing. Safari: its private file system is refused | | `vpn` | The visitor seems to be behind a VPN. `null` without a location for the address or a time zone from the browser | The browser's clock is in another time zone than its address. `vpn_confidence` is `high` when the address is also a cloud provider's or a Tor exit, else `medium` | | `ip_blocklist.tor_node` | The address is a Tor exit node | The Tor Project's published list | | `ip_info` | The address, under `v4` or `v6`: its `geolocation`, its network (`asn`, `asn_name`, `asn_network`), and whether it is a cloud provider's (`datacenter_result`, `datacenter_name`) | A GeoIP database for the place and the network, and cloud providers' published ranges | | `virtual_machine` | The browser's graphics are a virtual machine's | The graphics adapter's name | | `tampering` | The browser contradicts itself about what it is. `tampering_details.anomaly_score` is the share of five consistency checks that failed | The [reasons](/identify/verdicts#reason-codes) `user_agent_replaced`, `user_agent_mismatch`, `platform_mismatch`, `webdriver_hidden` and `permissions_mismatch` | | `developer_tools` | The DevTools protocol is attached: open DevTools, or a tool driving the browser | The reasons `devtools_protocol` and `device_emulation` | | `privacy_settings` | The browser hides its fingerprint | Brave, or Firefox answering a canvas reading differently each time | | `velocity` | How busy the session's [visitor](/identify/visitors) was in the 5 minutes, hour and 24 hours up to the session's start: its sessions (`events`), the addresses it came from (`distinct_ip`) and the entity ids it was linked to (`distinct_entity_id`). Only on [get\_session](/reference/identify/get-session), not in a list | Your organization's sessions | | `suspect_score` | The signals added up, each by a weight. 0 is nothing unusual | The table below | ## Suspect score [#suspect-score] | Signal | Adds | | ------------------------------------------------------------- | ---- | | An impersonated agent, or `automation` with `high` confidence | 20 | | `automation` with `medium` confidence | 12 | | `automation` with `low` confidence | 5 | | A Tor exit node | 15 | | Tampering | 8 | | A cloud provider's address, unless the visitor is an AI agent | 5 | | VPN | 5 | | Virtual machine | 5 | | Private window | 3 | | Developer tools | 2 | | Privacy settings | 1 | ## What they are and aren't [#what-they-are-and-arent] * **Rules on things already collected,** with weights set by hand. None is a trained model, and none has a measured error rate. * **Worked out when a session is read,** from the report and lookup kept with it. Nothing extra is stored, and sessions from before a signal existed have it too. * **Not included,** because nothing Finic has says it: whether an address is a residential proxy or a named VPN provider's, spam and attack blocklists, and how rare a device is. * **A person can set any of them off.** A traveller's clock is in another time zone. A developer has DevTools open. Use a signal as one input, not a decision. ## Geolocation needs a database [#geolocation-needs-a-database] `geolocation`, the `asn` fields and `vpn` come from GeoIP databases, which Finic's API has to be given. Until it is, they are `null` and the other signals work as described. # Edge package (/identify/edge) After this page your application receives a [verdict](/identify/verdicts) on every request as `finic-*` request headers, with no API call from your code. The package runs in front of your site and: * serves the snippet and relays its reports from your own domain (`/_identify/agent.js`, `/_identify/s`); * sets the [visitor](/identify/visitors) token as a cookie from your own domain, which Safari keeps for 400 days; one the snippet sets itself lasts 7; * removes any `finic-*` header the client sent, then sets its own; * never blocks a request. If Finic is slow or down, or your organization is out of credit, the request goes on without a verdict. Each lookup and each session is one identification, [$0.001](/pricing#identify). A new visitor's first request has no session yet, so it gets a lookup; its session is a second identification. A client that never runs the snippet, such as a crawler, gets a lookup, remembered for five minutes. It needs two keys: `FINIC_API_KEY`, your secret `gsk_…` [API key](/authentication), and `IDENTIFY_SITE_KEY`, a site's public `gpk_…` key ([create a site](/identify/quickstart#create-a-site)). ## Set it up [#set-it-up] For a site already proxied through Cloudflare. The Worker adds the script tag to your HTML pages itself, so your application doesn't change. In a new directory: ```js title="worker.js" export { default } from "@finic-ai/identify/cloudflare"; ``` ```toml title="wrangler.toml" name = "identify" main = "worker.js" compatibility_date = "2025-01-01" routes = [{ pattern = "{your_domain}/*", zone_name = "{your_domain}" }] [vars] IDENTIFY_SITE_KEY = "gpk_…" ``` ```bash npm init -y npm install @finic-ai/identify npm install -D wrangler npx wrangler secret put FINIC_API_KEY # paste your gsk_… key npx wrangler deploy ``` Optional: `IDENTIFY_ORIGIN_SECRET` (a secret, see [Trust the headers](#trust-the-headers)) and `IDENTIFY_SITE_ORIGIN` (your site's public origin, such as `https://www.example.com`). Needs Next.js 13.5.9, 14.2.25, 15.2.3 or later. Set `FINIC_API_KEY` and `IDENTIFY_SITE_KEY` in the environment. ```bash npm install @finic-ai/identify ``` ```ts title="middleware.ts" import { identifyMiddleware } from "@finic-ai/identify/next"; export default identifyMiddleware({ apiKey: process.env.FINIC_API_KEY!, siteKey: process.env.IDENTIFY_SITE_KEY!, }); ``` On Next.js 16 the file is `proxy.ts`. Don't add a `matcher` that leaves out pages or API routes: a request the middleware doesn't see keeps whatever `finic-*` headers its client sent. Add the tag inside `` in `app/layout.tsx`: ```tsx ``` With `data-visitor="off"` the snippet takes no fingerprint and neither reads nor sets `finic_visitor`. Sessions have no visitor; verdicts are the same. ## Where verdicts are computed [#where-verdicts-are-computed] On our servers, from the report, the request's address and user agent, and a [lookup](/identify/lookup) on them. A report is answered with the session id and, once the browser is identified, its visitor token, and nothing else: the verdict and the visitor's id are never given to the browser, which could change them. Your server reads it with your API key, or receives it from the [edge package](/identify/edge). ## The entity id [#the-entity-id] A session holds one thing that comes from you: its `entity_id`, your own id for the customer or account the session belongs to. It is empty until you set it, in one of two ways, and `entity_source` says which: | `entity_source` | Set by | Trust | | --------------- | ----------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------ | | `browser` | Your page, with `data-entity` on the tag or `finic.identify("user_123")` | The page's claim. Anyone can send any id from a browser, so don't rest a security decision on it | | `server` | Your server, with [`update_session`](/reference/identify/update-session) and your API key | Yours. Once your server has set or cleared the id, the page can't change it | The snippet sends an entity id only when your page gives it one. We store the string you send, with the session, and delete it with the session. It doesn't change the verdict. The API calls that set it, read it or list by it are kept in Finic's API log, as [Retention](#retention) says of every call. An id that means something only in your system, such as `user_123`, says less about a person than an email address does. ## Retention [#retention] A session (its IP address, user agent, page, latest report, verdict and entity id) is deleted 30 days after it starts. A [visitor](/identify/visitors) (its fingerprint's hashes, its browser and operating system, the last four addresses and networks it was seen at, and its token) is deleted a year after it was last seen, or when you [delete it](/reference/identify/delete-visitor). Your organization's [data retention](/grayson-api/data#data-retention) setting doesn't change either. Calls your server makes to the Identify API, such as a [lookup](/identify/lookup) or reading a session, are kept in Finic's API log like any other API request, with what was sent and what was answered and without your API key. That log isn't deleted after 30 days. ## Origins [#origins] A site's key is public, so any page could send reports under it. List the site's `origins` when you [create](/reference/identify/create-site) or [update](/reference/identify/update-site) it, and reports are taken only from those pages: ```bash curl -X PATCH https://api.finic.ai/v1/identify/sites/kst_01M4Z1X3G5P8D2F6J0YA4SMQNC \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{"origins": ["https://www.example.com", "https://shop.example.com"]}' ``` An origin is a scheme and host, such as `https://www.example.com`; up to 20 per site. With none listed, reports are taken from any page. Reports the [edge package](/identify/edge) relays carry your API key and are taken whatever the list, but a request signature on one is checked only when the site's origin is listed. ## Content-Security-Policy [#content-security-policy] | Setup | Your policy needs | | ---------------------------------- | ------------------------------------------------------------------------------------------------ | | The tag from `api.finic.ai` | `script-src https://api.finic.ai` and `connect-src https://api.finic.ai` | | The [edge package](/identify/edge) | `script-src 'self'` and `connect-src 'self'`: the snippet and its reports are on your own domain | On Cloudflare, the Worker gives the tag your page's nonce when the policy allows scripts by nonce. When it allows them only by hash or `'strict-dynamic'`, the Worker doesn't add the tag: add it to the page yourself. ## Limits [#limits] | Limit | Value | | ----------------------------- | -------------------------------------------------------------------- | | Reports from one address | 120 a minute. An IPv6 address counts as its /64 | | New sessions from one address | 20 a minute | | New sessions for one site | 10,000 an hour | | A report | 8 KB | | Reports from one page view | 40 | | A session | Takes reports for 12 hours. After that, the browser starts a new one | | Sites | 50 per organization | A report over a limit is dropped, not queued: it's answered `204` with an `X-Finic-Refused` header, and the snippet stops reporting for that page view. Nothing is printed in your page's console. Reports are dropped the same way, with `credit`, while your organization is [out of credit](/pricing#credit). API calls have their own [limits](/reference/identify#limits). ## Telling your visitors [#telling-your-visitors] The snippet reads device signals, fingerprints the browser and sets a cookie that lasts up to 400 days, and it doesn't ask anyone's permission. Tell your visitors. Where your jurisdiction requires consent for a fingerprint or a persistent identifier, as the EU and the UK generally do outside what is strictly necessary, load the tag with `data-visitor="off"` until you have it, or only after consent. When a person asks you to erase their data, [delete their visitor](/reference/identify/delete-visitor). # KYB (/kyb) KYB in Finic is a set of API endpoints for the businesses you onboard, such as merchants, sellers or suppliers. You send what a business tells you. Finic keeps it as records, screens it, and tells you what it finds. | Part | What it is | Endpoints | | ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------- | | **Businesses** | The central record: legal name, trade names, formation, website, contacts and your own `metadata`, with a status from `pending` to `approved`, `rejected` or `closed` | [Businesses](/reference/kyb/businesses) | | **Records** | A business's people, corporate owners, registrations and addresses, and the records screenings keep for it, such as the website they read | [Business records](/reference/kyb/records) | | **Screenings** | One check of one record, such as `sanctions` for a person or `address` for an address, with findings to review | [Screenings](/reference/kyb/screenings) | | **Verifications** | A package of screenings of a business and its records, with one outcome that sets the business's status | [Verifications](/reference/kyb/verifications) | | **Monitoring** | Screenings made again on a schedule, for each part of a business | [Businesses](/reference/kyb/businesses) | | **Events and webhooks** | What happened, in order, and sent to your endpoints as it happens | [Events](/reference/webhooks/events), [Webhooks](/reference/webhooks) | ## A first business [#a-first-business] Get an API key at [app.finic.ai](https://app.finic.ai) and set it as `FINIC_API_KEY`. Then create a business with one person and one address: ```bash curl https://api.finic.ai/v1/businesses \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "legal_name": "Acme Tools LLC", "external_id": "merchant_42", "entity_type": "llc", "formation": { "jurisdiction": { "country": "US", "state": "DE" } }, "website": "example.com", "country": "US", "addresses": [{ "kind": "registered", "line1": "8 The Green", "city": "Dover", "state": "DE", "country": "US" }], "people": [{ "first_name": "Grace", "last_name": "Hopper", "title": "CEO", "roles": ["control_person"] }] }' ``` The response is the business, `biz_…`, with `status` `pending`. Finic screens it at once: the business and Grace Hopper against sanctions lists, and the address against sanctioned jurisdictions. Each screening runs in the background. Read the results on the business's `screenings`, with [`list_screenings`](/reference/kyb/screenings), or as `screening.completed` [webhooks](/webhooks). Next: * [Businesses](/kyb/businesses): the fields, people and owners, statuses, and deleting. * [Screenings](/kyb/screenings): the kinds, findings and reviews. * [Verifications](/kyb/verifications): a package of screenings with one outcome, and its report. * [Monitoring](/kyb/monitoring): screening again on a schedule, and what changed. * [Webhooks](/webhooks) and [events](/webhooks/events): getting each change as it happens. ## Storage [#storage] Unlike scoring requests, the KYB endpoints **store what you send** until you delete it. Your data retention setting, including Zero Data Retention, applies to scoring requests, not to business records. See [Deleting](/kyb/businesses#deleting). ## Pricing [#pricing] Creating and reading records is free. Screenings that cost are charged from your credit when they complete: see [Prices](/kyb/screenings#prices). # Businesses (/kyb/businesses) A business is the central KYB record. Only `legal_name` is required; send what you know. | Field | What it is | | ----------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `legal_name` | The registered name. Required | | `external_id` | Your id for the business, unique among your businesses. Send it, so that a request made again is `409 business_exists`, with the existing `business_id`, and not a second business | | `trade_names` | The names it trades as | | `entity_type` | `llc`, `corporation`, `partnership`, `sole_proprietorship`, `nonprofit`, `trust`, `government` or `other` | | `formation` | Where and when it says it was formed: `{"jurisdiction": {"country": "US", "state": "DE"}, "date": "2019-04-02"}` | | `website`, `description`, `industry`, `country` | What it says it is and does. `country` is ISO 3166-1 alpha-2 | | `contacts` | Up to 20, each `{"type": "tel" or "email", "value": ...}`. Phone numbers are in international form, such as `+15555550100` | | `metadata` | Your own data, up to 16 KB | | `monitoring` | Screenings to make again on a schedule. See [Monitoring](/kyb/monitoring) | `jurisdiction`, here and on records, is an ISO 3166-1 alpha-2 `country` and, optionally, the ISO 3166-2 subdivision code without the country as `state`. ## People, owners and addresses [#people-owners-and-addresses] A business's other records are in collections, at `/v1/businesses/{id}/{collection}`. Send them in the create request as lists of up to 100 each, or add them later one at a time: | Collection | Fields (\* required) | | ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `people` | `first_name` or `last_name`*, `middle_name`, `name_suffix`, `title` (the job title), `roles`* (`shareholder`, `beneficial_owner`, `control_person`, `director`, `officer`, `signatory`), `percentage`, `date_of_birth`, `country`, `email`, `phone` | | `corporate_owners` | `legal_name`\*, `percentage`, `jurisdiction`, `linked_business_id` (when the owner is one of your businesses too) | | `registrations` | `kind`\* (`formation`, `foreign_qualification`, `tax_id`, `license`, `other`), `jurisdiction`\*, `number`, `name`, `status`, `issued_on`, `expires_on` | | `addresses` | `kind`\* (`registered`, `operating`, `mailing`, `other`), `line1`*, `country`*, `line2`, `city`, `state`, `postal_code` | ```bash curl https://api.finic.ai/v1/businesses/biz_01M4Z3Q8T6V2K9XR5HN7D1BCWE/people \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "first_name": "Ada", "last_name": "Lovelace", "title": "CFO", "roles": ["officer", "shareholder"], "percentage": 25, "email": "ada@example.com" }' ``` A record's fields are at its top level, beside `external_id`, `metadata`, `occurred_at` and `source_url`. A record with the same `external_id`, or the same identifying fields, replaces the one there. The shareholders' and corporate owners' percentages add up to at most 100, and a business can't own itself, directly or through others. Screenings and enrichment keep what they find as records of the business too: `websites`, and, where available, `registrations`, `liens`, `court_cases`, `bankruptcies` and `reviews`. Their `source` is `finic`. When you change one, it becomes yours, and Finic doesn't replace it again. ## Changing a business [#changing-a-business] `PATCH /v1/businesses/{id}` changes the fields sent. In `metadata`, `null` removes a key. `contacts` replaces the list. A change to a screened field, such as `legal_name`, screens it again, and an earlier answer is set aside. Change records at their own endpoints. ## Status [#status] A business is `pending` until you or a [verification](/kyb/verifications) changes it: | From | To | | ---------------------- | --------------------------------------------- | | `pending` | `in_review`, `approved`, `rejected`, `closed` | | `in_review` | `approved`, `rejected`, `closed` | | `approved`, `rejected` | `in_review`, `closed` | | `closed` | `in_review` | ```bash curl https://api.finic.ai/v1/businesses/biz_01M4Z3Q8T6V2K9XR5HN7D1BCWE/status \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "status": "approved" }' ``` Another change is `409 invalid_transition`. Each change is a `business.status_changed` event. ## Enrichment [#enrichment] `POST /v1/businesses/{id}/enrich` collects records about a business without judging them: no screening and no findings. `{"sources": ["website"]}` reads the business's site and keeps it as a `websites` record, free. Each source runs as a [job](/reference/score/get-job-status), and its `result` has the ids of the records kept. A source that isn't available to you answers `503 screening_unavailable`. ## Deleting [#deleting] `DELETE /v1/businesses/{id}` deletes a business with its records and screenings, and stops its jobs and monitoring. For 30 days you can bring it back with `POST /v1/businesses/{id}/restore`, which screens it again; after that, Finic removes it from its business records. With `?permanent=true`, and an API key an admin created, it's removed at once. A business that another business's record points to can't be deleted (`409 business_referenced`). Records of a business are deleted and restored the same way, at their own paths. # Screenings (/kyb/screenings) A screening is one check of one record. It runs in the background: the request answers `202` with the screening `pending`, and `screening.completed` comes when it ends. To check a business with a package of screenings and one outcome, see [Verifications](/kyb/verifications). To screen again on a schedule, see [Monitoring](/kyb/monitoring). ## Kinds [#kinds] | Kind | Checks | Of | | -------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------ | | `sanctions` | The name against the OFAC SDN and Consolidated, UN Security Council, EU and UK sanctions lists | Businesses, people, corporate owners | | `jurisdiction` | Whether the address is in a sanctioned country or region | Addresses | | `address` | Whether the address looks like a registered agent, virtual office or mail forwarder, or doesn't look real | Addresses | | `website` | The business's site and domain, compared with what the business told you | Businesses | [`list_screening_kinds`](/reference/kyb/screenings) lists every kind, with its fields, its [price](#prices) and whether it's available to you now. `sanctions` and `jurisdiction` run by themselves when a record is created, when a screened field changes, and when it's restored. Other kinds run when you ask for them: ```bash curl https://api.finic.ai/v1/businesses/biz_01M4Z3Q8T6V2K9XR5HN7D1BCWE/screen \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "kinds": ["website"] }' ``` To choose the kinds when you create a business, send `screening`, with kinds for each part. A part you leave out has the automatic kinds; `[]` starts none: ```json "screening": { "business": ["sanctions", "website"], "people": ["sanctions"], "addresses": ["jurisdiction", "address"] } ``` You can also screen data that isn't a record, such as an address from a form. It isn't kept as a record: ```bash curl https://api.finic.ai/v1/screenings \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "kind": "address", "input": { "line1": "8 The Green", "city": "Dover", "state": "DE", "country": "US" } }' ``` ## Prices [#prices] | Kind | Price per screening | | -------------- | ------------------------------------------------------------- | | `sanctions` | $0.05, the same as the `sanctions_screening` scoring endpoint | | `address` | $0.005 | | `website` | $0.10 | | `jurisdiction` | Free | A screening is charged from your credit when it completes. A screening that answers nothing, such as one that ends `inconclusive` because the check couldn't be made, costs nothing. Monitoring runs and the screenings of a verification are priced the same. A screening that costs waits while your organization has no credit, and runs when credit is added. ## States and findings [#states-and-findings] | State | Meaning | | ---------------- | ------------------------------------------------- | | `pending` | Not screened yet. `reason` says what it waits for | | `clear` | The check was made and found nothing to review | | `needs_review` | A finding is undecided | | `confirmed` | A reviewer confirmed a finding | | `false_positive` | A reviewer dismissed every finding | | `inconclusive` | The check couldn't be made. `reason` says why | A check that isn't made is never `clear`. A **finding** is `{id, code, severity, summary, details, fingerprint, decision}`. Severity `info` needs no review. | Kind | Finding codes | | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `sanctions` | `list_match` (the list entry is in `details`, at most 10), `name_not_latin` (the lists are in Latin script, so finding nothing says little) | | `jurisdiction` | `sanctioned_jurisdiction`, `region_missing` | | `address` | `registered_agent`, `virtual_office`, `mail_forwarding`, `doubtful_address`, `residential` (info) | | `website` | Of the site: `unreachable`, `placeholder`, `restricted_products`, `name_mismatch`, `impersonates_brand`, `undeclared_products`, `industry_mismatch`, `address_mismatch`, `contact_mismatch`, `people_mismatch`, `no_contact`, `missing_policies`. Of its domain: `domain_expired`, `domain_on_hold`, `domain_unresolved`, `domain_new`, `no_https`, `certificate_invalid`, `domain_recent`, `platform_domain`, `no_mail`, `certificate_organization`, `email_other_domain`, `email_free`, `domain_expiring`, `certificate_expiring`, `mail_unprotected` | `address` and `website` are Finic's estimates from the address as written and the pages read. `address` doesn't consult postal records, so it doesn't prove that an address exists. ## Reviews [#reviews] Decide a screening's findings with `POST /v1/screenings/{id}/review`: `confirmed` or `false_positive`, for the findings in `finding_ids` or all of them, with an optional `note`. ```bash curl https://api.finic.ai/v1/screenings/scr_01M4Z3S0A2B4C6D8E0F2G4H6JK/review \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "decision": "false_positive", "note": "Different date of birth and country." }' ``` A decision carries to a later screening of the same record and kind while the input and the finding are unchanged. # Verifications (/kyb/verifications) A verification is a package of screenings of a business and its records, with one outcome. Start one with `POST /v1/businesses/{id}/verify`, or with `"verify": true` in the create request. Send kinds for each part, or no body for each part's package. | Outcome | When | | ----------- | ------------------------------------------------------------------------------------------------------------------- | | `rejected` | A reviewer confirmed a high or medium finding, or there's a `sanctioned_jurisdiction` finding that no one dismissed | | `in_review` | A required check wasn't made, or a high or medium finding is undecided | | `approved` | Anything else | A check that can't be made is `skipped`, with the reason; a required one puts the outcome `in_review`. The business's status becomes the outcome, with `business.status_changed`. A `closed` business stays closed and can't be verified (`409 business_closed`). The request answers at once, `202` while the verification is `pending`: get `verification.completed` by [webhook](/webhooks), or send `?wait=` (up to 50 seconds) to wait for the outcome. When a screening in it ends or is reviewed later, the verification is decided again (`verification.updated`). A complete verification has a report, as JSON at `.../report` and as a PDF at `.../pdf`. A verification's `score`, 0 to 1000, sums up its checks' findings and reviews. It isn't a calibrated probability. The checks in a verification are [screenings](/kyb/screenings), priced the same way ([prices](/kyb/screenings#prices)), and you review their findings the same way ([reviews](/kyb/screenings#reviews)). # Monitoring (/kyb/monitoring) Monitoring keeps a business's [screenings](/kyb/screenings) current. Finic screens the business and its records again on a schedule, and you get an [event](/webhooks/events) for each run and for each change it finds. ## Turn it on [#turn-it-on] `monitoring`, on a business when you create it or in a `PATCH`, screens again every `interval_days` (1 to 365), with kinds for each part: ```json "monitoring": { "interval_days": 30, "business": ["sanctions", "website"], "people": ["sanctions"], "addresses": ["jurisdiction"] } ``` The first run is one interval later (`next_run_at`). A monitored kind also runs again when what it screens changes. Each run is priced as any screening. `null` stops monitoring, and nothing runs while the business is `rejected`, `closed` or deleted. Each run is a `monitoring.run` event. ## Changes [#changes] A screening made again is compared with the record's last one of the same kind and input. When findings came or went, or what was checked changed (such as a website's content or its domain's registration), the screening's `result.changes` has the values, and a `screening.changed` event names them. Use it to see what a monitoring run found new. # Webhooks (/webhooks) A webhook sends each Finic [event](/webhooks/events) to your HTTPS endpoint as it happens, so you don't have to poll. Webhooks and events belong to your whole organization, not to one product. Today the events come from [KYB](/kyb): business records, screenings, verifications and monitoring. Scores, ask and Identify don't send events yet. ## Add an endpoint [#add-an-endpoint] Add an endpoint with an API key an admin created. `url` must be public and `https`. `event_types` takes types, groups such as `screening.*`, or `*`: ```bash curl https://api.finic.ai/v1/webhook_endpoints \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "url": "https://example.com/webhooks/finic", "event_types": ["screening.*", "verification.completed", "business.status_changed"] }' ``` The response has the signing `secret`, `whsec_…`, shown only this once. Keep it. An organization has at most 20 endpoints. You can also manage endpoints in the Finic app, under **Settings → Webhooks**. Each delivery is a `POST` of the event, as [`GET /v1/events`](/webhooks/events#reading-events) shows it. ## Verify the signature [#verify-the-signature] Deliveries are signed by the [Standard Webhooks](https://www.standardwebhooks.com) specification, with three headers: `webhook-id` (the event's id), `webhook-timestamp` (Unix seconds) and `webhook-signature`. The signature is `v1,` and the base64 HMAC-SHA256 of `..`, keyed with the secret's bytes after `whsec_`, base64-decoded. The Standard Webhooks libraries check it for you (`pip install standardwebhooks`): ```python from standardwebhooks.webhooks import Webhook wh = Webhook(FINIC_WEBHOOK_SECRET) # "whsec_..." def handle(request): event = wh.verify(request.body, request.headers) # raises if the signature is wrong ... ``` Check the signature on the raw body, before parsing it. Refuse a timestamp that's minutes old. After you rotate the secret (`POST /v1/webhook_endpoints/{id}/rotate_secret`), deliveries are signed with the old secret too, for 24 hours, so `webhook-signature` can hold two signatures, separated by a space. ## Delivery and retries [#delivery-and-retries] * Answer with a `2xx` within 10 seconds. Do the work after you answer. * Otherwise Finic tries again after 5 seconds, 5 minutes, 30 minutes, and 2, 5, 10 and 14 hours. After that, the delivery is `failed`. * Redirects aren't followed. * Delivery is at least once, and in no set order. Use `webhook-id` to skip an event you've had, and `seq` to put events in order. * An endpoint that answers `410`, or fails for 5 days with no delivery taken, is disabled (`webhook_endpoint.disabled`), and what it has yet to get is cancelled. Events while it's disabled aren't sent later: read them from `GET /v1/events`, then turn the endpoint on again with `PATCH` and `"status": "enabled"`. `GET /v1/webhook_deliveries` lists deliveries, with each one's status, attempts and the HTTP status your endpoint answered with. Send one again with `POST /v1/webhook_deliveries/{id}/retry`, and a test event with `POST /v1/webhook_endpoints/{id}/test`. Finished deliveries are kept for 30 days. # Events (/webhooks/events) An **event** says what happened: a business created or its status changed, a screening completed or needing review, a verification completed. Each one is numbered in order for your organization. Read them from `GET /v1/events`, or have them sent to your endpoint by [webhook](/webhooks). Today Finic's events come from [KYB](/kyb). ## Event types [#event-types] | Group | Types | | ---------------- | ---------------------------------------------------------------------------------------------------------------------------- | | `business.*` | `created`, `updated`, `status_changed`, `deleted`, `restored` | | `object.*` | `created`, `updated`, `deleted`, `restored` (a business's records) | | `screening.*` | `completed`, `review_needed`, `reviewed`, `changed`, `deleted` | | `verification.*` | `completed`, `updated` | | Others | `monitoring.run`, `enrichment.completed`, `webhook_endpoint.created`, `.updated`, `.deleted`, `.disabled`, `.secret_rotated` | | `custom.*` | Your own, recorded with `POST /v1/events` | [`list_webhook_event_types`](/reference/webhooks) lists them all. An event holds ids, states, outcomes, scores, codes and the names of changed fields, never the values that were sent or found. Read the record it names for more. `actor_type` says who caused it: `api_key`, `user` (a member in the Finic app) or `finic`. ```json { "id": "evt_01M4Z3V4P6Q8R0S2T4V6W8X0YZ", "seq": 1042, "type": "screening.completed", "subject_type": "screening", "subject_id": "scr_01M4Z3S0A2B4C6D8E0F2G4H6JK", "business_id": "biz_01M4Z3Q8T6V2K9XR5HN7D1BCWE", "actor_type": "finic", "actor_id": "", "data": { "kind": "sanctions", "state": "clear" }, "created_at": "2026-12-02T15:04:06Z" } ``` ## Reading events [#reading-events] `GET /v1/events` lists events oldest first. `seq` counts up from 1 for your organization, without gaps: keep the last `seq` you read and send it as `after`, and you miss nothing. ```bash curl "https://api.finic.ai/v1/events?after=1041&limit=100" \ -H "Authorization: Bearer $FINIC_API_KEY" ``` Filter with `business_id`, `subject_id` or `type`. ## Your own events [#your-own-events] Record an event of your own, such as a manual check, with a type that starts with `custom.`. It's sent to webhooks like Finic's, and its `data` is kept as you sent it: ```bash curl https://api.finic.ai/v1/events \ -H "Authorization: Bearer $FINIC_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "type": "custom.call_completed", "business_id": "biz_01M4Z3Q8T6V2K9XR5HN7D1BCWE", "data": { "outcome": "owner_confirmed" } }' ``` # API reference (/reference) Base URL `https://api.finic.ai`. Send an API key as `Authorization: Bearer gsk_…` ([Authentication](/authentication)) and JSON bodies (`Content-Type: application/json`); `score`, `create_model` and `calibrate` also take `multipart/form-data`. Every response has an `X-Request-Id` header. ### Scores and decisions [#scores-and-decisions] | Endpoint | Request | What it does | | ------------------------------------------------------- | ------------------------------------------------------------ | ----------------------------------------------------------------------------------- | | [`score_use_case`](/reference/score/score-use-case) | `POST /v1/score/{use_case}` | Scores one request for a use case from 0 to 1000, with no setup | | [`score`](/reference/score/score) | `POST /v1/score` | Scores one record from 0 to 1000 | | [`list_events`](/reference/score/list-events) | `GET /v1/score/events` | Lists the records that were scored | | [`get_event`](/reference/score/get-event) | `GET /v1/score/events/{id}` | Gets one event, with what was scored and each question's answer | | [`create_model`](/reference/score/create-scoring-model) | `POST /v1/score/models` | Creates a scoring model from its criteria or from labeled records | | [`list_models`](/reference/score/list-scoring-models) | `GET /v1/score/models` | Lists your scoring models, with what each predicts | | [`get_model`](/reference/score/get-scoring-model) | `GET /v1/score/models/{model_id}` | Gets a scoring model, with its questions and their weights | | [`add_questions`](/reference/score/add-questions) | `POST /v1/score/models/{model_id}/questions` | Adds your own questions to a scoring model | | [`remove_question`](/reference/score/remove-question) | `DELETE /v1/score/models/{model_id}/questions/{question_id}` | Removes a question from a scoring model | | [`update_model`](/reference/score/update-scoring-model) | `PATCH /v1/score/models/{model_id}` | Renames a scoring model, changes its criteria, or archives or unarchives it | | [`delete_model`](/reference/score/delete-scoring-model) | `DELETE /v1/score/models/{model_id}` | Deletes a scoring model (admins only) | | [`calibrate`](/reference/score/calibrate) | `POST /v1/calibrate` | Sends labeled records, to fit a scoring model to your data and change its questions | | [`get_job_status`](/reference/score/get-job-status) | `GET /v1/jobs/{job_id}` | Whether creating or calibrating has finished | | [`ask`](/reference/grayson/ask) | `POST /v1/ask` | Answers your questions about a case | The model endpoints were at `/v1/scoring_models` before; those paths still work. ### KYB [#kyb] These endpoints store what you send, until you delete it. See [KYB](/kyb). | Endpoints | Requests | What they do | | --------------------------------------------- | ----------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | | [Businesses](/reference/kyb/businesses) | `/v1/businesses` | Create, list, change, delete, screen and enrich businesses | | [Business records](/reference/kyb/records) | `/v1/businesses/{id}/{collection}` | A business's people, corporate owners, registrations, addresses and the records screenings keep | | [Verifications](/reference/kyb/verifications) | `/v1/businesses/{id}/verify`, `/v1/businesses/{id}/verifications` | A package of screenings with one outcome, and its report | | [Screenings](/reference/kyb/screenings) | `/v1/screenings` | Screen a record or data you send, and review the findings | | [Events](/reference/webhooks/events) | `/v1/events` | What happened to your records, in order | | [Webhooks](/reference/webhooks) | `/v1/webhook_endpoints`, `/v1/webhook_deliveries` | Events sent to your endpoints | Lists take `limit` (1 to 100, default 50) and `after` (the last record's `id`; for events, its `seq`), and answer `{"data": [...], "has_more": false}`. ## Errors [#errors] A failed request returns an error status and this JSON: ```json { "error": { "type": "invalid_request", "message": "\" Yes\" appears twice in the criteria.", "param": "questions.q.criteria" } } ``` `type` is one of the types below: branch on it. `message` is for people and can change, so don't parse it. `param` is the dotted path to the field at fault, or `null`. Validation stops at the first problem. | HTTP | `type` | When | Retry | | ----- | ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- | | `400` | `invalid_request` | Malformed JSON, or the request breaks a rule of its endpoint | No. Fix the request | | `400` | `schema_mismatch` | A record sent to [`score`](/reference/score/score), or a labeled record sent to [`calibrate`](/reference/score/calibrate), has fields that differ from its scoring model's [schema](/score-model#schema) | No. Fix the records. A score call can send `skip_schema_validation` or `update_schema` | | `401` | `authentication_error` | Missing or invalid API key, including a revoked key | No. Check the key | | `402` | `insufficient_credit` | The organization's credit is used up (ask, score and scoring endpoint calls; a KYB screening that costs waits for credit instead) | No. An admin adds credit in the [Finic app](https://app.finic.ai) under **Settings → Billing** | | `403` | `plan_required` | Creating or unarchiving a scoring model when the organization has as many as its plan includes: none on Free, 5 on Starter, 20 on Growth | No. Archive or delete one, or upgrade the plan under **Settings → Billing** | | `403` | `permission_denied` | [`delete_model`](/reference/score/delete-scoring-model) with an API key an admin of the organization didn't create | No. Use an admin's key, or archive the scoring model instead | | `404` | `model_not_found` | Unknown `model` in an ask request | No. Use `grayson-1` | | `404` | `scoring_model_not_found` | No scoring model with that `model_id` in your organization | No. Check the `model_id` | | `404` | `question_not_found` | The scoring model has no question with that id | No. Check the id with [`get_model`](/reference/score/get-scoring-model) | | `404` | `use_case_not_found` | No [scoring endpoint](/score-api) with that name | No. The message lists the scoring endpoints | | `404` | `_not_found` | KYB: no such business, record, screening, verification or webhook endpoint in your organization, such as `business_not_found` | No. Check the id | | `404` | `job_not_found` | No job with that id in your organization | No. Check the `job_id` | | `404` | `invalid_request` | A path or method the API doesn't have | No. Fix the URL | | `409` | `scoring_model_not_ready` | The scoring model is still being created, or creating it failed | After its [job](/reference/score/get-job-status) completes. If the job failed, create the scoring model again | | `409` | `scoring_model_archived` | The scoring model is archived | After someone unarchives it, with [`update_model`](/reference/score/update-scoring-model) or in the Finic app | | `409` | `no_questions` | A score call to a scoring model with no questions yet (created from its criteria, with none added) | After you [add questions](/reference/score/add-questions) or [calibrate](/reference/score/calibrate) it | | `409` | `duplicate_score_id` | The scoring model already has a call with this `score_id` | No. Use a new `score_id` for each record | | `409` | `calibration_in_progress` | The scoring model is already being calibrated, so it can't be calibrated or have its questions changed | After that calibration's job completes | | `409` | `question_in_use` | [`remove_question`](/reference/score/remove-question) on a question the calibrated score uses | No. Remove it with `remove_questions` when you [calibrate](/reference/score/calibrate) | | `409` | `business_exists` | KYB: a business already has this `external_id`. The error has its `business_id` | No. Use that business | | `409` | `invalid_transition` | KYB: a business can't go from its status to the one sent | No | | `409` | `conflict` | The scoring model changed at the same moment as a question change | Yes | | `413` | `request_too_large` | A body over 2 MB, an ask request over 32,768 tokens, or a record too large to score | No. Send less | | `429` | `rate_limited` | Over the request rate, or a daily limit (100 new scoring models per organization; 10 calibrations and 50 changes per scoring model) | The request rate: yes, with backoff. A daily limit: after it resets | | `500` | `internal_error` | Something failed on Finic's side | Yes | | `503` | `screening_unavailable` | KYB: a screening kind asked for isn't available right now | Yes, later | | `503` | `overloaded` | Temporarily at capacity, an ask request didn't finish within 30 seconds, or creating scoring models or adding questions isn't available right now | Yes, with backoff | * **Out of credit,** ask and score calls get `402` before their data is checked; creating and calibrating never do. * **A `502` or `504`** from the network edge, during a deployment or an outage, has no JSON body or `X-Request-Id`: treat it like `503`. * **`202` from `create_model` (with labeled records) and `calibrate`** means accepted, with the work running in a job. A failed job reports its error at [`get_job_status`](/reference/score/get-job-status), in the same shape without `param`. Created from its criteria alone, a scoring model returns `201`, ready at once. * **A `429`** for the request rate says `Too many requests for this organization: the limit is 5 requests per second across its API keys and the playground.` and clears in moments. A daily limit's (`This organization has created 100 scoring models in the last 24 hours, the limit.`) doesn't, so retrying soon fails the same way. Some `invalid_request` errors: | Cause | `param` | `message` | | ---------------------------------------------------------------- | ------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `data` of only whitespace | `data` | `data must not be blank` | | An ask request with neither `data` nor `context` | `data` | `data is required: the JSON object, JSON array or text the questions are about. Free text can go in context.` | | Creating a scoring model with neither `criteria` nor `data` | `criteria` | `criteria is required to create a scoring model without labeled records: what the decision is and what a bad outcome means. Or send labeled records as data.` | | A question name starting with a digit | `questions.1st` | `invalid name '1st': must match ^[A-Za-z_][A-Za-z0-9_]{0,63}$` | | Two options whose descriptions differ only in case or whitespace | `questions.q.criteria` | `" Yes" appears twice in the criteria.` | | A noul's criteria with a key other than `true` or `false` | `questions.q.criteria` | `A noul's criteria can only describe "true" and "false", each as text.` | | A choice's `base_rate` shares that don't add up to 1 | `questions.q.base_rate` | `A choice's base_rate shares must add up to 1.` | | An unknown top-level field, such as `temperature` | `null` | `Unknown field "temperature".` | | An unknown field inside a question | `questions.q.temperature` | `Extra inputs are not permitted` | | A score call without `score_id` | `score_id` | `score_id is required: your unique id for this record's score.` | | A score call whose `data` holds several records | `data` | `data must hold one record; got 3. Send one score call per record.` | | A calibration without labeled records | `data` | `data is required: labeled records with the fields of the records this scoring model scores, each with is_bad (true when it turned out bad).` | | A calibration whose `remove_questions` would leave none | `remove_questions` | `Removing these leaves no questions to score with. Keep one, or add questions.` | | Emptying a scoring model's criteria before it's calibrated | `criteria` | `criteria can't be empty until the scoring model is calibrated: Finic writes its questions from it.` | ### Retrying [#retrying] * **`ask`** is safe to retry; a retry of a request that succeeded is answered again. * **`score`** with the same `score_id` scores a record once: if the first call succeeded, the retry gets `409 duplicate_score_id`, without the score. * **`create_model`** retried after a timeout can create a second scoring model, counted toward the daily limit. * **`calibrate`** retried while the first call's job runs gets `409 calibration_in_progress`. Retried after it, it calibrates again, counted toward the daily limit. * **`add_questions`** retried after a timeout that had succeeded gets `400 invalid_request`: the question is already one of the scoring model's. * **`remove_question`** retried after it succeeded gets `404 question_not_found`. * **`update_model`** is safe to retry. **`delete_model`** retried after it succeeded gets `404 scoring_model_not_found`. * **`list_models`, `get_model` and `get_job_status`** are always safe. Retry `429` (except a daily limit), `500`, `502`, `503`, `504`, network errors and timeouts with exponential backoff and jitter; don't retry other `4xx` without changing the request. Set client timeouts above 30 seconds, the longest an ask request can run. ```python import random import time import requests RETRYABLE = {429, 500, 502, 503, 504} def post(path: str, body: dict, api_key: str, attempts: int = 5) -> dict: for attempt in range(attempts): last = attempt == attempts - 1 try: response = requests.post( f"https://api.finic.ai{path}", # "/v1/ask" or "/v1/score" headers={"Authorization": f"Bearer {api_key}"}, json=body, timeout=60, ) except (requests.ConnectionError, requests.Timeout): if last: raise else: if response.status_code not in RETRYABLE or last: break time.sleep(min(8.0, 0.5 * 2**attempt) * random.uniform(0.5, 1.0)) if not response.ok: request_id = response.headers.get("X-Request-Id") try: error = response.json()["error"] except ValueError: # an edge 502/504 has no JSON body raise RuntimeError(f"{response.status_code} (request {request_id})") raise RuntimeError(f"{response.status_code} {error['type']}: {error['message']} (request {request_id})") return response.json() ``` For help, email [support@finic.ai](mailto:support@finic.ai) with the `X-Request-Id`. Support sees a request's time, key, endpoint, status and error type, not its content: if the problem depends on the content, describe it or send a redacted example. ## Limits [#limits] | Limit | Value | | ------------ | ---------------------------------------------------- | | Request body | 2 MB | | Request rate | 5 per second per organization, in bursts of up to 10 | ### Rate limits [#rate-limits] The request rate covers all of an organization's API keys, agent sign-ins and playground runs, for every endpoint but [`get_job_status`](/reference/score/get-job-status). Requests over it get `429 rate_limited`, with no `Retry-After` header: retry with exponential backoff ([Retrying](#retrying)). For higher volume, contact [support@finic.ai](mailto:support@finic.ai). ### Scoring models [#scoring-models] | Limit | Value | | ------------------------------------------------------ | ----------------------------------------------------------------------------- | | Labeled records to create or calibrate a scoring model | At least 100, with at least 20 where `is_bad` is true and 20 where it's false | | Rows used | Up to 2,000; more are sampled down, keeping the mix of outcomes | | A row, or a record to score | 60,000 bytes as compact JSON | | `name` | 100 characters | | `criteria` | 4,000 characters | | Your questions (`add_questions`) | 20 per request, 50 per scoring model (used or not), 500 characters each | | Changes to a scoring model | 50 per 24 hours: questions added or removed, calibrations, and creating it | | `score_id` | 200 characters, unique within the scoring model | | New scoring models | 100 per organization per 24 hours | | Calibrations | 10 per scoring model per 24 hours, one at a time | | Creating or calibrating a scoring model | About two minutes from labeled records; at once from its criteria alone | Over a daily limit, requests get `429 rate_limited` until the 24 hours pass. Over a question limit, they get `400 invalid_request`. ### Ask [#ask] | Limit | Value | | ------------------------------------------------------------- | --------------- | | Tokens per request (`data` + `context` + questions + markers) | 32,768 | | Questions per request | 1–128 | | Options per `choice` or `multi_choice` | 2–255 | | Question and option key length | 1–64 characters | Over a limit, a request gets `400 invalid_request`, or `413 request_too_large` for tokens and body size. ### How tokens are counted [#how-tokens-are-counted] `usage.input_tokens` counts everything the model reads: * **`data` and `context`:** a string as sent, an object or array as compact JSON. * **A `noul` or `choice` question:** its instructions and criteria, plus 2 marker tokens per question and 1 per option. * **A `multi_choice`:** each option is asked separately, so each costs the instructions, the list of all options (with 16 or fewer), the option and 2 markers. One with 8 options reads its instructions 8 times. Question names and option keys aren't read, so they don't count. To size requests, send a representative one and read `usage.input_tokens`; see [Data & context](/grayson-api/data#size) for fitting a long history. ## Earlier names [#earlier-names] `POST /v1/decide` is the earlier name of [`ask`](/reference/grayson/ask). It still works and answers the same way. In [`calibrate`](/reference/score/calibrate), `examples` is accepted as the earlier name of `data`. # score_use_case (/reference/score/score-use-case) One scoring endpoint for each use case, such as `POST /v1/score/account_opening`. Send what you know in `context`; each [scoring endpoint's page](/score-api) lists its fields. To score with questions of your own, [create a scoring model](/reference/score/create-scoring-model) and call [`score`](/reference/score/score). ## POST https://api.finic.ai/v1/score/{use_case} Scores one request for a use case with Finic's out-of-the-box score for it: an integer from 0 (lowest risk) to 1000 (highest), with the questions behind it and the probability that each one's answer is yes. Nothing to create or train first: pick the endpoint for your use case and send what you know in `context`. | `use_case` | Use case | Required in `context` | Per call | | --- | --- | --- | --- | | [`account_opening`](/score-api/endpoints/account-opening) | Account opening | `email` | $0.005 | | [`account_takeover`](/score-api/endpoints/account-takeover) | Account takeover detection | `activity` | $0.002 | | [`job_applicant`](/score-api/endpoints/job-applicant-fraud) | Job applicant fraud | `resume` | $0.01 | | [`payment`](/score-api/endpoints/payments) | Payments and orders | `order` | $0.005 | | [`payout`](/score-api/endpoints/payouts) | Payouts and withdrawals | `payout` | $0.005 | | [`scam`](/score-api/endpoints/scam-detection) | Real-time scam detection | `payment` | $0.005 | | [`merchant`](/score-api/endpoints/merchant-monitoring) | Merchant monitoring | `name`, `website` | $0.10 | | [`customer_risk`](/score-api/endpoints/customer-risk-rating) | Customer risk rating | `customer` | $0.01 | | [`sanctions_screening`](/score-api/endpoints/sanctions-screening) | Sanctions screening | `name` | $0.05 | | [`policy_abuse`](/score-api/endpoints/policy-abuse) | Policy abuse | `claim` | $0.002 | | [`content`](/score-api/endpoints/content-moderation) | Content moderation | `content` | $0.002 | | [`bot`](/score-api/endpoints/bot-detection) | AI agent and bot detection | `session` | $0.002 | | [`ai_token_fraud`](/score-api/endpoints/ai-token-fraud) | AI token fraud | `activity` | $0.002 | A call is charged its price only when it returns a score. Each use case's page lists its fields; every use case also takes `other_context`, for anything else that helps. Two use cases add to the response: `merchant` reads the merchant's website and returns what it read as `website`, and `sanctions_screening` screens the name against sanctions lists and returns `matches` and `lists`. A name with no match scores 0, with no questions. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `use_case`: The use case. See the table above. ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `context` | object | yes | What you know about the request, under the use case's field names: see the use case's page for its fields and which are required. Each value can be text, a number, an object or a list, as you have it. Put anything else that helps in `other_context`. | Example: ```json { "context": { "email": "xk92.bnq@proton.me", "address": "8 The Green, Suite A, Dover, DE 19901", "ip": { "address": "198.51.100.23", "country": "DE", "is_vpn": true, "is_datacenter": true }, "device": { "os": "Android 14", "model": "sdk_gphone64_x86_64", "is_emulator": true, "first_seen": "2026-11-25T14:02:11Z", "signups_last_hour": 3 } } } ``` ### Responses - **200**: The score. | Field | Type | Always | Description | | --- | --- | --- | --- | | `score` | integer | yes | The risk: 0 is the lowest, 1000 the highest. | | `questions` | array of object | yes | | | `website` | object | | `merchant` only: the site that was read. | | `matches` | array of object | | `sanctions_screening` only: the list entries whose names match, closest first. Empty when none does. | | `lists` | object | | `sanctions_screening` only: the lists screened and when they were loaded. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `questions[].text` | string | yes | One of the questions behind the score. | | `questions[].probability` | number | yes | The probability that the answer is yes. | | `website.url` | string | | | | `website.reached` | boolean | | | | `website.pages_read` | integer | | | | `website.title` | string | | | | `website.error` | string | | Why the site couldn't be read, when it couldn't. | | `matches[].list` | string | | The list, such as `OFAC SDN`. | | `matches[].id` | string | | The entry's number on its list. | | `matches[].name` | string | | | | `matches[].type` | `individual`, `entity`, `vessel`, `aircraft` | | | | `matches[].matched_name` | string | | The entry's name or alias that came closest. | | `matches[].similarity` | number | | How close it came | | `matches[].programs` | array of string | | | | `matches[].aliases` | array of string | | | | `matches[].dates_of_birth` | array of string | | | | `matches[].nationalities` | array of string | | | | `matches[].address_countries` | array of string | | | | `lists.names` | array of string | | | | `lists.entries` | integer | | | | `lists.loaded_at` | string | | | ```json { "score": 912, "questions": [ { "text": "Does the email address look machine-generated?", "probability": 0.91 }, { "text": "Is the sign-up coming from an emulator or a virtual device?", "probability": 0.97 }, { "text": "Has this device been used for other recent sign-ups?", "probability": 0.88 }, { "text": "Does the address look like a registered-agent or mail-forwarding address?", "probability": 0.83 } ], "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` - **400**: `invalid_request`: the body isn't `{"context": {...}}`, a required field of the use case is missing or empty (`param` names it, such as `context.email`), or a field's value can't be used (such as a `sanctions_screening` `name` that isn't a full name). - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `use_case_not_found`: no use case with this name. The message lists them. - **413**: `request_too_large`: over 2 MB, or the record is too large. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. - **503**: `overloaded`: temporarily at capacity. Retry with backoff. # score (/reference/score/score) See [Scoring models](/score-model). To see the questions behind a score, send `include_questions` ([Questions and weights](/score-model#questions-and-weights)). ## POST https://api.finic.ai/v1/score Scores one record with a scoring model you [created](/reference/score/create-scoring-model): an integer from 0 (lowest risk) to 1000 (highest). Once the scoring model is calibrated, it's about the probability of a bad outcome times 1,000; before then, scores rank records but their scale is an estimate. The record must have the fields of the scoring model's [schema](/score-model#schema), if it has one. A scoring model needs questions to score: one created from its criteria alone has none until you [add your own](/reference/score/add-questions) or [calibrate](/reference/score/calibrate) it. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json or multipart/form-data) | Field | Type | Required | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id, from [create_model](/reference/score/create-scoring-model). | | `score_id` | string | yes | Your unique id for this record's score, unique within the scoring model. | | `data` | object or array of object or string | yes | One record, with the fields of the scoring model's labeled records (one created from its criteria alone takes any record until it's calibrated). A JSON object (or an array holding one), or CSV text with a header and one row. Up to 60,000 bytes as compact JSON. An `is_bad` field is ignored. | | `skip_schema_validation` | boolean | | Score the record even if its fields differ from the scoring model's [schema](/score-model#schema). | | `update_schema` | boolean | | Score it and make its fields the schema from now on. | | `include_questions` | boolean | | Also return the questions the score used, each with Grayson's probability of yes for this record and its weight. | Example: ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "score_id": "pay_88213", "data": { "amount_usd": 1850, "merchant_category": "electronics", "account_age_days": 6, "new_device": true, "billing_country": "US", "ip_country": "RO" } } ``` ### Responses - **200**: The score. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id | | `score_id` | string | yes | As sent. | | `score` | integer | yes | 0 (lowest risk) to 1000 (highest). Once the scoring model is calibrated, score ÷ 1000 is about the probability of a bad outcome; before then, the scale is an estimate. | | `questions` | array of object | | Only with `include_questions`. The questions the score used, the strongest first. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `questions[].id` | string | yes | The question's id. | | `questions[].text` | string | yes | The question. | | `questions[].probability` | number | yes | Grayson's probability that the answer is yes for this record. | | `questions[].weight` | number | yes | Its weight, as in [get_model](/reference/score/get-scoring-model). | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "score_id": "pay_88213", "score": 874, "request_id": "req_01M4YF1068X8B4C458ENPD4JHT" } ``` - **400**: - `invalid_request`: `model_id` or `score_id` is missing, `score_id` is over 200 characters, or `data` isn't one record. - `schema_mismatch`: the record's fields differ from the scoring model's schema. The message lists them. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - **409**: - `scoring_model_not_ready`: the scoring model is still being created (check its job), or creating it failed (create it again). - `scoring_model_archived`: the scoring model is archived. Unarchive it with [update_model](/reference/score/update-scoring-model) or in the Finic app to use it again. - `no_questions`: the scoring model has no questions yet. Add your own with [add_questions](/reference/score/add-questions), or calibrate it with labeled records. - `duplicate_score_id`: this scoring model already has this `score_id`. A retry of a call that timed out but succeeded gets this, without the first call's score. - **413**: `request_too_large`: over 2 MB, or the record is too large. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. - **503**: `overloaded`: temporarily at capacity. Retry with backoff. # list_events (/reference/score/list-events) Every score is an event, whichever model scored it and wherever the call came from. The same list is under **Events** in the Finic app. ## GET https://api.finic.ai/v1/score/events Lists your organization's events, newest first. An event is one record that was scored, with a scoring model or a pre-made one, through the API, an MCP tool or the Finic app. A call that failed is an event too, with no score. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `model`: A model's `model_id`, to list only its events. - Query parameter `limit`: How many events to return, 1 to 100. More than 100 returns 100. - Query parameter `before`: An event's `id`: lists the events older than it. Send the last event of a page to get the next. ### Responses - **200**: A page of events. | Field | Type | Always | Description | | --- | --- | --- | --- | | `events` | array of object | yes | The events, newest first. | | `has_more` | boolean | yes | Whether there are older events than these. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `events[].id` | string | yes | The event's id: the `request_id` of the call that scored it. | | `events[].created_at` | string | yes | | | `events[].model_id` | string | yes | The model that scored it: a scoring model's `model_id`, or a pre-made model's. | | `events[].model_name` | string | yes | The model's name; empty for a scoring model that has been deleted. | | `events[].premade` | boolean | yes | Whether the model is one of Finic's pre-made ones. | | `events[].score` | integer or null | yes | The score, 0 to 1000; `null` for a call that failed. | | `events[].error_type` | string or null | yes | The [error type](/reference#errors) of a call that failed; otherwise `null`. | | `events[].latency_ms` | integer | yes | | | `events[].cost_usd` | number | yes | What the call cost. | | `events[].stored` | boolean | yes | Whether what was sent and answered is still kept, so [get_event](/reference/score/get-event) returns it. | ```json { "events": [ { "id": "req_01M4XZXNCRZBPXV30MSF7RN5H3", "created_at": "2026-12-01T17:04:11.482913Z", "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "model_name": "Card-not-present payment fraud", "premade": false, "score": 412, "error_type": null, "latency_ms": 640, "cost_usd": 0.000031, "stored": true } ], "has_more": false, "request_id": "req_01M4Y0A2K6T9W3B5D7FH1JQMRS" } ``` - **400**: `invalid_request`: `limit` isn't a number from 1 up. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. # get_event (/reference/score/get-event) An event's `id` is the `request_id` its [`score`](/reference/score/score) call returned. ## GET https://api.finic.ai/v1/score/events/{id} Gets one event, with what was scored and how each question was answered. `input` and `questions` are kept only as long as your [data retention](/grayson-api/data#data-retention) keeps request content, and never under Zero Data Retention; after that they are `null`, and the event still has its model, score, time and cost. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `id`: The event's `id`: from [list_events](/reference/score/list-events), or the `request_id` a score returned. ### Responses - **200**: The event. ```json { "id": "req_01M4XZXNCRZBPXV30MSF7RN5H3", "created_at": "2026-12-01T17:04:11.482913Z", "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "model_name": "Card-not-present payment fraud", "premade": false, "score": 412, "error_type": null, "latency_ms": 640, "cost_usd": 0.000031, "stored": true, "input": { "amount": 12500, "country": "US" }, "questions": [ { "text": "Is the payment over $10,000?", "probability": 0.97 } ], "error": null, "request_id": "req_01M4Y0A2K6T9W3B5D7FH1JQMRS" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `not_found`: no event with this id in your organization. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. # create_model (/reference/score/create-scoring-model) Up to 100 new scoring models per organization per day. Created from labeled records, a scoring model is calibrated from the start; created from its criteria alone, it has no questions until you add your own or [calibrate](/score-model/calibration#calibrate-a-scoring-model) it. See [Creating a scoring model](/score-model#creating-a-scoring-model). To add questions of your own, send `add_questions` ([Changing questions](/score-model#changing-questions)). ## POST https://api.finic.ai/v1/score/models Creates a scoring model, from either: - **Its `name` and `criteria` alone.** Returns `201` with its `model_id` at once. It has no questions yet: [add your own](/reference/score/add-questions) to score records right away, each weighed by Finic's estimate, or [calibrate](/reference/score/calibrate) it with labeled records, which has Finic write its questions and fit them to your data. - **Labeled records in `data`:** past records whose outcomes you know. Returns `202` with its `model_id` and a `job_id`: wait for the [job](/reference/score/get-job-status), about two minutes, then [score records](/reference/score/score). It's calibrated to them from the start. For what to send, see [Labeled records](/score-model#labeled-records). To try it here, open the playground and pick the **300 sample payments** example: they're synthetic card payments in the same shape as the score example (also as [sample-payments.csv](/examples/sample-payments.csv)). A scoring model built on sample data is only for trying Finic out. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (multipart/form-data or application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `data` | array of object or string | | Optional. Labeled records: a JSON array of objects, or CSV text with a header row. Every row needs `is_bad`: `true` when the outcome was bad, `false` when good (also `1`/`0`). At least 100 rows with 20 or more of each outcome; up to 2,000 are used. Row rules are under [Labeled records](/score-model#labeled-records). Without `data`, send `criteria`. | | `name` | string | yes | Required. A few words for people to recognize the scoring model by, such as "Card-not-present payment fraud". | | `criteria` | string | | What the decision is and what a bad outcome (`is_bad`) means, such as "Card-not-present payments. Bad: charged back as fraud within 90 days." Required without `data`: Finic writes its questions with it at the first calibration, and weighs your own questions by it until then. With `data`, optional context. You can change it later with [update_model](/reference/score/update-scoring-model). | | `add_questions` | array of string | | Optional. Your own yes/no questions about a record, such as "Was the account opened less than a week before the payment?". Created from labeled records, the scoring model uses the ones that help, alongside Finic's, and the others are listed as not used on its page in the Finic app. Created from criteria alone, they're its only questions until its first calibration, each weighed by Finic's estimate. Up to 20 at a time, and 50 per scoring model. | Example: ```json { "name": "Card-not-present payment fraud", "criteria": "Card-not-present payments at an online store. Bad: the payment was charged back as fraud within 90 days." } ``` ### Responses - **201**: Created from its criteria alone, the scoring model is ready, with no questions but any in `add_questions`. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id, `scm_…`, for adding questions, calibrating and scoring. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "request_id": "req_01M4Y7FASG9DB7MMWCS672J0JD" } ``` - **202**: Created from labeled records, the scoring model is being created. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id, `scm_…`, for scoring and calibrating. | | `job_id` | string | yes | The job creating it, `job_…`. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "job_id": "job_01M4XZXNCRZBPXV30MSF7RN5H3", "request_id": "req_01M4Y7FASG9DB7MMWCS672J0JD" } ``` - **400**: `invalid_request`: `name` is missing, neither `criteria` nor `data` was sent, or the labeled records break a rule. The message says which, for example: - `criteria is required to create a scoring model without labeled records: what the decision is and what a bad outcome means. Or send labeled records as data.` - `A scoring model needs at least 100 labeled rows; got 64.` - `A scoring model needs at least 20 rows with is_bad true and 20 with it false; got 12 and 140.` - `Row 12 has no is_bad field. Every row needs is_bad: true when the outcome was bad, false when it was good.` - `Row 7: is_bad must be true or false (or 1 or 0); got "maybe".` - `data is not valid CSV: record on line 9: wrong number of fields.` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **413**: `request_too_large`: over 2 MB, or the record is too large. - **429**: `rate_limited`: 100 scoring models created in the last 24 hours, or over the [request rate](/reference#rate-limits). - **503**: `overloaded`: creating scoring models, or weighing the questions in `add_questions`, isn't available right now. Try again. # list_models (/reference/score/list-scoring-models) Use it to find a scoring model's `model_id`, or to check whether one you need already exists. For one scoring model's questions, use [`get_model`](/reference/score/get-scoring-model). ## GET https://api.finic.ai/v1/score/models Lists the models you can score with. `models` are your organization's scoring models, newest first (up to 500), with each one's name, criteria and when it was last calibrated: use it to find a scoring model's `model_id`. `premade_models` are Finic's own, the same for everyone and ready to score with. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The organization's scoring models, and the pre-made ones. | Field | Type | Always | Description | | --- | --- | --- | --- | | `models` | array of object | yes | Your scoring models, newest first. | | `premade_models` | array of object | yes | Finic's pre-made models. | | `models[].model_id` | string | yes | The scoring model's id, `scm_…`. | | `models[].name` | string | yes | A few words saying what it predicts: the `name` it was created with, or the one it was given since. Empty for scoring models created before names, until someone names it. | | `models[].status` | `training`, `ready`, `failed` | yes | `training` while it's being created, `ready` to score records, `failed` if creating it failed (create it again). | | `models[].criteria` | string | yes | Its `criteria`, as created or as changed since. Empty if none was given. | | `models[].created_at` | string | yes | When the scoring model was created. | | `models[].calibrated_at` | string or null | yes | When it was last [calibrated](/reference/score/calibrate), or `null` if it isn't calibrated. One created from labeled records is calibrated from the start; one created from its criteria alone has only your questions, weighed by Finic's estimates, until you calibrate it. | | `models[].archived_at` | string or null | yes | When it was archived, or `null`. Calls to score with or calibrate an archived scoring model fail with `scoring_model_archived` until it's unarchived, with [update_model](/reference/score/update-scoring-model) or in the Finic app. | | `models[].examples` | integer | yes | The number of labeled records its latest calibration used (creating from them is one); 0 until it's calibrated. | | `models[].bad_rate` | number | yes | The share of those records with `is_bad` true, 0 to 1; 0 until it's calibrated. | | `models[].scored` | integer | yes | The number of records [scored](/reference/score/score) with it. | | `premade_models[].model_id` | string | yes | The model's id, such as `account_opening`. | | `premade_models[].name` | string | yes | | | `premade_models[].summary` | string | yes | What it scores. | | `premade_models[].price_usd` | number | yes | What one score costs. | | `premade_models[].fields` | array of object | yes | What a record should hold. | | `premade_models[].questions` | array of string | yes | The yes/no questions behind the score. | | `premade_models[].fields[].name` | string | yes | | | `premade_models[].fields[].required` | boolean | yes | | | `premade_models[].fields[].description` | string | yes | | | `premade_models[].fields[].example` | any | | A sample value. | ```json { "models": [ { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "name": "Card-not-present payment fraud", "status": "ready", "criteria": "Card-not-present payments. is_bad: the payment was charged back as fraud within 90 days.", "created_at": "2026-10-20T17:04:11Z", "calibrated_at": "2026-10-24T09:30:52Z", "archived_at": null, "examples": 1800, "bad_rate": 0.062, "scored": 41250 } ], "premade_models": [ { "model_id": "account_opening", "name": "Account opening", "summary": "Stop fake and duplicate accounts at sign-up.", "price_usd": 0.005, "fields": [ { "name": "email", "required": true, "description": "The email address, with anything you know about it, such as how old it is and whether you have seen it before.", "example": "xk92.bnq@proton.me" } ], "questions": [ "Does the email address look machine-generated?" ] } ] } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. # get_model (/reference/score/get-scoring-model) Use a question's `id` to remove it with [`remove_question`](/reference/score/remove-question), or when you [calibrate](/reference/score/calibrate). See [Questions and weights](/score-model#questions-and-weights). ## GET https://api.finic.ai/v1/score/models/{model_id} Gets one scoring model, with the fields [list_models](/reference/score/list-scoring-models) gives and the questions it uses, each with its weight at the latest calibration, or Finic's estimate if it isn't calibrated yet. Your own questions it doesn't use are listed on its page in the Finic app. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `model_id`: The scoring model's `model_id`. ### Responses - **200**: The scoring model. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id, `scm_…`. | | `name` | string | yes | A few words saying what it predicts: the `name` it was created with, or the one it was given since. Empty for scoring models created before names, until someone names it. | | `status` | `training`, `ready`, `failed` | yes | `training` while it's being created, `ready` to score records, `failed` if creating it failed (create it again). | | `criteria` | string | yes | Its `criteria`, as created or as changed since. Empty if none was given. | | `created_at` | string | yes | When the scoring model was created. | | `calibrated_at` | string or null | yes | When it was last [calibrated](/reference/score/calibrate), or `null` if it isn't calibrated. One created from labeled records is calibrated from the start; one created from its criteria alone has only your questions, weighed by Finic's estimates, until you calibrate it. | | `archived_at` | string or null | yes | When it was archived, or `null`. Calls to score with or calibrate an archived scoring model fail with `scoring_model_archived` until it's unarchived, with [update_model](/reference/score/update-scoring-model) or in the Finic app. | | `examples` | integer | yes | The number of labeled records its latest calibration used (creating from them is one); 0 until it's calibrated. | | `bad_rate` | number | yes | The share of those records with `is_bad` true, 0 to 1; 0 until it's calibrated. | | `scored` | integer | yes | The number of records [scored](/reference/score/score) with it. | | `questions` | array of object | yes | The questions it uses, the strongest first. Your own questions it doesn't use are listed on its page in the Finic app. | | `questions[].id` | string | yes | The question's id, such as `q007`, for [remove_question](/reference/score/remove-question) or `remove_questions`. | | `questions[].text` | string | yes | The question | | `questions[].source` | `finic`, `user` | yes | `finic` for a question Finic wrote, `user` for one you added. | | `questions[].weight` | number | yes | How much it moves the score, from the latest calibration, or Finic's estimate if the scoring model isn't calibrated yet, or as you [set it](/reference/score/set-question-weight) since. Positive when a likely yes raises the score, negative when it lowers it; the larger, the more it counts. | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "name": "Card-not-present payment fraud", "status": "ready", "criteria": "Card-not-present payments. is_bad: the payment was charged back as fraud within 90 days.", "created_at": "2026-10-20T17:04:11Z", "calibrated_at": "2026-10-24T09:30:52Z", "archived_at": null, "examples": 1800, "bad_rate": 0.062, "scored": 41250, "questions": [ { "id": "q004", "text": "This record is a card payment. Is the IP address in a different country from the billing address?", "source": "finic", "weight": 0.91 }, { "id": "q017", "text": "This record is a card payment. Does the account look newly opened for this purchase?", "source": "finic", "weight": 0.64 }, { "id": "q022", "text": "This record is a card payment. Is this a typical amount for the merchant category?", "source": "finic", "weight": -0.52 }, { "id": "q051", "text": "Was the account opened less than a week before the payment?", "source": "user", "weight": 0.38 } ] } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. # update_model (/reference/score/update-scoring-model) Send any of `name`, `criteria` and `archived`. Changing its criteria doesn't change the questions it has. Free. See [Scoring models](/score-model). ## PATCH https://api.finic.ai/v1/score/models/{model_id} Renames a scoring model, changes its criteria, or archives or unarchives it: send any of `name`, `criteria` and `archived`. Its criteria is what Finic writes its questions with at its first calibration, and weighs your questions by until then; changing it doesn't change the questions it has. An archived scoring model can't [score](/reference/score/score) or be [calibrated](/reference/score/calibrate) until it's unarchived. Free. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `model_id`: The scoring model's `model_id`. ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `name` | string | | A new name: a few words for people to recognize it by. | | `criteria` | string | | New criteria: what the decision is and what a bad outcome means. It can be emptied only once the scoring model is calibrated. | | `archived` | boolean | | `true` to archive it, `false` to unarchive it. | Example: ```json { "name": "Card-not-present payment fraud (EU)" } ``` ### Responses - **200**: The scoring model, as [get_model](/reference/score/get-scoring-model) returns it. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id, `scm_…`. | | `name` | string | yes | A few words saying what it predicts: the `name` it was created with, or the one it was given since. Empty for scoring models created before names, until someone names it. | | `status` | `training`, `ready`, `failed` | yes | `training` while it's being created, `ready` to score records, `failed` if creating it failed (create it again). | | `criteria` | string | yes | Its `criteria`, as created or as changed since. Empty if none was given. | | `created_at` | string | yes | When the scoring model was created. | | `calibrated_at` | string or null | yes | When it was last [calibrated](/reference/score/calibrate), or `null` if it isn't calibrated. One created from labeled records is calibrated from the start; one created from its criteria alone has only your questions, weighed by Finic's estimates, until you calibrate it. | | `archived_at` | string or null | yes | When it was archived, or `null`. Calls to score with or calibrate an archived scoring model fail with `scoring_model_archived` until it's unarchived, with [update_model](/reference/score/update-scoring-model) or in the Finic app. | | `examples` | integer | yes | The number of labeled records its latest calibration used (creating from them is one); 0 until it's calibrated. | | `bad_rate` | number | yes | The share of those records with `is_bad` true, 0 to 1; 0 until it's calibrated. | | `scored` | integer | yes | The number of records [scored](/reference/score/score) with it. | | `questions` | array of object | yes | The questions it uses, the strongest first. Your own questions it doesn't use are listed on its page in the Finic app. | | `questions[].id` | string | yes | The question's id, such as `q007`, for [remove_question](/reference/score/remove-question) or `remove_questions`. | | `questions[].text` | string | yes | The question | | `questions[].source` | `finic`, `user` | yes | `finic` for a question Finic wrote, `user` for one you added. | | `questions[].weight` | number | yes | How much it moves the score, from the latest calibration, or Finic's estimate if the scoring model isn't calibrated yet, or as you [set it](/reference/score/set-question-weight) since. Positive when a likely yes raises the score, negative when it lowers it; the larger, the more it counts. | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "name": "Card-not-present payment fraud (EU)", "status": "ready", "criteria": "Card-not-present payments. is_bad: the payment was charged back as fraud within 90 days.", "created_at": "2026-10-20T17:04:11Z", "calibrated_at": "2026-10-24T09:30:52Z", "archived_at": null, "examples": 1800, "bad_rate": 0.062, "scored": 41250, "questions": [ { "id": "q004", "text": "This record is a card payment. Is the IP address in a different country from the billing address?", "source": "finic", "weight": 0.91 }, { "id": "q051", "text": "Was the account opened less than a week before the payment?", "source": "user", "weight": 0.38 } ] } ``` - **400**: `invalid_request`: none of `name`, `criteria` and `archived` was sent; `name` is blank or over 100 characters; `criteria` is over 4,000 characters, or empty before the scoring model is calibrated. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - **409**: `scoring_model_not_ready`: the scoring model is still being created, or creating it failed. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. # delete_model (/reference/score/delete-scoring-model) Only with an API key an admin of your organization created. This can't be undone: to stop calls to a scoring model without deleting it, archive it with [`update_model`](/reference/score/update-scoring-model). ## DELETE https://api.finic.ai/v1/score/models/{model_id} Deletes a scoring model, with its records. Calls to it get `404 scoring_model_not_found` from then on, and it can't be undone: to stop using one without deleting it, archive it with [update_model](/reference/score/update-scoring-model). Only an admin of your organization can delete a scoring model: use an API key an admin created. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `model_id`: The scoring model's `model_id`. ### Responses - **200**: The scoring model is deleted. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id | | `deleted` | boolean | yes | Always `true`. | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "deleted": true } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: the API key wasn't created by an admin of the organization. Use an admin's key, or archive the scoring model instead. - **404**: `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. # add_questions (/reference/score/add-questions) Before a scoring model is calibrated, the questions you add count right away; after, they're tried at the next calibration. See [Changing questions](/score-model#changing-questions). Free. ## POST https://api.finic.ai/v1/score/models/{model_id}/questions Adds your own yes/no questions about a record to a scoring model, without calibrating it. - **If it isn't calibrated yet,** the score uses them right away, each with a weight Finic estimates. Until its first calibration, they're its only questions. - **If it's calibrated,** they're asked on every score call and tried at the next [calibration](/reference/score/calibrate), which uses them if they help. Until then they're listed as not used on its page in the Finic app. Up to 20 at a time, 50 of yours per scoring model (used or not), 500 characters each. See [Changing questions](/score-model#changing-questions). Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `model_id`: The scoring model's `model_id`. ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `questions` | array of string | yes | Your own yes/no questions about a record, such as "Was the account opened less than a week before the payment?". | Example: ```json { "questions": [ "Is the IP address in a different country from the billing address?" ] } ``` ### Responses - **200**: The scoring model, as [get_model](/reference/score/get-scoring-model) returns it, with `added`. ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "name": "Card-not-present payment fraud", "status": "ready", "criteria": "Card-not-present payments at an online store. Bad: the payment was charged back as fraud within 90 days.", "created_at": "2026-10-20T17:04:11Z", "calibrated_at": null, "archived_at": null, "examples": 0, "bad_rate": 0, "scored": 0, "questions": [ { "id": "q002", "text": "Is the IP address in a different country from the billing address?", "source": "user", "weight": 1.24 }, { "id": "q001", "text": "Was the account opened less than a week before the payment?", "source": "user", "weight": 0.93 } ], "added": [ { "id": "q002", "text": "Is the IP address in a different country from the billing address?", "used": true } ] } ``` - **400**: `invalid_request`: `questions` is missing or has more than 20; a question is blank, over 500 characters or already one of the scoring model's; or it would have more than 50 of yours. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - **409**: - `scoring_model_not_ready`: the scoring model is still being created, or creating it failed. - `scoring_model_archived`: the scoring model is archived. - `calibration_in_progress`: it's being calibrated. Add the questions when its job completes. - `conflict`: it changed at the same moment. Try again. - **429**: `rate_limited`: 50 changes to this scoring model in the last 24 hours (question changes, calibrations and creating it), or over the [request rate](/reference#rate-limits). - **503**: `overloaded`: the questions couldn't be added just now. Try again. # set_question_weight (/reference/score/set-question-weight) The weight you set replaces the one a calibration fitted or Finic estimated, and applies at once. The next calibration fits every weight again. See [Weights](/score-model#weights). Free. ## PATCH https://api.finic.ai/v1/score/models/{model_id}/questions/{question_id} Sets the weight of a question the score uses, yours or Finic's, in place of the one a calibration fitted or Finic estimated. A question's weight is how far a likely yes moves the score: positive raises it, negative lowers it, `0` leaves the answer out, and the larger the number the more the question counts. Fitted and estimated weights are mostly between -3 and 3. The score changes at once, calibrated or not. The next [calibration](/reference/score/calibrate) fits every weight again from your labeled records, including the ones you set. See [Weights](/score-model#weights). Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `model_id`: The scoring model's `model_id`. - Path parameter `question_id`: The question's `id`, from [get_model](/reference/score/get-scoring-model). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `weight` | number | yes | The question's new weight. | Example: ```json { "weight": 2 } ``` ### Responses - **200**: The scoring model, as [get_model](/reference/score/get-scoring-model) returns it. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id, `scm_…`. | | `name` | string | yes | A few words saying what it predicts: the `name` it was created with, or the one it was given since. Empty for scoring models created before names, until someone names it. | | `status` | `training`, `ready`, `failed` | yes | `training` while it's being created, `ready` to score records, `failed` if creating it failed (create it again). | | `criteria` | string | yes | Its `criteria`, as created or as changed since. Empty if none was given. | | `created_at` | string | yes | When the scoring model was created. | | `calibrated_at` | string or null | yes | When it was last [calibrated](/reference/score/calibrate), or `null` if it isn't calibrated. One created from labeled records is calibrated from the start; one created from its criteria alone has only your questions, weighed by Finic's estimates, until you calibrate it. | | `archived_at` | string or null | yes | When it was archived, or `null`. Calls to score with or calibrate an archived scoring model fail with `scoring_model_archived` until it's unarchived, with [update_model](/reference/score/update-scoring-model) or in the Finic app. | | `examples` | integer | yes | The number of labeled records its latest calibration used (creating from them is one); 0 until it's calibrated. | | `bad_rate` | number | yes | The share of those records with `is_bad` true, 0 to 1; 0 until it's calibrated. | | `scored` | integer | yes | The number of records [scored](/reference/score/score) with it. | | `questions` | array of object | yes | The questions it uses, the strongest first. Your own questions it doesn't use are listed on its page in the Finic app. | | `questions[].id` | string | yes | The question's id, such as `q007`, for [remove_question](/reference/score/remove-question) or `remove_questions`. | | `questions[].text` | string | yes | The question | | `questions[].source` | `finic`, `user` | yes | `finic` for a question Finic wrote, `user` for one you added. | | `questions[].weight` | number | yes | How much it moves the score, from the latest calibration, or Finic's estimate if the scoring model isn't calibrated yet, or as you [set it](/reference/score/set-question-weight) since. Positive when a likely yes raises the score, negative when it lowers it; the larger, the more it counts. | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "name": "Card-not-present payment fraud", "status": "ready", "criteria": "Card-not-present payments at an online store. Bad: the payment was charged back as fraud within 90 days.", "created_at": "2026-10-20T17:04:11Z", "calibrated_at": null, "archived_at": null, "examples": 0, "bad_rate": 0, "scored": 0, "questions": [ { "id": "q002", "text": "Is the IP address in a different country from the billing address?", "source": "user", "weight": 2 }, { "id": "q001", "text": "Was the account opened less than a week before the payment?", "source": "user", "weight": 0.93 } ] } ``` - **400**: `invalid_request`: `weight` is missing, or isn't a number from -10 to 10. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: - `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - `question_not_found`: the scoring model has no question with this id that you can see. - **409**: - `question_not_used`: the score doesn't use this question, so it has no weight. The next calibration tries it. - `scoring_model_not_ready`: the scoring model is still being created, or creating it failed. - `scoring_model_archived`: the scoring model is archived. - `calibration_in_progress`: it's being calibrated. Set the weight when its job completes. - `conflict`: it changed at the same moment. Try again. - **429**: `rate_limited`: 50 changes to this scoring model in the last 24 hours (question changes, calibrations and creating it), or over the [request rate](/reference#rate-limits). # remove_question (/reference/score/remove-question) A question the calibrated score uses is removed with `remove_questions` when you [calibrate](/reference/score/calibrate) instead. See [Changing questions](/score-model#changing-questions). Free. ## DELETE https://api.finic.ai/v1/score/models/{model_id}/questions/{question_id} Removes a question from a scoring model, without calibrating it. A removed question isn't asked or tried again. - **If it isn't calibrated yet,** you can remove any question. With none left, it can't score until you add one or calibrate it. - **If it's calibrated,** you can remove your own questions it doesn't use. A question the score uses is removed with `remove_questions` when you [calibrate](/reference/score/calibrate), so the score is refit without it. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `model_id`: The scoring model's `model_id`. - Path parameter `question_id`: The question's `id`, from [get_model](/reference/score/get-scoring-model). ### Responses - **200**: The scoring model, as [get_model](/reference/score/get-scoring-model) returns it. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model's id, `scm_…`. | | `name` | string | yes | A few words saying what it predicts: the `name` it was created with, or the one it was given since. Empty for scoring models created before names, until someone names it. | | `status` | `training`, `ready`, `failed` | yes | `training` while it's being created, `ready` to score records, `failed` if creating it failed (create it again). | | `criteria` | string | yes | Its `criteria`, as created or as changed since. Empty if none was given. | | `created_at` | string | yes | When the scoring model was created. | | `calibrated_at` | string or null | yes | When it was last [calibrated](/reference/score/calibrate), or `null` if it isn't calibrated. One created from labeled records is calibrated from the start; one created from its criteria alone has only your questions, weighed by Finic's estimates, until you calibrate it. | | `archived_at` | string or null | yes | When it was archived, or `null`. Calls to score with or calibrate an archived scoring model fail with `scoring_model_archived` until it's unarchived, with [update_model](/reference/score/update-scoring-model) or in the Finic app. | | `examples` | integer | yes | The number of labeled records its latest calibration used (creating from them is one); 0 until it's calibrated. | | `bad_rate` | number | yes | The share of those records with `is_bad` true, 0 to 1; 0 until it's calibrated. | | `scored` | integer | yes | The number of records [scored](/reference/score/score) with it. | | `questions` | array of object | yes | The questions it uses, the strongest first. Your own questions it doesn't use are listed on its page in the Finic app. | | `questions[].id` | string | yes | The question's id, such as `q007`, for [remove_question](/reference/score/remove-question) or `remove_questions`. | | `questions[].text` | string | yes | The question | | `questions[].source` | `finic`, `user` | yes | `finic` for a question Finic wrote, `user` for one you added. | | `questions[].weight` | number | yes | How much it moves the score, from the latest calibration, or Finic's estimate if the scoring model isn't calibrated yet, or as you [set it](/reference/score/set-question-weight) since. Positive when a likely yes raises the score, negative when it lowers it; the larger, the more it counts. | ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "name": "Card-not-present payment fraud", "status": "ready", "criteria": "Card-not-present payments at an online store. Bad: the payment was charged back as fraud within 90 days.", "created_at": "2026-10-20T17:04:11Z", "calibrated_at": null, "archived_at": null, "examples": 0, "bad_rate": 0, "scored": 0, "questions": [ { "id": "q002", "text": "Is the IP address in a different country from the billing address?", "source": "user", "weight": 1.24 } ] } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: - `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - `question_not_found`: the scoring model has no question with this id that you can see. - **409**: - `question_in_use`: the calibrated score uses this question. Remove it with `remove_questions` when you calibrate. - `scoring_model_not_ready`: the scoring model is still being created, or creating it failed. - `scoring_model_archived`: the scoring model is archived. - `calibration_in_progress`: it's being calibrated. Remove the question when its job completes. - `conflict`: it changed at the same moment. Try again. - **429**: `rate_limited`: 50 changes to this scoring model in the last 24 hours, or over the [request rate](/reference#rate-limits). # calibrate (/reference/score/calibrate) Up to 10 calibrations per scoring model per day. See [Calibration](/score-model/calibration#calibrate-a-scoring-model) and [Changing questions](/score-model#changing-questions). ## POST https://api.finic.ai/v1/calibrate Fits a scoring model to labeled records: past records with the fields of the records it scores, each with `is_bad`. Grayson answers all the scoring model's questions, and yours, for every record, and Finic chooses again which to use and how much each counts. It can add and remove questions too. A scoring model's first calibration, for one created from its criteria alone, also has Finic write its questions from the records and gives it its [schema](/score-model#schema). Creating one from labeled records is its first calibration. Returns `202` with a `job_id`; score calls after the [job](/reference/score/get-job-status) completes, in about two minutes, use the updated scoring model. One calibration at a time per scoring model. The records are kept encrypted only while the job runs, and deleted when it ends. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json or multipart/form-data) | Field | Type | Required | Description | | --- | --- | --- | --- | | `model_id` | string | yes | The scoring model to calibrate. | | `data` | array of object or string | yes | Labeled records: a JSON array of objects, or CSV text with a header row, with the fields of the records the scoring model scores and `is_bad` (`true` when the outcome was bad, `false` when good; also `1`/`0`). At least 100 rows with 20 or more of each outcome; up to 2,000 are used, by the [rules](/score-model#labeled-records) for creating. They must match the scoring model's schema, if it has one. | | `add_questions` | array of string | | Optional. Your own yes/no questions to try; the scoring model uses the ones that help, and the others are listed as not used on its page in the Finic app. Up to 20 at a time, and 50 per scoring model. [add_questions](/reference/score/add-questions) adds them without calibrating. | | `remove_questions` | array of string | | Optional. The ids of questions to stop using, from [get_model](/reference/score/get-scoring-model). A removed question isn't asked or tried again. | Example: ```json { "model_id": "scm_01M4XRC000RT2GZSKYPD8J86G9", "data": [ { "amount_usd": 2400, "merchant_category": "electronics", "account_age_days": 19, "new_device": true, "billing_country": "US", "ip_country": "NG", "is_bad": true }, { "amount_usd": 58.12, "merchant_category": "grocery", "account_age_days": 1260, "new_device": false, "billing_country": "US", "ip_country": "US", "is_bad": false } ], "add_questions": [ "Was the account opened less than a week before the payment?" ], "remove_questions": [ "q022" ] } ``` ### Responses - **202**: The calibration is running. | Field | Type | Always | Description | | --- | --- | --- | --- | | `job_id` | string | yes | The calibration's job, `job_…`. | | `rows` | integer | yes | The labeled records used. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | ```json { "job_id": "job_01M4YY4AZRJ8NR5QFRW628CJ5G", "rows": 1800, "request_id": "req_01M4YPJNK0SZGEQS0A76EEND4N" } ``` - **400**: - `invalid_request`: `model_id` or `data` is missing; a row breaks a rule (fewer than 100 rows or 20 of an outcome, a row without `is_bad`, …); a question in `add_questions` is blank, too long or already one of its questions; `remove_questions` names a question it doesn't have, or would leave none. - `schema_mismatch`: a row's fields differ from the scoring model's schema. The message lists them. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `scoring_model_not_found`: no scoring model with this `model_id` in your organization. - **409**: - `scoring_model_not_ready`: the scoring model is still being created, or creating it failed. - `scoring_model_archived`: the scoring model is archived. Unarchive it to calibrate it. - `calibration_in_progress`: a calibration is already running. Calibrate again when its job completes. - **413**: `request_too_large`: over 2 MB, or the record is too large. - **429**: `rate_limited`: 10 calibrations of this scoring model in the last 24 hours, or over the [request rate](/reference#rate-limits). # get_job_status (/reference/score/get-job-status) [Creating](/reference/score/create-scoring-model) and [calibrating](/reference/score/calibrate) a scoring model run as jobs. ## GET https://api.finic.ai/v1/jobs/{job_id} Whether creating or calibrating a scoring model has finished. It doesn't report progress: check every 10 seconds or so until `complete` is `true`. Not counted toward the request rate. It also answers for a KYB [enrichment](/reference/kyb/businesses) job, with its `kind`, its `status` and, when it succeeded, its `result`. Finished KYB jobs are kept for 30 days. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `job_id`: The `job_id` from creating or calibrating a scoring model. ### Responses - **200**: `complete` is `true` once the job has finished, whether it succeeded or failed. Complete without an `error` means the scoring model is ready, or its calibration is in use. A failed creation leaves the scoring model unusable (create a new one); a failed calibration leaves it as it was. | Field | Type | Always | Description | | --- | --- | --- | --- | | `job_id` | string | yes | The job's id | | `complete` | boolean | yes | Whether the job has finished. | | `error` | object | | Only when the job failed. | | `error.type` | string | yes | - `no_questions`: the calibration left no questions to score with. Add questions and calibrate again. - `internal_error`: something failed on Finic's side. Create or calibrate the scoring model again. - `unavailable`: creating or calibrating scoring models isn't available right now. Try again later. - `conflict`: the scoring model changed during the calibration. Calibrate again. | | `error.message` | string | yes | What to do. | ```json { "job_id": "job_01M4XZXNCRZBPXV30MSF7RN5H3", "complete": true } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `job_not_found`: no job with this id in your organization. ## Waiting for a job [#waiting-for-a-job] ```python import os import time import requests def wait_for_job(job_id: str) -> None: while True: r = requests.get(f"https://api.finic.ai/v1/jobs/{job_id}", headers={"Authorization": f"Bearer {os.environ['FINIC_API_KEY']}"}, timeout=30) r.raise_for_status() job = r.json() if job["complete"]: if "error" in job: raise RuntimeError(f"{job['error']['type']}: {job['error']['message']}") return time.sleep(30) ``` # ask (/reference/grayson/ask) ## POST https://api.finic.ai/v1/ask Takes a case, as structured `data`, free-text `context` or both, with named, typed questions, and returns a calibrated probability for every answer. See [Questions](/grayson-api/questions) and [Data & context](/grayson-api/data). The questions and answers follow the format of Jev and OpenRouter's Decisions API. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `model` | `grayson-1` | yes | The model. | | `data` | object or array or string | | The case's structured data, read as compact JSON in key order. A string must not be blank. | | `context` | string | | Free text about the case, such as notes, messages or documents. Must not be blank. | | `questions` | object | yes | 1 to 128 questions by name. Each question sees the case and itself only. | | `questions..type` | `noul`, `choice`, `multi_choice` | yes | `noul`: yes or no. `choice`: exactly one option. `multi_choice`: any of the options. | | `questions..instructions` | string | yes | The question in plain language, with any definitions or policy that matter. | | `questions..criteria` | object | | - `choice` and `multi_choice`: required. 2 to 255 options as `key: description`, descriptions unique ignoring case and whitespace; `null` reads as the key. - `noul`: optional. `true` and/or `false`: what each answer means. | | `questions..base_rate` | number or object | | Optional. How common each answer is in your cases, to shift the probabilities to your rates: a noul's share of yes, a choice's share per option (adding up to 1), a multi_choice's share for any options. See [Base rates](/score-model/calibration#base-rates-for-questions). | Example: ```json { "model": "grayson-1", "data": { "account": { "id": "acct_8812", "opened": "2026-08-30", "kyc": { "name": "Dana Ruiz", "dob": "1994-03-11", "ssn_last4": "4410" } }, "events": [ { "ts": "2026-09-20T02:14:09Z", "type": "login", "ip": "203.0.113.4", "device_id": "d_77a1", "new_device": true }, { "ts": "2026-09-20T02:16:40Z", "type": "email_change", "old": "dana.r@example.com", "new": "dr8812@example.net" }, { "ts": "2026-09-20T02:21:03Z", "type": "ach_out", "amount": 4900, "counterparty": "External bank account x9921", "memo": "rent" } ] }, "context": "Customer called 9/21 saying they never changed their email and don't recognize the transfer.", "questions": { "is_fraud": { "type": "noul", "instructions": "Is this account engaged in or the victim of fraud?" }, "ato_signs": { "type": "noul", "instructions": "Are there signs of account takeover?" }, "primary_typology": { "type": "choice", "instructions": "What is the most likely primary fraud typology?", "criteria": { "ato": "Account takeover", "synthetic_id": "Synthetic identity", "mule": "Money mule activity", "first_party": "First-party / bust-out", "none": "No fraud indicated" } }, "typologies_present": { "type": "multi_choice", "instructions": "Which of these fraud typologies are present on this account?", "criteria": { "ato": "Account takeover", "synthetic_id": "Synthetic identity", "mule": "Money mule activity", "first_party": "First-party / bust-out", "scam": "Authorized push payment scam" } } } } ``` ### Responses - **200**: One answer per question, by name. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The answers' id, `dec_…`. | | `model` | string | yes | The model that answered. | | `answers` | object | yes | One answer per question, by name. Probabilities aren't rounded. | | `usage` | object | yes | The tokens the request read and wrote. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `evaluation_time_ms` | number | yes | How long the model took. | | `answers.` | object | | Every answer repeats its question's `type`; the other fields depend on it. Probabilities aren't rounded. | | `answers..type` | `noul`, `choice`, `multi_choice` | yes | | | `answers..noul` | number | | `noul`: the probability of yes. | | `answers..choice` | string | | `choice`: the most likely option's key. | | `answers..multi_choice` | array of string | | `multi_choice`: the keys with probability 0.5 or more, in request order. | | `answers..confidence` | number | | `choice`: (K × top probability − 1) / (K − 1) over K options, 0 when every option is equally likely, 1 when one has all the probability. | | `answers..probabilities` | object | | `choice`: per option, in request order, summing to 1. `multi_choice`: per option, independent. | | `answers..calibrated` | boolean | | Only for a question that sent `base_rate`: `true` when it was applied, `false` until the question has 30 answers. | | `usage.input_tokens` | integer | yes | Tokens read: see [How tokens are counted](/reference#how-tokens-are-counted). | | `usage.output_tokens` | integer | yes | Always 0. | ```json { "id": "dec_4b19e0c2f7a8453d9e6c1a2b8f5d7e90", "model": "grayson-1", "answers": { "is_fraud": { "type": "noul", "noul": 0.92 }, "ato_signs": { "type": "noul", "noul": 0.94 }, "primary_typology": { "type": "choice", "choice": "ato", "confidence": 0.85, "probabilities": { "ato": 0.88, "synthetic_id": 0.02, "mule": 0.05, "first_party": 0.03, "none": 0.02 } }, "typologies_present": { "type": "multi_choice", "multi_choice": [ "ato", "mule" ], "probabilities": { "ato": 0.93, "synthetic_id": 0.04, "mule": 0.61, "first_party": 0.03, "scam": 0.07 } } }, "usage": { "input_tokens": 588, "output_tokens": 0 }, "request_id": "req_01J8Z4Q7XG5V0A2K7N4R8T1W3B", "evaluation_time_ms": 182.4 } ``` - **400**: `invalid_request`: the request breaks a rule. `param` names the field, such as `questions.primary_typology.criteria`. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `model_not_found`: unknown `model`. - **413**: `request_too_large`: over 2 MB, or over 32,768 tokens of data, context and questions. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. - **503**: `overloaded`: temporarily at capacity. Retry with backoff. # Identify API reference (/reference/identify) Base URL `https://api.finic.ai`. Send an API key as `Authorization: Bearer gsk_…` ([Authentication](/authentication)) and JSON bodies. Every response has an `X-Request-Id` header. | Endpoint | Request | What it does | | ---------------------------------------------------------------- | ----------------------------------- | ------------------------------------------------------------------------------------ | | [`lookup`](/reference/identify/lookup) | `POST /v1/identify/lookup` | Says whether one request comes from a declared AI agent, and whether that's verified | | [`list_lookup_sources`](/reference/identify/list-lookup-sources) | `GET /v1/identify/lookup/sources` | Lists the agents the lookup knows and the sources it reads | | [`create_site`](/reference/identify/create-site) | `POST /v1/identify/sites` | Creates a site: a public key and its script tag | | [`list_sites`](/reference/identify/list-sites) | `GET /v1/identify/sites` | Lists your sites | | [`update_site`](/reference/identify/update-site) | `PATCH /v1/identify/sites/{id}` | Renames a site or changes its origins | | [`delete_site`](/reference/identify/delete-site) | `DELETE /v1/identify/sites/{id}` | Deletes a site, so its key stops working | | [`get_session`](/reference/identify/get-session) | `GET /v1/identify/sessions/{id}` | Gets one session's verdict | | [`list_sessions`](/reference/identify/list-sessions) | `GET /v1/identify/sessions` | Lists the latest sessions | | [`update_session`](/reference/identify/update-session) | `PATCH /v1/identify/sessions/{id}` | Links a session to one of your customers, or clears the link | | [`get_visitor`](/reference/identify/get-visitor) | `GET /v1/identify/visitors/{id}` | Gets one visitor | | [`delete_visitor`](/reference/identify/delete-visitor) | `DELETE /v1/identify/visitors/{id}` | Deletes a visitor's fingerprint, addresses and token | The snippet uses two more, with no API key: `GET /identify/agent.js` (the script) and `POST /identify/s` (its reports). You don't call them yourself. ## Errors [#errors] Errors have the API's usual shape; see [Errors](/reference#errors). | HTTP | `type` | When | Retry | | ----- | ---------------------- | ------------------------------------------------------------------------------------------ | ----------------------- | | `400` | `invalid_request` | Malformed JSON, an unknown field, or a value that breaks a rule. `param` names the field | No. Fix the request | | `401` | `authentication_error` | Missing or invalid API key | No. Check the key | | `402` | `insufficient_credit` | The organization is out of credit. Every Identify call is refused until an admin adds more | No. Add credit | | `404` | `not_found` | No site, session or visitor with that id in your organization | No. Check the id | | `409` | `limit_reached` | The organization already has 50 sites | No. Delete a site first | | `413` | `request_too_large` | A body over 2 MB | No. Send less | | `429` | `rate_limited` | Over the request rate | Yes, with backoff | | `500` | `internal_error` | Something failed on Finic's side | Yes | ## Limits [#limits] | Limit | Value | | ------------------------ | ------------------------------------------------------------------------------------- | | Request rate | 50 per second per organization, in bursts of up to 100, across all Identify endpoints | | Sites | 50 per organization | | Origins | 20 per site | | `name` | 100 characters | | `entity_id` | 128 characters | | `user_agent` in a lookup | 2,000 characters | | `headers` in a lookup | 100 headers, 8,192 characters each | | Sessions in one list | 200 | Identify's request rate is its own: it doesn't count toward the [rate](/reference#rate-limits) for scores and questions. Over it, sites and sessions calls get `429` with `Too many Identify requests for this organization: the limit is 50 a second across its API keys. Retry with backoff.` The snippet's reports have separate [limits](/identify/data#limits). # lookup (/reference/identify/lookup) See [Agent lookup](/identify/lookup) for the flags, the agents it knows and the test values. ## POST https://api.finic.ai/v1/identify/lookup Says whether one request comes from a declared AI agent or crawler, from its IP address, user agent and signature headers, and whether that claim is [verified](/identify/lookup#verification). Send at least one of `ip`, `user_agent` and `headers`. The lookup returns a result only: it never blocks anything, and it can't say a request is from a person. Each lookup that answers is one identification, [$0.001](/pricing#identify) from your credit. To try it, send the built-in test agent: user agent `Finic-Test-Agent` from an address in `192.0.2.0/24`. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `ip` | string | | The client's IP address, IPv4 or IPv6. Send the address of the visitor, not of your own proxy. | | `user_agent` | string | | The request's user agent. Without it, a `User-Agent` in `headers` is used. | | `headers` | object | | The request's headers, to check a signature: `Signature`, `Signature-Input` and `Signature-Agent`, with any header the signature covers. Up to 100 headers of 8,192 characters each. | | `url` | string | | The full URL the request was for. A signature covers it, so checking one needs it. Build it from your site's own host name, not from the request's `Host` header. | | `method` | string | | The request's method, such as `GET`. Sent with `url`. | Example: ```json { "ip": "192.0.2.10", "user_agent": "Finic-Test-Agent" } ``` ### Responses - **200**: The lookup's result. | Field | Type | Always | Description | | --- | --- | --- | --- | | `status` | string | yes | Always `complete`. | | `actor` | `ai_agent`, `automation`, `unknown` | yes | `ai_agent` for a declared agent or crawler; `automation` for an HTTP library, an automation tool, or something posing as an agent; `unknown` otherwise. Never `human`. | | `operator` | string or null | yes | Who runs the agent, such as `OpenAI`, or `null`. For an impersonation, the operator it claims. | | `product` | string or null | yes | The agent, such as `GPTBot`, or `null`. | | `category` | `training_crawler`, `search_fetcher`, `user_triggered_agent`, `other_crawler`, `generic_automation`, `null` | yes | What kind of agent it is: `training_crawler`, `search_fetcher`, `user_triggered_agent` (it acts for a person who asked) or `other_crawler`; `generic_automation` for an HTTP library or automation tool; `null` when unknown. | | `verification` | `signed`, `network_verified`, `claimed`, `impersonated`, `none` | yes | How far the claim to be an agent was checked: `signed`, `network_verified`, `claimed`, `impersonated` or `none`. See [Verification](/identify/verdicts#verification). | | `impersonated` | boolean | yes | `true` when `verification` is `impersonated`. | | `network` | object | yes | Where the address is. | | `signature` | object | | Only when the request carried a Web Bot Auth signature. | | `flags` | array of string | yes | Stable codes that qualify the answer. See [Flags](/identify/lookup#flags). New codes can be added. | | `evidence` | array of object | yes | What the answer rests on. | | `test` | boolean | | `true` for the built-in test agent and test data center. Left out otherwise. | | `checked_at` | string | yes | When the lookup ran. | | `model_version` | string | yes | `lookup-` and when the published sources' content last changed. | | `cost_usd` | string | yes | The call's cost, as a decimal string. A lookup is one identification: `"0.001"`. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `network.type` | `data_center`, `operator`, `unknown` | yes | `data_center` for a listed cloud provider's address, `operator` for an address in an agent operator's published ranges, `unknown` otherwise. | | `network.provider` | string or null | yes | The cloud provider or operator, or `null`. | | `network.range` | string or null | yes | The published range that holds the address, such as `192.0.2.0/24`, or `null`. | | `signature.present` | boolean | yes | Always `true`. | | `signature.verified` | boolean | yes | `true` when the signature verifies against a key the agent publishes. | | `signature.signature_agent` | string | | The `Signature-Agent` URL the signature names. | | `signature.keyid` | string | | The key it says it was made with. | | `signature.authority` | string | | The host it was checked against: the host of `url`. Check that it's your site's own. | | `signature.reason` | string | | Why it wasn't verified, such as `expired`, `unknown_signature_agent`, `unknown_key` or `bad_signature`. Left out when it was. | | `evidence[].source` | string | yes | `user_agent`, or the name of the published source that was checked. | | `evidence[].url` | string | | Where the operator publishes that source. Left out when there's none. | | `evidence[].retrieved_at` | string | | When the source was last fetched. Left out when there's none. | | `evidence[].detail` | string | yes | A sentence for people. It can change | ```json { "status": "complete", "actor": "ai_agent", "operator": "Finic (test)", "product": "Finic-Test-Agent", "category": "user_triggered_agent", "verification": "network_verified", "impersonated": false, "network": { "type": "operator", "provider": "Finic (test)", "range": "192.0.2.0/24" }, "flags": [ "test" ], "evidence": [ { "source": "user_agent", "detail": "The user agent contains \"Finic-Test-Agent\", which Finic (test) documents for Finic-Test-Agent." }, { "source": "finic-test-agent", "detail": "192.0.2.10 is in 192.0.2.0/24, which Finic (test) publishes for Finic-Test-Agent." } ], "test": true, "checked_at": "2026-12-01T17:04:11.482913Z", "model_version": "lookup-2026-12-01T12:10:36Z", "cost_usd": "0.001", "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **400**: `invalid_request`: the body isn't a JSON object, has an unknown field, or breaks a rule. The message says which, for example: - `ip is not an IP address.` - `Give at least one of ip, user_agent and headers.` - `user_agent can be at most 2,000 characters.` - `headers can hold at most 100 headers.` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **413**: `request_too_large`: over 2 MB. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # list_lookup_sources (/reference/identify/list-lookup-sources) Use it to see which [agents](/identify/lookup#known-agents) a lookup can name today, and how fresh each source is. ## GET https://api.finic.ai/v1/identify/lookup/sources Lists the agents and cloud networks the [lookup](/reference/identify/lookup) knows, and every published file it reads them from, with when each was last fetched. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The agents, networks and sources. | Field | Type | Always | Description | | --- | --- | --- | --- | | `model_version` | string | yes | `lookup-` and when the sources' content last changed, as lookups report it. | | `sources` | array of object | yes | Each file of IP ranges or signing keys, by name. | | `agents` | array of object | yes | The agents the lookup recognises. | | `networks` | array of object | yes | The cloud providers whose addresses the lookup marks as data centers. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `sources[].name` | string | yes | The source's name, as a lookup's `evidence` gives it. | | `sources[].url` | string | | Where the operator publishes it. Left out for a built-in source. | | `sources[].kind` | `ranges`, `keys` | yes | `ranges` for IP ranges, `keys` for an agent's signing keys. | | `sources[].agents` | array of string | | The `key` of each agent it covers. | | `sources[].network` | string | | The `key` of the network it covers. | | `sources[].entries` | integer | yes | The number of ranges or keys in use. | | `sources[].checked_at` | string or null | yes | When it was last fetched and read without error, or `null`. | | `sources[].changed_at` | string or null | yes | When its content last changed, or `null`. | | `sources[].failed_at` | string | | When the latest fetch failed. Only after a failure; the last good entries stay in use. | | `sources[].error` | string | | Why it failed, as one word such as `unreachable`, `timeout` or `unreadable`. Only after a failure. | | `sources[].builtin` | boolean | | `true` for the test agent's and test data center's ranges, which are never fetched. | | `agents[].key` | string | yes | The agent's key, such as `openai-gptbot`. | | `agents[].operator` | string | yes | Who runs it, such as `OpenAI`. | | `agents[].product` | string | yes | The agent, such as `GPTBot`. | | `agents[].category` | `training_crawler`, `search_fetcher`, `user_triggered_agent`, `other_crawler`, `generic_automation`, `null` | yes | What kind of agent it is: `training_crawler`, `search_fetcher`, `user_triggered_agent` (it acts for a person who asked) or `other_crawler`; `generic_automation` for an HTTP library or automation tool; `null` when unknown. | | `agents[].user_agents` | array of string | yes | The user agent tokens it sends. Empty for an agent known only by its signature. | | `agents[].docs` | string | | The operator's page about it. | | `agents[].test` | boolean | | `true` for the built-in test agent. | | `networks[].key` | string | yes | The network's key, such as `aws`. | | `networks[].provider` | string | yes | The provider's name, such as `Amazon Web Services`. | | `networks[].type` | string | yes | `data_center`. | | `networks[].test` | boolean | | `true` for the built-in test data center. | ```json { "model_version": "lookup-2026-12-01T12:10:36Z", "sources": [ { "name": "openai-gptbot", "url": "https://openai.com/gptbot.json", "kind": "ranges", "agents": [ "openai-gptbot" ], "entries": 21, "checked_at": "2026-12-01T12:10:36.104882Z", "changed_at": "2026-11-24T06:02:10.771390Z" } ], "agents": [ { "key": "openai-gptbot", "operator": "OpenAI", "product": "GPTBot", "category": "training_crawler", "user_agents": [ "GPTBot" ], "docs": "https://developers.openai.com/api/docs/bots" } ], "networks": [ { "key": "aws", "provider": "Amazon Web Services", "type": "data_center" } ], "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # create_site (/reference/identify/create-site) Paste the `snippet` it returns into your pages; see the [Quickstart](/identify/quickstart). List your [origins](/identify/data#origins) so only your pages can report. ## POST https://api.finic.ai/v1/identify/sites Creates a site: a public key (`gpk_…`) for the [snippet](/identify/quickstart) and the script tag that carries it. The key is not a secret; it goes in your pages. An organization can have 50 sites. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `name` | string | | Optional. A name for people to recognize the site by. | | `origins` | array of string | | Optional. The origins whose pages reports are taken from, each a scheme and host such as `https://www.example.com`; up to 20. With none, reports are taken from any page. See [Origins](/identify/data#origins). | Example: ```json { "name": "Storefront", "origins": [ "https://www.example.com" ] } ``` ### Responses - **201**: The site, with its script tag. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The site's id, `kst_…`. | | `name` | string | yes | Its name. Empty if none was given. | | `key` | string | yes | Its public key, `gpk_…`: the `data-site` of the script tag. Not a secret. | | `origins` | array of string | yes | The origins reports are taken from. Empty means any page. | | `snippet` | string | | The script tag to paste into your pages. Only when the site is created. | | `created_at` | string | yes | When the site was created. | | `request_id` | string | | `req_…`, the same as the `X-Request-Id` header. | ```json { "id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "name": "Storefront", "key": "gpk_Zk3vQ8mT1xR7bN2cYw5LpA9d", "origins": [ "https://www.example.com" ], "snippet": "", "created_at": "2026-12-01T17:01:52.310447Z", "request_id": "req_01M4Z1X3H2N7Q4B8D6KC9TWEFA" } ``` - **400**: `invalid_request`: the body isn't a JSON object or has an unknown field; `name` is over 100 characters; `origins` has more than 20 entries, or one that isn't a site's address. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **409**: `limit_reached`: the organization already has 50 sites. [Delete one](/reference/identify/delete-site) first. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # list_sites (/reference/identify/list-sites) Use it to find a site's `id` or `key`. ## GET https://api.finic.ai/v1/identify/sites Lists your organization's sites, oldest first, with each one's public key and origins. Deleted sites aren't listed. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The organization's sites. | Field | Type | Always | Description | | --- | --- | --- | --- | | `sites` | array of object | yes | Your sites, oldest first. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `sites[].id` | string | yes | The site's id, `kst_…`. | | `sites[].name` | string | yes | Its name. Empty if none was given. | | `sites[].key` | string | yes | Its public key, `gpk_…`: the `data-site` of the script tag. Not a secret. | | `sites[].origins` | array of string | yes | The origins reports are taken from. Empty means any page. | | `sites[].snippet` | string | | The script tag to paste into your pages. Only when the site is created. | | `sites[].created_at` | string | yes | When the site was created. | | `sites[].request_id` | string | | `req_…`, the same as the `X-Request-Id` header. | ```json { "sites": [ { "id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "name": "Storefront", "key": "gpk_Zk3vQ8mT1xR7bN2cYw5LpA9d", "origins": [ "https://www.example.com" ], "created_at": "2026-12-01T17:01:52.310447Z" } ], "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # update_site (/reference/identify/update-site) Send `name`, `origins` or both. `origins` replaces the whole list; see [Origins](/identify/data#origins). ## PATCH https://api.finic.ai/v1/identify/sites/{id} Renames a site or replaces its [origins](/identify/data#origins): send `name`, `origins` or both. Its key stays the same. A change to its origins takes up to a minute to apply to reports. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `id`: The site's `id`. ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `name` | string | | A new name. | | `origins` | array of string | | Optional. The origins whose pages reports are taken from, each a scheme and host such as `https://www.example.com`; up to 20. With none, reports are taken from any page. See [Origins](/identify/data#origins). | Example: ```json { "origins": [ "https://www.example.com", "https://shop.example.com" ] } ``` ### Responses - **200**: The site, as changed. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The site's id, `kst_…`. | | `name` | string | yes | Its name. Empty if none was given. | | `key` | string | yes | Its public key, `gpk_…`: the `data-site` of the script tag. Not a secret. | | `origins` | array of string | yes | The origins reports are taken from. Empty means any page. | | `snippet` | string | | The script tag to paste into your pages. Only when the site is created. | | `created_at` | string | yes | When the site was created. | | `request_id` | string | | `req_…`, the same as the `X-Request-Id` header. | ```json { "id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "name": "Storefront", "key": "gpk_Zk3vQ8mT1xR7bN2cYw5LpA9d", "origins": [ "https://www.example.com", "https://shop.example.com" ], "created_at": "2026-12-01T17:01:52.310447Z", "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **400**: `invalid_request`: the body isn't a JSON object or has an unknown field; `name` is over 100 characters; `origins` has more than 20 entries, or one that isn't a site's address. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `not_found`: no site with this `id` in your organization. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # delete_site (/reference/identify/delete-site) This can't be undone. Remove the script tag from your pages too: reports under a deleted key are dropped. ## DELETE https://api.finic.ai/v1/identify/sites/{id} Deletes a site. Its key stops working within a minute: reports that carry it are dropped. This can't be undone. Its sessions can still be read until they're 30 days old. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `id`: The site's `id`. ### Responses - **200**: The site is deleted. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The site's id | | `deleted` | boolean | yes | Always `true`. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | ```json { "id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "deleted": true, "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `not_found`: no site with this `id` in your organization. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # get_session (/reference/identify/get-session) See [Verdicts](/identify/verdicts) for how to read it. Anyone can send a `finic_session` cookie: before you rely on a session, check that its `ip` and `user_agent` match the request in front of you. ## GET https://api.finic.ai/v1/identify/sessions/{id} Gets one session's [verdict](/identify/verdicts): what the visitor's browser is taken to be, how sure that is and why. The session's id is in the `finic_session` cookie on requests to your site, and in `window.finic.session` on the page. A verdict changes as the page is used, so read it when you need it. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `id`: The session's `id`, `ksn_…`. - Query parameter `signals`: `true` adds `signals`, the snippet's latest report. ### Responses - **200**: The session. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The session's id, `ksn_…`. | | `site_id` | string | yes | The site it belongs to, `kst_…`. | | `entity_id` | string or null | yes | Your own id for the customer or account the session belongs to, or `null` until one is set: by your page ([`data-entity` or `finic.identify()`](/identify/data#the-entity-id)) or by your server ([update_session](/reference/identify/update-session)). | | `entity_source` | `server`, `browser`, `null` | yes | Who set `entity_id`. `server`: your API key, which you can rely on. `browser`: your page, through the snippet, which is only the page's claim. `null` with no entity id. | | `status` | string | yes | Always `complete`. | | `actor` | `human`, `ai_agent`, `automation`, `unknown` | yes | What the visitor is taken to be: `human` (the page was used the way a hand uses it), `ai_agent`, `automation`, or `unknown` (nothing for or against yet, as on a page that has only loaded). See [Verdicts](/identify/verdicts). | | `operator` | string or null | yes | Who runs the agent, such as `OpenAI`, or `null`. For an impersonation, the operator it claims. | | `product` | string or null | yes | The agent, such as `ChatGPT-User`, or `null`. | | `category` | `training_crawler`, `search_fetcher`, `user_triggered_agent`, `other_crawler`, `generic_automation`, `null` | yes | What kind of agent it is: `training_crawler`, `search_fetcher`, `user_triggered_agent` (it acts for a person who asked) or `other_crawler`; `generic_automation` for an HTTP library or automation tool; `null` when unknown. | | `verification` | `signed`, `network_verified`, `claimed`, `impersonated`, `none` | yes | How far the claim to be an agent was checked: `signed`, `network_verified`, `claimed`, `impersonated` or `none`. See [Verification](/identify/verdicts#verification). | | `confidence` | `high`, `medium`, `low` | yes | How sure the verdict is. `low` is a hint, not a decision. See [Confidence](/identify/verdicts#confidence). | | `confidence_score` | number | yes | `confidence` as a number from 0 to 1, to two decimals: `high` is 0.85 to 0.99, `medium` 0.50 to 0.84, `low` 0.01 to 0.49, and `unknown` is 0. It is worked out from the same rules as the verdict and isn't a measured probability. See [Confidence score](/identify/verdicts#confidence-score). | | `reasons` | array of string | yes | What the verdict rests on, as [reason codes](/identify/verdicts#reason-codes). New codes can be added. | | `network` | object | yes | Where the address is. | | `ip` | string | yes | The visitor's address, from the report the verdict rests on: usually the latest. | | `user_agent` | string | yes | That report's user agent, cut to 400 characters. | | `page` | string | yes | The page that sent it: its origin and path, without the query. Path segments that look like a token or a name are `*`. | | `reports` | integer | yes | The number of reports the session has taken. | | `visitor_id` | string or null | yes | The session's [visitor](/identify/visitors), `kvi_…`: the same id for every session of the same browser. `null` until the browser has been identified, usually within a second of the page loading, and when the tag has `data-visitor="off"`. | | `visitor` | object or null | yes | The visitor and how this session was matched to it, or `null` with `visitor_id`. | | `incognito` | boolean or null | yes | Whether the browser is in a private window; `null` where it gives no way to tell. This and the fields down to `suspect_score` are the session's [smart signals](/identify/smart-signals). | | `vpn` | boolean or null | yes | Whether the visitor seems to be behind a VPN: the browser's clock is in another time zone than its address. `null` without a location for the address or a time zone from the browser. | | `vpn_confidence` | `high`, `medium` | | With `vpn: true`: `high` when the address is also a cloud provider's or a Tor exit node, else `medium`. | | `vpn_origin_timezone` | string | | With `vpn: true`: the browser's own time zone, such as `America/Toronto`. | | `vpn_methods` | object | | With a VPN verdict: what it rests on. | | `virtual_machine` | boolean | yes | Whether the browser's graphics are a virtual machine's. | | `tampering` | boolean | yes | Whether the browser contradicts itself about what it is. | | `tampering_details` | object | yes | | | `developer_tools` | boolean | yes | Whether the DevTools protocol is attached: open DevTools, or a tool driving the browser. | | `privacy_settings` | boolean | yes | Whether the browser hides its fingerprint: Brave, or Firefox resisting fingerprinting. | | `ip_info` | object | yes | The session's address, under `v4` or `v6`. | | `ip_blocklist` | object | yes | | | `velocity` | object | | How busy the session's visitor was in the 5 minutes, hour and 24 hours up to the session's start, this session included. Only from [get_session](/reference/identify/get-session), and only when the session has a visitor. | | `suspect_score` | integer | yes | The smart signals added up, each by a [weight](/identify/smart-signals#suspect-score). 0 is nothing unusual. | | `signals` | object | | With `signals=true`: the snippet's latest report, as `v`, `sv`, `page`, `env`, `input` and `fp`. Its fields are listed under [What the snippet collects](/identify/data#what-the-snippet-collects). | | `created_at` | string | yes | When the session started. | | `updated_at` | string | yes | When it last reported. | | `request_id` | string | | `req_…`, the same as the `X-Request-Id` header. | | `network.type` | `data_center`, `operator`, `unknown` | yes | `data_center` for a listed cloud provider's address, `operator` for an address in an agent operator's published ranges, `unknown` otherwise. | | `network.provider` | string or null | yes | The cloud provider or operator, or `null`. | | `network.range` | string or null | yes | The published range that holds the address, such as `192.0.2.0/24`, or `null`. | | `visitor.id` | string | yes | The same as `visitor_id`. | | `visitor.match` | `stored_id`, `fingerprint`, `new` | yes | How the visitor was recognised: `stored_id` (the id the browser kept), `fingerprint` (its fingerprint and network, with no stored id) or `new` (first seen in this session). See [How a visitor is matched](/identify/visitors#how-a-visitor-is-matched). | | `visitor.confidence` | `high`, `medium`, `low` | yes | How sure it is that this session is this visitor's and nobody else's. See [Confidence](/identify/visitors#confidence). | | `visitor.found` | boolean | yes | Whether the visitor had been seen before this session: `false` when `match` is `new`. | | `visitor.confidence_score` | number | yes | `confidence` as a number: how sure it is that the session was given the right visitor and not another browser's. `1` for `stored_id` and `new`; for `fingerprint`, 0.90 to 0.99 when `high`, 0.60 to 0.89 when `medium`, 0.30 to 0.59 when `low`, higher the more of the fingerprint agreed. Not a measured probability. See [Confidence](/identify/visitors#confidence). | | `visitor.sessions` | integer | yes | The number of sessions the visitor has had. | | `visitor.first_seen_at` | string | yes | When the visitor was first seen. | | `visitor.last_seen_at` | string or null | yes | When the visitor's last session before this one started. `null` for a new visitor. | | `vpn_methods.timezone_mismatch` | boolean | | The browser's time zone differs from its address's. | | `tampering_details.anomaly_score` | number | yes | The share of the five consistency checks that failed. | | `ip_info.v4` | object | | Where an address is and whose network it is on. | | `ip_info.v6` | object | | Where an address is and whose network it is on. | | `ip_info.v4.address` | string | yes | | | `ip_info.v4.geolocation` | object or null | yes | Where the address is, as near as its network says; `null` without a GeoIP database. | | `ip_info.v4.asn` | string or null | yes | The network's number, such as `64500`. | | `ip_info.v4.asn_name` | string or null | yes | | | `ip_info.v4.asn_network` | string or null | yes | The range the address is in, such as `198.51.100.0/24`. | | `ip_info.v4.datacenter_result` | boolean | yes | Whether the address is a listed cloud provider's. | | `ip_info.v4.datacenter_name` | string or null | yes | | | `ip_info.v4.geolocation.accuracy_radius` | integer | | In kilometres. | | `ip_info.v4.geolocation.latitude` | number | | | | `ip_info.v4.geolocation.longitude` | number | | | | `ip_info.v4.geolocation.postal_code` | string | | | | `ip_info.v4.geolocation.timezone` | string | | | | `ip_info.v4.geolocation.city_name` | string | | | | `ip_info.v4.geolocation.country_code` | string | | | | `ip_info.v4.geolocation.country_name` | string | | | | `ip_info.v4.geolocation.continent_code` | string | | | | `ip_info.v4.geolocation.continent_name` | string | | | | `ip_info.v4.geolocation.subdivisions` | array of object | | | | `ip_info.v4.geolocation.subdivisions[].iso_code` | string | | | | `ip_info.v4.geolocation.subdivisions[].name` | string | | | | `ip_info.v6.address` | string | yes | | | `ip_info.v6.geolocation` | object or null | yes | Where the address is, as near as its network says; `null` without a GeoIP database. | | `ip_info.v6.asn` | string or null | yes | The network's number, such as `64500`. | | `ip_info.v6.asn_name` | string or null | yes | | | `ip_info.v6.asn_network` | string or null | yes | The range the address is in, such as `198.51.100.0/24`. | | `ip_info.v6.datacenter_result` | boolean | yes | Whether the address is a listed cloud provider's. | | `ip_info.v6.datacenter_name` | string or null | yes | | | `ip_info.v6.geolocation.accuracy_radius` | integer | | In kilometres. | | `ip_info.v6.geolocation.latitude` | number | | | | `ip_info.v6.geolocation.longitude` | number | | | | `ip_info.v6.geolocation.postal_code` | string | | | | `ip_info.v6.geolocation.timezone` | string | | | | `ip_info.v6.geolocation.city_name` | string | | | | `ip_info.v6.geolocation.country_code` | string | | | | `ip_info.v6.geolocation.country_name` | string | | | | `ip_info.v6.geolocation.continent_code` | string | | | | `ip_info.v6.geolocation.continent_name` | string | | | | `ip_info.v6.geolocation.subdivisions` | array of object | | | | `ip_info.v6.geolocation.subdivisions[].iso_code` | string | | | | `ip_info.v6.geolocation.subdivisions[].name` | string | | | | `ip_blocklist.tor_node` | boolean | yes | Whether the address is a Tor exit node. | | `velocity.events` | object | | One count over three spans of time. | | `velocity.distinct_ip` | object | | One count over three spans of time. | | `velocity.distinct_entity_id` | object | | One count over three spans of time. | | `velocity.events.5_minutes` | integer | yes | | | `velocity.events.1_hour` | integer | yes | | | `velocity.events.24_hours` | integer | yes | | | `velocity.distinct_ip.5_minutes` | integer | yes | | | `velocity.distinct_ip.1_hour` | integer | yes | | | `velocity.distinct_ip.24_hours` | integer | yes | | | `velocity.distinct_entity_id.5_minutes` | integer | yes | | | `velocity.distinct_entity_id.1_hour` | integer | yes | | | `velocity.distinct_entity_id.24_hours` | integer | yes | | ```json { "id": "ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE", "site_id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "entity_id": null, "entity_source": null, "status": "complete", "actor": "human", "operator": null, "product": null, "category": null, "verification": "none", "confidence": "high", "confidence_score": 0.9, "reasons": [ "human_like_input" ], "network": { "type": "unknown", "provider": null, "range": null }, "ip": "198.51.100.24", "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36", "page": "https://www.example.com/checkout", "reports": 4, "visitor_id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "visitor": { "id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "match": "stored_id", "found": true, "confidence": "high", "confidence_score": 1, "sessions": 7, "first_seen_at": "2026-11-18T09:41:07.120443Z", "last_seen_at": "2026-11-30T20:15:42.004118Z" }, "created_at": "2026-12-01T17:04:11.482913Z", "updated_at": "2026-12-01T17:04:19.905127Z", "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `not_found`: no session with this `id` in your organization. Sessions are deleted after 30 days. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # list_sessions (/reference/identify/list-sessions) Send `site` to list one site's sessions, and `entity_id` to list the sessions you [linked](/reference/identify/update-session) to one of your customers. It returns up to 200 sessions and has no paging: use it to look at recent traffic, and [`get_session`](/reference/identify/get-session) to read one. ## GET https://api.finic.ai/v1/identify/sessions Lists the latest sessions, newest first, each with its [verdict](/identify/verdicts) and [visitor](/identify/visitors): across your organization's sites, for one site with `site`, for one visitor with `visitor`, or for one of your customers with `entity_id`. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `limit`: How many sessions to return, 1 to 200. More than 200 returns 200. - Query parameter `site`: A site's `id`, to list only that site's sessions. An id that isn't one of your sites gives an empty list. - Query parameter `visitor`: A visitor's `id`, to list only that [visitor](/identify/visitors)'s sessions. It combines with `site` and `entity_id`. - Query parameter `entity_id`: An [entity id](/reference/identify/update-session), to list only the sessions you linked to it. It must match exactly, and combines with `site`. One that no session has gives an empty list. - Query parameter `signals`: `true` adds each session's `signals`. ### Responses - **200**: The latest sessions. | Field | Type | Always | Description | | --- | --- | --- | --- | | `sessions` | array of object | yes | The sessions, newest first. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | | `sessions[].id` | string | yes | The session's id, `ksn_…`. | | `sessions[].site_id` | string | yes | The site it belongs to, `kst_…`. | | `sessions[].entity_id` | string or null | yes | Your own id for the customer or account the session belongs to, or `null` until one is set: by your page ([`data-entity` or `finic.identify()`](/identify/data#the-entity-id)) or by your server ([update_session](/reference/identify/update-session)). | | `sessions[].entity_source` | `server`, `browser`, `null` | yes | Who set `entity_id`. `server`: your API key, which you can rely on. `browser`: your page, through the snippet, which is only the page's claim. `null` with no entity id. | | `sessions[].status` | string | yes | Always `complete`. | | `sessions[].actor` | `human`, `ai_agent`, `automation`, `unknown` | yes | What the visitor is taken to be: `human` (the page was used the way a hand uses it), `ai_agent`, `automation`, or `unknown` (nothing for or against yet, as on a page that has only loaded). See [Verdicts](/identify/verdicts). | | `sessions[].operator` | string or null | yes | Who runs the agent, such as `OpenAI`, or `null`. For an impersonation, the operator it claims. | | `sessions[].product` | string or null | yes | The agent, such as `ChatGPT-User`, or `null`. | | `sessions[].category` | `training_crawler`, `search_fetcher`, `user_triggered_agent`, `other_crawler`, `generic_automation`, `null` | yes | What kind of agent it is: `training_crawler`, `search_fetcher`, `user_triggered_agent` (it acts for a person who asked) or `other_crawler`; `generic_automation` for an HTTP library or automation tool; `null` when unknown. | | `sessions[].verification` | `signed`, `network_verified`, `claimed`, `impersonated`, `none` | yes | How far the claim to be an agent was checked: `signed`, `network_verified`, `claimed`, `impersonated` or `none`. See [Verification](/identify/verdicts#verification). | | `sessions[].confidence` | `high`, `medium`, `low` | yes | How sure the verdict is. `low` is a hint, not a decision. See [Confidence](/identify/verdicts#confidence). | | `sessions[].confidence_score` | number | yes | `confidence` as a number from 0 to 1, to two decimals: `high` is 0.85 to 0.99, `medium` 0.50 to 0.84, `low` 0.01 to 0.49, and `unknown` is 0. It is worked out from the same rules as the verdict and isn't a measured probability. See [Confidence score](/identify/verdicts#confidence-score). | | `sessions[].reasons` | array of string | yes | What the verdict rests on, as [reason codes](/identify/verdicts#reason-codes). New codes can be added. | | `sessions[].network` | object | yes | Where the address is. | | `sessions[].ip` | string | yes | The visitor's address, from the report the verdict rests on: usually the latest. | | `sessions[].user_agent` | string | yes | That report's user agent, cut to 400 characters. | | `sessions[].page` | string | yes | The page that sent it: its origin and path, without the query. Path segments that look like a token or a name are `*`. | | `sessions[].reports` | integer | yes | The number of reports the session has taken. | | `sessions[].visitor_id` | string or null | yes | The session's [visitor](/identify/visitors), `kvi_…`: the same id for every session of the same browser. `null` until the browser has been identified, usually within a second of the page loading, and when the tag has `data-visitor="off"`. | | `sessions[].visitor` | object or null | yes | The visitor and how this session was matched to it, or `null` with `visitor_id`. | | `sessions[].incognito` | boolean or null | yes | Whether the browser is in a private window; `null` where it gives no way to tell. This and the fields down to `suspect_score` are the session's [smart signals](/identify/smart-signals). | | `sessions[].vpn` | boolean or null | yes | Whether the visitor seems to be behind a VPN: the browser's clock is in another time zone than its address. `null` without a location for the address or a time zone from the browser. | | `sessions[].vpn_confidence` | `high`, `medium` | | With `vpn: true`: `high` when the address is also a cloud provider's or a Tor exit node, else `medium`. | | `sessions[].vpn_origin_timezone` | string | | With `vpn: true`: the browser's own time zone, such as `America/Toronto`. | | `sessions[].vpn_methods` | object | | With a VPN verdict: what it rests on. | | `sessions[].virtual_machine` | boolean | yes | Whether the browser's graphics are a virtual machine's. | | `sessions[].tampering` | boolean | yes | Whether the browser contradicts itself about what it is. | | `sessions[].tampering_details` | object | yes | | | `sessions[].developer_tools` | boolean | yes | Whether the DevTools protocol is attached: open DevTools, or a tool driving the browser. | | `sessions[].privacy_settings` | boolean | yes | Whether the browser hides its fingerprint: Brave, or Firefox resisting fingerprinting. | | `sessions[].ip_info` | object | yes | The session's address, under `v4` or `v6`. | | `sessions[].ip_blocklist` | object | yes | | | `sessions[].velocity` | object | | How busy the session's visitor was in the 5 minutes, hour and 24 hours up to the session's start, this session included. Only from [get_session](/reference/identify/get-session), and only when the session has a visitor. | | `sessions[].suspect_score` | integer | yes | The smart signals added up, each by a [weight](/identify/smart-signals#suspect-score). 0 is nothing unusual. | | `sessions[].signals` | object | | With `signals=true`: the snippet's latest report, as `v`, `sv`, `page`, `env`, `input` and `fp`. Its fields are listed under [What the snippet collects](/identify/data#what-the-snippet-collects). | | `sessions[].created_at` | string | yes | When the session started. | | `sessions[].updated_at` | string | yes | When it last reported. | | `sessions[].request_id` | string | | `req_…`, the same as the `X-Request-Id` header. | | `sessions[].network.type` | `data_center`, `operator`, `unknown` | yes | `data_center` for a listed cloud provider's address, `operator` for an address in an agent operator's published ranges, `unknown` otherwise. | | `sessions[].network.provider` | string or null | yes | The cloud provider or operator, or `null`. | | `sessions[].network.range` | string or null | yes | The published range that holds the address, such as `192.0.2.0/24`, or `null`. | | `sessions[].visitor.id` | string | yes | The same as `visitor_id`. | | `sessions[].visitor.match` | `stored_id`, `fingerprint`, `new` | yes | How the visitor was recognised: `stored_id` (the id the browser kept), `fingerprint` (its fingerprint and network, with no stored id) or `new` (first seen in this session). See [How a visitor is matched](/identify/visitors#how-a-visitor-is-matched). | | `sessions[].visitor.confidence` | `high`, `medium`, `low` | yes | How sure it is that this session is this visitor's and nobody else's. See [Confidence](/identify/visitors#confidence). | | `sessions[].visitor.found` | boolean | yes | Whether the visitor had been seen before this session: `false` when `match` is `new`. | | `sessions[].visitor.confidence_score` | number | yes | `confidence` as a number: how sure it is that the session was given the right visitor and not another browser's. `1` for `stored_id` and `new`; for `fingerprint`, 0.90 to 0.99 when `high`, 0.60 to 0.89 when `medium`, 0.30 to 0.59 when `low`, higher the more of the fingerprint agreed. Not a measured probability. See [Confidence](/identify/visitors#confidence). | | `sessions[].visitor.sessions` | integer | yes | The number of sessions the visitor has had. | | `sessions[].visitor.first_seen_at` | string | yes | When the visitor was first seen. | | `sessions[].visitor.last_seen_at` | string or null | yes | When the visitor's last session before this one started. `null` for a new visitor. | | `sessions[].vpn_methods.timezone_mismatch` | boolean | | The browser's time zone differs from its address's. | | `sessions[].tampering_details.anomaly_score` | number | yes | The share of the five consistency checks that failed. | | `sessions[].ip_info.v4` | object | | Where an address is and whose network it is on. | | `sessions[].ip_info.v6` | object | | Where an address is and whose network it is on. | | `sessions[].ip_info.v4.address` | string | yes | | | `sessions[].ip_info.v4.geolocation` | object or null | yes | Where the address is, as near as its network says; `null` without a GeoIP database. | | `sessions[].ip_info.v4.asn` | string or null | yes | The network's number, such as `64500`. | | `sessions[].ip_info.v4.asn_name` | string or null | yes | | | `sessions[].ip_info.v4.asn_network` | string or null | yes | The range the address is in, such as `198.51.100.0/24`. | | `sessions[].ip_info.v4.datacenter_result` | boolean | yes | Whether the address is a listed cloud provider's. | | `sessions[].ip_info.v4.datacenter_name` | string or null | yes | | | `sessions[].ip_info.v4.geolocation.accuracy_radius` | integer | | In kilometres. | | `sessions[].ip_info.v4.geolocation.latitude` | number | | | | `sessions[].ip_info.v4.geolocation.longitude` | number | | | | `sessions[].ip_info.v4.geolocation.postal_code` | string | | | | `sessions[].ip_info.v4.geolocation.timezone` | string | | | | `sessions[].ip_info.v4.geolocation.city_name` | string | | | | `sessions[].ip_info.v4.geolocation.country_code` | string | | | | `sessions[].ip_info.v4.geolocation.country_name` | string | | | | `sessions[].ip_info.v4.geolocation.continent_code` | string | | | | `sessions[].ip_info.v4.geolocation.continent_name` | string | | | | `sessions[].ip_info.v4.geolocation.subdivisions` | array of object | | | | `sessions[].ip_info.v4.geolocation.subdivisions[].iso_code` | string | | | | `sessions[].ip_info.v4.geolocation.subdivisions[].name` | string | | | | `sessions[].ip_info.v6.address` | string | yes | | | `sessions[].ip_info.v6.geolocation` | object or null | yes | Where the address is, as near as its network says; `null` without a GeoIP database. | | `sessions[].ip_info.v6.asn` | string or null | yes | The network's number, such as `64500`. | | `sessions[].ip_info.v6.asn_name` | string or null | yes | | | `sessions[].ip_info.v6.asn_network` | string or null | yes | The range the address is in, such as `198.51.100.0/24`. | | `sessions[].ip_info.v6.datacenter_result` | boolean | yes | Whether the address is a listed cloud provider's. | | `sessions[].ip_info.v6.datacenter_name` | string or null | yes | | | `sessions[].ip_info.v6.geolocation.accuracy_radius` | integer | | In kilometres. | | `sessions[].ip_info.v6.geolocation.latitude` | number | | | | `sessions[].ip_info.v6.geolocation.longitude` | number | | | | `sessions[].ip_info.v6.geolocation.postal_code` | string | | | | `sessions[].ip_info.v6.geolocation.timezone` | string | | | | `sessions[].ip_info.v6.geolocation.city_name` | string | | | | `sessions[].ip_info.v6.geolocation.country_code` | string | | | | `sessions[].ip_info.v6.geolocation.country_name` | string | | | | `sessions[].ip_info.v6.geolocation.continent_code` | string | | | | `sessions[].ip_info.v6.geolocation.continent_name` | string | | | | `sessions[].ip_info.v6.geolocation.subdivisions` | array of object | | | | `sessions[].ip_info.v6.geolocation.subdivisions[].iso_code` | string | | | | `sessions[].ip_info.v6.geolocation.subdivisions[].name` | string | | | | `sessions[].ip_blocklist.tor_node` | boolean | yes | Whether the address is a Tor exit node. | | `sessions[].velocity.events` | object | | One count over three spans of time. | | `sessions[].velocity.distinct_ip` | object | | One count over three spans of time. | | `sessions[].velocity.distinct_entity_id` | object | | One count over three spans of time. | | `sessions[].velocity.events.5_minutes` | integer | yes | | | `sessions[].velocity.events.1_hour` | integer | yes | | | `sessions[].velocity.events.24_hours` | integer | yes | | | `sessions[].velocity.distinct_ip.5_minutes` | integer | yes | | | `sessions[].velocity.distinct_ip.1_hour` | integer | yes | | | `sessions[].velocity.distinct_ip.24_hours` | integer | yes | | | `sessions[].velocity.distinct_entity_id.5_minutes` | integer | yes | | | `sessions[].velocity.distinct_entity_id.1_hour` | integer | yes | | | `sessions[].velocity.distinct_entity_id.24_hours` | integer | yes | | ```json { "sessions": [ { "id": "ksn_01M4Z2P4D7H1S8A3F6GY9CJNRV", "site_id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "entity_id": null, "entity_source": null, "status": "complete", "actor": "unknown", "operator": null, "product": null, "category": null, "verification": "none", "confidence": "low", "confidence_score": 0, "reasons": [], "network": { "type": "unknown", "provider": null, "range": null }, "ip": "198.51.100.61", "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:133.0) Gecko/20100101 Firefox/133.0", "page": "https://www.example.com/", "reports": 2, "visitor_id": null, "visitor": null, "created_at": "2026-12-01T17:06:40.118302Z", "updated_at": "2026-12-01T17:06:40.764915Z" }, { "id": "ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE", "site_id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "entity_id": "user_123", "entity_source": "server", "status": "complete", "actor": "human", "operator": null, "product": null, "category": null, "verification": "none", "confidence": "high", "confidence_score": 0.9, "reasons": [ "human_like_input" ], "network": { "type": "unknown", "provider": null, "range": null }, "ip": "198.51.100.24", "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36", "page": "https://www.example.com/checkout", "reports": 4, "visitor_id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "visitor": { "id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "match": "stored_id", "found": true, "confidence": "high", "confidence_score": 1, "sessions": 7, "first_seen_at": "2026-11-18T09:41:07.120443Z", "last_seen_at": "2026-11-30T20:15:42.004118Z" }, "created_at": "2026-12-01T17:04:11.482913Z", "updated_at": "2026-12-01T17:04:19.905127Z" } ], "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # update_session (/reference/identify/update-session) Send `entity_id` once you know whose session it is, such as after sign-in. Send `null` or `""` to clear it. Either way the session's `entity_source` becomes `server`, and an id your page [names from the browser](/identify/data#the-entity-id) no longer changes it. [`list_sessions`](/reference/identify/list-sessions) with `entity_id` then lists that customer's sessions. ## PATCH https://api.finic.ai/v1/identify/sessions/{id} Sets or clears a session's `entity_id`: your own id for the customer or user account the session belongs to. Send a string to set it, and `null` or `""` to clear it. What this call sets or clears stands: the session's `entity_source` becomes `server`, and an id the page names through the snippet no longer changes it. Nothing else of the session changes, its [verdict](/identify/verdicts) and `updated_at` included. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `id`: The session's `id`, `ksn_…`. ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `entity_id` | string or null | | Your id for the customer or account, 1 to 128 characters with no control characters. Spaces around it are dropped. `null` or `""` clears it. Without it, nothing changes. | Example: ```json { "entity_id": "user_123" } ``` ### Responses - **200**: The session, as changed. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The session's id, `ksn_…`. | | `site_id` | string | yes | The site it belongs to, `kst_…`. | | `entity_id` | string or null | yes | Your own id for the customer or account the session belongs to, or `null` until one is set: by your page ([`data-entity` or `finic.identify()`](/identify/data#the-entity-id)) or by your server ([update_session](/reference/identify/update-session)). | | `entity_source` | `server`, `browser`, `null` | yes | Who set `entity_id`. `server`: your API key, which you can rely on. `browser`: your page, through the snippet, which is only the page's claim. `null` with no entity id. | | `status` | string | yes | Always `complete`. | | `actor` | `human`, `ai_agent`, `automation`, `unknown` | yes | What the visitor is taken to be: `human` (the page was used the way a hand uses it), `ai_agent`, `automation`, or `unknown` (nothing for or against yet, as on a page that has only loaded). See [Verdicts](/identify/verdicts). | | `operator` | string or null | yes | Who runs the agent, such as `OpenAI`, or `null`. For an impersonation, the operator it claims. | | `product` | string or null | yes | The agent, such as `ChatGPT-User`, or `null`. | | `category` | `training_crawler`, `search_fetcher`, `user_triggered_agent`, `other_crawler`, `generic_automation`, `null` | yes | What kind of agent it is: `training_crawler`, `search_fetcher`, `user_triggered_agent` (it acts for a person who asked) or `other_crawler`; `generic_automation` for an HTTP library or automation tool; `null` when unknown. | | `verification` | `signed`, `network_verified`, `claimed`, `impersonated`, `none` | yes | How far the claim to be an agent was checked: `signed`, `network_verified`, `claimed`, `impersonated` or `none`. See [Verification](/identify/verdicts#verification). | | `confidence` | `high`, `medium`, `low` | yes | How sure the verdict is. `low` is a hint, not a decision. See [Confidence](/identify/verdicts#confidence). | | `confidence_score` | number | yes | `confidence` as a number from 0 to 1, to two decimals: `high` is 0.85 to 0.99, `medium` 0.50 to 0.84, `low` 0.01 to 0.49, and `unknown` is 0. It is worked out from the same rules as the verdict and isn't a measured probability. See [Confidence score](/identify/verdicts#confidence-score). | | `reasons` | array of string | yes | What the verdict rests on, as [reason codes](/identify/verdicts#reason-codes). New codes can be added. | | `network` | object | yes | Where the address is. | | `ip` | string | yes | The visitor's address, from the report the verdict rests on: usually the latest. | | `user_agent` | string | yes | That report's user agent, cut to 400 characters. | | `page` | string | yes | The page that sent it: its origin and path, without the query. Path segments that look like a token or a name are `*`. | | `reports` | integer | yes | The number of reports the session has taken. | | `visitor_id` | string or null | yes | The session's [visitor](/identify/visitors), `kvi_…`: the same id for every session of the same browser. `null` until the browser has been identified, usually within a second of the page loading, and when the tag has `data-visitor="off"`. | | `visitor` | object or null | yes | The visitor and how this session was matched to it, or `null` with `visitor_id`. | | `incognito` | boolean or null | yes | Whether the browser is in a private window; `null` where it gives no way to tell. This and the fields down to `suspect_score` are the session's [smart signals](/identify/smart-signals). | | `vpn` | boolean or null | yes | Whether the visitor seems to be behind a VPN: the browser's clock is in another time zone than its address. `null` without a location for the address or a time zone from the browser. | | `vpn_confidence` | `high`, `medium` | | With `vpn: true`: `high` when the address is also a cloud provider's or a Tor exit node, else `medium`. | | `vpn_origin_timezone` | string | | With `vpn: true`: the browser's own time zone, such as `America/Toronto`. | | `vpn_methods` | object | | With a VPN verdict: what it rests on. | | `virtual_machine` | boolean | yes | Whether the browser's graphics are a virtual machine's. | | `tampering` | boolean | yes | Whether the browser contradicts itself about what it is. | | `tampering_details` | object | yes | | | `developer_tools` | boolean | yes | Whether the DevTools protocol is attached: open DevTools, or a tool driving the browser. | | `privacy_settings` | boolean | yes | Whether the browser hides its fingerprint: Brave, or Firefox resisting fingerprinting. | | `ip_info` | object | yes | The session's address, under `v4` or `v6`. | | `ip_blocklist` | object | yes | | | `velocity` | object | | How busy the session's visitor was in the 5 minutes, hour and 24 hours up to the session's start, this session included. Only from [get_session](/reference/identify/get-session), and only when the session has a visitor. | | `suspect_score` | integer | yes | The smart signals added up, each by a [weight](/identify/smart-signals#suspect-score). 0 is nothing unusual. | | `signals` | object | | With `signals=true`: the snippet's latest report, as `v`, `sv`, `page`, `env`, `input` and `fp`. Its fields are listed under [What the snippet collects](/identify/data#what-the-snippet-collects). | | `created_at` | string | yes | When the session started. | | `updated_at` | string | yes | When it last reported. | | `request_id` | string | | `req_…`, the same as the `X-Request-Id` header. | | `network.type` | `data_center`, `operator`, `unknown` | yes | `data_center` for a listed cloud provider's address, `operator` for an address in an agent operator's published ranges, `unknown` otherwise. | | `network.provider` | string or null | yes | The cloud provider or operator, or `null`. | | `network.range` | string or null | yes | The published range that holds the address, such as `192.0.2.0/24`, or `null`. | | `visitor.id` | string | yes | The same as `visitor_id`. | | `visitor.match` | `stored_id`, `fingerprint`, `new` | yes | How the visitor was recognised: `stored_id` (the id the browser kept), `fingerprint` (its fingerprint and network, with no stored id) or `new` (first seen in this session). See [How a visitor is matched](/identify/visitors#how-a-visitor-is-matched). | | `visitor.confidence` | `high`, `medium`, `low` | yes | How sure it is that this session is this visitor's and nobody else's. See [Confidence](/identify/visitors#confidence). | | `visitor.found` | boolean | yes | Whether the visitor had been seen before this session: `false` when `match` is `new`. | | `visitor.confidence_score` | number | yes | `confidence` as a number: how sure it is that the session was given the right visitor and not another browser's. `1` for `stored_id` and `new`; for `fingerprint`, 0.90 to 0.99 when `high`, 0.60 to 0.89 when `medium`, 0.30 to 0.59 when `low`, higher the more of the fingerprint agreed. Not a measured probability. See [Confidence](/identify/visitors#confidence). | | `visitor.sessions` | integer | yes | The number of sessions the visitor has had. | | `visitor.first_seen_at` | string | yes | When the visitor was first seen. | | `visitor.last_seen_at` | string or null | yes | When the visitor's last session before this one started. `null` for a new visitor. | | `vpn_methods.timezone_mismatch` | boolean | | The browser's time zone differs from its address's. | | `tampering_details.anomaly_score` | number | yes | The share of the five consistency checks that failed. | | `ip_info.v4` | object | | Where an address is and whose network it is on. | | `ip_info.v6` | object | | Where an address is and whose network it is on. | | `ip_info.v4.address` | string | yes | | | `ip_info.v4.geolocation` | object or null | yes | Where the address is, as near as its network says; `null` without a GeoIP database. | | `ip_info.v4.asn` | string or null | yes | The network's number, such as `64500`. | | `ip_info.v4.asn_name` | string or null | yes | | | `ip_info.v4.asn_network` | string or null | yes | The range the address is in, such as `198.51.100.0/24`. | | `ip_info.v4.datacenter_result` | boolean | yes | Whether the address is a listed cloud provider's. | | `ip_info.v4.datacenter_name` | string or null | yes | | | `ip_info.v4.geolocation.accuracy_radius` | integer | | In kilometres. | | `ip_info.v4.geolocation.latitude` | number | | | | `ip_info.v4.geolocation.longitude` | number | | | | `ip_info.v4.geolocation.postal_code` | string | | | | `ip_info.v4.geolocation.timezone` | string | | | | `ip_info.v4.geolocation.city_name` | string | | | | `ip_info.v4.geolocation.country_code` | string | | | | `ip_info.v4.geolocation.country_name` | string | | | | `ip_info.v4.geolocation.continent_code` | string | | | | `ip_info.v4.geolocation.continent_name` | string | | | | `ip_info.v4.geolocation.subdivisions` | array of object | | | | `ip_info.v4.geolocation.subdivisions[].iso_code` | string | | | | `ip_info.v4.geolocation.subdivisions[].name` | string | | | | `ip_info.v6.address` | string | yes | | | `ip_info.v6.geolocation` | object or null | yes | Where the address is, as near as its network says; `null` without a GeoIP database. | | `ip_info.v6.asn` | string or null | yes | The network's number, such as `64500`. | | `ip_info.v6.asn_name` | string or null | yes | | | `ip_info.v6.asn_network` | string or null | yes | The range the address is in, such as `198.51.100.0/24`. | | `ip_info.v6.datacenter_result` | boolean | yes | Whether the address is a listed cloud provider's. | | `ip_info.v6.datacenter_name` | string or null | yes | | | `ip_info.v6.geolocation.accuracy_radius` | integer | | In kilometres. | | `ip_info.v6.geolocation.latitude` | number | | | | `ip_info.v6.geolocation.longitude` | number | | | | `ip_info.v6.geolocation.postal_code` | string | | | | `ip_info.v6.geolocation.timezone` | string | | | | `ip_info.v6.geolocation.city_name` | string | | | | `ip_info.v6.geolocation.country_code` | string | | | | `ip_info.v6.geolocation.country_name` | string | | | | `ip_info.v6.geolocation.continent_code` | string | | | | `ip_info.v6.geolocation.continent_name` | string | | | | `ip_info.v6.geolocation.subdivisions` | array of object | | | | `ip_info.v6.geolocation.subdivisions[].iso_code` | string | | | | `ip_info.v6.geolocation.subdivisions[].name` | string | | | | `ip_blocklist.tor_node` | boolean | yes | Whether the address is a Tor exit node. | | `velocity.events` | object | | One count over three spans of time. | | `velocity.distinct_ip` | object | | One count over three spans of time. | | `velocity.distinct_entity_id` | object | | One count over three spans of time. | | `velocity.events.5_minutes` | integer | yes | | | `velocity.events.1_hour` | integer | yes | | | `velocity.events.24_hours` | integer | yes | | | `velocity.distinct_ip.5_minutes` | integer | yes | | | `velocity.distinct_ip.1_hour` | integer | yes | | | `velocity.distinct_ip.24_hours` | integer | yes | | | `velocity.distinct_entity_id.5_minutes` | integer | yes | | | `velocity.distinct_entity_id.1_hour` | integer | yes | | | `velocity.distinct_entity_id.24_hours` | integer | yes | | ```json { "id": "ksn_01M4Z2K8Q0V7C3N5T9XB6RHDWE", "site_id": "kst_01M4Z1X3G5P8D2F6J0YA4SMQNC", "entity_id": "user_123", "entity_source": "server", "status": "complete", "actor": "human", "operator": null, "product": null, "category": null, "verification": "none", "confidence": "high", "confidence_score": 0.9, "reasons": [ "human_like_input" ], "network": { "type": "unknown", "provider": null, "range": null }, "ip": "198.51.100.24", "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36", "page": "https://www.example.com/checkout", "reports": 4, "visitor_id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "visitor": { "id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "match": "stored_id", "found": true, "confidence": "high", "confidence_score": 1, "sessions": 7, "first_seen_at": "2026-11-18T09:41:07.120443Z", "last_seen_at": "2026-11-30T20:15:42.004118Z" }, "created_at": "2026-12-01T17:04:11.482913Z", "updated_at": "2026-12-01T17:04:19.905127Z", "request_id": "req_01M4Z2R6B3K9T1W5X8NC7DGHJQ" } ``` - **400**: `invalid_request`: the body isn't a JSON object or has an unknown field; or `entity_id` isn't a string or `null`, is only spaces, is over 128 characters, or has a control character (`param` is `entity_id`). - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `not_found`: no session with this `id` in your organization. Sessions are deleted after 30 days. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # get_visitor (/reference/identify/get-visitor) See [Visitors](/identify/visitors) for what a visitor is and how one is matched. ## GET https://api.finic.ai/v1/identify/visitors/{id} Gets one [visitor](/identify/visitors): a browser your sites have seen, with how many sessions it has had and when it was first and last seen. A session carries its visitor's id as `visitor_id`. To list a visitor's sessions, call [list_sessions](/reference/identify/list-sessions) with `visitor`. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `id`: The visitor's `id`, `kvi_…`. ### Responses - **200**: The visitor. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The visitor's id, `kvi_…`. | | `browser` | string | yes | The make of browser, from its user agent: `chrome`, `safari`, `firefox`, `edge`, `opera`, `samsung` or `other`. | | `os` | string | yes | Its operating system: `windows`, `mac`, `ios`, `android`, `linux`, `chromeos` or `other`. | | `sessions` | integer | yes | The number of sessions the visitor has had. | | `first_seen_at` | string | yes | When the visitor was first seen. | | `last_seen_at` | string | yes | When its latest session started. | | `request_id` | string | | `req_…`, the same as the `X-Request-Id` header. | ```json { "id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "browser": "chrome", "os": "mac", "sessions": 7, "first_seen_at": "2026-11-18T09:41:07.120443Z", "last_seen_at": "2026-12-01T17:04:11.482913Z", "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `not_found`: no visitor with this `id` in your organization. A visitor is deleted a year after it was last seen. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # delete_visitor (/reference/identify/delete-visitor) Use it when a person asks you to erase their data. This can't be undone, and the browser is a new visitor if it comes back. ## DELETE https://api.finic.ai/v1/identify/visitors/{id} Deletes a visitor: its fingerprint, the addresses it was seen at and its token. Its sessions stay, without a visitor, until they're 30 days old. If the browser comes back, it is a new visitor with a new id. This can't be undone. Authorization: `Bearer ` (see [Authentication](/authentication)). - Path parameter `id`: The visitor's `id`. ### Responses - **200**: The visitor is deleted. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | yes | The visitor's id | | `deleted` | boolean | yes | Always `true`. | | `request_id` | string | yes | `req_…`, the same as the `X-Request-Id` header. | ```json { "id": "kvi_01M4Z2Q7B3X9K5W1E8TN6GHPAD", "deleted": true, "request_id": "req_01M4Z2M1T6W9E3R7Y5VA8PKGHB" } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **402**: `insufficient_credit`: the organization is out of credit. An admin adds more in the Finic app. - **404**: `not_found`: no visitor with this `id` in your organization. - **429**: `rate_limited`: over Identify's [request rate](/reference/identify#limits) for the organization, 50 a second. Retry with backoff. # Businesses (/reference/kyb/businesses) See [KYB](/kyb) and [Businesses](/kyb/businesses). Unlike scoring requests, these endpoints store what you send until you delete it. | Endpoint | Request | What it does | | ---------------------------------------------------------------------- | ---------------------------------- | ---------------------------------------------------------------------------------------------------- | | [`create_business`](/reference/kyb/businesses/create-business) | `POST /v1/businesses` | Creates a business, with its addresses, people, corporate owners and registrations in the same call. | | [`list_businesses`](/reference/kyb/businesses/list-businesses) | `GET /v1/businesses` | Lists your businesses, newest first. | | [`get_business`](/reference/kyb/businesses/get-business) | `GET /v1/businesses/{id}` | Gets a business, with its current screenings, its latest verification and `possible_duplicates`. | | [`update_business`](/reference/kyb/businesses/update-business) | `PATCH /v1/businesses/{id}` | Changes the fields sent. | | [`delete_business`](/reference/kyb/businesses/delete-business) | `DELETE /v1/businesses/{id}` | Deletes a business, with its records and screenings, and cancels their jobs. | | [`restore_business`](/reference/kyb/businesses/restore-business) | `POST /v1/businesses/{id}/restore` | Brings back a deleted business, with what was deleted with it, and screens it again. | | [`set_business_status`](/reference/kyb/businesses/set-business-status) | `POST /v1/businesses/{id}/status` | Sets a business's status. | | [`screen_business`](/reference/kyb/businesses/screen-business) | `POST /v1/businesses/{id}/screen` | Screens the business again, for `kinds` or for each kind it can have now. | | [`enrich_business`](/reference/kyb/businesses/enrich-business) | `POST /v1/businesses/{id}/enrich` | Collects records about a business without judging them: no screening and no findings. | # create_business (/reference/kyb/businesses/create-business) ## POST https://api.finic.ai/v1/businesses Creates a business, with its addresses, people, corporate owners and registrations in the same call. Only `legal_name` is required. It's all saved or none of it; an error names the record at fault (`people[0].roles`). A new business is screened at once: `sanctions` for the business, its people and corporate owners, and `jurisdiction` for its addresses. Send `screening` to choose other kinds, or `verify` to start a [verification](/kyb/verifications) instead. Send an `external_id`, so that a request made again is `409 business_exists` and not a second business. Business records are stored until you delete them. Your data retention setting, including Zero Data Retention, applies to scoring requests, not to business records. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `wait`: Seconds to wait for a verification's outcome before answering. ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | Example: ```json { "legal_name": "Acme Tools LLC", "external_id": "merchant_42", "trade_names": [ "Acme Tools" ], "entity_type": "llc", "formation": { "jurisdiction": { "country": "US", "state": "DE" }, "date": "2019-04-02" }, "website": "example.com", "description": "Sells hand tools to builders", "industry": "Hardware retail", "country": "US", "contacts": [ { "type": "email", "value": "ops@example.com" } ], "addresses": [ { "kind": "registered", "line1": "8 The Green", "city": "Dover", "state": "DE", "country": "US" } ], "people": [ { "first_name": "Grace", "last_name": "Hopper", "title": "CEO", "roles": [ "control_person", "shareholder" ], "percentage": 40 } ], "monitoring": { "interval_days": 30, "business": [ "sanctions" ], "people": [ "sanctions" ] } } ``` ### Responses - **201**: The business. - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **409**: `business_exists`: a business has this `external_id`. The error has its `business_id`. - **413**: `request_too_large`: over 2 MB, or the record is too large. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. - **503**: `screening_unavailable`: a screening kind asked for isn't available right now. # list_businesses (/reference/kyb/businesses/list-businesses) ## GET https://api.finic.ai/v1/businesses Lists your businesses, newest first. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `status`: - Query parameter `external_id`: - Query parameter `limit`: - Query parameter `after`: The last record's `id` on the page before, for the next page. ### Responses - **200**: A page of businesses. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of any | | | | `has_more` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **429**: `rate_limited`: over the organization's [request rate](/reference#rate-limits). Retry with backoff. # get_business (/reference/kyb/businesses/get-business) ## GET https://api.finic.ai/v1/businesses/{id} Gets a business, with its current screenings, its latest verification and `possible_duplicates`. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The business. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # update_business (/reference/kyb/businesses/update-business) ## PATCH https://api.finic.ai/v1/businesses/{id} Changes the fields sent. In `metadata`, `null` removes a key. `contacts` replaces the list. `monitoring` replaces the schedule, and `null` stops it. Changing a screened field, such as `legal_name`, screens it again. To change addresses, people, corporate owners or registrations, use their own endpoints. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `legal_name` | string | | | | `external_id` | string | | Your id for the business. Unique among your businesses. | | `trade_names` | array of string | | | | `entity_type` | `llc`, `corporation`, `partnership`, `sole_proprietorship`, `nonprofit`, `trust`, `government`, `other` | | | | `formation` | object | | Where and when the business says it was formed. | | `contacts` | array of object | | Sending it replaces the list. | | `website` | string | | | | `description` | string | | | | `industry` | string | | | | `country` | string | | ISO 3166-1 alpha-2. | | `metadata` | object | | Your own data, up to 16 KB. | | `monitoring` | object or null | | Screens again every `interval_days`, for the kinds of each part. Each run is priced as any screening. Nothing runs while the business is `rejected`, `closed` or deleted. | | `formation.jurisdiction` | object | | | | `formation.date` | string | | | | `formation.jurisdiction.country` | string | yes | ISO 3166-1 alpha-2, such as `US`. | | `formation.jurisdiction.state` | string | | The ISO 3166-2 subdivision code without the country, such as `DE`. | | `contacts[].type` | `tel`, `email` | yes | | | `contacts[].value` | string | yes | A phone number in international form (`+15555550100`), or an email address. | | `monitoring.interval_days` | integer | yes | | | `monitoring.business` | array of string | | | | `monitoring.people` | array of string | | | | `monitoring.corporate_owners` | array of string | | | | `monitoring.addresses` | array of string | | | | `monitoring.next_run_at` | string | | | Example: ```json { "website": "example.com", "metadata": { "tier": "gold" } } ``` ### Responses - **200**: The business. - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # delete_business (/reference/kyb/businesses/delete-business) ## DELETE https://api.finic.ai/v1/businesses/{id} Deletes a business, with its records and screenings, and cancels their jobs. You can [restore](/reference/kyb/businesses) it for 30 days; after that, Finic removes it from its business records. With `permanent=true` (an admin's key), it's removed at once. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `permanent`: ### Responses - **200**: Deleted. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | | | `deleted` | boolean | | | | `permanent` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: this needs an API key an admin of the organization created. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **409**: `business_referenced`: another business's record points to it. # restore_business (/reference/kyb/businesses/restore-business) ## POST https://api.finic.ai/v1/businesses/{id}/restore Brings back a deleted business, with what was deleted with it, and screens it again. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The business. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # set_business_status (/reference/kyb/businesses/set-business-status) ## POST https://api.finic.ai/v1/businesses/{id}/status Sets a business's status. `pending` can become `in_review`, `approved`, `rejected` or `closed`; `in_review` can become `approved`, `rejected` or `closed`; `approved` and `rejected` can become `in_review` or `closed`; `closed` can become `in_review`. A verification also sets it. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `status` | `pending`, `in_review`, `approved`, `rejected`, `closed` | yes | | Example: ```json { "status": "approved" } ``` ### Responses - **200**: The business. - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **409**: `invalid_transition`: the business can't go from its status to this one. # screen_business (/reference/kyb/businesses/screen-business) ## POST https://api.finic.ai/v1/businesses/{id}/screen Screens the business again, for `kinds` or for each kind it can have now. Each screening runs in the background; read it with [get_screening](/reference/kyb/screenings), or get `screening.completed` by [webhook](/webhooks). Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `kinds` | array of string | | | Example: ```json { "kinds": [ "sanctions", "website" ] } ``` ### Responses - **202**: A screening for each kind. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `scr_…` | | `data[].subject_type` | `business`, `object`, `null` | | | | `data[].subject_id` | string or null | | | | `data[].business_id` | string or null | | | | `data[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `data[].state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `data[].reason` | string or null | | Why it's `pending` or `inconclusive`. | | `data[].input` | object | | What was screened. | | `data[].findings` | array of object | | | | `data[].score` | integer or null | | | | `data[].result` | object | | What else the kind says, such as the sanctions `lists` screened. | | `data[].review_note` | string or null | | | | `data[].reviewed_at` | string or null | | | | `data[].superseded_at` | string or null | | | | `data[].created_at` | string | | | | `data[].completed_at` | string or null | | | | `data[].findings[].id` | string | | | | `data[].findings[].code` | string | | What was found, such as `list_match` or `mail_forwarding`. | | `data[].findings[].severity` | `info`, `low`, `medium`, `high` | | `info` needs no review. | | `data[].findings[].summary` | string | | | | `data[].findings[].details` | object | | | | `data[].findings[].fingerprint` | string | | | | `data[].findings[].decision` | `confirmed`, `false_positive`, `null` | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **503**: `screening_unavailable`: a screening kind asked for isn't available right now. # enrich_business (/reference/kyb/businesses/enrich-business) ## POST https://api.finic.ai/v1/businesses/{id}/enrich Collects records about a business without judging them: no screening and no findings. `website` reads the business's site and keeps it as a `website` record, free. Each source is a [job](/reference/score/get-job-status); its `result` has `object_ids`, the records kept. A source that isn't available answers `503 screening_unavailable`. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `sources` | array of string | yes | The sources to collect from, such as `website`. | Example: ```json { "sources": [ "website" ] } ``` ### Responses - **202**: A job for each source. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].source` | string | | | | `data[].job_id` | string | | | ```json { "data": [ { "source": "website", "job_id": "job_01M4Z3Y5E7F9G1H3J5K7M9N1PQ" } ], "has_more": false } ``` - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **503**: `screening_unavailable`: a screening kind asked for isn't available right now. # Verifications (/reference/kyb/verifications) See [Verifications](/kyb/verifications). | Endpoint | Request | What it does | | --------------------------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- | | [`verify_business`](/reference/kyb/verifications/verify-business) | `POST /v1/businesses/{id}/verify` | Starts a verification: a package of screenings of the business and its records, with one outcome, `approved`, `in_review` or `rejected`. | | [`list_verifications`](/reference/kyb/verifications/list-verifications) | `GET /v1/businesses/{id}/verifications` | Lists a business's verifications, newest first. | | [`get_verification`](/reference/kyb/verifications/get-verification) | `GET /v1/businesses/{id}/verifications/{verification_id}` | Gets a verification, with each of its checks. | | [`get_verification_report`](/reference/kyb/verifications/get-verification-report) | `GET /v1/businesses/{id}/verifications/{verification_id}/report` | A complete verification's report, as JSON: the business as it was, and every check with its whole screening. | | [`get_verification_pdf`](/reference/kyb/verifications/get-verification-pdf) | `GET /v1/businesses/{id}/verifications/{verification_id}/pdf` | The same report as a PDF document. | # verify_business (/reference/kyb/verifications/verify-business) ## POST https://api.finic.ai/v1/businesses/{id}/verify Starts a verification: a package of screenings of the business and its records, with one outcome, `approved`, `in_review` or `rejected`. The business's status becomes the outcome. Send the kinds for each part (`business`, `people`, `corporate_owners`, `addresses`), or an empty body for each part's package. A check that can't be made is `skipped`, with the reason; a required check that isn't made puts the outcome `in_review`. It answers at once, `202` while the verification is `pending`. Get `verification.completed` by [webhook](/webhooks), or send `wait` to have the request wait for the outcome. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `wait`: Seconds to wait for a verification's outcome before answering. ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `business` | array of string | | | | `people` | array of string | | | | `corporate_owners` | array of string | | | | `addresses` | array of string | | | Example: ```json { "business": [ "sanctions", "website" ], "people": [ "sanctions" ], "addresses": [ "jurisdiction", "address" ] } ``` ### Responses - **200**: The verification, complete. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `ver_…` | | `business_id` | string | | | | `status` | `pending`, `complete` | | | | `outcome` | `approved`, `in_review`, `rejected`, `null` | | | | `score` | integer or null | | 0 to 1000, from the checks' findings and reviewers' decisions. It isn't a calibrated probability. | | `reasons` | array of object | | Why: findings' codes, and `check_not_made`, worst first. | | `checks` | array of object | | Each check, with its screening. | | `created_at` | string | | | | `updated_at` | string | | | | `completed_at` | string or null | | | | `checks[].part` | `business`, `people`, `corporate_owners`, `addresses` | | | | `checks[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `checks[].subject_type` | string | | | | `checks[].subject_id` | string | | | | `checks[].required` | boolean | | | - **202**: The verification, pending. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `ver_…` | | `business_id` | string | | | | `status` | `pending`, `complete` | | | | `outcome` | `approved`, `in_review`, `rejected`, `null` | | | | `score` | integer or null | | 0 to 1000, from the checks' findings and reviewers' decisions. It isn't a calibrated probability. | | `reasons` | array of object | | Why: findings' codes, and `check_not_made`, worst first. | | `checks` | array of object | | Each check, with its screening. | | `created_at` | string | | | | `updated_at` | string | | | | `completed_at` | string or null | | | | `checks[].part` | `business`, `people`, `corporate_owners`, `addresses` | | | | `checks[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `checks[].subject_type` | string | | | | `checks[].subject_id` | string | | | | `checks[].required` | boolean | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **409**: `business_closed`: the business is closed. # list_verifications (/reference/kyb/verifications/list-verifications) ## GET https://api.finic.ai/v1/businesses/{id}/verifications Lists a business's verifications, newest first. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `status`: - Query parameter `outcome`: - Query parameter `limit`: - Query parameter `after`: The last record's `id` on the page before, for the next page. ### Responses - **200**: A page of verifications. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `ver_…` | | `data[].business_id` | string | | | | `data[].status` | `pending`, `complete` | | | | `data[].outcome` | `approved`, `in_review`, `rejected`, `null` | | | | `data[].score` | integer or null | | 0 to 1000, from the checks' findings and reviewers' decisions. It isn't a calibrated probability. | | `data[].reasons` | array of object | | Why: findings' codes, and `check_not_made`, worst first. | | `data[].checks` | array of object | | Each check, with its screening. | | `data[].created_at` | string | | | | `data[].updated_at` | string | | | | `data[].completed_at` | string or null | | | | `data[].checks[].part` | `business`, `people`, `corporate_owners`, `addresses` | | | | `data[].checks[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `data[].checks[].subject_type` | string | | | | `data[].checks[].subject_id` | string | | | | `data[].checks[].required` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # get_verification (/reference/kyb/verifications/get-verification) ## GET https://api.finic.ai/v1/businesses/{id}/verifications/{verification_id} Gets a verification, with each of its checks. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `wait`: Seconds to wait for a verification's outcome before answering. ### Responses - **200**: The verification. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `ver_…` | | `business_id` | string | | | | `status` | `pending`, `complete` | | | | `outcome` | `approved`, `in_review`, `rejected`, `null` | | | | `score` | integer or null | | 0 to 1000, from the checks' findings and reviewers' decisions. It isn't a calibrated probability. | | `reasons` | array of object | | Why: findings' codes, and `check_not_made`, worst first. | | `checks` | array of object | | Each check, with its screening. | | `created_at` | string | | | | `updated_at` | string | | | | `completed_at` | string or null | | | | `checks[].part` | `business`, `people`, `corporate_owners`, `addresses` | | | | `checks[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `checks[].subject_type` | string | | | | `checks[].subject_id` | string | | | | `checks[].required` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # get_verification_report (/reference/kyb/verifications/get-verification-report) ## GET https://api.finic.ai/v1/businesses/{id}/verifications/{verification_id}/report A complete verification's report, as JSON: the business as it was, and every check with its whole screening. A check of a record deleted since is `deleted`. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The report. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **409**: `verification_not_complete`: the verification is still pending. # get_verification_pdf (/reference/kyb/verifications/get-verification-pdf) ## GET https://api.finic.ai/v1/businesses/{id}/verifications/{verification_id}/pdf The same report as a PDF document. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The report. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **409**: `verification_not_complete`: the verification is still pending. # Business records (/reference/kyb/records) See [Businesses](/kyb/businesses#people-owners-and-addresses). | Endpoint | Request | What it does | | --------------------------------------------------------------------------- | ----------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | [`create_business_record`](/reference/kyb/records/create-business-record) | `POST /v1/businesses/{id}/{collection}` | Adds a record to a business: a person, a corporate owner, a registration, an address, or one of the records screenings and enrichment keep (liens, court cases, bankruptcies, reviews, websites). | | [`list_business_records`](/reference/kyb/records/list-business-records) | `GET /v1/businesses/{id}/{collection}` | Lists a business's records of one collection, newest first. | | [`get_business_record`](/reference/kyb/records/get-business-record) | `GET /v1/businesses/{id}/{collection}/{object_id}` | Gets one of a business's records. | | [`update_business_record`](/reference/kyb/records/update-business-record) | `PATCH /v1/businesses/{id}/{collection}/{object_id}` | Changes the fields sent; `null` removes a field. | | [`delete_business_record`](/reference/kyb/records/delete-business-record) | `DELETE /v1/businesses/{id}/{collection}/{object_id}` | Deletes a record and its screenings. | | [`restore_business_record`](/reference/kyb/records/restore-business-record) | `POST /v1/businesses/{id}/{collection}/{object_id}/restore` | Brings back a deleted record, and screens it again. | | [`screen_business_record`](/reference/kyb/records/screen-business-record) | `POST /v1/businesses/{id}/{collection}/{object_id}/screen` | Screens a record again, for `kinds` or for each kind it can have now, such as `sanctions` for a person or `address` for an address. | # create_business_record (/reference/kyb/records/create-business-record) ## POST https://api.finic.ai/v1/businesses/{id}/{collection} Adds a record to a business: a person, a corporate owner, a registration, an address, or one of the records screenings and enrichment keep (liens, court cases, bankruptcies, reviews, websites). The record's fields are at the top level, beside `external_id`, `metadata`, `occurred_at` and `source_url`. A record with the same `external_id`, or the same identifying fields, replaces the one there (`200`). | `collection` | Fields (* required) | | --- | --- | | `people` | `first_name` or `last_name`*, `middle_name`, `name_suffix`, `title`, `roles`* (`shareholder`, `beneficial_owner`, `control_person`, `director`, `officer`, `signatory`), `percentage`, `date_of_birth`, `country`, `email`, `phone` | | `corporate_owners` | `legal_name`*, `percentage`, `jurisdiction`, `linked_business_id` | | `registrations` | `kind`* (`formation`, `foreign_qualification`, `tax_id`, `license`, `other`), `jurisdiction`*, `number`, `name`, `status`, `issued_on`, `expires_on` | | `addresses` | `kind`* (`registered`, `operating`, `mailing`, `other`), `line1`*, `country`*, `line2`, `city`, `state`, `postal_code` | | `liens` | `kind`* (`ucc`, `tax`, `judgment`, `mechanics`, `other`), `jurisdiction`*, `filing_number`, `debtors`, `secured_parties`, `status`, `amount`, `currency`, `collateral`, `filed_on`, `lapses_on` | | `court_cases` | `court`*, `number`, `caption`, `kind`, `status` (`open`, `closed`, `unknown`), `status_text`, `role`, `filed_on`, `parties` | | `bankruptcies` | `court`*, `number`, `title`, `chapter`, `debtor`, `status` (`open`, `discharged`, `dismissed`, `closed`), `disposition`, `filed_on`, `closed_on`, `discharged_on`, `dismissed_on`, `reopened_on` | | `reviews` | `site`*, `url`, `rating`, `rating_max`, `review_count`, `title`, `text` | | `websites` | `url`*, `reached`*, `final_url`, `status`, `error`, `title`, `description`, `text`, `fetched_at`, `pages`, `domain` | `jurisdiction` is `{country, state?}`: an ISO 3166-1 alpha-2 country, and the ISO 3166-2 subdivision code without the country. The shareholders' and corporate owners' percentages of a business add up to at most 100. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `id` | string | | `obj_…` | | `business_id` | string | | | | `external_id` | string or null | | | | `metadata` | object | | | | `occurred_at` | string or null | | | | `source_url` | string or null | | | | `source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `created_at` | string | | | | `updated_at` | string | | | | `screenings..id` | string | | | | `screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `screenings..reason` | string or null | | | Example: ```json { "first_name": "Ada", "last_name": "Lovelace", "title": "CFO", "roles": [ "officer", "signatory" ], "country": "US", "email": "ada@example.com" } ``` ### Responses - **200**: The record, replacing one that was there. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `obj_…` | | `business_id` | string | | | | `external_id` | string or null | | | | `metadata` | object | | | | `occurred_at` | string or null | | | | `source_url` | string or null | | | | `source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `created_at` | string | | | | `updated_at` | string | | | | `screenings..id` | string | | | | `screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `screenings..reason` | string or null | | | - **201**: The record. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `obj_…` | | `business_id` | string | | | | `external_id` | string or null | | | | `metadata` | object | | | | `occurred_at` | string or null | | | | `source_url` | string or null | | | | `source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `created_at` | string | | | | `updated_at` | string | | | | `screenings..id` | string | | | | `screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `screenings..reason` | string or null | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **409**: `object_exists`: a record of the business has the same identifying fields and another `external_id`. The error has its `object_id`. # list_business_records (/reference/kyb/records/list-business-records) ## GET https://api.finic.ai/v1/businesses/{id}/{collection} Lists a business's records of one collection, newest first. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `external_id`: - Query parameter `limit`: - Query parameter `after`: The last record's `id` on the page before, for the next page. ### Responses - **200**: A page of records. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `obj_…` | | `data[].business_id` | string | | | | `data[].external_id` | string or null | | | | `data[].metadata` | object | | | | `data[].occurred_at` | string or null | | | | `data[].source_url` | string or null | | | | `data[].source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `data[].screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `data[].created_at` | string | | | | `data[].updated_at` | string | | | | `data[].screenings..id` | string | | | | `data[].screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `data[].screenings..reason` | string or null | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # get_business_record (/reference/kyb/records/get-business-record) ## GET https://api.finic.ai/v1/businesses/{id}/{collection}/{object_id} Gets one of a business's records. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The record. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `obj_…` | | `business_id` | string | | | | `external_id` | string or null | | | | `metadata` | object | | | | `occurred_at` | string or null | | | | `source_url` | string or null | | | | `source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `created_at` | string | | | | `updated_at` | string | | | | `screenings..id` | string | | | | `screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `screenings..reason` | string or null | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # update_business_record (/reference/kyb/records/update-business-record) ## PATCH https://api.finic.ai/v1/businesses/{id}/{collection}/{object_id} Changes the fields sent; `null` removes a field. Changing a screened field, such as a person's name, screens the record again. A record Finic kept becomes yours when you change it, and Finic doesn't replace it again. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `id` | string | | `obj_…` | | `business_id` | string | | | | `external_id` | string or null | | | | `metadata` | object | | | | `occurred_at` | string or null | | | | `source_url` | string or null | | | | `source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `created_at` | string | | | | `updated_at` | string | | | | `screenings..id` | string | | | | `screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `screenings..reason` | string or null | | | Example: ```json { "title": "CEO" } ``` ### Responses - **200**: The record. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `obj_…` | | `business_id` | string | | | | `external_id` | string or null | | | | `metadata` | object | | | | `occurred_at` | string or null | | | | `source_url` | string or null | | | | `source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `created_at` | string | | | | `updated_at` | string | | | | `screenings..id` | string | | | | `screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `screenings..reason` | string or null | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # delete_business_record (/reference/kyb/records/delete-business-record) ## DELETE https://api.finic.ai/v1/businesses/{id}/{collection}/{object_id} Deletes a record and its screenings. You can restore it for 30 days. With `permanent=true` (an admin's key), it's removed at once. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `permanent`: ### Responses - **200**: Deleted. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | | | `deleted` | boolean | | | | `permanent` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: this needs an API key an admin of the organization created. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # restore_business_record (/reference/kyb/records/restore-business-record) ## POST https://api.finic.ai/v1/businesses/{id}/{collection}/{object_id}/restore Brings back a deleted record, and screens it again. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The record. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `obj_…` | | `business_id` | string | | | | `external_id` | string or null | | | | `metadata` | object | | | | `occurred_at` | string or null | | | | `source_url` | string or null | | | | `source` | `customer`, `finic` | | `finic` for a record a screening or enrichment kept. | | `screenings` | object | | Each kind's current screening: `{: {id, state, reason}}`. | | `created_at` | string | | | | `updated_at` | string | | | | `screenings..id` | string | | | | `screenings..state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `screenings..reason` | string or null | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # screen_business_record (/reference/kyb/records/screen-business-record) ## POST https://api.finic.ai/v1/businesses/{id}/{collection}/{object_id}/screen Screens a record again, for `kinds` or for each kind it can have now, such as `sanctions` for a person or `address` for an address. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `kinds` | array of string | | | Example: ```json { "kinds": [ "sanctions" ] } ``` ### Responses - **202**: A screening for each kind. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `scr_…` | | `data[].subject_type` | `business`, `object`, `null` | | | | `data[].subject_id` | string or null | | | | `data[].business_id` | string or null | | | | `data[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `data[].state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `data[].reason` | string or null | | Why it's `pending` or `inconclusive`. | | `data[].input` | object | | What was screened. | | `data[].findings` | array of object | | | | `data[].score` | integer or null | | | | `data[].result` | object | | What else the kind says, such as the sanctions `lists` screened. | | `data[].review_note` | string or null | | | | `data[].reviewed_at` | string or null | | | | `data[].superseded_at` | string or null | | | | `data[].created_at` | string | | | | `data[].completed_at` | string or null | | | | `data[].findings[].id` | string | | | | `data[].findings[].code` | string | | What was found, such as `list_match` or `mail_forwarding`. | | `data[].findings[].severity` | `info`, `low`, `medium`, `high` | | `info` needs no review. | | `data[].findings[].summary` | string | | | | `data[].findings[].details` | object | | | | `data[].findings[].fingerprint` | string | | | | `data[].findings[].decision` | `confirmed`, `false_positive`, `null` | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **503**: `screening_unavailable`: a screening kind asked for isn't available right now. # Screenings (/reference/kyb/screenings) See [Screenings](/kyb/screenings) and [Monitoring](/kyb/monitoring). | Endpoint | Request | What it does | | ------------------------------------------------------------------------ | --------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------- | | [`create_screening`](/reference/kyb/screenings/create-screening) | `POST /v1/screenings` | Screens a record (`subject_type` and `subject_id`), for `kinds` or for each kind it can have now. | | [`list_screenings`](/reference/kyb/screenings/list-screenings) | `GET /v1/screenings` | Lists screenings, newest first. | | [`list_screening_kinds`](/reference/kyb/screenings/list-screening-kinds) | `GET /v1/screenings/kinds` | Lists every screening kind, with its fields, its price and whether it's available to you now. | | [`get_screening`](/reference/kyb/screenings/get-screening) | `GET /v1/screenings/{id}` | Gets a screening, with its findings. | | [`delete_screening`](/reference/kyb/screenings/delete-screening) | `DELETE /v1/screenings/{id}` | Deletes a screening of data sent with a request. | | [`review_screening`](/reference/kyb/screenings/review-screening) | `POST /v1/screenings/{id}/review` | Records a reviewer's decision on a screening's findings: `confirmed` or `false_positive`, for the findings in `finding_ids` or all of them. | # create_screening (/reference/kyb/screenings/create-screening) ## POST https://api.finic.ai/v1/screenings Screens a record (`subject_type` and `subject_id`), for `kinds` or for each kind it can have now. Or screens data sent with the request (`kind` and `input`), which isn't kept as a record: its `subject_id` is `null`. | `kind` | Fields of `input` (* required) | Of | Price | | --- | --- | --- | --- | | `sanctions` | `name`*, `short_name`, `date_of_birth`, `country` | Businesses, people, corporate owners | $0.05 | | `jurisdiction` | `country`*, `line1`, `line2`, `city`, `state`, `postal_code` | Addresses | Free | | `address` | `line1`*, `country`*, `line2`, `city`, `state`, `postal_code` | Addresses | $0.005 | | `website` | `website`*, `name`, `description`, `industry`, `line1`, `line2`, `city`, `state`, `postal_code` | Businesses | $0.10 | [list_screening_kinds](/reference/kyb/screenings) lists every kind, with its price and whether it's available to you now. A screening that costs waits while there's no credit. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | Example: ```json { "subject_type": "object", "subject_id": "obj_01M4Z3R2D8F5G7H9J1K3M5N7PQ", "kinds": [ "sanctions" ] } ``` ### Responses - **202**: A screening for each kind. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `scr_…` | | `data[].subject_type` | `business`, `object`, `null` | | | | `data[].subject_id` | string or null | | | | `data[].business_id` | string or null | | | | `data[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `data[].state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `data[].reason` | string or null | | Why it's `pending` or `inconclusive`. | | `data[].input` | object | | What was screened. | | `data[].findings` | array of object | | | | `data[].score` | integer or null | | | | `data[].result` | object | | What else the kind says, such as the sanctions `lists` screened. | | `data[].review_note` | string or null | | | | `data[].reviewed_at` | string or null | | | | `data[].superseded_at` | string or null | | | | `data[].created_at` | string | | | | `data[].completed_at` | string or null | | | | `data[].findings[].id` | string | | | | `data[].findings[].code` | string | | What was found, such as `list_match` or `mail_forwarding`. | | `data[].findings[].severity` | `info`, `low`, `medium`, `high` | | `info` needs no review. | | `data[].findings[].summary` | string | | | | `data[].findings[].details` | object | | | | `data[].findings[].fingerprint` | string | | | | `data[].findings[].decision` | `confirmed`, `false_positive`, `null` | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. - **503**: `screening_unavailable`: a screening kind asked for isn't available right now. # list_screenings (/reference/kyb/screenings/list-screenings) ## GET https://api.finic.ai/v1/screenings Lists screenings, newest first. Without `history`, only each record's current screening of each kind. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `business_id`: - Query parameter `subject_id`: - Query parameter `kind`: - Query parameter `state`: - Query parameter `history`: `true` includes screenings replaced since. - Query parameter `limit`: - Query parameter `after`: The last record's `id` on the page before, for the next page. ### Responses - **200**: A page of screenings. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `scr_…` | | `data[].subject_type` | `business`, `object`, `null` | | | | `data[].subject_id` | string or null | | | | `data[].business_id` | string or null | | | | `data[].kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `data[].state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `data[].reason` | string or null | | Why it's `pending` or `inconclusive`. | | `data[].input` | object | | What was screened. | | `data[].findings` | array of object | | | | `data[].score` | integer or null | | | | `data[].result` | object | | What else the kind says, such as the sanctions `lists` screened. | | `data[].review_note` | string or null | | | | `data[].reviewed_at` | string or null | | | | `data[].superseded_at` | string or null | | | | `data[].created_at` | string | | | | `data[].completed_at` | string or null | | | | `data[].findings[].id` | string | | | | `data[].findings[].code` | string | | What was found, such as `list_match` or `mail_forwarding`. | | `data[].findings[].severity` | `info`, `low`, `medium`, `high` | | `info` needs no review. | | `data[].findings[].summary` | string | | | | `data[].findings[].details` | object | | | | `data[].findings[].fingerprint` | string | | | | `data[].findings[].decision` | `confirmed`, `false_positive`, `null` | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. # list_screening_kinds (/reference/kyb/screenings/list-screening-kinds) ## GET https://api.finic.ai/v1/screenings/kinds Lists every screening kind, with its fields, its price and whether it's available to you now. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The kinds. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].kind` | string | | | | `data[].name` | string | | | | `data[].price_micros` | integer | | The price of a screening, in millionths of a dollar: 50000 is $0.05. | | `data[].required` | array of string | | | | `data[].optional` | array of string | | | | `data[].available` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. # get_screening (/reference/kyb/screenings/get-screening) ## GET https://api.finic.ai/v1/screenings/{id} Gets a screening, with its findings. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The screening. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `scr_…` | | `subject_type` | `business`, `object`, `null` | | | | `subject_id` | string or null | | | | `business_id` | string or null | | | | `kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `reason` | string or null | | Why it's `pending` or `inconclusive`. | | `input` | object | | What was screened. | | `findings` | array of object | | | | `score` | integer or null | | | | `result` | object | | What else the kind says, such as the sanctions `lists` screened. | | `review_note` | string or null | | | | `reviewed_at` | string or null | | | | `superseded_at` | string or null | | | | `created_at` | string | | | | `completed_at` | string or null | | | | `findings[].id` | string | | | | `findings[].code` | string | | What was found, such as `list_match` or `mail_forwarding`. | | `findings[].severity` | `info`, `low`, `medium`, `high` | | `info` needs no review. | | `findings[].summary` | string | | | | `findings[].details` | object | | | | `findings[].fingerprint` | string | | | | `findings[].decision` | `confirmed`, `false_positive`, `null` | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # delete_screening (/reference/kyb/screenings/delete-screening) ## DELETE https://api.finic.ai/v1/screenings/{id} Deletes a screening of data sent with a request. A record's screenings are deleted with the record. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: Deleted. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | | | `deleted` | boolean | | | | `permanent` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # review_screening (/reference/kyb/screenings/review-screening) ## POST https://api.finic.ai/v1/screenings/{id}/review Records a reviewer's decision on a screening's findings: `confirmed` or `false_positive`, for the findings in `finding_ids` or all of them. The screening's state follows: `confirmed` when a finding is confirmed, `false_positive` when every finding is dismissed. A decision carries to a later screening of the same record and kind while the input and the finding are unchanged. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `decision` | `confirmed`, `false_positive` | yes | | | `finding_ids` | array of string | | | | `note` | string | | | Example: ```json { "decision": "false_positive", "note": "Different date of birth and country." } ``` ### Responses - **200**: The screening. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `scr_…` | | `subject_type` | `business`, `object`, `null` | | | | `subject_id` | string or null | | | | `business_id` | string or null | | | | `kind` | string | | A screening kind, such as `sanctions`, `jurisdiction`, `address` or `website`. See [list_screening_kinds](/reference/kyb/screenings). | | `state` | `pending`, `clear`, `needs_review`, `confirmed`, `false_positive`, `inconclusive` | | `pending`: not screened yet. `clear`: the check was made and found nothing to review. `needs_review`: a finding is undecided. `confirmed`: a reviewer confirmed a finding. `false_positive`: every finding was dismissed. `inconclusive`: the check couldn't be made (`reason` says why). A check that isn't made is never `clear`. | | `reason` | string or null | | Why it's `pending` or `inconclusive`. | | `input` | object | | What was screened. | | `findings` | array of object | | | | `score` | integer or null | | | | `result` | object | | What else the kind says, such as the sanctions `lists` screened. | | `review_note` | string or null | | | | `reviewed_at` | string or null | | | | `superseded_at` | string or null | | | | `created_at` | string | | | | `completed_at` | string or null | | | | `findings[].id` | string | | | | `findings[].code` | string | | What was found, such as `list_match` or `mail_forwarding`. | | `findings[].severity` | `info`, `low`, `medium`, `high` | | `info` needs no review. | | `findings[].summary` | string | | | | `findings[].details` | object | | | | `findings[].fingerprint` | string | | | | `findings[].decision` | `confirmed`, `false_positive`, `null` | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # Webhooks (/reference/webhooks) See [Webhooks](/webhooks) and [Events](/webhooks/events). | Endpoint | Request | What it does | | -------------------------------------------------------------------------- | ----------------------------------------------- | ------------------------------------------------------------------------- | | [`create_webhook_endpoint`](/reference/webhooks/create-webhook-endpoint) | `POST /v1/webhook_endpoints` | Adds an address to send events to (an admin's key). | | [`list_webhook_endpoints`](/reference/webhooks/list-webhook-endpoints) | `GET /v1/webhook_endpoints` | Lists your webhook endpoints, newest first. | | [`get_webhook_endpoint`](/reference/webhooks/get-webhook-endpoint) | `GET /v1/webhook_endpoints/{id}` | Gets a webhook endpoint. | | [`update_webhook_endpoint`](/reference/webhooks/update-webhook-endpoint) | `PATCH /v1/webhook_endpoints/{id}` | Changes the fields sent (an admin's key). | | [`delete_webhook_endpoint`](/reference/webhooks/delete-webhook-endpoint) | `DELETE /v1/webhook_endpoints/{id}` | Deletes a webhook endpoint (an admin's key). | | [`rotate_webhook_secret`](/reference/webhooks/rotate-webhook-secret) | `POST /v1/webhook_endpoints/{id}/rotate_secret` | Makes a new signing secret (an admin's key), shown only in this response. | | [`test_webhook_endpoint`](/reference/webhooks/test-webhook-endpoint) | `POST /v1/webhook_endpoints/{id}/test` | Sends a test event to the endpoint (an admin's key). | | [`list_webhook_deliveries`](/reference/webhooks/list-webhook-deliveries) | `GET /v1/webhook_deliveries` | Lists deliveries, newest first. | | [`get_webhook_delivery`](/reference/webhooks/get-webhook-delivery) | `GET /v1/webhook_deliveries/{id}` | Gets a delivery, with the event it sends. | | [`retry_webhook_delivery`](/reference/webhooks/retry-webhook-delivery) | `POST /v1/webhook_deliveries/{id}/retry` | Sends a delivery again, from its first attempt. | | [`list_webhook_event_types`](/reference/webhooks/list-webhook-event-types) | `GET /v1/webhook_event_types` | Lists the event types an endpoint can get. | # create_webhook_endpoint (/reference/webhooks/create-webhook-endpoint) ## POST https://api.finic.ai/v1/webhook_endpoints Adds an address to send events to (an admin's key). `url` is public and `https`. `event_types` lists types, groups (`screening.*`) or `*`. The response has the signing `secret`, shown only this once. An organization has at most 20 endpoints. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `url` | string | yes | | | `event_types` | array of string | yes | | | `description` | string | | | Example: ```json { "url": "https://example.com/webhooks/finic", "event_types": [ "screening.*", "verification.completed", "business.status_changed" ] } ``` ### Responses - **201**: The endpoint, with its secret. - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: this needs an API key an admin of the organization created. # list_webhook_endpoints (/reference/webhooks/list-webhook-endpoints) ## GET https://api.finic.ai/v1/webhook_endpoints Lists your webhook endpoints, newest first. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `limit`: - Query parameter `after`: The last record's `id` on the page before, for the next page. ### Responses - **200**: A page of endpoints. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `whe_…` | | `data[].url` | string | | | | `data[].description` | string | | | | `data[].event_types` | array of string | | | | `data[].status` | `enabled`, `disabled` | | | | `data[].disabled_reason` | string | | Why it was disabled. | | `data[].failing_since` | string or null | | | | `data[].created_at` | string | | | | `data[].updated_at` | string | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. # get_webhook_endpoint (/reference/webhooks/get-webhook-endpoint) ## GET https://api.finic.ai/v1/webhook_endpoints/{id} Gets a webhook endpoint. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The endpoint. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `whe_…` | | `url` | string | | | | `description` | string | | | | `event_types` | array of string | | | | `status` | `enabled`, `disabled` | | | | `disabled_reason` | string | | Why it was disabled. | | `failing_since` | string or null | | | | `created_at` | string | | | | `updated_at` | string | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # update_webhook_endpoint (/reference/webhooks/update-webhook-endpoint) ## PATCH https://api.finic.ai/v1/webhook_endpoints/{id} Changes the fields sent (an admin's key). Set `status` to `enabled` to turn a disabled endpoint on again. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `url` | string | | | | `event_types` | array of string | | | | `description` | string | | | | `status` | `enabled`, `disabled` | | | Example: ```json { "event_types": [ "*" ] } ``` ### Responses - **200**: The endpoint. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `whe_…` | | `url` | string | | | | `description` | string | | | | `event_types` | array of string | | | | `status` | `enabled`, `disabled` | | | | `disabled_reason` | string | | Why it was disabled. | | `failing_since` | string or null | | | | `created_at` | string | | | | `updated_at` | string | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: this needs an API key an admin of the organization created. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # delete_webhook_endpoint (/reference/webhooks/delete-webhook-endpoint) ## DELETE https://api.finic.ai/v1/webhook_endpoints/{id} Deletes a webhook endpoint (an admin's key). What it has yet to get is cancelled. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: Deleted. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | | | `deleted` | boolean | | | | `permanent` | boolean | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: this needs an API key an admin of the organization created. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # rotate_webhook_secret (/reference/webhooks/rotate-webhook-secret) ## POST https://api.finic.ai/v1/webhook_endpoints/{id}/rotate_secret Makes a new signing secret (an admin's key), shown only in this response. For 24 hours, deliveries are signed with the old secret too. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The endpoint, with its new secret. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: this needs an API key an admin of the organization created. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # test_webhook_endpoint (/reference/webhooks/test-webhook-endpoint) ## POST https://api.finic.ai/v1/webhook_endpoints/{id}/test Sends a test event to the endpoint (an admin's key). Find its delivery with `event_id` in [list_webhook_deliveries](/reference/webhooks). Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **202**: The test event; its delivery is under way. | Field | Type | Always | Description | | --- | --- | --- | --- | | `event_id` | string | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **403**: `permission_denied`: this needs an API key an admin of the organization created. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # list_webhook_deliveries (/reference/webhooks/list-webhook-deliveries) ## GET https://api.finic.ai/v1/webhook_deliveries Lists deliveries, newest first. Finished deliveries are kept for 30 days. Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `endpoint_id`: - Query parameter `event_id`: - Query parameter `status`: - Query parameter `limit`: - Query parameter `after`: The last record's `id` on the page before, for the next page. ### Responses - **200**: A page of deliveries. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `whd_…` | | `data[].endpoint_id` | string | | | | `data[].event_id` | string | | | | `data[].event_type` | string | | | | `data[].status` | `pending`, `succeeded`, `failed`, `cancelled` | | | | `data[].attempts` | integer | | | | `data[].response_status` | integer or null | | The HTTP status your endpoint answered with. | | `data[].error` | string | | | | `data[].next_attempt_at` | string or null | | | | `data[].created_at` | string | | | | `data[].attempted_at` | string or null | | | | `data[].finished_at` | string or null | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. # get_webhook_delivery (/reference/webhooks/get-webhook-delivery) ## GET https://api.finic.ai/v1/webhook_deliveries/{id} Gets a delivery, with the event it sends. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The delivery. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `whd_…` | | `endpoint_id` | string | | | | `event_id` | string | | | | `event_type` | string | | | | `status` | `pending`, `succeeded`, `failed`, `cancelled` | | | | `attempts` | integer | | | | `response_status` | integer or null | | The HTTP status your endpoint answered with. | | `error` | string | | | | `next_attempt_at` | string or null | | | | `created_at` | string | | | | `attempted_at` | string or null | | | | `finished_at` | string or null | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # retry_webhook_delivery (/reference/webhooks/retry-webhook-delivery) ## POST https://api.finic.ai/v1/webhook_deliveries/{id}/retry Sends a delivery again, from its first attempt. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **202**: The delivery. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | `whd_…` | | `endpoint_id` | string | | | | `event_id` | string | | | | `event_type` | string | | | | `status` | `pending`, `succeeded`, `failed`, `cancelled` | | | | `attempts` | integer | | | | `response_status` | integer or null | | The HTTP status your endpoint answered with. | | `error` | string | | | | `next_attempt_at` | string or null | | | | `created_at` | string | | | | `attempted_at` | string or null | | | | `finished_at` | string or null | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. - **404**: `_not_found`, such as `business_not_found`: no such record in your organization. # list_webhook_event_types (/reference/webhooks/list-webhook-event-types) ## GET https://api.finic.ai/v1/webhook_event_types Lists the event types an endpoint can get. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Responses - **200**: The event types. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of string | | | | `has_more` | boolean | | | ```json { "data": [ "business.created", "business.updated", "business.status_changed", "screening.completed", "screening.review_needed", "verification.completed" ], "has_more": false } ``` - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. # Events (/reference/webhooks/events) See [Events](/webhooks/events). | Endpoint | Request | What it does | | ----------------------------------------------------------- | ----------------- | ------------------------------------------------------------------------------------------------------------ | | [`list_kyb_events`](/reference/webhooks/events/list-events) | `GET /v1/events` | Lists what happened to your business records, screenings, verifications and webhook endpoints, oldest first. | | [`create_event`](/reference/webhooks/events/create-event) | `POST /v1/events` | Records an event of your own, such as a manual review. | # list_kyb_events (/reference/webhooks/events/list-events) ## GET https://api.finic.ai/v1/events Lists what happened to your business records, screenings, verifications and webhook endpoints, oldest first. `seq` counts up without gaps, so a reader that keeps the last `seq` and sends it as `after` misses nothing. Events hold ids, states, outcomes, scores, codes and the names of changed fields, never the values sent or found (except `custom.*` events' `data`). Authorization: `Bearer ` (see [Authentication](/authentication)). - Query parameter `business_id`: - Query parameter `subject_id`: - Query parameter `type`: An event type, such as `screening.completed`. - Query parameter `limit`: - Query parameter `after`: The last event's `seq`. ### Responses - **200**: A page of events. | Field | Type | Always | Description | | --- | --- | --- | --- | | `data` | array of object | | | | `has_more` | boolean | | | | `data[].id` | string | | `evt_…` | | `data[].seq` | integer | | Counts up from 1 for your organization, without gaps. | | `data[].type` | string | | Such as `screening.completed`. See [list_webhook_event_types](/reference/webhooks). | | `data[].subject_type` | string | | | | `data[].subject_id` | string | | | | `data[].business_id` | string or null | | | | `data[].actor_type` | `api_key`, `user`, `finic` | | | | `data[].actor_id` | string | | | | `data[].data` | object | | | | `data[].created_at` | string | | | - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. # create_event (/reference/webhooks/events/create-event) ## POST https://api.finic.ai/v1/events Records an event of your own, such as a manual review. Its type starts with `custom.`; it's sent to webhooks like Finic's. Authorization: `Bearer ` (see [Authentication](/authentication)). ### Request body (application/json) | Field | Type | Required | Description | | --- | --- | --- | --- | | `type` | string | yes | `custom.` and your own name, in lower-case letters, digits, `_` and dots, such as `custom.contract_signed`. | | `business_id` | string | | | | `data` | object | | | Example: ```json { "type": "custom.call_completed", "business_id": "biz_01M4Z3Q8T6V2K9XR5HN7D1BCWE", "data": { "outcome": "owner_confirmed" } } ``` ### Responses - **201**: The event. | Field | Type | Always | Description | | --- | --- | --- | --- | | `id` | string | | | | `type` | string | | | | `business_id` | string or null | | | - **400**: `invalid_request`: the request breaks a rule of the endpoint. `param` names the field at fault. - **401**: `authentication_error`: the API key is missing, unknown, revoked or expired. # MCP reference (/mcp) Finic's MCP server is `https://api.finic.ai/mcp` (Streamable HTTP). To add it to Claude, ChatGPT, Cursor or another client, see the [Agent quickstart](/agent-quickstart). | Server | Sign-in | For | | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------- | | `https://api.finic.ai/mcp` | OAuth: the user signs in or creates an account in their browser, and the client keeps the token. An API key in the `Authorization` header works too | Every client that supports sign-in | | `https://api.finic.ai/mcp/keys` | The user approves an API key from a link, and the agent receives it ([`sign_up`](/mcp/sign-up)) | Clients that can't sign in | ## Tools [#tools] | Tool | What it does | | ----------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | | [`get_quickstart_skill`](/mcp/get-quickstart-skill) | Returns a skill for setting Finic up with the user, testing it on their data and going live. Call it first | | [`score`](/mcp/score) | Scores one record from 0 to 1000 | | [`list_events`, `get_event`](/mcp/events) | Read back the records that were scored | | [`create_model`](/mcp/create-scoring-model) | Creates a scoring model from its criteria or from labeled records | | [`list_models`](/mcp/list-scoring-models) | Lists the organization's scoring models and Finic's pre-made models | | [`get_model`](/mcp/get-scoring-model) | One scoring model, with its questions and their weights | | [`add_questions`](/mcp/add-questions) | Adds the user's own questions to a scoring model | | [`set_question_weight`](/mcp/set-question-weight) | Sets a question's weight in a scoring model | | [`remove_question`](/mcp/remove-question) | Removes a question from a scoring model | | [`calibrate`](/mcp/calibrate) | Sends labeled records, to fit a scoring model to the user's data and change its questions | | [`update_model`](/mcp/update-scoring-model) | Renames a scoring model, changes its criteria, or archives or unarchives it | | [`delete_model`](/mcp/delete-scoring-model) | Deletes a scoring model (admins only) | | [`get_job_status`](/mcp/get-job-status) | Whether creating or calibrating a scoring model has finished | | [`create_site`, `list_sites`, `update_site`, `delete_site`](/mcp/sites) | Set Identify up for a website: a site, its public key and its script tag | | [`list_sessions`, `get_session`, `update_session`](/mcp/sessions) | Read who each visitor is, and link a session to one of the user's customers | | [`get_visitor`, `delete_visitor`](/mcp/visitors) | One returning browser, or forget it | | [`lookup`, `list_lookup_sources`](/mcp/lookup) | Check one HTTP request for a declared AI agent, with no snippet | | [`ask`](/mcp/ask) | Answers questions about a case. Works with no setup | | [`get_account`](/mcp/get-account) | The organization, its credit and the prices | | [`get_data_retention`, `set_data_retention`](/mcp/data-retention) | Read, or set, the user's own data retention | | [`sign_up`, `get_api_key`](/mcp/sign-up) | Only on `/mcp/keys`: get an API key from the user | Each tool goes through the same API as its endpoint, with the same rules, [limits](/reference#limits), credit and data retention, and its calls appear under Usage in the Finic app. On `/mcp/keys`, every tool also takes an optional `api_key` argument. The scoring model tools were `create_scoring_model`, `list_scoring_models`, `get_scoring_model`, `update_scoring_model` and `delete_scoring_model` before, and `ask` was `decide`. MCP clients pick up the new names when they reconnect; calls to the earlier `_scoring_model` names still work. ## Errors [#errors] A failed call comes back as a tool error with the API's error type, message and field, for example `invalid_request: A choice's base_rate shares must add up to 1. (questions.claim_type.base_rate)`. The types are under [Errors](/reference#errors). An `authentication_error` on `/mcp/keys` adds a hint to call `sign_up`, and `insufficient_credit` adds where an admin adds credit. # get_quickstart_skill (/mcp/get-quickstart-skill) No arguments. On `/mcp` and `/mcp/keys`. Returns a skill: the Markdown of a `SKILL.md` with frontmatter `name: finic-quickstart`. Agents should call it before anything else, follow it, and can save it as a skill for later. It covers: * **Access:** signing in, or getting an API key, and setting up the account. * **Questions for the user:** 1. Do you want to be able to view your past requests, or turn on Zero Data Retention? (See [Data retention](/grayson-api/data#data-retention).) 2. Do you already have data to test Finic with? It needs a good or bad label for each record. The agent may reshape it into Finic's format, and cleans and standardizes it before sending. 3. What do you want to test: the use case, what counts as good and bad, and what you're trying to detect? * **Preparing data** in Finic's format ([Labeled records](/score-model#labeled-records)). * **Testing accuracy on the user's data:** hold out some labeled rows, create a scoring model from the rest, score the held-out rows, and measure AUC, precision and recall at chosen thresholds, and calibration. For questions, run `ask` with a `base_rate` on labeled cases and measure the same. * **Going live:** API keys, thresholds and calibrating again with fresh labeled records. # score (/mcp/score) Scores one record, as [`POST /v1/score`](/reference/score/score). | Input | Description | | ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------ | | `model_id` | Required. A scoring model's, from `create_model` once its job is complete, or a pre-made model's, from [`list_models`](/mcp/list-scoring-models) | | `score_id` | Required with a scoring model you created. Your unique id for this record's score, such as the payment's id | | `data` | Required. One record: a JSON object, or CSV text with a header and one row | | `skip_schema_validation` | Optional. Score it even if its fields differ from the scoring model's schema | | `update_schema` | Optional. Make this record's fields the expected shape from now on | | `include_questions` | Optional. Also return the questions the score used, each with Grayson's probability of yes for this record and its weight | | `api_key` | `/mcp/keys` only | Returns `model_id`, `score_id`, `score` (0 to 1000: once the scoring model is calibrated, 250 is about a 25% chance of a bad outcome; before then, scores rank records but their scale is an estimate), `request_id` and, with `include_questions`, `questions`: each one's `id`, `text`, `probability` and `weight`, strongest first. See [Questions and weights](/score-model#questions-and-weights). **A scoring model needs questions to score.** One created from criteria alone has none until the user adds their own with [`add_questions`](/mcp/add-questions) or you [`calibrate`](/mcp/calibrate) it; until then, `score` gets `no_questions`. **The record must match the scoring model's schema,** from the labeled records it was created or calibrated with: the same fields, names and types. A scoring model created from criteria alone takes any record until it's calibrated. A record that differs gets `schema_mismatch`, listing the differences. Fix the record, or set `skip_schema_validation` for a one-off, or `update_schema` for a lasting change. See [Schema](/score-model#schema). **A pre-made model needs no setup.** `data` is a JSON object with the model's `fields`. It returns the `score` with each question's `probability`, and costs the model's `price_usd`. Every score is an event, read back with [`list_events` and `get_event`](/mcp/events). # list_events, get_event (/mcp/events) An event is one record that was scored, with a scoring model or a pre-made one, through the API, these tools or the Finic app. Both tools are read-only and free. ## list\_events [#list_events] Lists the organization's events, newest first, as [`GET /v1/score/events`](/reference/score/list-events). | Input | Description | | --------- | ----------------------------------------------- | | `model` | A model's `model_id`, for only its events | | `limit` | 1 to 100; 50 by default | | `before` | An event's `id`: lists the events older than it | | `api_key` | `/mcp/keys` only | Returns `events` and `has_more`. Each event has `id`, `created_at`, `model_id`, `model_name`, `premade`, `score` (`null` for a call that failed, with `error_type` saying why), `latency_ms`, `cost_usd` and `stored`. ## get\_event [#get_event] Shows one event, as [`GET /v1/score/events/{id}`](/reference/score/get-event). | Input | Description | | ---------- | ------------------------------------------------------------------------------------ | | `event_id` | Required. The event's `id`: from `list_events`, or the `request_id` a score returned | | `api_key` | `/mcp/keys` only | Returns the event with `input` (the record that was scored), `questions` (each one's `text` and `probability`) and `error`. `input` and `questions` are `null` once the organization's [data retention](/grayson-api/data#data-retention) no longer keeps them. # create_model (/mcp/create-scoring-model) Creates a scoring model, as [`POST /v1/score/models`](/reference/score/create-scoring-model). Up to 100 per organization per day. | Input | Description | | --------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `name` | Required. A few words the user will recognize it by | | `criteria` | What the decision is and what `is_bad` means, in the user's words. Required without `data`; with it, optional context | | `data` | Optional. Labeled records: a JSON array of objects, or CSV text with a header row, each row with `is_bad` | | `add_questions` | Optional. The user's own yes/no questions about a record: up to 20, 500 characters each. With `data`, they're used alongside Finic's, and the ones that don't help aren't used; without it, they're its only questions until it's calibrated | | `api_key` | `/mcp/keys` only, if the client doesn't send the key as a header | Returns `model_id` and `request_id`, and with `data` a `job_id`: poll [`get_job_status`](/mcp/get-job-status) until it's complete. Then call [`score`](/mcp/score) with the `model_id`. [`get_model`](/mcp/get-scoring-model) shows the questions it uses. * **From criteria alone:** ready at once, with no questions. Add the user's own with [`add_questions`](/mcp/add-questions), each weighed by Finic's estimate, to score any record right away; or [`calibrate`](/mcp/calibrate) it with labeled records, which has Finic write its questions and fit them to the user's data. Scoring it with no questions gets `no_questions`. * **From labeled records:** calibrated from the start, so more accurate. It takes about two minutes. ## Before calling it with data [#before-calling-it-with-data] Ask the user whether to use **data they already have** or have you **generate sample data**. A scoring model built on generated data is only for trying Finic out: it isn't calibrated to the company's real fraud distribution. Good labeled records are: * **JSON records about customer identity or events:** sign-ups, logins, payments, transactions. * **One row per past decision,** with its real outcome as `is_bad` (`true` when bad). * **Only fields known at the time of the decision:** no later chargebacks, fraud flags or verdicts. * **Consistent:** the same field names and types in every row, in words, with units. * **Enough:** 100+ rows with 20+ of each outcome, under 2 MB. Up to 2,000 rows are used. The records you'll score later must have the same shape. See [Labeled records](/score-model#labeled-records). # list_models (/mcp/list-scoring-models) Lists the organization's scoring models, newest first, and Finic's pre-made models, as [`GET /v1/score/models`](/reference/score/list-scoring-models). Read-only. | Input | Description | | --------- | ---------------- | | `api_key` | `/mcp/keys` only | Returns `models`, each with its `model_id`, `name`, `status` (`training`, `ready` or `failed`), `criteria` (the context it was built with, or empty), `created_at`, `calibrated_at` (or `null` if it isn't calibrated: one created from criteria alone has only the user's questions, weighed by Finic's estimates, until it's calibrated), `archived_at` (or `null`; an archived scoring model can't be used until it's unarchived with [`update_model`](/mcp/update-scoring-model)), `examples` and `bad_rate` (the labeled records of its latest calibration, or 0) and `scored` (records scored with it). Check it before [`create_model`](/mcp/create-scoring-model): the user may already have the scoring model they need. For one scoring model's questions, call [`get_model`](/mcp/get-scoring-model). It also returns `premade_models`: Finic's own, ready to [`score`](/mcp/score) with. Each has its `model_id`, `name`, `summary`, `price_usd`, `fields` (what a record should hold) and `questions`. # get_model (/mcp/get-scoring-model) Shows one scoring model, as [`GET /v1/score/models/{model_id}`](/reference/score/get-scoring-model). Read-only. | Input | Description | | ---------- | ---------------------------------------- | | `model_id` | Required. The scoring model's `model_id` | | `api_key` | `/mcp/keys` only | Returns the fields [`list_models`](/mcp/list-scoring-models) gives, and `questions`: the ones the scoring model uses, strongest first. Each has: * **`id`,** such as `q007`, to remove it with [`remove_question`](/mcp/remove-question) or [`calibrate`](/mcp/calibrate). * **`text`,** the question Grayson is asked about each record. * **`source`:** `finic` for a question Finic wrote, `user` for one the user added. * **`weight`:** how much it moves the score, as of the latest calibration, or Finic's estimate if `calibrated_at` is `null` (then all its questions are the user's). Positive when a likely yes raises the score, negative when it lowers it; the larger, the more it counts. The user's own questions it doesn't use are listed on its page in the Finic app. See [Questions and weights](/score-model#questions-and-weights). # add_questions (/mcp/add-questions) Adds the user's own questions to a scoring model, as [`POST /v1/score/models/{model_id}/questions`](/reference/score/add-questions). Free. | Input | Description | | ----------- | ----------------------------------------------------------------------------------------------------------------------- | | `model_id` | Required. The scoring model | | `questions` | Required. The user's own yes/no questions about a record: up to 20 at a time, 50 per scoring model, 500 characters each | | `api_key` | `/mcp/keys` only | Returns the scoring model as [`get_model`](/mcp/get-scoring-model) does, plus `added`: each new question's `id`, `text` and `used`, whether the score uses it yet. * **Before the scoring model is calibrated,** the score uses them right away, each with a weight Finic estimates. Until its first calibration, they're its only questions. * **After,** they're asked on every [`score`](/mcp/score) call and tried at the next [`calibrate`](/mcp/calibrate), which keeps the ones that help. Until then they're listed as not used on its page in the Finic app. See [Changing questions](/score-model#changing-questions). # set_question_weight (/mcp/set-question-weight) Sets a question's weight in a scoring model, as [`PATCH /v1/score/models/{model_id}/questions/{question_id}`](/reference/score/set-question-weight). Free. | Input | Description | | ------------- | ------------------------------------------------------------------------- | | `model_id` | Required. The scoring model | | `question_id` | Required. The question's `id`, from [`get_model`](/mcp/get-scoring-model) | | `weight` | Required. A number from -10 to 10 | | `api_key` | `/mcp/keys` only | Returns the scoring model as [`get_model`](/mcp/get-scoring-model) does. A weight is how far a likely yes moves the score: positive raises it, negative lowers it, `0` leaves the answer out. The one you set replaces the weight a calibration fitted or Finic estimated, and the score changes at once. The next [`calibrate`](/mcp/calibrate) fits every weight again. See [Weights](/score-model#weights). # remove_question (/mcp/remove-question) Removes a question from a scoring model, as [`DELETE /v1/score/models/{model_id}/questions/{question_id}`](/reference/score/remove-question). Free. | Input | Description | | ------------- | ------------------------------------------------------------------------- | | `model_id` | Required. The scoring model | | `question_id` | Required. The question's `id`, from [`get_model`](/mcp/get-scoring-model) | | `api_key` | `/mcp/keys` only | Returns the scoring model as [`get_model`](/mcp/get-scoring-model) does. A removed question isn't asked or tried again. * **Before the scoring model is calibrated,** any question can be removed. With none left, it can't score until the user adds one or you calibrate it. * **After,** a question the score uses is removed with `remove_questions` in [`calibrate`](/mcp/calibrate) instead, so the score is refit without it: removing it here gets `question_in_use`. The user's questions it doesn't use can be removed here. See [Changing questions](/score-model#changing-questions). # update_model (/mcp/update-scoring-model) Changes a scoring model, as [`PATCH /v1/score/models/{model_id}`](/reference/score/update-scoring-model). Free. | Input | Description | | ---------- | --------------------------------------------------------------------------------------------------------------------------------- | | `model_id` | Required. The scoring model | | `name` | Optional. A new name: a few words the user will recognize it by | | `criteria` | Optional. New criteria: what the decision is and what `is_bad` means. It can be emptied only once the scoring model is calibrated | | `archived` | Optional. `true` to archive it, `false` to unarchive it | | `api_key` | `/mcp/keys` only | Send at least one of `name`, `criteria` and `archived`. Returns the scoring model as [`get_model`](/mcp/get-scoring-model) does. * **Criteria** is what Finic writes the scoring model's questions with at its first calibration, and weighs the user's questions by until then. Changing it doesn't change the questions it has. * **An archived scoring model** can't [`score`](/mcp/score) or be [calibrated](/mcp/calibrate), which get `scoring_model_archived`, until it's unarchived. Nothing about it is deleted. # delete_model (/mcp/delete-scoring-model) Deletes a scoring model, as [`DELETE /v1/score/models/{model_id}`](/reference/score/delete-scoring-model). | Input | Description | | ---------- | --------------------------- | | `model_id` | Required. The scoring model | | `api_key` | `/mcp/keys` only | Returns `model_id` and `deleted: true`. Calls to it get `scoring_model_not_found` from then on. * **It can't be undone.** Confirm with the user first. If they only want to stop using it, archive it instead with [`update_model`](/mcp/update-scoring-model) and `archived: true`. * **Only an admin of the organization** can delete a scoring model: with someone else's key or sign-in, it gets `permission_denied`. # calibrate (/mcp/calibrate) Calibrates a scoring model, as [`POST /v1/calibrate`](/reference/score/calibrate). Up to 10 per scoring model per day. | Input | Description | | ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `model_id` | Required. The scoring model | | `data` | Required. Labeled records with the same fields as the ones it scores, each with `is_bad` (`true` when the outcome was bad), as a JSON array or CSV text: 100+ rows with 20+ of each outcome, up to 2,000 used, under 2 MB | | `add_questions` | Optional. The user's own yes/no questions to try: up to 20, 500 characters each. [`add_questions`](/mcp/add-questions) the tool adds them without calibrating | | `remove_questions` | Optional. The ids of questions to stop using, from [`get_model`](/mcp/get-scoring-model) | | `api_key` | `/mcp/keys` only | Returns `job_id`, `rows` (the records used) and `request_id`. Poll [`get_job_status`](/mcp/get-job-status); it takes about two minutes, and score calls after it completes use the updated scoring model. Send good and bad outcomes alike. Each calibration chooses again among all the scoring model's questions, and the user's, the ones that best predict `is_bad`. **A scoring model's first calibration** (one created from criteria alone) also has Finic write its questions from the records, and gives it a schema: records scored after it must have their fields. The user's questions that don't help are listed as not used on the scoring model's page in the Finic app, and are tried again at each calibration. A removed question isn't asked or tried again. See [Calibration](/score-model/calibration#calibrate-a-scoring-model) and [Changing questions](/score-model#changing-questions). # get_job_status (/mcp/get-job-status) Checks a job from [`create_model`](/mcp/create-scoring-model) or [`calibrate`](/mcp/calibrate), as [`GET /v1/jobs/{job_id}`](/reference/score/get-job-status). Read-only. | Input | Description | | --------- | -------------------------------------------- | | `job_id` | Required. From `create_model` or `calibrate` | | `api_key` | `/mcp/keys` only | Returns `job_id`, `complete` and, if the job failed, `error` with a `type` and a `message` saying what to do. Call it about every 10 seconds until `complete` is `true`, not in a tight loop: creating a scoring model from labeled records, or calibrating one, takes about two minutes, and there's no progress to report. (Creating one from criteria alone has no job.) # create_site, list_sites, update_site, delete_site (/mcp/sites) A site is a public key for [Identify](/identify)'s snippet. An agent creates one, adds the `snippet` to the user's pages, and reads the visits with [`list_sessions`](/mcp/sessions). All four tools are free; each session a site starts is one identification, [$0.001](/pricing#identify). ## create\_site [#create_site] Creates a site, as [`POST /v1/identify/sites`](/reference/identify/create-site). | Input | Description | | --------- | ---------------------------------------------------------------------------------------------------------------- | | `name` | A few words naming the site. Up to 100 characters | | `origins` | The addresses whose pages may report, like `https://www.example.com`. Up to 20. None takes reports from any page | | `api_key` | `/mcp/keys` only | Returns the site's `id`, `name`, `key` (`gpk_…`, public), `origins`, `created_at` and `snippet`: the script tag for the `` of every page. Up to 50 sites per organization. ## list\_sites [#list_sites] No inputs. Read-only. Returns `sites`, oldest first, as [`GET /v1/identify/sites`](/reference/identify/list-sites). ## update\_site [#update_site] Renames a site or replaces its origins, as [`PATCH /v1/identify/sites/{id}`](/reference/identify/update-site). | Input | Description | | --------- | ----------------------------------------------------------------------------------------- | | `site_id` | Required. The site's `id` | | `name` | The new name. Left out, it stays | | `origins` | The new list, replacing the old one. Left out, it stays; `[]` takes reports from any page | | `api_key` | `/mcp/keys` only | Returns the site. ## delete\_site [#delete_site] Deletes a site, as [`DELETE /v1/identify/sites/{id}`](/reference/identify/delete-site). Its key stops working at once and can't be restored, so the agent should confirm with the user first. Its sessions leave `list_sessions` and can be read by id until they're 30 days old. | Input | Description | | --------- | ------------------------- | | `site_id` | Required. The site's `id` | | `api_key` | `/mcp/keys` only | # list_sessions, get_session, update_session (/mcp/sessions) A session is one visit to a page that carries the snippet, with its [verdict](/identify/verdicts), [visitor](/identify/visitors) and [smart signals](/identify/smart-signals). Reading and linking are free. ## list\_sessions [#list_sessions] Lists the latest sessions, newest first, as [`GET /v1/identify/sessions`](/reference/identify/list-sessions). Read-only. The filters combine. | Input | Description | | ----------- | ---------------------------------------------------------------------------- | | `site` | A site's `id`, for only that site's sessions | | `actor` | `human`, `ai_agent`, `automation` or `unknown` | | `visitor` | A visitor's `id` (`kvi_…`), for only that browser's sessions | | `entity_id` | An entity id, for only the sessions linked to it | | `limit` | 1 to 200; 50 by default | | `signals` | `true` adds each session's `signals`, what the snippet read from the browser | | `api_key` | `/mcp/keys` only | Returns `sessions`. Each has `id`, `site_id`, `actor`, `confidence_score` (0 to 1), `reasons`, `operator` and `product` for a known AI agent, `visitor_id` and `visitor`, `entity_id` and `entity_source` (`server`, or `browser` for an id the page named itself), `ip`, `user_agent`, `page` and the smart signals, among them `vpn`, `incognito`, `tampering` and `suspect_score`. ## get\_session [#get_session] Shows one session, as [`GET /v1/identify/sessions/{id}`](/reference/identify/get-session). Read-only. It adds `velocity`: how many sessions, addresses and entities the session's visitor has had lately. | Input | Description | | ------------ | --------------------------------------------------------------------------------------------------- | | `session_id` | Required. The session's `id` (`ksn_…`): from `list_sessions`, or `window.finic.session` in the page | | `signals` | `true` adds `signals` | | `api_key` | `/mcp/keys` only | A verdict firms up over a session's first seconds. Read it when the customer does something that matters (signs up, logs in, pays), not the instant the page loads. ## update\_session [#update_session] Sets or clears a session's `entity_id`, as [`PATCH /v1/identify/sessions/{id}`](/reference/identify/update-session): your own id for the customer the session belongs to. Nothing else about the session changes. | Input | Description | | ------------ | --------------------------------------------------------------------------------------------------------------------- | | `session_id` | Required. The session's `id` | | `entity_id` | Required. Your id for the customer, up to 128 characters; `null` clears it. Use an id, not an email address or a name | | `api_key` | `/mcp/keys` only | Returns the session. # get_visitor, delete_visitor (/mcp/visitors) A [visitor](/identify/visitors) is a browser Identify recognises from one session to the next. Both tools are free. For a visitor's sessions, call [`list_sessions`](/mcp/sessions) with `visitor`. ## get\_visitor [#get_visitor] Shows one visitor, as [`GET /v1/identify/visitors/{id}`](/reference/identify/get-visitor). Read-only. | Input | Description | | ------------ | ---------------------------------------------------------------- | | `visitor_id` | Required. The visitor's `id` (`kvi_…`): a session's `visitor_id` | | `api_key` | `/mcp/keys` only | Returns `id`, `browser`, `os`, `sessions`, `first_seen_at` and `last_seen_at`. ## delete\_visitor [#delete_visitor] Forgets a visitor, as [`DELETE /v1/identify/visitors/{id}`](/reference/identify/delete-visitor): its fingerprint, addresses and stored id are deleted and can't be restored, so the agent should confirm with the user first. Its sessions stay, without a visitor. The same browser is a new visitor if it comes back. | Input | Description | | ------------ | ---------------------------- | | `visitor_id` | Required. The visitor's `id` | | `api_key` | `/mcp/keys` only | # lookup, list_lookup_sources (/mcp/lookup) The [agent lookup](/identify/lookup) answers for one request your server already has. It can't say a request is from a person; for that, use the snippet and [`list_sessions`](/mcp/sessions). ## lookup [#lookup] Looks one request up, as [`POST /v1/identify/lookup`](/reference/identify/lookup). Send at least one of `ip`, `user_agent` and `headers`. Each lookup that answers is one identification, [$0.001](/pricing#identify). | Input | Description | | ------------ | ------------------------------------------------------------- | | `ip` | The client's IP address, as your server saw it | | `user_agent` | The request's `User-Agent`. Up to 2,000 characters | | `headers` | The request's headers, to check a Web Bot Auth signature | | `url` | The full URL the request was for. Needed to check a signature | | `method` | The request's method. Needed to check a signature | | `api_key` | `/mcp/keys` only | Returns `actor` (`ai_agent`, `automation` or `unknown`), `operator`, `product`, `category`, `verification` (`signed`, `network_verified`, `claimed`, `impersonated` or `none`), `network`, `flags`, `evidence` and `cost_usd`. To try it, send the test agent: `user_agent` `Finic-Test-Agent` with `ip` `192.0.2.10`. ## list\_lookup\_sources [#list_lookup_sources] No inputs. Read-only and free. Returns the `agents` and `networks` the lookup knows and the `sources` it reads, each with when it was last fetched, as [`GET /v1/identify/lookup/sources`](/reference/identify/list-lookup-sources). # ask (/mcp/ask) Asks questions about a case, as [`POST /v1/ask`](/reference/grayson/ask), and returns the same response. No setup needed. | Input | Description | | ----------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `data` | The case's structured data: a JSON object or array (or text) | | `context` | Free text about the case: notes, messages, documents | | `questions` | Required. Names to questions, each with `type` (`noul`, `choice` or `multi_choice`), `instructions`, `criteria` and optional `base_rate`, as in [Questions](/grayson-api/questions) | | `model` | Optional. `grayson-1` by default | | `api_key` | `/mcp/keys` only | Send `data`, `context` or both; up to 32,768 tokens with the questions. Put definitions and policy in the instructions and criteria, act on probabilities with thresholds you choose, and add a `base_rate` when the user knows how common an answer is in their cases ([Calibration](/score-model/calibration#base-rates-for-questions)). ```json title="Arguments" { "context": "Login from a new device in Lagos, then a $4,900 wire to a new payee 6 minutes later. Customer usually logs in from Ohio.", "questions": { "is_ato": { "type": "noul", "instructions": "Is this account takeover?" }, "next_step": { "type": "choice", "instructions": "What should the analyst do next?", "criteria": { "block": "Block the wire and call the customer", "review": "Hold for manual review", "allow": "Let it through" } } } } ``` # get_account (/mcp/get-account) No arguments (`api_key` on `/mcp/keys`). Read-only. Returns `organization`, `credit_usd`, `pending_credit_usd` (free credit added once Finic approves an account created through an agent), `usd_per_million_tokens` (the price of score and ask calls), `usd_per_identification` (the price of an Identify session or lookup), `models`, and `add_credit_url`, where an admin adds credit. With an API key, it also returns `key_name` and `key_expires_at`. # get_data_retention, set_data_retention (/mcp/data-retention) Retention has two layers: the organization's setting and your own, which can only be stricter. A request's content is kept for the shorter of the two. See [Data retention](/grayson-api/data#data-retention). ## get\_data\_retention [#get_data_retention] No arguments. Read-only. Returns `organization`, `organization_retention_days`, `your_retention_days` (`null` when you follow the organization), `effective_retention_days` (the shorter; `0` is Zero Data Retention) and a `note`. ## set\_data\_retention [#set_data_retention] | Input | Description | | ------ | --------------------------------------------------------------------------------------------------- | | `days` | Required. `0` (Zero Data Retention), `7`, `30`, `90` or `365`; or `null` to follow the organization | Returns the same fields as `get_data_retention`. Changes only your own account's setting, across all your organizations; never the organization's. A shorter period deletes content already kept beyond it. Ask the user before calling it: "Do you want to be able to view your past requests, or turn on Zero Data Retention?" # sign_up, get_api_key (/mcp/sign-up) `https://api.finic.ai/mcp/keys` is for clients that can't sign in with OAuth, such as headless scripts. The key passes through the agent, so prefer [`/mcp`](/agent-quickstart) whenever the client supports sign-in. 1. The agent calls `sign_up` and shows the user the link (it works for 24 hours). 2. The user creates an account or signs in, and approves an API key: 30 days by default, or 1 hour, 1 day, 7 days, 90 days, 1 year or never. 3. When the user says they're done, the agent calls `get_api_key` and receives the key, once. It stores it securely, such as in `FINIC_API_KEY`, and sends it as the `Authorization` header or the `api_key` argument (the argument wins if both are sent). The key is listed under [API keys](https://app.finic.ai/keys) as "Agent: " and the agent's name; revoke it there anytime. Every other tool works on `/mcp/keys` too, with the optional `api_key` argument. ## sign\_up [#sign_up] | Input | Description | | --------------------- | -------------------------------------------------------------- | | `agent_name` | Optional. Shown to the user on the page, such as "Claude Code" | | `company`, `use_case` | Optional. The user's company, and what they want Finic for | Returns `signup_url` (for the user), `setup_code` (for the agent only; never show it), `expires_at` and `next_steps`. ## get\_api\_key [#get_api_key] Takes `setup_code`. Call it after the user says they've approved, not repeatedly: repeated calls are slowed down. | `status` | Meaning | | --------------- | ----------------------------------------------------------------------------------------------------- | | `pending` | Not approved yet | | `ready` | With `api_key` (returned only this once), `key_expires_at`, `organization` and `credit_usd` | | `already_taken` | The key was already returned. If it's lost, create one in the Finic app | | `declined` | The user declined | | `expired` | The link is over 24 hours old, or the approved key wasn't taken within 24 hours. Call `sign_up` again | | `invalid` | Not a setup code from `sign_up` |