---
title: "Link entities (batch)"
method: POST
path: "/med-link/nel/link/batch"
tags: ["Entity Linking"]
---

# Link entities (batch)

`POST /med-link/nel/link/batch`

Links up to 5 free-text entities in a single call. All queries in a batch share the same `ontology`, `version`, `top_k` and `metadata`. The response contains one result block per query, in request order.

## Request body

- NELBatchRequest
  - `queries` string[], required — List of free-text entities to link (1–5).
  - `ontology` string, required — Ontology name applied to every query in the batch.
  - `version` string, required — Ontology version applied to every query in the batch.
  - `top_k` integer — Number of candidate results to return per query.
  - `metadata` object — Ontology-specific hints applied to every query in the batch.
  - `request_id` string, nullable — Optional request ID. Generated automatically if omitted.

## Response `200`

One result block per query, in request order.

- NELBatchResponse
  - `results` NELResponse[], required — One `NELResponse` per query, in request order.
    - `request_id` string, required
    - `query` string, required
    - `query_breakdown` object, nullable — How the query was parsed. Present for LOINC, medication and ICD-10-CM Comprehend; `null` for SNOMED CT.
    - `results` NELResult[], required
      - `term_id` string, required — The ontology code for this candidate.
      - `term_name` string, required — Human-readable name of the candidate term.
      - `score` number, nullable — Relevance/confidence of the candidate. `null` for medication, where matching is reported through `metadata.matching_breakdown` instead.
      - `is_linked` boolean — `true` when the pipeline is confident this candidate is the correct single match for the query.
      - `metadata` object, nullable — Ontology-specific detail about the candidate (e.g. `semantic_tag` for SNOMED, `matching_breakdown`/`eka_id` for LOINC, `generic_name`/`matching_breakdown` for medication).
    - `ontology` string, required
    - `version` string, required
    - `index_name` string, required — The index that served the request.
    - `model_version` string, nullable

## Other responses

- `422` — Validation error — a required field is missing or malformed.

---

[API](https://skmtc.net/eka/apis/eka-developer-apis.md) · [All operations](https://skmtc.net/eka/apis/eka-developer-apis/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/eka/eka-developer-apis/versions/9ea23456f722/schema)
