Match a list of records to firms
match_companiesMatch a list of up to 500 records (name, optional county, domain or CUI) to Romanian firms: each row gets match {cui, companyName, confidence, matchedOn} and the record, or no_match with up to 3 candidates.
Instructions
Match a list of up to 500 records (name, optional county, domain or CUI) to Romanian firms: each row gets match {cui, companyName, confidence, matchedOn} and the record, or no_match with up to 3 candidates. A valid CUI wins (confidence 1.0). Each row is one lookup; rows past today's allowance come back not_processed (partial: true, remaining: rows to resend after the reset).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"rows": "<rows>"
},
"name": "match_companies"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| rows | Yes | Up to 500 records, each {name, county, domain, cui, ref} (any of them; ref is your own id, echoed back), or a bare string (a CUI, a domain or a name). | |
| fields | No | Optional: keep only these company fields in each row, comma-separated (companyName,cui,county,risk; dotted paths such as risk.level work). Without it the full record is returned. | |
| compact | No | Optional: true keeps a short preset per row (name, CUI, county, city, legal form, risk level and what it did not check, phone, website, latest revenue and headcount, record url). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| asOf | No | What to cite: registry (ONRC snapshot date), financialYear (fiscal year of the figures), anaf (day of the ANAF data), snapshot, published, source. | |
| error | No | Set only when there is no answer (empty_query, invalid_cui, data_unavailable, plan_required ...); such a call is not counted. | |
| total | No | Number of input rows. | |
| errors | No | Rows that are input errors (nothing to match on). | |
| fields | No | The company fields kept when fields or compact trimmed the rows. | |
| source | No | Data source: onrc (registry) or mfp (Ministry of Finance filings). | |
| matched | No | Rows matched to a firm. | |
| message | No | A sentence for the caller. | |
| noMatch | No | Rows with no match above the threshold. | |
| partial | No | true when today's allowance ran out partway: the first processed rows were answered, the rest have status not_processed (not run, not counted). | |
| results | No | Per row: row, input, status (matched or no_match), match {cui, companyName, confidence, matchedOn}, company, or candidates. | |
| metering | No | What the batch cost: rows, counted, notCounted (input-error rows and rows not processed are not counted), notProcessed (when partial) and the rule. | |
| warnings | No | Notes on how the request was read (a clamped limit, a widened CAEN code, an ignored field). | |
| processed | No | Rows answered, from the first one (input-error rows included). | |
| remaining | No | Rows not processed (the last ones): send them again after the reset. 0 when the whole batch ran. | |
| threshold | No | Confidence a row needs to be matched (0-1). | |
| dailyLimit | No | When partial: the daily-limit notice in the refusal vocabulary (error daily_limit_reached, message, limit, used, remaining allowance, resets_at, requested, processed, plan, get_a_key, pricing, docs, upgrade with a key). | |
| attribution | No | The credit line to keep when redistributing the data (CC BY 4.0). |