@walayer/integrations-core
v0.1.0
Published
Shared, credential-free core for the WALayer n8n / Make / Zapier integrations
Readme
@walayer/integrations-core
The platform-agnostic half of the WALayer n8n / Make / Zapier integrations (FR-206).
Everything here is pure and dependency-free:
| Module | What it holds |
|---|---|
| requests.ts | One builder per operation → { method, path, headers, query, body }. No credential ever passes through them: the host platform attaches Authorization from its own credential store. |
| operations.ts | The operation catalogue — every exposed operation pinned to a route in docs/04-api-spec.md, plus the §8.4 event catalogue. |
| errors.ts | WALayer's { error: { code, … } } envelope → a message worth showing a human, with a retry-after and a retryability classification. ACK_TIMEOUT / SEND_UNKNOWN are never retryable. |
| webhook.ts | createVerifier(verifyWebhook) — wraps the official SDK's HMAC check with header parsing, the replay window and a fail-closed policy. The crypto is not re-implemented. |
| idempotency.ts | Derives a stable Idempotency-Key from identifiers a host platform keeps constant across its own retry. |
node --test "test/**/*.test.ts" # 56 tests, nothing to install
../../node_modules/.bin/tsc --noEmit -p tsconfig.json # typecheck
npm run build # ESM → dist/, CommonJS → dist/cjs/The dual build exists because n8n compiles its community nodes to CommonJS and the Zapier runtime is CommonJS, while the rest of this repository is ESM.
