Supported PushTopic Queries

All custom objects are supported in PushTopic queries. A subset of standard objects is supported in PushTopic queries, including:
  • Account
  • Campaign
  • Case
  • Contact
  • ContractLineItem
  • Entitlement
  • Lead
  • LiveChatTranscript
  • MessagingSession
  • Opportunity
  • Quote
  • QuoteLineItem
  • ServiceAppointment
  • ServiceContract
  • Task
  • UserServicePresence
  • WorkOrder
  • WorkOrderLineItem

It’s possible that not all objects are available in your org. Some objects require specific feature settings and permissions to be enabled.

Tasks that are created or updated using these methods don’t appear in task object topics in the streaming API.

  • Lead conversion
  • Entity merge
  • Mass email contacts/leads

Important

Also, the standard SOQL operators and most SOQL statements and expressions are supported. Some SOQL statements aren’t supported. See Unsupported PushTopic Queries.

The following are examples of supported SOQL statements.
  • Custom object
    SELECT Id, MyCustomField__c FROM MyCustomObject__c
  • Standard objects (can include custom fields)
    • Account
      SELECT Id, Name FROM Account WHERE NumberOfEmployees > 1000
    • Campaign
      SELECT Id, Name FROM Campaign WHERE Status = 'Planned'
    • Case
      SELECT Id, Subject FROM Case WHERE Status = 'Working' AND IsEscalated = TRUE
    • Contact
      SELECT Id, Name, Email FROM Contact;
    • Lead
      SELECT Id, Company FROM Lead WHERE Industry = 'Computer Services'
    • Opportunity
      SELECT Id, Name, Amount FROM Opportunity WHERE CloseDate < 2011-06-14
    • Task
      SELECT Id, Subject, IsClosed, Status FROM Task WHERE isClosed = TRUE

Considerations

System fields—In general, changes in fields that the system populates, such as LastModifiedDate and LastActivityDate, don’t trigger notifications.

Task records—Check out these considerations for task records.

  • To receive notifications on the IsClosed field, the subscriber must subscribe to the Status field referenced in the query.
  • To receive notifications on the WhoCount and WhatCount fields, the subscriber must subscribe to the WhoId and WhatId fields. Subscriptions based only on the WhoCount or WhatCount fields aren’t supported.
  • To receive notifications for task record deletions, the subscribed user must have the View All Data or the Modify All Data permission when the organization-wide sharing setting for activities is private.

Custom picklist values—If the PushTopic query references a custom picklist with a global value set, the PushTopic notification message includes the API name of the value instead of the label. For example, you have a custom picklist field with the name Colour__c. One picklist value has the API name of RD and the label of Red. The PushTopic query references the Colour__c picklist field: SELECT Id, Colour__c, Salutation FROM Contact. The PushTopic notification message contains the Colour__c field with this value: RD.