Repository navigation
Conversation
🚀 Package Preview Available!Install this PR's preview build with npm: npm i @base44-preview/sdk@0.8.53-pr.319.3e74a61Prefer not to change any import paths? Install using npm alias so your code still imports npm i "@base44/sdk@npm:@base44-preview/sdk@0.8.53-pr.319.3e74a61"Or add it to your {
"dependencies": {
"@base44/sdk": "npm:@base44-preview/sdk@0.8.53-pr.319.3e74a61"
}
}
Preview published to npm registry — try new features instantly! |
2 of 4 tasks
ozsay
force-pushed
the
feat/platform-server-webhooks
branch
from
October 12, 2026 11:41
d85e70c to
9b2915b
Compare
🚀 Package Preview Available! (
|
3 of 4 tasks
ozsay
force-pushed
the
feat/platform-server-webhooks
branch
from
October 12, 2026 12:01
9b2915b to
f0a1592
Compare
verifyEvent checks Standard Webhooks v1a (Ed25519, WebCrypto) signatures and returns a typed event; handleChallenge answers the activation probe. Event types are generated from the published JSON Schemas. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
createHandler returns a fetch-style route handler that verifies, answers the activation challenge, dispatches per event type and maps outcomes to status codes, with onEvent/onSuccess/onError callbacks. verifyEvent stays for callers who dispatch themselves. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ozsay
force-pushed
the
feat/platform-server-webhooks
branch
from
October 12, 2026 12:08
f0a1592 to
75a4b1c
Compare
ozsay
added this pull request to stack #321
October 12, 2026 12:08
…tory createBase44PlatformServer keeps only the shared serverUrl/apiKey. verifyEvent and createHandler now require publicKeys in their options. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #316 (base is that branch; retarget to
mainonce it merges).Summary
platform.webhooks.verifyEvent(rawBody, headers, { publicKeys, toleranceSeconds? })verifies Standard Webhooksv1a(Ed25519) signatures with WebCrypto only, so it runs on Node 20+, Deno, Bun and edge runtimes. Returns a typedWebhookEvent; nothing is parsed before the signature passes. Makes no network calls.platform.webhooks.createHandler({ publicKeys, on, onEvent, onSuccess, onError, toleranceSeconds? })returns a fetch-style(request: Request) => Promise<Response>:webhook.test.v1activation challenge itself (callbacks never see the probe);onEvent, then the per-type handler fromon(event narrowed per key), thenonSuccess;onSuccess/onErrormay return aResponseto override the default.WebhookVerificationError(400) vsWebhookConfigurationError(missing/malformed keys, 500).createBase44PlatformServertakes only the sharedserverUrl/apiKey; each module handles its own settings. The webhooks module takespublicKeyson every call that verifies (verifyEvent,createHandler); there is no module-level init/config. No env reads, no key fetching.datainterfaces andWebhookEventMapare generated from the schemas published at https://base44.com/webhooks/schemas bynpm run generate:webhooks(event list inscripts/webhook-event-types.json;--from <dir>for a local apper checkout).engines.node >=20, README section, two examples (verifyEvent+switch, andcreateHandler), andjson-schema-to-typescriptas a devDependency.Test plan
npm test -w @base44/platform(type tests incl. per-handler narrowing, 63 unit tests incl. tamper/relabel/stale/rotation/config and handler status/callback ordering, typedoc, packed-package runtime and declaration checks)npx eslint packages/platform🤖 Generated with Claude Code