# /hilma/tenders/search

`POST /api/hilma/tenders/search`

Price: 20 credits

Search Hilma notices — procurement plans, prior information, contract notices, awards and modifications from every Finnish contracting authority, national and small-value notices included — by keyword, notice kind, form type, CPV and NUTS codes, buyer business id, winner, contract nature, procedure, sending system, open state, national, EU and small-value flags, framework and DPS flags, estimated and awarded value, publication date and deadline, with the buyer, winners, values, lots and dates of each notice.

## How to use it

A query returns at most its first 5,000 notices, newest first by default; narrow a wide one with published_from/published_to or main_type. buyer takes the Finnish business id that hilma/buyers/search returns. Pass the id of a row, such as EF-57737 or OLD-160600, to hilma/tenders for the organisations, awards and the whole published notice.

## Parameters

- `access-token` (string, required)

## Request body

- `timeout` (integer) — Max scrapping execution timeout (in seconds) (default: 300; min: 20; max: 1500)
- `count` (integer, required) — Max number of results (min: 1; max: 5000)
- `keyword` (string, nullable) — Full-text keyword (examples: "siivous"; minLength: 1)
- `main_type` (array, nullable) — Notice kinds to include (one of: "procurement_plan", "prior_information", "contract_notice", "national_notice", "contract_award", "modification"; minItems: 1)
- `form_type` (array, nullable) — Hilma form type codes (examples: ["E4"], ["16","29"]; minItems: 1)
- `cpv` (array, nullable) — CPV codes or code prefixes (examples: ["45200000"], ["452"]; minItems: 1)
- `nuts` (array, nullable) — NUTS codes or prefixes of the place of performance (examples: ["FI1B"])
- `buyer` (array, nullable) — Finnish business ids of buyers (examples: ["0201256-6"]; minItems: 1)
- `supplier` (string, nullable) — Word in the winner name (examples: "Lassila"; minLength: 1)
- `contract_nature` (array, nullable) — Contract natures to include (one of: "works", "services", "supplies"; minItems: 1)
- `procedure_type` (array, nullable) — Procedure types to include (one of: "open", "restricted", "neg-wo-call", "neg-w-call", "comp-dial", "oth-single", "oth-mult", "innovation", "comp-tend"; minItems: 1)
- `sending_system` (array, nullable) — Systems the notice was sent from (examples: ["Cloudia Kilpailutus"]; minItems: 1)
- `is_open` (boolean, nullable) — Only notices not yet expired, or only expired ones
- `is_national_procurement` (boolean, nullable) — National procurement flag
- `is_eu_procurement` (boolean, nullable) — EU-threshold procurement flag
- `is_national_small_value` (boolean, nullable) — National small-value procurement flag
- `has_framework_agreement` (boolean, nullable) — Framework agreement flag
- `has_dynamic_purchasing_system` (boolean, nullable) — Dynamic purchasing system flag
- `is_eforms` (boolean, nullable) — eForms notice flag
- `value_from` (integer, nullable) — Minimum estimated value in EUR (examples: 1000000; min: 0)
- `value_to` (integer, nullable) — Maximum estimated value in EUR (examples: 10000; min: 0)
- `awarded_value_from` (integer, nullable) — Minimum awarded total in EUR (examples: 1000000; min: 0)
- `awarded_value_to` (integer, nullable) — Maximum awarded total in EUR (examples: 50000; min: 0)
- `published_from` (string, nullable) — Earliest publication date, inclusive (examples: "2026-09-01")
- `published_to` (string, nullable) — Latest publication date, inclusive (examples: "2026-09-21")
- `deadline_from` (string, nullable) — Earliest tender deadline date, inclusive (examples: "2026-10-01")
- `deadline_to` (string, nullable) — Latest tender deadline date, inclusive (examples: "2026-10-31")
- `sort` (string, nullable) — Result order (one of: "newest", "oldest")

## Response

### 200 — Successful Response

- `@type` (string) (default: "HilmaTenderSummary")
- `id` (string, required)
- `notice_id` (string, nullable)
- `notice_number` (string, nullable)
- `procedure_id` (string, nullable)
- `legacy_procedure_id` (string, nullable)
- `plan_id` (string, nullable)
- `eforms_id` (string, nullable)
- `eforms_version_id` (string, nullable)
- `contract_folder_id` (string, nullable)
- `parent_notice_id` (string, nullable)
- `previous_notice_ids` (array) (default: [])
- `previous_notice_numbers` (array) (default: [])
- `previous_ted_publication_ids` (array) (default: [])
- `previous_eforms_ids` (array) (default: [])
- `previous_eforms_version_ids` (array) (default: [])
- `previous_contract_folder_ids` (array) (default: [])
- `linked_ted_publication_ids` (array) (default: [])
- `ted_publication_id` (string, nullable)
- `ojs_number` (string, nullable)
- `referenced_notice_id` (string, nullable)
- `form_type` (string, nullable)
- `main_type` (string, nullable)
- `stage` (string, nullable)
- `titles` (object, nullable)
  - `@type` (string) (default: "HilmaText")
  - `fi` (string, nullable)
  - `sv` (string, nullable)
  - `en` (string, nullable)
  - `other` (string, nullable)
