Lookahead Announcement

We’re introducing Webhook Payload V3 - a redesigned webhook structure that follows industry standards and provides better developer experience. This update affects how you receive trigger events via webhooks and Pusher.

What’s Changing?

New Webhook Structure

We’re adopting the Standard Webhooks specification for better consistency and reliability.

Headers

A new header will identify the webhook version:

x-composio-webhook-version: V3

Payload Structure

The payload structure is being reorganized to separate Composio metadata from trigger data:

Before (V2):

1{
2 "log_id": "log_TpxVOLXYnwXZ",
3 "timestamp": "2025-12-23T13:06:07.695Z",
4 "type": "gmail_new_gmail_message",
5 "data": {
6 "connection_id": "a1b2c3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d",
7 "connection_nano_id": "ca_xYz9AbCdEfGh",
8 "trigger_nano_id": "ti_JZFoTyYKbzhB",
9 "trigger_id": "7f8e9d0c-1b2a-3c4d-5e6f-7a8b9c0d1e2f",
10 "user_id": "usr-demo-12a3b4c5...",
11 // ... actual trigger data mixed with metadata
12 }
13}

After (V3):

1{
2 "id": "msg_a1b2c3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d",
3 "timestamp": "2025-12-23T13:06:07.695Z",
4 "type": "composio.trigger.message",
5 "metadata": {
6 "log_id": "log_TpxVOLXYnwXZ",
7 "trigger_slug": "GMAIL_NEW_GMAIL_MESSAGE",
8 "auth_config_id": "ac_aCYTppZ5RsRc",
9 "connected_account_id": "ca_cATYssZ5RrSc",
10 "trigger_id": "ti_JZFoTyYKbzhB",
11 "user_id": "pg-test-86c9fc84..."
12 },
13 "data": {
14 // Clean trigger data without Composio metadata
15 }
16}

Key Improvements

  1. Metadata Separation: Composio-specific fields (connection IDs, trigger IDs, user IDs) are now in a dedicated metadata object
  2. Clean Data: The data field now contains only the actual trigger payload without infrastructure metadata
  3. Standardized Type Field: The type field now follows a consistent format (composio.trigger.message) instead of trigger-specific names like gmail_new_gmail_message
  4. Trigger Slug in Metadata: The trigger slug (e.g., GMAIL_NEW_GMAIL_MESSAGE) is now available in metadata.trigger_slug for easy identification
  5. Standards Compliance: Follows Standard Webhooks specification for better interoperability
  6. Consistent Structure: Same payload structure for both webhooks and Pusher channels

Migration Guide

Updating Your Webhook Handlers

If you’re accessing Composio metadata fields, update your code:

1# Before (V2)
2trigger_type = payload["type"] # "gmail_new_gmail_message"
3connection_id = payload["data"]["connection_id"]
4trigger_id = payload["data"]["trigger_id"]
5message_text = payload["data"]["message_text"]
6
7# After (V3)
8trigger_type = payload["type"] # "composio.trigger.message"
9trigger_slug = payload["metadata"]["trigger_slug"] # "GMAIL_NEW_GMAIL_MESSAGE"
10connection_id = payload["metadata"]["connected_account_id"]
11trigger_id = payload["metadata"]["trigger_id"]
12message_text = payload["data"]["message_text"]
1// Before (V2)
2const triggerSlug = payload.type; // "gmail_new_gmail_message"
3const connectionId = payload.data.connection_id;
4const triggerId = payload.data.trigger_id;
5const messageText = payload.data.message_text;
6
7// After (V3)
8const webhookType = payload.type; // "composio.trigger.message"
9const triggerSlug = payload.metadata.trigger_slug; // "GMAIL_NEW_GMAIL_MESSAGE"
10const connectionId = payload.metadata.connected_account_id;
11const triggerId = payload.metadata.trigger_id;
12const messageText = payload.data.message_text;

Checking Webhook Version

You can detect the webhook version from headers:

1webhook_version = headers.get("x-composio-webhook-version", "V2")
2if webhook_version == "V3":
3 # Use new structure
4 metadata = payload["metadata"]
5else:
6 # Use old structure
7 metadata = payload["data"]

Rollout Timeline

  • December 2025: V3 released, opt-in via project settings
  • February 15, 2026: All new organizations will default to V3
  • Existing organizations: Continue using V2 by default, can opt-in to V3 anytime

How to Opt-In

  1. Go to your project settings in the Composio dashboard
  2. Navigate to the Webhooks section
  3. Select “Webhook Payload Version: V3”
  4. Update your webhook handlers to use the new structure
  5. Test thoroughly before enabling in production

Organizations created before February 15, 2026 will remain on V2 by default. You can switch to V3 at your convenience.

Organizations created on or after February 15, 2026 will use V3 by default.

Benefits

  • Better DX: Clear separation between metadata and actual trigger data
  • Standards Compliance: Follows industry-standard webhook specifications
  • Consistency: Same structure across webhooks and Pusher channels
  • Future-Proof: Built on established standards for long-term compatibility

Need Help?

If you have questions about migrating to V3 or need assistance: