TrustPager Docs

← Help Center

Automations

Trigger Schema Reference

How to discover what fields each automation trigger type expects, using the schema API endpoints and MCP tools, with example payloads for common trigger types.

Every automation trigger in TrustPager has a defined schema — the exact fields it expects, their types, and which are required. This reference explains how to discover those schemas via the API and MCP, and walks through the common trigger types and their payloads.

Discovering trigger schemas via the API

Rather than guessing what fields a trigger needs, you can query the schema directly.

List all trigger types:

GET /api/v1/schemas/triggers

Returns every available trigger type with a sample payload and the {{variable}} tokens you can use in trigger_data. Free (0 credits).

Get one trigger's schema:

GET /api/v1/schemas/triggers/{trigger_type}

# Example:
GET /api/v1/schemas/triggers/facebook_lead_ad

Returns the full schema for that trigger — field names, data types, required vs optional, and example values.

Via MCP:

These tools are the right starting point any time you're building a new integration or wiring up an external event source — they tell you exactly what the trigger expects before you write a line of code.

Common trigger types and their payloads

Below are the most frequently used trigger types. Exact field names and additional optional fields are always available via the schema endpoints above.

Stage Change

Fires when an opportunity moves between pipeline stages.

{
  "trigger_data": {
    "deal_id": "{{deal_id}}",
    "from_stage_id": "{{from_stage_id}}",
    "to_stage_id": "{{to_stage_id}}"
  }
}

Form Submission

Fires when a contact submits a TrustPager form. Use the trigger type form_completed.

{
  "trigger_data": {
    "form_id": "{{form_id}}",
    "contact_id": "{{contact_id}}",
    "submission_id": "{{submission_id}}"
  }
}
Deprecated trigger type: form_submitted was a legacy stub that never wired to the automation engine — no event ever fired it. It has been removed; automations that had it set were automatically migrated to form_completed (the working trigger for form submissions). New automations that try to use form_submitted get a 400 error pointing to form_completed.

New Contact Created

Fires when a contact is added to the CRM.

{
  "trigger_data": {
    "contact_id": "{{contact_id}}"
  }
}

Webhook Received

Fires when an external system sends a payload to a TrustPager incoming webhook. The full webhook body is available as trigger data. Configure incoming webhooks at https://app.trustpager.com/settings/webhooks.

Facebook Lead Ad

Fires when a new lead is submitted via a connected Facebook Lead Ad form.

{
  "trigger_data": {
    "lead_id": "{{lead_id}}",
    "form_id": "{{form_id}}",
    "page_id": "{{page_id}}",
    "full_name": "{{full_name}}",
    "email": "{{email}}",
    "phone": "{{phone}}"
  }
}

Manual

Fires when triggered explicitly — either via the UI button on an opportunity, or via the API/MCP. No required trigger data fields, though you can pass context.

{
  "trigger_data": {
    "contact_id": "{{contact_id}}"
  }
}

Using {{variable}} tokens

Variable tokens like {{contact_id}} in schema examples are placeholders — replace them with actual IDs or values when making your API call. They're used in schema docs to show you what type of value goes in each field, not as templating syntax in your request body.

Where to go next

Once you know the schema for your trigger type, you're ready to fire it. See https://trustpager.com/help-center/trigger-automations-via-api-mcp for the full walkthrough on calling the trigger endpoint and handling the response.

Tip: Schema endpoints are free (0 credits) and can be called as often as needed — they're safe to call at agent startup to build a local index of available trigger types.
← Back to Help Center Open on trustpager.com ↗