| title | Quickstart |
|---|---|
| description | Start scheduling webhooks in under 2 minutes |
This guide walks you through setting up Posthook, connecting your local environment, and sending your first scheduled hook.
Prefer an interactive guide? You can follow this same walkthrough interactively in the [Posthook Dashboard](https://posthook.io/app/home).Connect your local development server to Posthook using the CLI. This lets you receive webhooks locally without tunneling tools like ngrok.
npx posthook loginyarn dlx posthook loginpnpm dlx posthook loginYou will be prompted to enter your API Secret Key. You can find this in the Settings page of your project in the Dashboard.
Start the Posthook listener to forward webhooks to your local application.
npx posthook listen --forward http://localhost:3000Replace http://localhost:3000 with the base URL of your local server.
Install an official SDK for a streamlined experience. You can also use curl directly.
npm install @posthook/nodepip install posthook-pythongo get github.com/posthook/posthook-goIn a new terminal, schedule a test webhook to fire in 5 seconds.
import Posthook from '@posthook/node';
const posthook = new Posthook('phk_your_api_key');
const hook = await posthook.hooks.schedule({
path: '/webhooks/posthook/send-reminder',
postIn: '5s',
data: {
user_id: 'usr_123',
reminder_id: 'rem_456'
}
});
console.log('Scheduled:', hook.id);from posthook import Posthook
client = Posthook("phk_your_api_key")
hook = client.hooks.schedule(
path="/webhooks/posthook/send-reminder",
post_in="5s",
data={
"user_id": "usr_123",
"reminder_id": "rem_456"
}
)
print("Scheduled:", hook.id)client, _ := posthook.NewClient("phk_your_api_key")
hook, _, _ := client.Hooks.Schedule(context.Background(), &posthook.HookScheduleParams{
Path: "/webhooks/posthook/send-reminder",
PostIn: "5s",
Data: map[string]string{
"user_id": "usr_123",
"reminder_id": "rem_456",
},
})
fmt.Println("Scheduled:", hook.ID)curl -X POST https://api.posthook.io/v1/hooks \
-H "Content-Type: application/json" \
-H "X-API-Key: $POSTHOOK_API_KEY" \
-d '{
"path": "/webhooks/posthook/send-reminder",
"postIn": "5s",
"data": {
"user_id": "usr_123",
"reminder_id": "rem_456"
}
}'You can find your API Key in the Settings page of your project in the Dashboard.
Check your posthook listen terminal. You should see the hook arrive when it fires:
2026-01-01 12:00:00 [200 OK] POST /webhooks/posthook/send-reminder
Open the Activity page in the Dashboard. You can inspect the full payload, view delivery timing, and check response details for any hook.
Understand the full hook lifecycle from scheduling to delivery. Handle deliveries in your app with framework-specific examples. Verify the `Posthook-Signature` to ensure requests are genuine. Explore the full API to schedule, list, and manage your hooks.