Skip to navigation

Quickstart

Normalize your first clinical term in five minutes.
1

Install an SDK

npm install @imo-demo/precision-normalize
2

Set your credentials

Export the client credentials issued to you in the Developer Portal:

export IMO_CLIENT_ID="your-client-id"
export IMO_CLIENT_SECRET="your-client-secret"

The SDK exchanges these for a JWT automatically and refreshes it before it expires. See Authentication for the underlying flow.

3

Normalize a term

import { ImoHealthClient } from "@imo-demo/precision-normalize";
const client = new ImoHealthClient({
clientId: process.env.IMO_CLIENT_ID!,
clientSecret: process.env.IMO_CLIENT_SECRET!,
});
const result = await client.normalize.normalize({
clientRequestId: "quickstart-001",
preferences: { threshold: 0.5, size: 3 },
requests: [
{ recordId: "1", domain: "Problem", inputTerm: "chest pain" },
{ recordId: "2", domain: "Problem", inputTerm: "type 2 diabetes" },
],
});
for (const record of result.requests ?? []) {
const top = record.response?.items?.[0];
console.log(record.recordId, "->", top?.lexicalTitle, top?.score);
}
4

Read the response

Each record echoes your record_id and carries a ranked items array. The score is a confidence value from 0–1, with 1 an exact match.

{
"summary": { "count": 1, "error_count": 0 },
"request_id": "7f3c1a90-5f2e-4d1b-9c8a-1b2c3d4e5f60",
"client_request_id": "quickstart-001",
"response_time": 42,
"requests": [
{
"record_id": "1",
"domain": "Problem",
"input_term": "chest pain",
"response": {
"match_field": "input_term",
"domain": "Problem",
"explanation": "The input term 'chest pain' was matched to the IMO lexical 'Chest pain' with a score of 1.0.",
"items": [
{
"lexical_code": "3763",
"lexical_title": "Chest pain",
"score": 1.0,
"certainty": "High"
}
]
}
}
]
}

Set preferences.size to cap how many candidate lexicals come back per record, and preferences.threshold to drop low-confidence matches entirely.

Where to go next