GA4 Integration
Send conversion events to Google Analytics 4 using the Measurement Protocol. TrolleyShield fires custom events when calls and form submissions are analyzed, giving you visibility into lead quality directly in GA4.
Requirements
- Call Pro or Call Agency plan
- A GA4 property with a Measurement Protocol API secret
Setup
1. Get Your GA4 Credentials
- Go to your GA4 property in Google Analytics
- Navigate to Admin → Data Streams → (your stream)
- Copy the Measurement ID (starts with
G-) - Under Measurement Protocol API secrets, create a new secret and copy it
2. Configure in TrolleyShield
- Go to Settings → Integrations in the TrolleyShield dashboard
- Find the Google Analytics section
- Enter your Measurement ID (e.g.,
G-XXXXXXXXXX) - Enter your API Secret
- Save
Events Sent
TrolleyShield sends four custom event types to GA4:
call_lead
Fired when a call is analyzed with a classifiable intent.
| Parameter | Type | Description |
|---|---|---|
call_intent | string | qualified_lead, general_inquiry, existing_customer, spam, wrong_number, job_seeker, vendor, or incomplete |
call_confidence | number | AI confidence score (0-100) |
call_duration_seconds | number | Call duration |
call_source | string | Where the call originated |
caller_city | string | Caller's city |
caller_state | string | Caller's state |
is_first_time_caller | boolean | Whether this is a new caller |
lead_score | number | Numeric score: high=100, medium=70, existing=50, low=30 |
call_conversion
Fired when a high-intent call triggers a conversion.
| Parameter | Type | Description |
|---|---|---|
value | number | Conversion value (if set) |
currency | string | Currency code (default: USD) |
call_source | string | Call origin |
form_lead
Fired when a form submission is analyzed as legitimate or suspicious.
| Parameter | Type | Description |
|---|---|---|
form_intent | string | legitimate or suspicious |
form_confidence | number | AI confidence score (0-100) |
behavioral_score | number | Client-side behavioral score |
site_url | string | Website URL |
form_id | string | Form identifier |
lead_score | number | Numeric score: legitimate=100, suspicious=30 |
form_spam_blocked
Fired when a form submission is classified as spam or bot.
| Parameter | Type | Description |
|---|---|---|
spam_type | string | suspicious or bot_detected |
site_url | string | Website URL |
Viewing Events in GA4
Events appear in GA4 within 24 hours of being sent. You can find them under:
- Reports → Realtime (for recent events)
- Reports → Engagement → Events (for historical data)
- Explore (for custom reports and funnels)
Create custom GA4 audiences based on call_lead and form_lead events to build remarketing lists of high-intent visitors.
Troubleshooting
Events Not Appearing
- GA4 Measurement Protocol events can take up to 24 hours to appear in standard reports (Realtime is faster)
- Verify your Measurement ID and API Secret are correct in Settings
- The Measurement Protocol returns
204 No Contenteven for invalid payloads — a successful response doesn't guarantee the event was processed
Server-Side Client IDs
Since TrolleyShield fires events server-side, a generated client_id is used instead of the visitor's GA4 cookie. This means these events may not be stitched to the same user session in GA4 unless you're using User-ID or other identity resolution.