- `description` (string, nullable)
- `descriptions` (object, nullable)
  - `@type` (string) (default: "HilmaText")
  - `fi` (string, nullable)
  - `sv` (string, nullable)
  - `en` (string, nullable)
  - `other` (string, nullable)
- `buyer` (object, nullable)
  - `@type` (string) (default: "HilmaBuyer")
  - `name` (string, nullable)
  - `names` (object, nullable)
    - `@type` (string) (default: "HilmaText")
    - `fi` (string, nullable)
    - `sv` (string, nullable)
    - `en` (string, nullable)
    - `other` (string, nullable)
  - `business_id` (string, nullable)
  - `department` (string, nullable)
  - `address` (string, nullable)
  - `nuts` (string, nullable)
  - `organisation_type` (string, nullable)
- `suppliers` (array) (default: [])
  - `@type` (string) (default: "HilmaSupplier")
  - `name` (string, required)
  - `identifier` (string, nullable)
- `cpv` (array) (default: [])
- `nuts` (array) (default: [])
- `contract_natures` (array) (default: [])
- `procedure_type` (string, nullable)
- `value` (object, nullable)
  - `@type` (string) (default: "HilmaValue")
  - `amount` (number, nullable)
  - `currency` (string, nullable)
- `awarded_value` (object, nullable)
  - `@type` (string) (default: "HilmaValue")
  - `amount` (number, nullable)
  - `currency` (string, nullable)
- `framework_max_value` (object, nullable)
  - `@type` (string) (default: "HilmaValue")
  - `amount` (number, nullable)
  - `currency` (string, nullable)
- `framework_approximate_value` (object, nullable)
  - `@type` (string) (default: "HilmaValue")
  - `amount` (number, nullable)
  - `currency` (string, nullable)
- `dates` (object, nullable)
  - `@type` (string) (default: "HilmaDates")
  - `published_at` (integer, nullable)
  - `modified_at` (integer, nullable)
  - `deadline_at` (integer, nullable)
  - `expires_at` (integer, nullable)
- `is_cancelled` (boolean, nullable)
- `is_corrigendum` (boolean, nullable)
- `is_eforms` (boolean, nullable)
- `is_eu_procurement` (boolean, nullable)
- `is_national_procurement` (boolean, nullable)
- `is_national_small_value` (boolean, nullable)
- `is_private_small_value` (boolean, nullable)
- `is_plan` (boolean, nullable)
- `is_latest` (boolean, nullable)
- `is_tendering_in_hilma` (boolean, nullable)
- `has_framework_agreement` (boolean, nullable)
- `has_dynamic_purchasing_system` (boolean, nullable)
- `estimated_opportunities` (string, nullable)
- `documents_url` (string, nullable)
- `sending_system` (string, nullable)
- `sustainability` (object, nullable)
  - `@type` (string) (default: "HilmaSustainability")
  - `has_biodiversity` (boolean, nullable)
  - `has_circular_economy` (boolean, nullable)
  - `has_code_of_conduct` (boolean, nullable)
  - `has_employment_condition` (boolean, nullable)
  - `has_end_user_involvement` (boolean, nullable)
  - `has_energy_efficiency` (boolean, nullable)
  - `has_innovation` (boolean, nullable)
  - `has_just_working_conditions` (boolean, nullable)
  - `has_listed_green_criteria` (boolean, nullable)
  - `has_low_carbon` (boolean, nullable)
  - `has_sme_participation` (boolean, nullable)
  - `is_solution_new_to_buyer` (boolean, nullable)
  - `is_solution_new_to_market` (boolean, nullable)
  - `has_sustainable_food_production` (boolean, nullable)
