Skip to main content
Glama

CEIDG sole proprietorships in Poland

polish-new-sole-proprietorships-ceidg
Read-onlyIdempotent

Fetches new and changed Polish sole proprietorships (JDG) from the CEIDG registry by date range, PKD codes and voivodeship, returning NIP, REGON, status and address data.

Instructions

Returns new and changed Polish sole proprietorships (JDG) from the official CEIDG Hurtownia v3 API. Each item has the registered name, NIP, REGON, status, start date and a public address. includePkd (default on) adds PKD codes and suspension, resumption, end and deletion dates. There is no phone, email, website, or separate first and last name. Empty dateFrom and dateTo mean yesterday in Europe/Warsaw. Filter by an inclusive date range of at most 366 days, events (started, changed, or both), PKD prefixes and voivodeships. includeVatStatus is off by default. When it is on, each found entry also gets VAT status from the Ministry of Finance whitelist. soleTraderFullAddress is off by default, so street, building and apartment stay out. ceidgApiToken is optional. When it is empty the Actor reads CEIDG_API_TOKEN. Use it for sole-trader feeds. For KRS companies use polish-new-companies-krs, and to look up a known NIP, REGON or KRS use polish-company-lookup-regon. Read-only: it only queries the public source and never writes to the registry. Each call needs the APIFY_TOKEN env var and starts one paid run of the Apify Actor enterprising_hamster/polish-new-sole-proprietorships-ceidg on your Apify account, billed pay-per-event per delivered company plus any Apify platform usage; the server waits up to 300 s for the run and returns JSON {items, truncated} with at most maxItems (max 100) items and 256 KiB.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "polish-new-sole-proprietorships-ceidg"
  }
}

Input Schema

NameRequiredDescriptionDefault
pkdNoPKD codes or prefixes as the CEIDG filter expects them, for example 41 or 4120Z. Dots are removed. Empty means any activity.
dateToNoLast day, inclusive, YYYY-MM-DD. When dateFrom is empty, this day alone is the range. When dateFrom is later than dateTo, the two days are swapped and the run continues. The inclusive range may be at most 366 days, for example 2024-01-01 through 2024-12-31. Started mode reads that range in consecutive windows of at most 31 days. Changed mode still reads it in windows of 5 days.
eventsNostarted filters /firmy by the activity start date. changed reads /zmiana by the entry-change date, then each entry. Both run started first, then changed, and the same id is charged once.
dateFromNoFirst day (YYYY-MM-DD, Europe/Warsaw). For events started this is the activity start date. For events changed this is the entry-change date. Empty with dateTo empty means yesterday. One day when only dateFrom is set.
maxItemsNoStop after this many found entries are saved.
includePkdNoAfter the /firmy list, read each entry for PKD codes and suspension, resumption, end and deletion dates. The list itself has no PKD. The same field allow-list applies.
voivodeshipsNoPlace of business must be in one of these voivodeships. Values match the API, for example mazowieckie. Empty means the whole country.
ceidgApiTokenNoJWT for the CEIDG Hurtownia (Authorization Bearer). Stored as a secret. If empty, the Actor reads the CEIDG_API_TOKEN environment variable. If both are empty the run fails before any request.
includeVatStatusNoAfter a found entry, ask the Ministry of Finance whitelist (WL2) for statusVat on today's date in Europe/Warsaw. The row then also has statusVatCode and dataSprawdzenia. Bank accounts, PESEL, phone, and email are not requested. Default false. One call per found NIP, at least 0.25 seconds apart.
soleTraderFullAddressNoWhen false, the address has voivodeship, county, municipality, city, postal code and TERC/SIMC/ULIC only. Street, building and apartment are added only when this is true.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.6

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover read-only/open-world/idempotent safety, and the description adds substantial value on top: paid per-run billing on the caller's Apify account, APIFY_TOKEN requirement, a 300 s server wait, token fallback to CEIDG_API_TOKEN with failure when both are empty, and {items, truncated} output capped at maxItems and 256 KiB. It also discloses deliberate omissions (no phone, email, website, first/last name) and the 0.25 s spacing on VAT whitelist calls. Minor gap: truncation/partial-result handling beyond the cap is not explained.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Returned fields and scope come first, followed by option defaults, alternatives, and cost/runtime facts in a sensible order, so it is well front-loaded. It runs long and repeats schema-level details (e.g., the includePkd explanation, the default states) that an agent could also read from the schema, so not every sentence fully earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 10-parameter, zero-required tool with no output schema, the description covers data scope, defaults, date semantics, cost, auth, runtime limits, and the shape of the returned JSON. An agent has everything needed to decide whether to call it and how to interpret the result.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3, and the description still adds cross-parameter meaning the schema spreads out: empty dateFrom and dateTo mean yesterday in Europe/Warsaw, the inclusive range is capped at 366 days, includePkd default-on adds PKD codes plus suspension/resumption/end/deletion dates, includeVatStatus and soleTraderFullAddress are off by default, and ceidgApiToken is optional. It largely restates defaults already in the schema rather than extending them, which keeps it below 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb and resource: 'Returns new and changed Polish sole proprietorships (JDG) from the official CEIDG Hurtownia v3 API', then enumerates the returned fields (name, NIP, REGON, status, start date, public address). It explicitly names the two sibling tools that cover adjacent resources, so an agent can distinguish it without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

States when to use it ('Use it for sole-trader feeds') and routes the agent elsewhere for adjacent cases: KRS companies to polish-new-companies-krs and known-identifier lookups to polish-company-lookup-regon. The alternative conditions are explicit rather than inferred.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.