I have a Requirement where We need to Create Customer Journey in Dynamics 365 Customer Insights Using Power Automate Flow.
For that I have Followed the Below Steps:
Step 1) Create a Journey Record from Power Automate in Draft State. For Draft State Journey I have Used below Json:
{
"actions": {
"d2ed6678-7e54-404d-a337-7adfbb4b8fed": {
"displayName": "",
"id": "d2ed6678-7e54-404d-a337-7adfbb4b8fed",
"parameters": {
"complianceSettingsId": "7f4a6355-1811-4cde-bde3-fee8c85f56b1",
"contentId": "b1627228-63b8-ef11-b8e8-7c1e52011131",
"contentReadyToSend": true,
"messageDesignation": 534120000,
"persistedUIState": {
"cachedEmailEntity": {
"createdon": "2024-12-12T08:29:10Z",
"modifiedon": "2024-12-12T08:29:36Z",
"msdynmkt_name": "Email 1",
"msdynmkt_subject": "asdfasdasd",
"statecode": 0,
"statuscode": 2
},
"errors": [
],
"links": [
{
"name": " BUY IT NOW",
"value": "<span style=\"font-family:Arial,Helvetica,sans-serif;display:inline-block;min-width:1px\"> BUY IT NOW</span>"
},
{
"name": "KEEP SHOPPING",
"value": "<span style=\"font-family:Arial,Helvetica,sans-serif;display:inline-block;min-width:1px\">KEEP SHOPPING</span>"
},
{
"name": "Unsubscribe",
"value": "Unsubscribe"
}
]
},
"placeholderBindings": {
"CompanyAddress": {
"binding": {
"inputs": {
"sourceType": {
"value": "Default"
}
},
"outputPath": "companyaddress",
"outputType": "unspecified",
"source": "LegalDataSource"
},
"category": "general",
"defaultValue": null,
"isInternal": false,
"title": "CompanyAddress",
"touched": true,
"type": [
"null",
"string"
]
},
"PreferenceCenter": {
"binding": {
"inputs": {
"sourceType": {
"value": "Default"
}
},
"outputPath": "preferencescenterurl",
"outputType": "unspecified",
"source": "LegalDataSource"
},
"category": "general",
"defaultValue": null,
"isInternal": false,
"title": "PreferenceCenter",
"touched": true,
"type": [
"null",
"string"
]
}
},
"placeholderBindingsOriginal": {
"CompanyAddress": {
"binding": {
"inputs": {
"sourceType": {
"value": "Default"
}
},
"outputPath": "companyaddress",
"outputType": "unspecified",
"source": "LegalDataSource"
},
"category": "general",
"defaultValue": null,
"isInternal": false,
"title": "CompanyAddress",
"touched": true,
"type": [
"null",
"string"
]
},
"PreferenceCenter": {
"binding": {
"inputs": {
"sourceType": {
"value": "Default"
}
},
"outputPath": "preferencescenterurl",
"outputType": "unspecified",
"source": "LegalDataSource"
},
"category": "general",
"defaultValue": null,
"isInternal": false,
"title": "PreferenceCenter",
"touched": true,
"type": [
"null",
"string"
]
}
},
"purposeId": "10000000-0000-0000-0000-000000000003",
"recipient": {
"binding": {
"inputs": {
"sourceType": {
"value": "contact"
}
},
"outputPath": "emailaddress1",
"outputType": "unspecified",
"source": "CdsProfileDataSource"
},
"category": "general",
"defaultValue": null,
"isInternal": true,
"title": null,
"touched": true,
"type": [
"null",
"string"
]
},
"topicId": null
},
"runAfter": {
},
"type": "Email"
}
},
"contentVersion": "1.0.0.0",
"exitCriteria": {
"exitEvents": [
]
},
"goal": null,
"journeyUiFeatureFlags": {
"clientUserAgentDetails": true,
"emailLinkTrackingV2": false,
"uniqueLinkIds": true
},
"name": "Journey 15",
"targetEntityLogicalNames": [
"contact"
],
"timeZoneCode": 190,
"timeZoneWindowsName": "India Standard Time",
"trigger": {
"audience": "bc2befbd-96be-ef11-b8e8-7c1e52011131",
"exclusionSegments": [
],
"parameters": {
"startTime": "2025-01-07T09:30:00.000Z"
},
"type": "Ongoing"
},
"type": 1,
"typeName": "scheduled",
"uiMetadata": {
"creationEndTime": "2025-01-07T08:13:51.164Z",
"creationStartTime": "2025-01-07T08:13:16.371Z",
"fromCopilot": false
}
}
Step 2) Update a Row in Power Automate to Update the Journey Status as Publishing. IN this Step I have Added One more Field That is populated during Publishing State of Journey i.e. Flags as
["ChannelResolvesDataDemandEnabled","EnableClientUserAgentDetails","EnableUniqueLinkIds"]
Step 3) In the Last Step I have Added one more update Step in Power Automate to Update Journey Status as Live.
In between I have also added 5 minutes delay in Each step as Journey Takes time during State Change.
When Our Journey Is in live State Contacts are not Moving into Journey. Also If we Again do some changes in Journey and Then Republish it from Designer the it works fine as expected:
The Main Cause for that might be Some Background Flows that is created when we create and Publish Journey using Designer.
But When we create Journey and Try to Publish it using Power Automate ; we are just changing it's status or state code.
Can Anyone Suggest the Exact Process to Create And Publish Realtime Customer Journey Using Power Automate?