Skip to navigation

SDKs

Idiomatic clients for TypeScript, Python, and Java — generated from the OpenAPI spec.

All three SDKs are generated from the same OpenAPI specification that powers this API Reference, so they never drift from the API.

Install

npm install @imo-demo/precision-normalize

What you get

Automatic token management

The client performs the OAuth client-credentials exchange and refreshes the JWT before expiry. You never touch /oauth/token.

Fully typed

Every request and response is typed, including the enums for domain, input_code_system, match_field_pref, severity, and sex.

Typed errors

Distinct error classes per status code carrying the parsed error envelope.

Retries and timeouts

Configurable per-request timeouts, retry counts, and idempotent retry on transient failures.

Namespaces

The client mirrors the API’s resources:

NamespaceMethods
normalizenormalize(), enrich()
sessionscreate()
eventslogSelection()
authgetToken() — called for you; rarely needed directly
import { ImoHealthClient } from "@imo-demo/precision-normalize";
const client = new ImoHealthClient({
clientId: process.env.IMO_CLIENT_ID!,
clientSecret: process.env.IMO_CLIENT_SECRET!,
});
await client.normalize.normalize({ /* ... */ });
await client.normalize.enrich({ /* ... */ });
await client.sessions.create();
await client.events.logSelection({ /* ... */ });

Async support

from imo_precision_normalize import AsyncImoHealth, NormalizeRequestRequestsItem
client = AsyncImoHealth(
client_id=os.environ["IMO_CLIENT_ID"],
client_secret=os.environ["IMO_CLIENT_SECRET"],
)
result = await client.normalize.normalize(
client_request_id="async-001",
requests=[
NormalizeRequestRequestsItem(
record_id="1", domain="Problem", input_term="chest pain"
)
],
)

Environments

The sandbox is the default base URL. Override it to point at production:

const client = new ImoHealthClient({
environment: "https://api.imohealth.com",
clientId: process.env.IMO_CLIENT_ID!,
clientSecret: process.env.IMO_CLIENT_SECRET!,
});

The published spec declares only the sandbox host (https://api-sandbox.imohealth.com). Confirm your production host with IMO Health before switching.