Claimful docs
TypeScript SDK
Server-side helpers for TypeScript integrations.
Install
pnpm add @claimful/sdk or npm install @claimful/sdk. Create a server-side Claimful client with the merchant API key.
Writes
Idempotency keys are generated by the SDK for every write request and reused across retry attempts. Callers may provide a valid key when they need caller-side replay control.
Quote contract
Quote requests use protectionProgramId, orderId, and orderAmountCents in SDK code. The SDK serializes those to the Laravel API fields protection_program_id, order_id, and order_amount_cents.
Webhooks
Use verifyWebhook(rawBody, signatureHeader, secret) with the exact raw request bytes. The helper verifies the ADR 0009 signature envelope and 300-second replay window.