TypeScript SDK
The OpenApp TypeScript SDK (@tomers/openapp-sdk)
is the official Node.js client. It ships OpenAPI-generated types plus an async
AsyncClient over the shared core bridge.
Package & source
Section titled “Package & source”| Package registry | npm @tomers/openapp-sdk |
| Published package | npm (package files) |
| Issues | npm package issues · GitHub issues |
Sources ship with the npm tarball (types in dist/). There is no separate public GitHub mirror
tree for this package today.
Install
Section titled “Install”npm install @tomers/openapp-sdkRequires Node.js 20+ and an OpenApp API key.
Minimal example
Section titled “Minimal example”import { AsyncClient } from "@tomers/openapp-sdk";
const client = new AsyncClient(process.env.OPENAPP_API_KEY!);
try { const orgs = await client.orgs.list(); console.log(orgs);} finally { client.close();}Basic operations
Section titled “Basic operations”import { AsyncClient } from "@tomers/openapp-sdk";
const client = new AsyncClient(process.env.OPENAPP_API_KEY!);
const created = await client.orgs.create("Example Org");const org = await client.orgs.get("org_123");const devices = await client.devices.list("org_123");const plan = await client.billing.plan("org_123");const invites = await client.me.invitations();
client.close();Error handling
Section titled “Error handling”import { AsyncClient, ApiError, AuthError } from "@tomers/openapp-sdk";
const client = new AsyncClient(process.env.OPENAPP_API_KEY!);
try { await client.orgs.list();} catch (err) { if (err instanceof AuthError) { console.error("Authentication failed:", err.message); } else if (err instanceof ApiError) { console.error("API error:", err.message, err.code); } else { console.error("Unexpected error:", err); }} finally { client.close();}TypeScript API types
Section titled “TypeScript API types”The package exports OpenAPI-aligned TypeScript types in addition to the runtime client:
import type { paths } from "@tomers/openapp-sdk";Shared guides
Section titled “Shared guides”Cross-language topics (TypeScript examples appear where the façade exposes the operation):
- Authentication — API keys and client setup.
- Errors & retries —
ApiError,AuthError, and retry policy. - Organization context & pagination.
- Devices, Zones, Entities, Organizations, Users, Billing, Integrations, Scripting, and the rest of the SDK overview index.
Some resources are not on the high-level AsyncClient façade yet; use the shared transport
patterns documented on the resource pages or another SDK for full coverage.
HTTP contract: API reference · OpenAPI JSON