Webhook Verifier Protocol • AI Agent SDK

WebhookVerifierProtocol: Protocol for verifying inbound webhook authenticity.

WebhookVerifierProtocol

Defined in the protocols module.

AI Agent

Protocol for verifying inbound webhook authenticity.

Internet-facing bot adapters (Slack, WhatsApp, Linear, AgentMail, …) receive webhooks that must be authenticated before they become an agent run. This protocol declares the contract so the wrapper ingress can enforce verification centrally and fail-closed: an adapter that declares `PlatformCapabilities.accepts_webhooks` must expose a verifier and that verifier must pass before dispatch.

Implementations live in the `praisonai-bot package (praisonai_bot.bots`) and wrap an HMAC comparison over the raw request body.

Diagram

Allow

Deny

Event Trigger

Hook: WebhookVerifierProtocol

Decision

Process

Block

Methods

Usage

python
class SlackVerifier:
        def verify(self, *, headers, raw_body):
            ...

Source

View on GitHub

praisonaiagents/bots/protocols.py at line 306


Related Documentation