Workspace Tab

📡 Platform Events Guide

What It Does

The Platform Events tab lets you subscribe to Salesforce Platform Events and Change Data Capture (CDC) channels directly from TrackForcePro. See events arrive in real time as they're published from your org, integrations, or custom Apex code. No Apex subscriber required — just subscribe and watch the feed. Perfect for monitoring custom event integrations, debugging event flows, and capturing intermittent events that are hard to reproduce in Setup.

Why Use It

Platform Events in Salesforce typically require Apex code to subscribe and process events. TrackForcePro gives you:

  • No Code Required — Subscribe and monitor without writing Apex. Perfect for testing and debugging.
  • Real-Time Visibility — Watch events flow in as they're published. Catch intermittent issues as they happen.
  • Integration Debugging — Verify that external systems are publishing events correctly.
  • Change Data Capture Monitoring — Track record changes across your org in real time.
  • Event Payload Inspection — View full JSON payloads with syntax highlighting and collapsible sections.
  • Replay ID Capture — Get replay IDs for implementing event recovery in your Apex code.

How to Access

Open the TrackForcePro workspace popup and click the Platform Events tab (📡 icon) in the main tab bar. The tab displays an available events/channels list on the left and a real-time event log on the right.

Subscribing to Events

To start monitoring events:

  1. Open the Platform Events tab
  2. Browse the Available Channels list on the left, or search by name
  3. Click any Platform Event or CDC channel to select it
  4. Click the Subscribe button
  5. The event log on the right opens and begins showing events in real time

Once subscribed, events appear in the log immediately as they're published. You can subscribe to multiple channels simultaneously by selecting each one and clicking Subscribe.

Multi-Channel Subscriptions: Subscribe to multiple Platform Events and CDC channels at the same time. The unified event log shows all events in chronological order, color-coded by channel for easy identification.

Event Log

The event log displays a real-time feed of events from your subscribed channels. Each log entry shows:

Field What It Shows
Timestamp When the event was published (in your local timezone)
Channel Name Which Platform Event or CDC channel the event came from
Replay ID Unique identifier for the event (used in Apex for event replay subscriptions)
Payload Preview First-line summary of event data
Event Status Green checkmark for successful, red X for errors or failures

Event Log Features

  • Chronological Order — Events displayed in reverse chronological order (newest first)
  • Click to Expand — Click any event to expand and view its full JSON payload with syntax highlighting
  • Filter by Channel — Click channel pills to filter log to specific channels
  • Auto-Scroll — Log automatically scrolls as new events arrive. Pause to lock the view.
  • Clear Log — Clear all events from the log to start fresh

Change Data Capture (CDC)

Change Data Capture is a special type of Salesforce event that publishes whenever a record is created, updated, or deleted. CDC subscriptions let you monitor real-time data changes across your org without polling.

What CDC Events Show

  • Which fields changed — Before/after values for each modified field
  • Who made the change — User ID and timestamp of the modification
  • Record ID — The Salesforce ID of the changed record
  • Operation type — Created, Updated, or Deleted
  • Change number — Sequential number for ordering events across objects

Supported Objects

CDC is available for all custom objects and most standard objects (Account, Contact, Opportunity, Lead, Case, etc.). Check your Salesforce edition to see which standard objects support CDC in your org.

Common CDC Use Cases

  • Debug data sync issues — See exactly which fields changed during a problematic sync
  • Monitor record deletions — Verify that records are being deleted as expected during cleanup jobs
  • Track high-frequency changes — Capture rapid updates that are hard to catch manually
  • Test integration workflows — Confirm that external systems are triggering record changes as designed
  • Audit sensitive field changes — Monitor when critical fields (salary, pricing, etc.) are modified and by whom
Replay for Recovery: CDC events support replay, allowing your Apex subscribers to recover and process events they may have missed. The Replay ID is shown in each event in the TrackForcePro log.

Event Payload Inspection

Each event carries a JSON payload with detailed information. Expand any event in the log to see the full payload formatted with syntax highlighting:

Example CDC Payload

{
  "event": {
    "replayId": "5004000",
    "type": "com.salesforce.cdc.dcapi.Event",
    "created": "2026-03-27T14:32:45.000+0000"
  },
  "sobject": {
    "Account": {
      "Id": "001xx000000001",
      "Name": "Updated Corp",
      "BillingCity": "San Francisco"
    },
    "ChangeEventHeader": {
      "entityName": "Account",
      "recordIds": ["001xx000000001"],
      "changeType": "UPDATE",
      "changedFields": ["Name", "BillingCity"],
      "commitTimestamp": 1711529565000,
      "commitUser": "005xx000000001"
    }
  }
}

Payload Structure

  • event — Metadata about the event (replay ID, type, creation timestamp)
  • sobject — The actual data: record fields and a ChangeEventHeader with change details
  • ChangeEventHeader — Special field containing: entity name, record IDs, change type (CREATE/UPDATE/DELETE), list of changed fields, timestamp, and user ID

LMS (Lightning Message Service)

LMS (Lightning Message Service) channels are now integrated into the LWC Explorer on-page overlay, not in the Platform Events tab. To manage LMS channels:

  1. Open any Salesforce page with Lightning Web Components
  2. Use your configured keyboard shortcut or click the LWC Explorer button to open the overlay
  3. Click the LMS type pill to view LMS channels
  4. Select a channel to view schema, publish/subscribe, and activity feed

LMS channels are live, real-time message buses for Lightning components. Monitor which components are publishing and subscribing to which channels, and test channel messages directly from the LWC Explorer.

Tips & Best Practices

  • Monitor integrations in real time — Leave a Platform Event subscription running to verify that external systems are publishing events as expected.
  • CDC for debugging data sync issues — See exactly which fields changed and in what order when data isn't syncing correctly.
  • Capture intermittent events — Some events are hard to reproduce manually. Leave TrackForcePro open with a subscription running to catch events as they happen.
  • Use Replay IDs in Apex code — The Replay ID shown in each event can be used in Apex CdcEventStore.getEventsByReplayId() calls to implement event recovery.
  • Filter by timestamp for debugging — If many events are flowing, note the timestamp of the event you're interested in and filter the log to focus on that time window.
  • Export event payloads for analysis — Copy and paste event JSON into your editor or IDE for offline analysis and correlation with your code.
  • Subscribe while running batch jobs — Monitor CDC events while running batch Apex jobs that modify records. Verify record changes are being captured correctly.
💡 Pro Tip: Platform Events are zero-code visibility into your org's event flows. Use them to prototype event-driven workflows, debug integrations, and learn how your org's data is changing in real time.