@simo-online/api
v1.0.0
Published
Official TypeScript client for the SIMO Public API — EU AI Act risk classification and Data Strategy maturity assessment. Bearer auth, rate-limit aware, retries with exponential backoff.
Downloads
129
Maintainers
Readme
@simo-online/api
Official TypeScript client for the SIMO Public API v1.
Two task-focused capabilities:
- EU AI Act Quickcheck — classify any AI use case into the four risk tiers of Regulation (EU) 2024/1689 (
prohibited/high_risk/limited/minimal) with reasoning and applicable articles. - Data Strategy Assessment — turn 11 multiple-choice answers into a maturity level (1–5) plus 5 prioritised next steps with effort in calendar weeks.
Bearer auth, rate-limit aware (X-RateLimit-* headers parsed for you), automatic retry with exponential backoff on 429 and 5xx, native fetch (Node 18+ and modern browsers).
Engineered at SIMO GmbH · Aschaffenburg, Germany
Install
npm install @simo-online/apiQuick start
import { SimoClient } from "@simo-online/api";
const simo = new SimoClient({ apiKey: process.env.SIMO_API_KEY! });
// EU AI Act risk classification
const ai = await simo.euAiAct.quickcheck({
use_case: "AI assistant that scores loan applications and recommends approval",
context: { sector: "banking", deployment: "internal" },
});
console.log(ai.tier); // "high_risk"
console.log(ai.applicable_articles); // ["Article 6 (high-risk classification)", ...]
// Data strategy maturity
const questions = await simo.dataStrategy.getQuestions();
const answers = Object.fromEntries(
questions.questions.map((q) => [q.id, q.options[0]!.id]),
);
const ds = await simo.dataStrategy.assess({ answers });
console.log(ds.maturity_level); // 1..5
console.log(ds.next_steps[0]); // { title, description, effort_weeks, priority }Get an API key
Free sandbox key (deterministic mock answers): https://simo-online.com/developers/request-key
Production key (49 €/month including 500 calls + 0.05 €/call beyond): self-service Stripe checkout at https://simo-online.com/developers.
Configuration
const simo = new SimoClient({
apiKey: "simo_sand_…",
baseUrl: "https://simo-online.com/api/v1", // default
lang: "en", // sends Accept-Language
timeoutMs: 30_000, // per-attempt
maxRetries: 3, // 0 disables retries
retryBaseMs: 500, // doubles per retry, full-jitter
});Errors
All errors derive from SimoApiError. Specialised subclasses for ergonomic narrowing:
| Class | Triggers on |
|-------|-------------|
| SimoAuthError | auth_missing, auth_invalid (401) |
| SimoKeyError | key_revoked (403), key_past_due (402) |
| SimoValidationError | validation_failed (422), invalid_request (400) |
| SimoRateLimitError | rate_limit_exceeded, quota_exhausted (429) |
| SimoNetworkError | timeout, DNS, TLS, fetch abort (no HTTP response) |
| SimoApiError | everything else (catch-all) |
import {
SimoClient,
SimoRateLimitError,
SimoAuthError,
} from "@simo-online/api";
try {
await simo.euAiAct.quickcheck({ use_case: "..." });
} catch (err) {
if (err instanceof SimoRateLimitError) {
console.warn(`Rate-limited until ${err.rateLimit?.reset}, retry in ${err.retryAfter}s`);
} else if (err instanceof SimoAuthError) {
console.error("Invalid or missing API key");
} else {
throw err;
}
}Every error carries code, message, status, requestId, details?, retryAfter?, and the latest rateLimit snapshot.
Rate limits
After every successful call, simo.lastRateLimit reflects the headers from that response:
await simo.euAiAct.quickcheck({ use_case: "..." });
console.log(simo.lastRateLimit);
// { limit: 60, remaining: 59, reset: 1717200000 }Documentation
- Interactive Swagger UI: https://simo-online.com/api/v1/docs
- OpenAPI 3.1 spec: https://simo-online.com/openapi.json
- Developer portal: https://simo-online.com/developers
License
MIT © SIMO GmbH, Aschaffenburg, Germany
