Integrations

SDKs

eupeak.io is a plain REST API — you can call it with any HTTP client. For convenience, we publish thin, fully typed SDKs in TypeScript and Python that wrap authentication, retries and response typing.

TypeScript · Node ≥ 18

@eupeak/sdk

Isomorphic, zero-dependency, fully typed. Works in Node.js, Deno, Bun and edge runtimes.

Python · ≥ 3.10

eupeak

Async-first using httpx. Sync client also available. Type hints everywhere.

TypeScript

Install

pnpm add @eupeak/sdk
# or
npm i @eupeak/sdk
# or
yarn add @eupeak/sdk

Screen an entity

import { Eupeak } from '@eupeak/sdk';

const eupeak = new Eupeak({ apiKey: process.env.EUPEAK_API_KEY! });

const result = await eupeak.screen({
  query: 'Acme Corporation SA',
  type: 'entity',
});

if (result.risk_level === 'high' || result.risk_level === 'critical') {
  for (const flag of result.flags) {
    console.log(flag.type, flag.source, flag.match_score);
  }
}

Retrieve a past screening

const history = await eupeak.screenings.get(
  'b3c1e2a4-5f6d-4a8b-9c0e-1f2d3a4b5c6d'
);

Webhook signature verification

import { verifyWebhook } from '@eupeak/sdk/webhooks';

export function POST(req: Request) {
  const body = await req.text();
  const signature = req.headers.get('x-eupeak-signature') ?? '';

  if (!verifyWebhook(body, signature, process.env.EUPEAK_WEBHOOK_SECRET!)) {
    return new Response('invalid signature', { status: 401 });
  }

  const event = JSON.parse(body);
  // …handle event.data
  return new Response('ok');
}

Python

Install

pip install eupeak
# or
uv add eupeak

Screen an entity (async)

import os
from eupeak import AsyncEupeak

eupeak = AsyncEupeak(api_key=os.environ["EUPEAK_API_KEY"])

async def run():
    result = await eupeak.screen(
        query="Acme Corporation SA",
        type="entity",
    )
    if result.risk_level in ("high", "critical"):
        for flag in result.flags:
            print(flag.type, flag.source, flag.match_score)

Screen an entity (sync)

from eupeak import Eupeak

eupeak = Eupeak(api_key=os.environ["EUPEAK_API_KEY"])
result = eupeak.screen(query="Acme Corporation SA", type="entity")
print(result.risk_score, result.risk_level)

Webhook signature verification

from eupeak.webhooks import verify_webhook

def handler(request):
    body = request.body  # bytes
    signature = request.headers.get("x-eupeak-signature", "")

    if not verify_webhook(body, signature, os.environ["EUPEAK_WEBHOOK_SECRET"]):
        return 401, "invalid signature"

    event = json.loads(body)
    # …handle event
    return 200, "ok"

Language support

Not using TypeScript or Python? The raw REST API is fully documented under Endpoints. The OpenAPI 3.1 specification is available at https://api.eupeak.io/v1/openapi.json — you can generate a client in any language with openapi-generator.

Official Go, Rust and Java SDKs are on the roadmap. If you would like to prioritise one, let us know at support@samarkandindustries.com.