- `lots` (array) (default: [])
  - `@type` (string) (default: "HilmaLotSummary")
  - `id` (string, nullable)
  - `titles` (object, nullable)
    - `@type` (string) (default: "HilmaText")
    - `fi` (string, nullable)
    - `sv` (string, nullable)
    - `en` (string, nullable)
    - `other` (string, nullable)
  - `description` (string, nullable)
  - `descriptions` (object, nullable)
    - `@type` (string) (default: "HilmaText")
    - `fi` (string, nullable)
    - `sv` (string, nullable)
    - `en` (string, nullable)
    - `other` (string, nullable)
  - `cpv` (array) (default: [])
  - `nuts` (array) (default: [])
  - `contract_natures` (array) (default: [])
  - `procedure_type` (string, nullable)
  - `value` (object, nullable)
    - `@type` (string) (default: "HilmaValue")
    - `amount` (number, nullable)
    - `currency` (string, nullable)
  - `awarded_value` (object, nullable)
    - `@type` (string) (default: "HilmaValue")
    - `amount` (number, nullable)
    - `currency` (string, nullable)
  - `suppliers` (array) (default: [])
    - `@type` (string) (default: "HilmaSupplier")
    - `name` (string, required)
    - `identifier` (string, nullable)
  - `deadline_at` (integer, nullable)
  - `expires_at` (integer, nullable)
  - `has_framework_agreement` (boolean, nullable)
  - `has_dynamic_purchasing_system` (boolean, nullable)
  - `estimated_opportunities` (string, nullable)
  - `statistics` (object, nullable)
    - `@type` (string) (default: "HilmaTenderStatistics")
    - `received_tender_count` (integer, nullable)
    - `received_application_count` (integer, nullable)
    - `electronic_tender_count` (integer, nullable)
    - `micro_tenderer_count` (integer, nullable)
    - `small_tenderer_count` (integer, nullable)
    - `medium_tenderer_count` (integer, nullable)
    - `sme_tenderer_count` (integer, nullable)
    - `other_eea_tenderer_count` (integer, nullable)
    - `outside_eea_tenderer_count` (integer, nullable)
    - `unverified_tender_count` (integer, nullable)
    - `inadmissible_tender_count` (integer, nullable)
    - `abnormally_low_tender_count` (integer, nullable)
  - `sustainability` (object, nullable)
    - `@type` (string) (default: "HilmaSustainability")
    - `has_biodiversity` (boolean, nullable)
    - `has_circular_economy` (boolean, nullable)
    - `has_code_of_conduct` (boolean, nullable)
    - `has_employment_condition` (boolean, nullable)
    - `has_end_user_involvement` (boolean, nullable)
    - `has_energy_efficiency` (boolean, nullable)
    - `has_innovation` (boolean, nullable)
    - `has_just_working_conditions` (boolean, nullable)
    - `has_listed_green_criteria` (boolean, nullable)
    - `has_low_carbon` (boolean, nullable)
    - `has_sme_participation` (boolean, nullable)
    - `is_solution_new_to_buyer` (boolean, nullable)
    - `is_solution_new_to_market` (boolean, nullable)
    - `has_sustainable_food_production` (boolean, nullable)
- `country` (string) (default: "FI")
- `url` (string, required)

## Errors

### 422 — Validation Error

A filter value Hilma does not accept

What to do: Check the fields against this schema. A URN with the wrong prefix is the most common cause.

- `detail` (array)
  - `loc` (array, required)
  - `msg` (string, required)
  - `type` (string, required)
  - `input` (any)
  - `ctx` (object)

### 408

The request ran past its time limit

What to do: Raise `timeout` in the request body, up to the maximum this endpoint documents. Lowering `count` or turning off the `with_*` flags also helps, because less work finishes sooner.

### 412

The entity was not found, or a precondition failed

What to do: Retrying will not help: either the entity does not exist, or the input points at a different one.

### 429

Too many requests: a rate limit or a usage window is exhausted

What to do: When the response carries an X-Retry-After header, wait that many seconds and retry: the same number is in the body as `detail.retry_after`, and the limit clears once that window passes. The message in the body names the limit that was hit.

### 500

Something broke on our side

What to do: Retrying will not help. If it keeps happening, send us the X-Request-ID from the response headers.

### 529

Rate limit reached, or the endpoint is overloaded

What to do: Wait at least 30 seconds, then retry.

## Response envelope

Success: Array of objects (may be empty if no results)

Error: Error may coexist with partial results if it occurs mid-execution. Check X-Error header and status code.

Every response carries these headers:

- `X-Error` — Error message text (present only on error)
- `X-Request-ID` — Unique request identifier
- `X-Execution-Time` — Execution time in seconds
- `X-Result-Count` — How many records the body carries. 0 means an empty result, which is a normal answer and not by itself an error. A non-zero count can come back together with X-Error when the failure happened partway through — read this header and X-Error independently.
- `X-Total-Available-Results` — How many records exist for this query, when the endpoint can say. On a `dry_run` request this is the answer and the body is empty. It saturates: the endpoint's documented maximum means 'at least that many', any smaller number is exact.
- `X-Warning` — Present when the request body carried keys this endpoint does not document. They were ignored, so any filter you meant to apply through them did not apply. Check the spelling against this schema and retry.
- `X-Retry-After` — Seconds to wait before retrying. Present only on 429.

