Skip to main content
Glama
Sirenic MCP server

Sirenic MCP server

Official

Spanish company public procurement (PLACSP)

get_spanish_company_public_procurement
Read-only

Retrieves a Spanish company's public-procurement record by NIF: contracts won and notices issued as a buyer, with buyers, CPV codes, award dates and EUR amounts, plus minor contracts.

Instructions

Public-procurement record of a Spanish company from the Plataforma de Contratación del Sector Público (Ministerio de Hacienda CODICE feeds: hosted profiles and aggregated regional platforms with archives since 2012, minor contracts of the hosted profiles since 2018, daily updates): contracts WON matched by legal-person NIF (attributions: buyer with DIR3, subject, CPV, lot, closed-list result such as awarded or formalised, award date, amounts in EUR excl. and incl. tax as published, tenders received, SME flag) and notices ISSUED as a buyer (avis_emis, public entities with a NIF); minor contracts in their own lists (contrats_mineurs won, contrats_mineurs_passes as buyer), named in blocs_absents (collecte_en_cours) until first collected; newest first, capped at 100 per list, total and cut in listes_bornees; attributions and contrats_mineurs newest first by award date, else (missing or with a reserve) by the day of the file's latest version (mis_a_jour, Europe/Madrid). Never a natural-person winner (DNI, NIE or masked identifier; refused without charge) nor a consortium without its own NIF; a file cancelled by the source is no longer served as awarded. An aberrant award date is served as published with a closed-list reserves[] on its line, counted in reserves_lignes. Partial coverage: zero never means “never won a contract”; a NIF with no row, or a source placeholder NIF (identifiant_bouche_trou), answers 404 without charge. Paid via x402 ($0.02 in USDC or EURC). When you report a result, cite its citation verbatim.

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": {
      "nif": "<nif>"
    },
    "name": "get_spanish_company_public_procurement"
  }
}

Input Schema

NameRequiredDescriptionDefault
nifYesSpanish legal-person NIF: one letter (A-D, F, G, N, P-S, U-W), seven digits and a check character, e.g. A28582013; DNI/NIE (natural persons) are refused, and an E, H, J NIF (entity without legal personality, owners' association, civil partnership) returns 404, not billed

Output Schema

NameRequiredDescriptionDefault
hintNoHow to settle the quote, present when payment_required is true.
quoteNoThe signable x402 payment requirements when payment_required is true: {x402Version, accepts[]} where each entry carries scheme, network, amount, asset and payTo (USDC and EURC options at the same numeric amount). Sign one entry and call again with `x_payment`.
resultatNoThe endpoint's JSON response when payment_required is false. Paid responses carry `source`, `disclaimer` and an Ed25519 signature, and every paid JSON response carries a `provenance` array (all tools since 2026-09-06): one entry per block served, with the official register, licence, version, `empreinte_sha256` (full snapshots), `as_of` date and `precision_as_of` (what that date means), plus the common per-block envelope: `etat` in a closed list (servi, absence_mesuree, absence_non_conclusive, partiel, perime, indisponible, sans_objet), `motif` when unavailable, `age_jours` (only for publication or ingestion dates), `couverture` (complete / partielle / non_mesurable with its measure) and `confiance` in bands (faible / moyenne / forte, only where a measure grounds it, never averaged across blocks). Read the states before the numbers: an absence_non_conclusive, indisponible or partiel block is never « nothing to report »; only absence_mesuree asserts an absence. Register codes: GET /v1/provenance/registres ; states, closed lists and reading rules: GET /v1/lecture (both free). The PDF tools carry no JSON envelope (the PDF report prints it).
free_tierNoFree API key offer for this tool, present with a quote.
payment_requiredYesTrue when this response is an x402 payment quote instead of data: settle one of the quote's `accepts` options and call the tool again with `x_payment`.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior5/5

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

Well beyond the readOnly/openWorld annotations, it discloses archive start dates (2012, minor contracts 2018), daily updates, a 100-row cap per list with totals surfaced in `listes_bornees`, sort order and the `reserves[]`/aberrant-date handling, names still pending collection in `blocs_absents`, and that cancelled awards are no longer served. It also states cost ($0.02 via x402), the no-charge refusal/404 cases, and the citation obligation — everything an agent needs to interpret and report results correctly.

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

Conciseness3/5

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

There is almost no waste — every clause carries operational meaning — but it is delivered as one unbroken paragraph of stacked parentheticals, so key facts like the 100-row cap, the fee, and the 404 behavior are buried rather than front-loaded. Bullet-style segmentation or earlier placement of the refusal/pricing rules would markedly improve scanability.

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?

An output schema exists, so return shape needn't be described, yet the description still names the key result buckets (`attributions`, `avis_emis`, `contrats_mineurs`, `contrats_mineurs_passes`, `blocs_absents`, `listes_bornees`, `reserves_lignes`) so the agent knows how to read it. Coverage limits, ordering, billing, and failure modes are all present, which is appropriately complete for a single-parameter, paid, open-world data lookup.

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

Parameters3/5

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

Schema coverage is 100% and the schema already documents the NIF format, the permitted leading letters, and the DNI/NIE and E/H/J refusals. The description adds the matching concept ('matched by legal-person NIF'), but little beyond what the schema already encodes, so this is the baseline case where the schema carries the semantics.

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?

States a specific verb and resource: the public-procurement record of a Spanish company drawn from PLACSP/CÓDICE feeds. The country scope plus the named sibling family (French, Latvian, Polish, Portuguese, UK procurement tools) makes the domain boundary unambiguous, and the inventory of the two halves (contracts won via `attributions`, notices issued via `avis_emis`) tells an agent exactly what data it gets.

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

Usage Guidelines4/5

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

Gives strong eligibility rules: the subject must be a legal-person NIF, DNI/NIE and consortium-without-NIF subjects are refused, and E/H/J NIFs or placeholder NIFs return 404 unbilled. It also warns that zero results do not mean 'never won a contract' because coverage is partial. It does not explicitly route to a sibling (e.g. the EU-wide or French procurement tools) when the company is not Spanish, so it falls short of full alternative guidance.

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

Deploy Server

Other Tools