WorkflowOutboundMessage defines an outbound integration action that sends selected Salesforce record fields to a designated endpoint as a SOAP message, an XML-based message format. The definition controls the destination, payload fields, sending identity, and settings for API calls back to Salesforce.
Outbound messages can be used by workflow rules and approval processes. The action definition is distinct from the conditions that initiate delivery: creating or deploying an outbound message does not create a firing rule. Definitions belong to the object-scoped Workflow component's outboundMessages collection.
Key Elements
| Element | What the Element Controls |
|---|---|
fullName |
Required developer name used for API access and action references. It must be unique, begin with a letter, contain only alphanumeric characters and underscores, and have no trailing underscore or consecutive underscores. |
name |
Required component name shown to users. An invoking workflow action references the developer name, not this display name. |
endpointUrl |
Required URL that receives the SOAP payload. |
fields |
Repeatable list of named record fields to send. Use a separate fields element for each field. Selected custom fields can create dependencies on CustomField components. |
integrationUser |
Required named reference to the Salesforce user under which the message is sent. It is not a username or password for the external endpoint. |
includeSessionId |
Required Boolean. When true, includes a Salesforce session ID so the receiver can make API calls back to Salesforce without supplying a username and password. |
apiVersion |
Required stored API version for callbacks using the enterprise or partner Web Services Description Language (WSDL) contracts. Valid values are 8.0 and 18.0 or later. Salesforce sets it to the current API version when the message is created. |
protected |
Required Boolean controlling package-reference accessibility. When true, components created in the installing organization cannot link to or reference this component. |
useDeadLetterQueue |
When set, uses the dead letter queue for messages that fail normal delivery. Available only in organizations with dead letter queue permissions enabled. |
Behavior and Constraints
For workflow-driven delivery, WorkflowRule.active, the rule's criteria, and triggerType govern invocation. Criteria are expressed through criteriaItems or formula. References in WorkflowRule.actions represent immediate actions; references in WorkflowTimeTrigger.actions, under the rule's workflowTimeTriggers, support time-based execution.
A WorkflowActionReference that invokes an outbound message uses type set to OutboundMessage. Its name identifies the action's developer name, corresponding to the outbound message's fullName, rather than its display name.
Consider endpointUrl, fields, integrationUser, and includeSessionId together. The endpoint determines where data goes, and the repeatable fields list determines which record data leaves Salesforce. The integration user establishes the Salesforce sending identity. Enabling includeSessionId sends an authentication credential to the receiver in addition to record data; it does not configure authentication to the receiving endpoint.
protected restricts which components can reference the action after package installation. It does not authenticate the endpoint or protect the transmitted payload.
apiVersion is part of the integration contract, not merely the API version used to submit a metadata deployment. You can change it only through Metadata API, not through the Salesforce user interface. If a change selects a version that does not support a configured field, messages fail until the receiving service, or listener, is updated to consume the updated WSDL.
Setting useDeadLetterQueue does not enable the required organization permission. To monitor delivery status, enter Outbound Messages in Setup's Quick Find box and select Outbound Messages.
Deployment and Retrieval
In Metadata API format, outbound-message definitions appear inside the object's Workflow file in the workflows directory. Files use the .workflow suffix, with one file per standard or custom object that has workflow. For example, workflows/Custom_Object__c.workflow can contain outbound messages alongside rules and other workflow actions.
For a manifest-based retrieval of all workflow components, specify Workflow as the type and * as the member. Retrieve the object's workflow metadata when looking for its outboundMessages definitions rather than expecting a separate outbound-message file.
The invoking action reference, the outbound-message definition, and its selected fields are separate dependencies. Deployment scope depends on the actual references and the destination organization's configuration. In particular, inspect the selected custom fields, the sending-user reference, and the endpoint configuration separately from the rule that invokes the action.
For deletion-impact analysis, check more than workflow rules. Nested action references can also occur in ApprovalProcess and EntitlementProcess. Removing or changing a rule does not account for those other possible consumers of the outbound-message definition.
Relationships
Workflow contains the definition through outboundMessages. Invoking components identify the action through nested name elements, while the definition's fields collection identifies payload fields. These connections describe possible dependencies, not proof that a particular action is used in an organization. Separately, integrationUser names a Salesforce user as the sending identity.
References
-
CustomField:fields.
Referenced By
-
ApprovalProcess:namein nested action references. -
EntitlementProcess:namein nested action references. -
Workflow:namein nested action references. -
WorkflowRule:namein action references, including immediate and time-triggered actions.
Reported Issues
- Repeated delivery does not necessarily mean the workflow rule fired repeatedly. In a 2013 case, repeated messages and "Premature end of file" errors were traced to an incorrectly encoded acknowledgement from the listener. The accepted explanation described at-least-once delivery, retries for up to 24 hours, and possible redelivery even after the listener sent a valid acknowledgement. Under that reported model, receivers need idempotent processing, meaning repeated receipt does not repeat side effects, or deduplication using message IDs. The XML parsing failure concerned the listener's response, not necessarily a selected outbound field. See the repeated-delivery discussion.
-
A receiver that requires HTTP Basic authentication may need a different integration design. A 2013 answer reported that outbound-message request headers could not be configured for Basic authentication. It proposed Apex callouts or a proxy as alternatives. Those were proposed designs, not authentication settings on this metadata type, and
includeSessionIdshould not be interpreted as Basic authentication support. See the Basic authentication discussion. -
The listener's operating-system identity can explain failures limited to one hosting mode. In a 2014 report, "SOAP response was a nack" occurred when Tomcat ran as a Windows service, although the same application worked from the command line. Correcting the Windows service's running-user permissions resolved the issue. That external service account was distinct from the Salesforce
integrationUser. See the Windows service permissions report. -
Generating receiver code from multiple outbound-message WSDLs can cause naming collisions. A 2015 discussion involving Lead and Opportunity payloads identified overlapping SOAP wrapper names, including
notificationsandNotification, with payload-specific notification types. Separate generated namespaces and handler implementations were proposed for .NET. The discussion did not establish that the WSDLs could safely be merged into one contract. See the multiple-WSDL discussion. -
A missing outbound-message dependency may be found inside the object's workflow file. In a 2012 deployment discussion, the accepted answer directed the administrator to retrieve the object's
Workflowmetadata, where rules and actions share a.workflowfile, rather than look for a separate outbound-message file. See the workflow retrieval discussion. -
A REST "NOT_FOUND" response can indicate use of the wrong API route rather than an unsupported type. In a 2017 report, the request targeted the standard data API's
sobjects/WorkflowOutboundMessageroute. The accepted answer demonstrated access through the Tooling API'stooling/sobjects/WorkflowOutboundMessageroute. See the Tooling API endpoint discussion. -
Searching by endpoint URL may require retrieving full workflow metadata. In a 2018 discussion,
listMetadataresults did not contain the endpoint URL. An answer reported that querying the Tooling API metadata field was limited to one result at a time and suggested exporting workflow definitions and searching their contents instead. See the endpoint inventory discussion.
Common Questions
How do I retrieve WorkflowOutboundMessage metadata?
Retrieve the object's Workflow component. Its .workflow file contains the outboundMessages collection. To retrieve all workflow components through a manifest, use type Workflow with member *.
Why doesn't my deployed outbound message fire?
The definition alone does not establish an invocation. For workflow-driven delivery, check the action reference's type and developer-name reference, then the rule's active setting, criteria, and trigger conditions. Also distinguish immediate actions from time-triggered actions.
Does includeSessionId authenticate the outbound message to my endpoint?
No. It includes a Salesforce session ID for API calls back to Salesforce. It is not an endpoint login setting, and integrationUser identifies the Salesforce sending user rather than an external service account.
How do I change the API version of an outbound message?
Change its stored apiVersion through Metadata API; the Salesforce user interface cannot modify it. If the change selects a version that does not support a configured field, messages fail until the listener consumes the updated WSDL.
Why is my listener receiving the same outbound message more than once?
A reported delivery model allows retries and possible redelivery even after a listener sends a valid acknowledgement. Repeated receipt therefore does not prove repeated rule execution. Inspect the acknowledgement response and use idempotent processing or message-ID deduplication.