When deploying Marketing Cloud Next (MCN) flows from a sandbox environment (UAT) to Production or QA using change sets, the deployment fails with errors such as:
Field integrity exception: unknown
Invalid cross-reference errors
Deployment validation failures
An unexpected error occurred. Please include this ErrorId if you contact support
Marketing Cloud Next flows store hardcoded record IDs from the org where they were originally built. When deployed via change set to a different org (e.g., UAT → Production), these IDs aren't automatically translated, causing the deployment to fail.
However, Apex-typed values (serialized JSON blobs) inside Apex action input parameters are treated as opaque and are never scanned or remapped during deployment. As a result, the source-org IDs deploy verbatim, and the target org rejects them as invalid cross-references.
This is expected platform behavior for MCN flows containing consent actions and form submission triggers. The IDs must be handled manually.
This issue can be resolved depending on how the change set is being created and deployed
Change Sets created within the Salesforce UI:
Review the view source file in the Outbound Change Set to identify where Record IDs are used within the Metadata.
In the Flow remove source of the Records IDs. i.e remove the segment, email content, email senders, etc Save as Draft ( there will be errors on the flow, but will save with those errors).
Recreate the Outbound Change Set and upload, deploy as usual.
CLI Retrieve and Deploy:
Review XML file created by the Sandbox to identify the Record IDs that are being referenced.
Remove the Record IDs but leave the tags for that specific source. Save the file.
Deploy as normal
005391241

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.