{
	"ProcessTemplates": [
		{
			"Name": "Magento to Dynamics365 - Orders",
			"Modified": "2024-07-16T10:24:57.1904048",
			"Modifier": "janne.pennanen@frends.com",
			"Tags": [
				"Magento",
				"Dynamics365"
			],
			"TemplateProcessTags": [],
			"Description": "This template process fetches orders from Adobe Commerce / Magento and inserts them into Dynamics365.",
			"Version": 1,
			"UniqueIdentifier": "986a6287-7c3f-4b21-8aec-e591682c4c98",
			"ProcessVariablesJson": "{\"Dynamics365ClientId\":{\"Value\":\"\\\"aaaaa-bbbbb-ccccc-ddddd\\\"\",\"IsSecret\":false,\"Mode\":\"text\",\"Description\":\"The client ID for Dynamics365.\"},\"Dynamics365TenantId\":{\"Value\":\"\\\"11111-22222-33333-44444\\\"\",\"IsSecret\":false,\"Mode\":\"text\",\"Description\":\"The tenant ID for Dynamics365.\"},\"Dynamics365ClientSecret\":{\"Value\":\"\\\"\\\"\",\"IsSecret\":true,\"Mode\":\"text\",\"Description\":\"The client secret for Dynamics365.\"},\"Dynamics365Url\":{\"Value\":\"\\\"https://<my-dynamics-instance>.dynamics.com\\\"\",\"IsSecret\":false,\"Mode\":\"text\",\"Description\":\"The URL to for Dynamics365 instance.\"},\"MagentoBaseUrl\":{\"Value\":\"\\\"\\\"\",\"IsSecret\":false,\"Mode\":\"text\",\"Description\":\"The base URL for Magento.\"},\"MagentoUser\":{\"Value\":\"\\\"myUsername\\\"\",\"IsSecret\":false,\"Mode\":\"text\",\"Description\":\"The username for Magento.\"},\"MagentoPassword\":{\"Value\":\"\\\"myPassword\\\"\",\"IsSecret\":true,\"Mode\":\"text\",\"Description\":\"The password for your Magento user.\"}}",
			"ProcessInfo": {
				"Process": {
					"Name": "Magento to Dynamics365 - Orders",
					"Modified": "2024-07-16T10:24:57.1904048",
					"Modifier": "janne.pennanen@frends.com",
					"TagString": null,
					"Tags": [],
					"Description": "This template process fetches orders from Adobe Commerce / Magento and inserts them into Dynamics365.",
					"Version": 1,
					"UniqueIdentifier": "5a27ab14-b300-4acb-8e0b-8daf6aeac783",
					"GraphJson": null,
					"Bpmn": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<bpmn2:definitions xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:bpmn2=\"http://www.omg.org/spec/BPMN/20100524/MODEL\" xmlns:bpmndi=\"http://www.omg.org/spec/BPMN/20100524/DI\" xmlns:dc=\"http://www.omg.org/spec/DD/20100524/DC\" xmlns:di=\"http://www.omg.org/spec/DD/20100524/DI\" id=\"sample-diagram\" targetNamespace=\"http://bpmn.io/schema/bpmn\" xsi:schemaLocation=\"http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd\"><bpmn2:process id=\"Process_1\" isExecutable=\"false\"><bpmn2:startEvent id=\"StartEvent_1\" name=\"Manual\"><bpmn2:outgoing>Flow_0737pen</bpmn2:outgoing></bpmn2:startEvent><bpmn2:task id=\"Activity_0ks7ips\" name=\"Obtain authorisation token from Magento\"><bpmn2:incoming>Flow_0737pen</bpmn2:incoming><bpmn2:outgoing>Flow_03symyo</bpmn2:outgoing></bpmn2:task><bpmn2:sequenceFlow id=\"Flow_0737pen\" sourceRef=\"StartEvent_1\" targetRef=\"Activity_0ks7ips\" /><bpmn2:exclusiveGateway id=\"Gateway_0tz7zpc\" name=\"Token received?\" default=\"Flow_0vig9jh\"><bpmn2:incoming>Flow_03symyo</bpmn2:incoming><bpmn2:outgoing>Flow_18nhiph</bpmn2:outgoing><bpmn2:outgoing>Flow_0vig9jh</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:sequenceFlow id=\"Flow_03symyo\" sourceRef=\"Activity_0ks7ips\" targetRef=\"Gateway_0tz7zpc\" /><bpmn2:task id=\"Activity_1gp43wn\" name=\"Get orders from Magento\"><bpmn2:incoming>Flow_18nhiph</bpmn2:incoming><bpmn2:outgoing>Flow_1qm8po5</bpmn2:outgoing><bpmn2:property id=\"Property_1395yje\" name=\"__targetRef_placeholder\" /><bpmn2:dataInputAssociation id=\"DataInputAssociation_1cklt14\"><bpmn2:sourceRef>DataStoreReference_0kiz3dh</bpmn2:sourceRef><bpmn2:targetRef>Property_1395yje</bpmn2:targetRef></bpmn2:dataInputAssociation></bpmn2:task><bpmn2:sequenceFlow id=\"Flow_18nhiph\" name=\"yes\" sourceRef=\"Gateway_0tz7zpc\" targetRef=\"Activity_1gp43wn\" /><bpmn2:intermediateThrowEvent id=\"Event_1sgpzth\" name=\"Throw error if obtaining token from Magento failed\"><bpmn2:incoming>Flow_0vig9jh</bpmn2:incoming><bpmn2:signalEventDefinition /></bpmn2:intermediateThrowEvent><bpmn2:sequenceFlow id=\"Flow_0vig9jh\" name=\"no\" sourceRef=\"Gateway_0tz7zpc\" targetRef=\"Event_1sgpzth\" /><bpmn2:exclusiveGateway id=\"Gateway_0xcgyrz\" name=\"Orders received?\" default=\"Flow_0ny1eo2\"><bpmn2:incoming>Flow_1qm8po5</bpmn2:incoming><bpmn2:outgoing>Flow_0ny1eo2</bpmn2:outgoing><bpmn2:outgoing>Flow_02pbox5</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:sequenceFlow id=\"Flow_1qm8po5\" sourceRef=\"Activity_1gp43wn\" targetRef=\"Gateway_0xcgyrz\" /><bpmn2:intermediateThrowEvent id=\"Event_0m2tmsv\" name=\"Throw error if getting orders from Magento failed\"><bpmn2:incoming>Flow_0ny1eo2</bpmn2:incoming><bpmn2:signalEventDefinition /></bpmn2:intermediateThrowEvent><bpmn2:sequenceFlow id=\"Flow_0ny1eo2\" name=\"no\" sourceRef=\"Gateway_0xcgyrz\" targetRef=\"Event_0m2tmsv\" /><bpmn2:scriptTask id=\"Activity_0vsfxcb\" name=\"Initialize error variable\"><bpmn2:incoming>Flow_02pbox5</bpmn2:incoming><bpmn2:outgoing>Flow_0u63m03</bpmn2:outgoing></bpmn2:scriptTask><bpmn2:sequenceFlow id=\"Flow_02pbox5\" name=\"yes\" sourceRef=\"Gateway_0xcgyrz\" targetRef=\"Activity_0vsfxcb\" /><bpmn2:subProcess id=\"Activity_122wx66\" name=\"For each order\"><bpmn2:incoming>Flow_0nnqxe0</bpmn2:incoming><bpmn2:outgoing>Flow_0qbb2hn</bpmn2:outgoing><bpmn2:multiInstanceLoopCharacteristics isSequential=\"true\" /><bpmn2:startEvent id=\"Event_1d7mxqi\"><bpmn2:outgoing>Flow_1c711ii</bpmn2:outgoing></bpmn2:startEvent><bpmn2:task id=\"Activity_17rezji\" name=\"Get order information from Dynamics365\"><bpmn2:incoming>Flow_1c711ii</bpmn2:incoming><bpmn2:outgoing>Flow_0zm3e5v</bpmn2:outgoing></bpmn2:task><bpmn2:sequenceFlow id=\"Flow_1c711ii\" sourceRef=\"Event_1d7mxqi\" targetRef=\"Activity_17rezji\" /><bpmn2:exclusiveGateway id=\"Gateway_103p3e7\" name=\"Order information gotten succesfully?\" default=\"Flow_0mc5lrd\"><bpmn2:incoming>Flow_0zm3e5v</bpmn2:incoming><bpmn2:outgoing>Flow_0mc5lrd</bpmn2:outgoing><bpmn2:outgoing>Flow_1ir2qde</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:sequenceFlow id=\"Flow_0zm3e5v\" sourceRef=\"Activity_17rezji\" targetRef=\"Gateway_103p3e7\" /><bpmn2:endEvent id=\"Event_13peark\" name=\"Add error to error variable and move to next order\"><bpmn2:incoming>Flow_0mc5lrd</bpmn2:incoming></bpmn2:endEvent><bpmn2:sequenceFlow id=\"Flow_0mc5lrd\" name=\"no\" sourceRef=\"Gateway_103p3e7\" targetRef=\"Event_13peark\" /><bpmn2:exclusiveGateway id=\"Gateway_0808xi3\" name=\"Does the order already exist?\" default=\"Flow_1r2roc3\"><bpmn2:incoming>Flow_1ir2qde</bpmn2:incoming><bpmn2:outgoing>Flow_1r2roc3</bpmn2:outgoing><bpmn2:outgoing>Flow_084g1pn</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:sequenceFlow id=\"Flow_1ir2qde\" name=\"yes\" sourceRef=\"Gateway_103p3e7\" targetRef=\"Gateway_0808xi3\" /><bpmn2:task id=\"Activity_077e37l\" name=\"Create order into Dynamics365\"><bpmn2:incoming>Flow_1ex111t</bpmn2:incoming><bpmn2:outgoing>Flow_0hj1z78</bpmn2:outgoing><bpmn2:dataOutputAssociation id=\"DataOutputAssociation_13r7aa3\"><bpmn2:targetRef>DataStoreReference_1du7bqs</bpmn2:targetRef></bpmn2:dataOutputAssociation></bpmn2:task><bpmn2:sequenceFlow id=\"Flow_1r2roc3\" name=\"no\" sourceRef=\"Gateway_0808xi3\" targetRef=\"Activity_1iznpsk\" /><bpmn2:exclusiveGateway id=\"Gateway_0iyaldx\" name=\"Creation successful?\" default=\"Flow_1oh9txw\"><bpmn2:incoming>Flow_0hj1z78</bpmn2:incoming><bpmn2:outgoing>Flow_1oh9txw</bpmn2:outgoing><bpmn2:outgoing>Flow_0xcfa28</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:endEvent id=\"Event_10mk1nc\" name=\"Add error to error variable and move to next order\"><bpmn2:incoming>Flow_084g1pn</bpmn2:incoming></bpmn2:endEvent><bpmn2:endEvent id=\"Event_18es51m\" name=\"Add error to error variable and move to next order\"><bpmn2:incoming>Flow_1oh9txw</bpmn2:incoming></bpmn2:endEvent><bpmn2:sequenceFlow id=\"Flow_1oh9txw\" name=\"no\" sourceRef=\"Gateway_0iyaldx\" targetRef=\"Event_18es51m\" /><bpmn2:sequenceFlow id=\"Flow_084g1pn\" name=\"yes\" sourceRef=\"Gateway_0808xi3\" targetRef=\"Event_10mk1nc\" /><bpmn2:endEvent id=\"Event_17etyfe\" name=\"Move to next order\"><bpmn2:incoming>Flow_1rpwyaq</bpmn2:incoming></bpmn2:endEvent><bpmn2:task id=\"Activity_11kg5j4\" name=\"Get created order from Dynamics365\"><bpmn2:incoming>Flow_0xcfa28</bpmn2:incoming><bpmn2:outgoing>Flow_0o3q852</bpmn2:outgoing></bpmn2:task><bpmn2:task id=\"Activity_16awrck\" name=\"Get unit of measurement from Dynamics365\"><bpmn2:incoming>Flow_0fe2bps</bpmn2:incoming><bpmn2:outgoing>Flow_099yrmj</bpmn2:outgoing></bpmn2:task><bpmn2:exclusiveGateway id=\"Gateway_1dsidvv\" name=\"Unit of measurement gotten successfully?\" default=\"Flow_1mzezp3\"><bpmn2:incoming>Flow_099yrmj</bpmn2:incoming><bpmn2:outgoing>Flow_1ex111t</bpmn2:outgoing><bpmn2:outgoing>Flow_1mzezp3</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:sequenceFlow id=\"Flow_099yrmj\" sourceRef=\"Activity_16awrck\" targetRef=\"Gateway_1dsidvv\" /><bpmn2:task id=\"Activity_1iznpsk\" name=\"Get contact information from Dynamics365\"><bpmn2:incoming>Flow_1r2roc3</bpmn2:incoming><bpmn2:outgoing>Flow_0vic8ja</bpmn2:outgoing></bpmn2:task><bpmn2:exclusiveGateway id=\"Gateway_1vkw495\" name=\"Contact information gotten successfully?\" default=\"Flow_0hybrw0\"><bpmn2:incoming>Flow_0vic8ja</bpmn2:incoming><bpmn2:outgoing>Flow_0fe2bps</bpmn2:outgoing><bpmn2:outgoing>Flow_0hybrw0</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:sequenceFlow id=\"Flow_0vic8ja\" sourceRef=\"Activity_1iznpsk\" targetRef=\"Gateway_1vkw495\" /><bpmn2:sequenceFlow id=\"Flow_0fe2bps\" name=\"yes\" sourceRef=\"Gateway_1vkw495\" targetRef=\"Activity_16awrck\" /><bpmn2:endEvent id=\"Event_03fj5ap\" name=\"Add error to error variable and move to next order\"><bpmn2:incoming>Flow_0hybrw0</bpmn2:incoming></bpmn2:endEvent><bpmn2:sequenceFlow id=\"Flow_0hybrw0\" name=\"no\" sourceRef=\"Gateway_1vkw495\" targetRef=\"Event_03fj5ap\" /><bpmn2:sequenceFlow id=\"Flow_1ex111t\" name=\"yes\" sourceRef=\"Gateway_1dsidvv\" targetRef=\"Activity_077e37l\" /><bpmn2:sequenceFlow id=\"Flow_0xcfa28\" name=\"yes\" sourceRef=\"Gateway_0iyaldx\" targetRef=\"Activity_11kg5j4\" /><bpmn2:endEvent id=\"Event_0j9lotw\" name=\"Add error to error variable and move to next order\"><bpmn2:incoming>Flow_1mzezp3</bpmn2:incoming></bpmn2:endEvent><bpmn2:sequenceFlow id=\"Flow_1mzezp3\" name=\"no\" sourceRef=\"Gateway_1dsidvv\" targetRef=\"Event_0j9lotw\" /><bpmn2:dataStoreReference id=\"DataStoreReference_1du7bqs\" name=\"Dynamics365\" /><bpmn2:sequenceFlow id=\"Flow_0hj1z78\" sourceRef=\"Activity_077e37l\" targetRef=\"Gateway_0iyaldx\" /><bpmn2:sequenceFlow id=\"Flow_0o3q852\" sourceRef=\"Activity_11kg5j4\" targetRef=\"Activity_0kwaels\" /><bpmn2:scriptTask id=\"Activity_0kwaels\" name=\"Initialize loop variable\"><bpmn2:incoming>Flow_0o3q852</bpmn2:incoming><bpmn2:outgoing>Flow_0e8b03k</bpmn2:outgoing></bpmn2:scriptTask><bpmn2:scriptTask id=\"Activity_1cjxt28\" name=\"Initialize loop index\"><bpmn2:incoming>Flow_0e8b03k</bpmn2:incoming><bpmn2:outgoing>Flow_0x0kilt</bpmn2:outgoing></bpmn2:scriptTask><bpmn2:sequenceFlow id=\"Flow_0e8b03k\" sourceRef=\"Activity_0kwaels\" targetRef=\"Activity_1cjxt28\" /><bpmn2:subProcess id=\"Activity_1mcq9ri\" name=\"Process order lines\"><bpmn2:incoming>Flow_0x0kilt</bpmn2:incoming><bpmn2:outgoing>Flow_1rpwyaq</bpmn2:outgoing><bpmn2:standardLoopCharacteristics /><bpmn2:startEvent id=\"Event_1hqo3rs\"><bpmn2:outgoing>Flow_0ygq663</bpmn2:outgoing></bpmn2:startEvent><bpmn2:task id=\"Activity_09n02ai\" name=\"Get product information from Dynamics365\"><bpmn2:incoming>Flow_0ygq663</bpmn2:incoming><bpmn2:outgoing>Flow_0iy07g3</bpmn2:outgoing></bpmn2:task><bpmn2:task id=\"Activity_0ktykp0\" name=\"Add order product to created order\"><bpmn2:incoming>Flow_0lcyhoi</bpmn2:incoming><bpmn2:outgoing>Flow_0wg7n3j</bpmn2:outgoing><bpmn2:dataOutputAssociation id=\"DataOutputAssociation_12vpse0\"><bpmn2:targetRef>DataStoreReference_1b9n4bv</bpmn2:targetRef></bpmn2:dataOutputAssociation></bpmn2:task><bpmn2:task id=\"Activity_11aievh\" name=\"Delete the created order\"><bpmn2:incoming>Flow_07u7pfj</bpmn2:incoming><bpmn2:incoming>Flow_1rkrzux</bpmn2:incoming><bpmn2:outgoing>Flow_0d95jvv</bpmn2:outgoing></bpmn2:task><bpmn2:exclusiveGateway id=\"Gateway_1tkwy54\" name=\"Product information gotten successfully?\" default=\"Flow_00yje9n\"><bpmn2:incoming>Flow_0iy07g3</bpmn2:incoming><bpmn2:outgoing>Flow_0lcyhoi</bpmn2:outgoing><bpmn2:outgoing>Flow_00yje9n</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:exclusiveGateway id=\"Gateway_0xt54e1\" name=\"Order product added successfully?\" default=\"Flow_1sch0kb\"><bpmn2:incoming>Flow_0wg7n3j</bpmn2:incoming><bpmn2:outgoing>Flow_1pnnn1j</bpmn2:outgoing><bpmn2:outgoing>Flow_1sch0kb</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:endEvent id=\"Event_0cku1vj\" name=\"Move to next order line\"><bpmn2:incoming>Flow_0fsf42v</bpmn2:incoming></bpmn2:endEvent><bpmn2:endEvent id=\"Event_0lc0x56\" name=\"Stop processing current order\"><bpmn2:incoming>Flow_0d95jvv</bpmn2:incoming></bpmn2:endEvent><bpmn2:dataStoreReference id=\"DataStoreReference_1b9n4bv\" name=\"Dynamics365\" /><bpmn2:sequenceFlow id=\"Flow_0ygq663\" sourceRef=\"Event_1hqo3rs\" targetRef=\"Activity_09n02ai\" /><bpmn2:sequenceFlow id=\"Flow_0iy07g3\" sourceRef=\"Activity_09n02ai\" targetRef=\"Gateway_1tkwy54\" /><bpmn2:sequenceFlow id=\"Flow_0lcyhoi\" name=\"yes\" sourceRef=\"Gateway_1tkwy54\" targetRef=\"Activity_0ktykp0\" /><bpmn2:sequenceFlow id=\"Flow_0wg7n3j\" sourceRef=\"Activity_0ktykp0\" targetRef=\"Gateway_0xt54e1\" /><bpmn2:exclusiveGateway id=\"Gateway_05h2njg\" name=\"All lines processed?\" default=\"Flow_0fsf42v\"><bpmn2:incoming>Flow_1pnnn1j</bpmn2:incoming><bpmn2:outgoing>Flow_0fsf42v</bpmn2:outgoing><bpmn2:outgoing>Flow_0ta0j1v</bpmn2:outgoing></bpmn2:exclusiveGateway><bpmn2:endEvent id=\"Event_0afkaim\" name=\"Finish processing order lines\"><bpmn2:incoming>Flow_0549fl8</bpmn2:incoming></bpmn2:endEvent><bpmn2:sequenceFlow id=\"Flow_0d95jvv\" sourceRef=\"Activity_11aievh\" targetRef=\"Event_0lc0x56\" /><bpmn2:sequenceFlow id=\"Flow_0fsf42v\" name=\"no\" sourceRef=\"Gateway_05h2njg\" targetRef=\"Event_0cku1vj\" /><bpmn2:sequenceFlow id=\"Flow_1pnnn1j\" name=\"yes\" sourceRef=\"Gateway_0xt54e1\" targetRef=\"Gateway_05h2njg\" /><bpmn2:scriptTask id=\"Activity_1ev31fu\" name=\"Increment insert count\"><bpmn2:incoming>Flow_0ta0j1v</bpmn2:incoming><bpmn2:outgoing>Flow_0549fl8</bpmn2:outgoing></bpmn2:scriptTask><bpmn2:sequenceFlow id=\"Flow_0ta0j1v\" name=\"yes\" sourceRef=\"Gateway_05h2njg\" targetRef=\"Activity_1ev31fu\" /><bpmn2:sequenceFlow id=\"Flow_0549fl8\" sourceRef=\"Activity_1ev31fu\" targetRef=\"Event_0afkaim\" /><bpmn2:scriptTask id=\"Activity_069d16b\" name=\"Add error to error variable\"><bpmn2:incoming>Flow_00yje9n</bpmn2:incoming><bpmn2:outgoing>Flow_1rkrzux</bpmn2:outgoing></bpmn2:scriptTask><bpmn2:sequenceFlow id=\"Flow_00yje9n\" name=\"no\" sourceRef=\"Gateway_1tkwy54\" targetRef=\"Activity_069d16b\" /><bpmn2:scriptTask id=\"Activity_067pldp\" name=\"Add error to errors variable\"><bpmn2:incoming>Flow_1sch0kb</bpmn2:incoming><bpmn2:outgoing>Flow_07u7pfj</bpmn2:outgoing></bpmn2:scriptTask><bpmn2:sequenceFlow id=\"Flow_1sch0kb\" name=\"no\" sourceRef=\"Gateway_0xt54e1\" targetRef=\"Activity_067pldp\" /><bpmn2:sequenceFlow id=\"Flow_07u7pfj\" sourceRef=\"Activity_067pldp\" targetRef=\"Activity_11aievh\" /><bpmn2:sequenceFlow id=\"Flow_1rkrzux\" sourceRef=\"Activity_069d16b\" targetRef=\"Activity_11aievh\" /><bpmn2:textAnnotation id=\"TextAnnotation_10p9f8i\"><bpmn2:text>The created order is deleted to prevent only partially successful orders being inserted.</bpmn2:text></bpmn2:textAnnotation><bpmn2:association id=\"Association_1d8x94g\" sourceRef=\"Activity_11aievh\" targetRef=\"TextAnnotation_10p9f8i\" /></bpmn2:subProcess><bpmn2:sequenceFlow id=\"Flow_0x0kilt\" sourceRef=\"Activity_1cjxt28\" targetRef=\"Activity_1mcq9ri\" /><bpmn2:sequenceFlow id=\"Flow_1rpwyaq\" sourceRef=\"Activity_1mcq9ri\" targetRef=\"Event_17etyfe\" /><bpmn2:textAnnotation id=\"TextAnnotation_1os5dj9\"><bpmn2:text>Existing orders are skipped by this template.</bpmn2:text></bpmn2:textAnnotation><bpmn2:association id=\"Association_18rf52l\" sourceRef=\"Activity_17rezji\" targetRef=\"TextAnnotation_1os5dj9\" /><bpmn2:textAnnotation id=\"TextAnnotation_0yc6pd7\"><bpmn2:text>The products to be inserted into the created order need a unit of measurement.</bpmn2:text></bpmn2:textAnnotation><bpmn2:association id=\"Association_1f6p69n\" sourceRef=\"Activity_16awrck\" targetRef=\"TextAnnotation_0yc6pd7\" /><bpmn2:textAnnotation id=\"TextAnnotation_025x5ym\"><bpmn2:text>The customer email associated with the order from Magento is used to connect it to the corresponding contact in Dynamics365.</bpmn2:text></bpmn2:textAnnotation><bpmn2:association id=\"Association_1ni0zii\" sourceRef=\"Activity_1iznpsk\" targetRef=\"TextAnnotation_025x5ym\" /></bpmn2:subProcess><bpmn2:endEvent id=\"Event_0yt9hzd\" name=\"Process completed, return insert count and possible error messages\"><bpmn2:incoming>Flow_0qbb2hn</bpmn2:incoming></bpmn2:endEvent><bpmn2:sequenceFlow id=\"Flow_0qbb2hn\" sourceRef=\"Activity_122wx66\" targetRef=\"Event_0yt9hzd\" /><bpmn2:dataStoreReference id=\"DataStoreReference_0kiz3dh\" name=\"Magento\" /><bpmn2:scriptTask id=\"Activity_12xmh3s\" name=\"Initialize insert count\"><bpmn2:incoming>Flow_0u63m03</bpmn2:incoming><bpmn2:outgoing>Flow_0nnqxe0</bpmn2:outgoing></bpmn2:scriptTask><bpmn2:sequenceFlow id=\"Flow_0u63m03\" sourceRef=\"Activity_0vsfxcb\" targetRef=\"Activity_12xmh3s\" /><bpmn2:sequenceFlow id=\"Flow_0nnqxe0\" sourceRef=\"Activity_12xmh3s\" targetRef=\"Activity_122wx66\" /><bpmn2:group id=\"Group_0pvpbv2\" categoryValueRef=\"CategoryValue_13411y8\" /><bpmn2:group id=\"Group_0sjd3lf\" categoryValueRef=\"CategoryValue_11kv364\" /><bpmn2:group id=\"Group_1tr25qf\" categoryValueRef=\"CategoryValue_1ie4i31\" /><bpmn2:group id=\"Group_1c6dlps\" categoryValueRef=\"CategoryValue_0uk02tz\" /></bpmn2:process><bpmn2:category id=\"Category_0a57upg\"><bpmn2:categoryValue id=\"CategoryValue_13411y8\" value=\"Get order data from Magento\" /></bpmn2:category><bpmn2:category id=\"Category_0fruav5\"><bpmn2:categoryValue id=\"CategoryValue_11kv364\" value=\"Get required information from Dynamics365\" /></bpmn2:category><bpmn2:category id=\"Category_1vfhw4h\"><bpmn2:categoryValue id=\"CategoryValue_1ie4i31\" value=\"Create empty order into Dynamics365\" /></bpmn2:category><bpmn2:category id=\"Category_0yz0av3\"><bpmn2:categoryValue id=\"CategoryValue_0uk02tz\" value=\"Populate the created order\" /></bpmn2:category><bpmndi:BPMNDiagram id=\"BPMNDiagram_1\"><bpmndi:BPMNPlane id=\"BPMNPlane_1\" bpmnElement=\"Process_1\"><bpmndi:BPMNShape id=\"_BPMNShape_StartEvent_2\" bpmnElement=\"StartEvent_1\"><dc:Bounds x=\"482\" y=\"250\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"482\" y=\"286\" width=\"37\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_0ks7ips_di\" bpmnElement=\"Activity_0ks7ips\"><dc:Bounds x=\"590\" y=\"228\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_0tz7zpc_di\" bpmnElement=\"Gateway_0tz7zpc\" isMarkerVisible=\"true\"><dc:Bounds x=\"745\" y=\"243\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"730\" y=\"213\" width=\"80\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_1gp43wn_di\" bpmnElement=\"Activity_1gp43wn\"><dc:Bounds x=\"860\" y=\"228\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_1sgpzth_di\" bpmnElement=\"Event_1sgpzth\"><dc:Bounds x=\"752\" y=\"382\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"733\" y=\"425\" width=\"76\" height=\"53\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_0xcgyrz_di\" bpmnElement=\"Gateway_0xcgyrz\" isMarkerVisible=\"true\"><dc:Bounds x=\"1025\" y=\"243\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1008\" y=\"213\" width=\"85\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_0m2tmsv_di\" bpmnElement=\"Event_0m2tmsv\"><dc:Bounds x=\"1032\" y=\"382\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1016\" y=\"425\" width=\"68\" height=\"53\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_0vsfxcb_di\" bpmnElement=\"Activity_0vsfxcb\"><dc:Bounds x=\"1185\" y=\"253\" width=\"30\" height=\"30\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_122wx66_di\" bpmnElement=\"Activity_122wx66\" isExpanded=\"true\"><dc:Bounds x=\"1430\" y=\"-70\" width=\"3350\" height=\"790\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_1d7mxqi_di\" bpmnElement=\"Event_1d7mxqi\"><dc:Bounds x=\"1470\" y=\"250\" width=\"36\" height=\"36\" /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_17rezji_di\" bpmnElement=\"Activity_17rezji\"><dc:Bounds x=\"1560\" y=\"228\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_103p3e7_di\" bpmnElement=\"Gateway_103p3e7\" isMarkerVisible=\"true\"><dc:Bounds x=\"1765\" y=\"243\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1747\" y=\"190\" width=\"87\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_13peark_di\" bpmnElement=\"Event_13peark\"><dc:Bounds x=\"1772\" y=\"382\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1745\" y=\"425\" width=\"90\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_0808xi3_di\" bpmnElement=\"Gateway_0808xi3\" isMarkerVisible=\"true\"><dc:Bounds x=\"1905\" y=\"243\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1893\" y=\"206\" width=\"75\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_077e37l_di\" bpmnElement=\"Activity_077e37l\"><dc:Bounds x=\"2690\" y=\"228\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_0iyaldx_di\" bpmnElement=\"Gateway_0iyaldx\" isMarkerVisible=\"true\"><dc:Bounds x=\"2875\" y=\"243\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2873\" y=\"219\" width=\"57\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_10mk1nc_di\" bpmnElement=\"Event_10mk1nc\"><dc:Bounds x=\"1912\" y=\"382\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1885\" y=\"425\" width=\"90\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_18es51m_di\" bpmnElement=\"Event_18es51m\"><dc:Bounds x=\"2882\" y=\"382\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2855\" y=\"425\" width=\"90\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_17etyfe_di\" bpmnElement=\"Event_17etyfe\"><dc:Bounds x=\"4702\" y=\"250\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4688\" y=\"206\" width=\"64\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_11kg5j4_di\" bpmnElement=\"Activity_11kg5j4\"><dc:Bounds x=\"3010\" y=\"228\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_16awrck_di\" bpmnElement=\"Activity_16awrck\"><dc:Bounds x=\"2360\" y=\"228\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_1dsidvv_di\" bpmnElement=\"Gateway_1dsidvv\" isMarkerVisible=\"true\"><dc:Bounds x=\"2535\" y=\"243\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2526\" y=\"193\" width=\"69\" height=\"53\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_1iznpsk_di\" bpmnElement=\"Activity_1iznpsk\"><dc:Bounds x=\"2040\" y=\"228\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_1vkw495_di\" bpmnElement=\"Gateway_1vkw495\" isMarkerVisible=\"true\"><dc:Bounds x=\"2225\" y=\"243\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2206\" y=\"200\" width=\"89\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_03fj5ap_di\" bpmnElement=\"Event_03fj5ap\"><dc:Bounds x=\"2232\" y=\"382\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2205\" y=\"425\" width=\"90\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_0j9lotw_di\" bpmnElement=\"Event_0j9lotw\"><dc:Bounds x=\"2542\" y=\"382\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2516\" y=\"425\" width=\"90\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"DataStoreReference_1du7bqs_di\" bpmnElement=\"DataStoreReference_1du7bqs\"><dc:Bounds x=\"2715\" y=\"115\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2707\" y=\"93\" width=\"68\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_0kwaels_di\" bpmnElement=\"Activity_0kwaels\"><dc:Bounds x=\"3205\" y=\"253\" width=\"30\" height=\"30\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_1cjxt28_di\" bpmnElement=\"Activity_1cjxt28\"><dc:Bounds x=\"3335\" y=\"253\" width=\"30\" height=\"30\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_1mcq9ri_di\" bpmnElement=\"Activity_1mcq9ri\" isExpanded=\"true\"><dc:Bounds x=\"3440\" y=\"30\" width=\"1190\" height=\"640\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"TextAnnotation_10p9f8i_di\" bpmnElement=\"TextAnnotation_10p9f8i\"><dc:Bounds x=\"3930\" y=\"361\" width=\"110\" height=\"98\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_1hqo3rs_di\" bpmnElement=\"Event_1hqo3rs\"><dc:Bounds x=\"3500\" y=\"252\" width=\"36\" height=\"36\" /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"BPMNShape_1s3zmq0\" bpmnElement=\"Activity_09n02ai\"><dc:Bounds x=\"3620\" y=\"230\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"BPMNShape_056kj05\" bpmnElement=\"Activity_0ktykp0\"><dc:Bounds x=\"3930\" y=\"230\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_1tkwy54_di\" bpmnElement=\"Gateway_1tkwy54\" isMarkerVisible=\"true\"><dc:Bounds x=\"3805\" y=\"245\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"3786\" y=\"200\" width=\"89\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_0xt54e1_di\" bpmnElement=\"Gateway_0xt54e1\" isMarkerVisible=\"true\"><dc:Bounds x=\"4105\" y=\"245\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4096\" y=\"200\" width=\"69\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_0cku1vj_di\" bpmnElement=\"Event_0cku1vj\"><dc:Bounds x=\"4512\" y=\"392\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4498\" y=\"356\" width=\"64\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_0lc0x56_di\" bpmnElement=\"Event_0lc0x56\"><dc:Bounds x=\"4512\" y=\"532\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4490\" y=\"496\" width=\"80\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"DataStoreReference_1b9n4bv_di\" bpmnElement=\"DataStoreReference_1b9n4bv\"><dc:Bounds x=\"3955\" y=\"125\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"3947\" y=\"103\" width=\"68\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Gateway_05h2njg_di\" bpmnElement=\"Gateway_05h2njg\" isMarkerVisible=\"true\"><dc:Bounds x=\"4255\" y=\"245\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4251\" y=\"208\" width=\"58\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Event_0afkaim_di\" bpmnElement=\"Event_0afkaim\"><dc:Bounds x=\"4512\" y=\"252\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4487\" y=\"206\" width=\"87\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_1ev31fu_di\" bpmnElement=\"Activity_1ev31fu\"><dc:Bounds x=\"4385\" y=\"255\" width=\"30\" height=\"30\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_069d16b_di\" bpmnElement=\"Activity_069d16b\"><dc:Bounds x=\"3815\" y=\"535\" width=\"30\" height=\"30\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"BPMNShape_1gt3a9a\" bpmnElement=\"Activity_11aievh\"><dc:Bounds x=\"4080\" y=\"510\" width=\"100\" height=\"80\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"BPMNShape_0k431od\" bpmnElement=\"Activity_067pldp\"><dc:Bounds x=\"4115\" y=\"385\" width=\"30\" height=\"30\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNEdge id=\"Association_1d8x94g_di\" bpmnElement=\"Association_1d8x94g\"><di:waypoint x=\"4092\" y=\"510\" /><di:waypoint x=\"4040\" y=\"456\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0ygq663_di\" bpmnElement=\"Flow_0ygq663\"><di:waypoint x=\"3536\" y=\"270\" /><di:waypoint x=\"3620\" y=\"270\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0iy07g3_di\" bpmnElement=\"Flow_0iy07g3\"><di:waypoint x=\"3720\" y=\"270\" /><di:waypoint x=\"3805\" y=\"270\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0lcyhoi_di\" bpmnElement=\"Flow_0lcyhoi\"><di:waypoint x=\"3855\" y=\"270\" /><di:waypoint x=\"3930\" y=\"270\" /><bpmndi:BPMNLabel><dc:Bounds x=\"3885\" y=\"252\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0wg7n3j_di\" bpmnElement=\"Flow_0wg7n3j\"><di:waypoint x=\"4030\" y=\"270\" /><di:waypoint x=\"4105\" y=\"270\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0d95jvv_di\" bpmnElement=\"Flow_0d95jvv\"><di:waypoint x=\"4180\" y=\"550\" /><di:waypoint x=\"4512\" y=\"550\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0fsf42v_di\" bpmnElement=\"Flow_0fsf42v\"><di:waypoint x=\"4280\" y=\"295\" /><di:waypoint x=\"4280\" y=\"410\" /><di:waypoint x=\"4512\" y=\"410\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4289\" y=\"343\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1pnnn1j_di\" bpmnElement=\"Flow_1pnnn1j\"><di:waypoint x=\"4155\" y=\"270\" /><di:waypoint x=\"4255\" y=\"270\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4170\" y=\"250\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0ta0j1v_di\" bpmnElement=\"Flow_0ta0j1v\"><di:waypoint x=\"4305\" y=\"270\" /><di:waypoint x=\"4385\" y=\"270\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4337\" y=\"252\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0549fl8_di\" bpmnElement=\"Flow_0549fl8\"><di:waypoint x=\"4415\" y=\"270\" /><di:waypoint x=\"4512\" y=\"270\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_00yje9n_di\" bpmnElement=\"Flow_00yje9n\"><di:waypoint x=\"3830\" y=\"295\" /><di:waypoint x=\"3830\" y=\"535\" /><bpmndi:BPMNLabel><dc:Bounds x=\"3839\" y=\"421\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1sch0kb_di\" bpmnElement=\"Flow_1sch0kb\"><di:waypoint x=\"4130\" y=\"295\" /><di:waypoint x=\"4130\" y=\"385\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4139\" y=\"340\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_07u7pfj_di\" bpmnElement=\"Flow_07u7pfj\"><di:waypoint x=\"4130\" y=\"415\" /><di:waypoint x=\"4130\" y=\"510\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1rkrzux_di\" bpmnElement=\"Flow_1rkrzux\"><di:waypoint x=\"3845\" y=\"550\" /><di:waypoint x=\"4080\" y=\"550\" /></bpmndi:BPMNEdge><bpmndi:BPMNShape id=\"TextAnnotation_1os5dj9_di\" bpmnElement=\"TextAnnotation_1os5dj9\"><dc:Bounds x=\"1560\" y=\"70\" width=\"100\" height=\"56\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"TextAnnotation_0yc6pd7_di\" bpmnElement=\"TextAnnotation_0yc6pd7\"><dc:Bounds x=\"2350\" y=\"55\" width=\"120\" height=\"85\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"TextAnnotation_025x5ym_di\" bpmnElement=\"TextAnnotation_025x5ym\"><dc:Bounds x=\"2020\" y=\"49\" width=\"150\" height=\"101\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNEdge id=\"Flow_1c711ii_di\" bpmnElement=\"Flow_1c711ii\"><di:waypoint x=\"1506\" y=\"268\" /><di:waypoint x=\"1560\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0zm3e5v_di\" bpmnElement=\"Flow_0zm3e5v\"><di:waypoint x=\"1660\" y=\"268\" /><di:waypoint x=\"1765\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0mc5lrd_di\" bpmnElement=\"Flow_0mc5lrd\"><di:waypoint x=\"1790\" y=\"293\" /><di:waypoint x=\"1790\" y=\"382\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1795\" y=\"331\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1ir2qde_di\" bpmnElement=\"Flow_1ir2qde\"><di:waypoint x=\"1815\" y=\"268\" /><di:waypoint x=\"1905\" y=\"268\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1853\" y=\"250\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1r2roc3_di\" bpmnElement=\"Flow_1r2roc3\"><di:waypoint x=\"1955\" y=\"268\" /><di:waypoint x=\"2040\" y=\"268\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1992\" y=\"251\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1oh9txw_di\" bpmnElement=\"Flow_1oh9txw\"><di:waypoint x=\"2900\" y=\"293\" /><di:waypoint x=\"2900\" y=\"382\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2909\" y=\"335\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_084g1pn_di\" bpmnElement=\"Flow_084g1pn\"><di:waypoint x=\"1930\" y=\"293\" /><di:waypoint x=\"1930\" y=\"382\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1938\" y=\"321\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_099yrmj_di\" bpmnElement=\"Flow_099yrmj\"><di:waypoint x=\"2460\" y=\"268\" /><di:waypoint x=\"2535\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0vic8ja_di\" bpmnElement=\"Flow_0vic8ja\"><di:waypoint x=\"2140\" y=\"268\" /><di:waypoint x=\"2225\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0fe2bps_di\" bpmnElement=\"Flow_0fe2bps\"><di:waypoint x=\"2275\" y=\"268\" /><di:waypoint x=\"2360\" y=\"268\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2311\" y=\"250\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0hybrw0_di\" bpmnElement=\"Flow_0hybrw0\"><di:waypoint x=\"2250\" y=\"293\" /><di:waypoint x=\"2250\" y=\"382\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2259\" y=\"335\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1ex111t_di\" bpmnElement=\"Flow_1ex111t\"><di:waypoint x=\"2585\" y=\"268\" /><di:waypoint x=\"2690\" y=\"268\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2617\" y=\"250\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0xcfa28_di\" bpmnElement=\"Flow_0xcfa28\"><di:waypoint x=\"2925\" y=\"268\" /><di:waypoint x=\"3010\" y=\"268\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2962\" y=\"250\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1mzezp3_di\" bpmnElement=\"Flow_1mzezp3\"><di:waypoint x=\"2560\" y=\"293\" /><di:waypoint x=\"2560\" y=\"382\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2569\" y=\"335\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0hj1z78_di\" bpmnElement=\"Flow_0hj1z78\"><di:waypoint x=\"2790\" y=\"268\" /><di:waypoint x=\"2875\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0o3q852_di\" bpmnElement=\"Flow_0o3q852\"><di:waypoint x=\"3110\" y=\"268\" /><di:waypoint x=\"3205\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0e8b03k_di\" bpmnElement=\"Flow_0e8b03k\"><di:waypoint x=\"3235\" y=\"268\" /><di:waypoint x=\"3335\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0x0kilt_di\" bpmnElement=\"Flow_0x0kilt\"><di:waypoint x=\"3365\" y=\"268\" /><di:waypoint x=\"3440\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1rpwyaq_di\" bpmnElement=\"Flow_1rpwyaq\"><di:waypoint x=\"4630\" y=\"268\" /><di:waypoint x=\"4702\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Association_18rf52l_di\" bpmnElement=\"Association_18rf52l\"><di:waypoint x=\"1610\" y=\"228\" /><di:waypoint x=\"1610\" y=\"126\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Association_1f6p69n_di\" bpmnElement=\"Association_1f6p69n\"><di:waypoint x=\"2410\" y=\"228\" /><di:waypoint x=\"2410\" y=\"140\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Association_1ni0zii_di\" bpmnElement=\"Association_1ni0zii\"><di:waypoint x=\"2090\" y=\"228\" /><di:waypoint x=\"2090\" y=\"150\" /></bpmndi:BPMNEdge><bpmndi:BPMNShape id=\"Event_0yt9hzd_di\" bpmnElement=\"Event_0yt9hzd\"><dc:Bounds x=\"4882\" y=\"250\" width=\"36\" height=\"36\" /><bpmndi:BPMNLabel><dc:Bounds x=\"4857\" y=\"177\" width=\"87\" height=\"66\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"DataStoreReference_0kiz3dh_di\" bpmnElement=\"DataStoreReference_0kiz3dh\"><dc:Bounds x=\"885\" y=\"105\" width=\"50\" height=\"50\" /><bpmndi:BPMNLabel><dc:Bounds x=\"888\" y=\"83\" width=\"44\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Activity_12xmh3s_di\" bpmnElement=\"Activity_12xmh3s\"><dc:Bounds x=\"1305\" y=\"253\" width=\"30\" height=\"30\" /><bpmndi:BPMNLabel /></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Group_0pvpbv2_di\" bpmnElement=\"Group_0pvpbv2\"><dc:Bounds x=\"550\" y=\"10\" width=\"580\" height=\"530\" /><bpmndi:BPMNLabel><dc:Bounds x=\"804\" y=\"17\" width=\"72\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Group_0sjd3lf_di\" bpmnElement=\"Group_0sjd3lf\"><dc:Bounds x=\"1400\" y=\"-150\" width=\"1210\" height=\"920\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1965\" y=\"-143\" width=\"80\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"Group_1tr25qf_di\" bpmnElement=\"Group_1tr25qf\"><dc:Bounds x=\"2650\" y=\"-150\" width=\"490\" height=\"920\" /><bpmndi:BPMNLabel><dc:Bounds x=\"2862\" y=\"-143\" width=\"68\" height=\"40\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNShape id=\"BPMNShape_0xjr7vs\" bpmnElement=\"Group_1c6dlps\"><dc:Bounds x=\"3180\" y=\"-150\" width=\"1630\" height=\"920\" /><bpmndi:BPMNLabel><dc:Bounds x=\"3962\" y=\"-143\" width=\"68\" height=\"27\" /></bpmndi:BPMNLabel></bpmndi:BPMNShape><bpmndi:BPMNEdge id=\"Flow_0737pen_di\" bpmnElement=\"Flow_0737pen\"><di:waypoint x=\"518\" y=\"268\" /><di:waypoint x=\"590\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_03symyo_di\" bpmnElement=\"Flow_03symyo\"><di:waypoint x=\"690\" y=\"268\" /><di:waypoint x=\"745\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"DataInputAssociation_1cklt14_di\" bpmnElement=\"DataInputAssociation_1cklt14\"><di:waypoint x=\"910\" y=\"155\" /><di:waypoint x=\"910\" y=\"228\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_18nhiph_di\" bpmnElement=\"Flow_18nhiph\"><di:waypoint x=\"795\" y=\"268\" /><di:waypoint x=\"860\" y=\"268\" /><bpmndi:BPMNLabel><dc:Bounds x=\"812\" y=\"250\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0vig9jh_di\" bpmnElement=\"Flow_0vig9jh\"><di:waypoint x=\"770\" y=\"293\" /><di:waypoint x=\"770\" y=\"382\" /><bpmndi:BPMNLabel><dc:Bounds x=\"779\" y=\"335\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_1qm8po5_di\" bpmnElement=\"Flow_1qm8po5\"><di:waypoint x=\"960\" y=\"268\" /><di:waypoint x=\"1025\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0ny1eo2_di\" bpmnElement=\"Flow_0ny1eo2\"><di:waypoint x=\"1050\" y=\"293\" /><di:waypoint x=\"1050\" y=\"382\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1059\" y=\"335\" width=\"13\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_02pbox5_di\" bpmnElement=\"Flow_02pbox5\"><di:waypoint x=\"1075\" y=\"268\" /><di:waypoint x=\"1185\" y=\"268\" /><bpmndi:BPMNLabel><dc:Bounds x=\"1098\" y=\"250\" width=\"16\" height=\"14\" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"DataOutputAssociation_13r7aa3_di\" bpmnElement=\"DataOutputAssociation_13r7aa3\"><di:waypoint x=\"2740\" y=\"228\" /><di:waypoint x=\"2740\" y=\"165\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"DataOutputAssociation_12vpse0_di\" bpmnElement=\"DataOutputAssociation_12vpse0\"><di:waypoint x=\"3980\" y=\"230\" /><di:waypoint x=\"3980\" y=\"175\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0qbb2hn_di\" bpmnElement=\"Flow_0qbb2hn\"><di:waypoint x=\"4780\" y=\"268\" /><di:waypoint x=\"4882\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0u63m03_di\" bpmnElement=\"Flow_0u63m03\"><di:waypoint x=\"1215\" y=\"268\" /><di:waypoint x=\"1305\" y=\"268\" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id=\"Flow_0nnqxe0_di\" bpmnElement=\"Flow_0nnqxe0\"><di:waypoint x=\"1335\" y=\"268\" /><di:waypoint x=\"1430\" y=\"268\" /></bpmndi:BPMNEdge></bpmndi:BPMNPlane></bpmndi:BPMNDiagram></bpmn2:definitions>",
					"ElementParameters": "[{\"Id\":\"StartEvent_1\",\"Type\":0,\"Parameters\":{},\"SelectedTypeId\":\"ManualTrigger\",\"PromoteResultAs\":null,\"Name\":\"Manual\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_0ks7ips\",\"Type\":1,\"Parameters\":{\"input\":{\"Method\":{\"mode\":\"select\",\"value\":\"POST\"},\"ResultMethod\":{\"mode\":\"select\",\"value\":\"JToken\"},\"Url\":{\"mode\":\"text\",\"value\":\"{{#var.MagentoBaseUrl}}/index.php/rest/V1/integration/admin/token\"},\"Message\":{\"mode\":\"text\",\"value\":\"{\\r\\n    \\\"username\\\": {{\\\"\\\\\\\"\\\" + #var.MagentoUser + \\\"\\\\\\\"\\\"}},\\r\\n    \\\"password\\\": {{\\\"\\\\\\\"\\\" + #var.MagentoPassword.Replace(\\\"\\\\\\\"\\\", \\\"\\\\\\\\\\\\\\\"\\\") + \\\"\\\\\\\"\\\"}}\\r\\n}\"},\"Headers\":[{\"Name\":{\"mode\":\"text\",\"value\":\"Content-Type\"},\"Value\":{\"mode\":\"text\",\"value\":\"application/json\"}}]},\"options\":{\"Authentication\":{\"mode\":\"select\",\"value\":\"None\"},\"Username\":{\"mode\":\"text\",\"value\":\"\"},\"Password\":{\"mode\":\"text\",\"value\":\"\"},\"Token\":{\"mode\":\"text\",\"value\":\"\"},\"ClientCertificateSource\":{\"mode\":\"select\",\"value\":\"CertificateStore\"},\"ClientCertificateFilePath\":{\"mode\":\"text\",\"value\":\"\"},\"ClientCertificateInBase64\":{\"mode\":\"text\",\"value\":\"\"},\"ClientCertificateKeyPhrase\":{\"mode\":\"text\",\"value\":\"\"},\"CertificateThumbprint\":{\"mode\":\"text\",\"value\":\"\"},\"LoadEntireChainForCertificate\":{\"mode\":\"toggle\",\"value\":true},\"ConnectionTimeoutSeconds\":{\"mode\":\"integer\",\"value\":30},\"FollowRedirects\":{\"mode\":\"toggle\",\"value\":true},\"AllowInvalidCertificate\":{\"mode\":\"toggle\",\"value\":false},\"AllowInvalidResponseContentTypeCharSet\":{\"mode\":\"toggle\",\"value\":false},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false},\"AutomaticCookieHandling\":{\"mode\":\"toggle\",\"value\":true}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/d2f2020e-4ce6-4e5f-879f-ef34e57c9fca/v1\",\"PromoteResultAs\":null,\"Name\":\"Obtain authorisation token from Magento\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":true,\"ShouldDispose\":null},{\"Id\":\"Gateway_0tz7zpc\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.StatusCode == 200\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Token received?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_18nhiph\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_1gp43wn\",\"Type\":1,\"Parameters\":{\"input\":{\"Method\":{\"mode\":\"select\",\"value\":\"GET\"},\"ResultMethod\":{\"mode\":\"select\",\"value\":\"JToken\"},\"Url\":{\"mode\":\"text\",\"value\":\"{{#var.MagentoBaseUrl}}/rest/V1/orders?searchCriteria[filterGroups][0]\"},\"Message\":{\"mode\":\"text\",\"value\":\"\"},\"Headers\":[]},\"options\":{\"Authentication\":{\"mode\":\"select\",\"value\":\"OAuth\"},\"Username\":{\"mode\":\"text\",\"value\":\"\"},\"Password\":{\"mode\":\"text\",\"value\":\"\"},\"Token\":{\"mode\":\"csharp\",\"value\":\"#result[Obtain authorisation token from Magento].Body\"},\"ClientCertificateSource\":{\"mode\":\"select\",\"value\":\"CertificateStore\"},\"ClientCertificateFilePath\":{\"mode\":\"text\",\"value\":\"\"},\"ClientCertificateInBase64\":{\"mode\":\"text\",\"value\":\"\"},\"ClientCertificateKeyPhrase\":{\"mode\":\"text\",\"value\":\"\"},\"CertificateThumbprint\":{\"mode\":\"text\",\"value\":\"\"},\"LoadEntireChainForCertificate\":{\"mode\":\"toggle\",\"value\":true},\"ConnectionTimeoutSeconds\":{\"mode\":\"integer\",\"value\":30},\"FollowRedirects\":{\"mode\":\"toggle\",\"value\":true},\"AllowInvalidCertificate\":{\"mode\":\"toggle\",\"value\":false},\"AllowInvalidResponseContentTypeCharSet\":{\"mode\":\"toggle\",\"value\":false},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false},\"AutomaticCookieHandling\":{\"mode\":\"toggle\",\"value\":true}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/d2f2020e-4ce6-4e5f-879f-ef34e57c9fca/v1\",\"PromoteResultAs\":null,\"Name\":\"Get orders from Magento\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_1sgpzth\",\"Type\":6,\"Parameters\":{\"expression\":{\"mode\":\"text\",\"value\":\"An exception occurred when obtaining the authorisation token from Magento:\\\\n{{#result[Obtain authorisation token from Magento].Body.message}}\"},\"bypassGlobalExceptionHandler\":{\"mode\":\"toggle\",\"value\":true}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0vig9jh\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_0xcgyrz\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.StatusCode == 200\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Orders received?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_0m2tmsv\",\"Type\":6,\"Parameters\":{\"expression\":{\"mode\":\"text\",\"value\":\"An exception occurred when getting orders from Magento:\\\\n{{#result[Obtain authorisation token from Magento].Body.message}}\"},\"bypassGlobalExceptionHandler\":{\"mode\":\"toggle\",\"value\":true}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0ny1eo2\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_02pbox5\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_0vsfxcb\",\"Type\":12,\"Parameters\":{\"variableName\":\"errors\",\"variableExpression\":{\"mode\":\"csharp\",\"value\":\"\\\"\\\"\"},\"shouldAssignVariable\":{\"mode\":\"toggle\",\"value\":true}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Initialize error variable\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_1d7mxqi\",\"Type\":13,\"Parameters\":{},\"SelectedTypeId\":\"\",\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_122wx66\",\"Type\":10,\"Parameters\":{\"variable\":\"order\",\"expression\":{\"mode\":\"csharp\",\"value\":\"#result[Get orders from Magento].Body.items\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"For each order\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_0yt9hzd\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.errors != \\\"\\\" ? $\\\"{#var.insertedCount} orders inserted succesfully into Dynamics365. The following errors occurred:\\\\n{#var.errors}\\\" : $\\\"{#var.insertedCount} orders inserted succesfully into Dynamics365.\\\"\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_17rezji\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"GET\"},\"Path\":{\"mode\":\"text\",\"value\":\"salesorders?$filter=ordernumber eq 'MAG{{#var.order.entity_id}}'\"},\"Payload\":{\"mode\":\"text\",\"value\":\"\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Get order information from Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_103p3e7\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.Success\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Order information gotten succesfully?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0mc5lrd\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_13peark\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.errors += $\\\"\\\\nAn error occurred when fetching order information from Dynamics365:\\\\n{#result[Get order information from Dynamics365].ErrorMessage}\\\"\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_1ir2qde\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_0808xi3\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result[Get order information from Dynamics365].Data.value.Count > 0\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Does the order already exist?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_1r2roc3\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_077e37l\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"POST\"},\"Path\":{\"mode\":\"text\",\"value\":\"salesorders\"},\"Payload\":{\"mode\":\"text\",\"value\":\"{\\r\\n    \\\"ordernumber\\\": \\\"{{\\\"MAG\\\" + #var.order.entity_id}}\\\",\\r\\n    \\\"customerid_contact@odata.bind\\\": \\\"/contacts({{#result[Get contact information from Dynamics365].Data.value[0].contactid}})\\\",\\r\\n    \\\"name\\\": \\\"{{\\\"Magento order \\\" + #var.order.entity_id}}\\\",\\r\\n    \\\"description\\\": \\\"{{\\\"An order imported from Magento using the Frends template process. The ID of this order on Magento is \\\" + #var.order.entity_id}}.\\\",\\r\\n    \\\"statecode\\\": 0,\\r\\n    \\\"freightamount\\\": {{#var.order.base_shipping_amount}},\\r\\n    \\\"emailaddress\\\": \\\"{{#var.order.customer_email}}\\\",\\r\\n    \\\"shipto_city\\\": \\\"{{#var.order.extension_attributes.shipping_assignments[0].shipping.address.city}}\\\",\\r\\n    \\\"shipto_contactname\\\": \\\"{{#var.order.extension_attributes.shipping_assignments[0].shipping.address.firstname}} {{#var.order.extension_attributes.shipping_assignments[0].shipping.address.lastname}}\\\",\\r\\n    \\\"shipto_country\\\": \\\"{{#var.order.extension_attributes.shipping_assignments[0].shipping.address.country_id}}\\\",\\r\\n    \\\"shipto_postalcode\\\": \\\"{{#var.order.extension_attributes.shipping_assignments[0].shipping.address.postcode}}\\\",\\r\\n    \\\"shipto_telephone\\\": \\\"{{#var.order.extension_attributes.shipping_assignments[0].shipping.address.telephone}}\\\",\\r\\n    \\\"shipto_line1\\\": \\\"{{#var.order.extension_attributes.shipping_assignments[0].shipping.address.street[0]}}\\\",\\r\\n    \\\"billto_city\\\": \\\"{{#var.order.billing_address.city}}\\\",\\r\\n    \\\"billto_contactname\\\": \\\"{{#var.order.billing_address.firstname}} {{#var.order.billing_address.lastname}}\\\",\\r\\n    \\\"billto_country\\\": \\\"{{#var.order.billing_address.country_id}}\\\",\\r\\n    \\\"billto_line1\\\": \\\"{{#var.order.billing_address.street[0]}}\\\",\\r\\n    \\\"billto_postalcode\\\": \\\"{{#var.order.billing_address.postcode}}\\\",\\r\\n    \\\"billto_telephone\\\": \\\"{{#var.order.billing_address.telephone}}\\\"\\r\\n}\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Create order into Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_0iyaldx\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.Success\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Creation successful?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_10mk1nc\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.errors += $\\\"\\\\n Order already exists on Dynamics365, order id: {#var.order.entity_id}\\\"\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_1oh9txw\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_18es51m\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.errors += $\\\"\\\\nAn error occurred when creating the order into Dynamics365:\\\\n{#result.ErrorMessage}\\\"\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_084g1pn\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_17etyfe\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_11kg5j4\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"GET\"},\"Path\":{\"mode\":\"text\",\"value\":\"salesorders?$filter=ordernumber eq '{{\\\"MAG\\\" + #var.order.entity_id}}'\"},\"Payload\":{\"mode\":\"text\",\"value\":\"\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Get created order from Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_16awrck\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"GET\"},\"Path\":{\"mode\":\"text\",\"value\":\"uoms?$filter=name eq 'Primary Unit'\"},\"Payload\":{\"mode\":\"text\",\"value\":\"\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Get unit of measurement from Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_1dsidvv\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.Success\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Unit of measurement gotten successfully?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_1iznpsk\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"GET\"},\"Path\":{\"mode\":\"text\",\"value\":\"contacts?$filter=emailaddress1 eq '{{#var.order.customer_email}}'\"},\"Payload\":{\"mode\":\"text\",\"value\":\"\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Get contact information from Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_1vkw495\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.Success\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Contact information gotten successfully?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0fe2bps\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0hybrw0\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_03fj5ap\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.errors += $\\\"\\\\nAn error occurred when fetching contact information from Dynamics365:\\\\n{#result.ErrorMessage}\\\"\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"DataStoreReference_0kiz3dh\",\"Type\":22,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Magento\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_1ex111t\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0xcfa28\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_1mzezp3\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_0j9lotw\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.errors += $\\\"\\\\nAn error occurred when fetching unit of measurement information from Dynamics365:\\\\n{#result.ErrorMessage}\\\"\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"DataStoreReference_1du7bqs\",\"Type\":22,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_0kwaels\",\"Type\":12,\"Parameters\":{\"variableName\":\"linesProcessingFinished\",\"variableExpression\":{\"mode\":\"csharp\",\"value\":\"false\"},\"shouldAssignVariable\":{\"mode\":\"toggle\",\"value\":true}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Initialize loop variable\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_1hqo3rs\",\"Type\":13,\"Parameters\":{},\"SelectedTypeId\":\"\",\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_09n02ai\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"GET\"},\"Path\":{\"mode\":\"text\",\"value\":\"products?$filter=productnumber eq '{{\\\"MAG\\\" + #var.order.items[#var.index].product_id}}'\"},\"Payload\":{\"mode\":\"text\",\"value\":\"\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Get product information from Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_0ktykp0\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"POST\"},\"Path\":{\"mode\":\"text\",\"value\":\"salesorderdetails\"},\"Payload\":{\"mode\":\"text\",\"value\":\"{\\r\\n    \\\"salesorderid@odata.bind\\\": \\\"/salesorders({{#result[Get created order from Dynamics365].Data.value[0].salesorderid}})\\\",\\r\\n    \\\"productid@odata.bind\\\": \\\"/products({{#result[Get product information from Dynamics365].Data.value[0].productid}})\\\",\\r\\n    \\\"quantity\\\": {{(float)#var.order.items[#var.index].qty_ordered}},\\r\\n    \\\"uomid@odata.bind\\\": \\\"/uoms({{#result[Get unit of measurement from Dynamics365].Data.value[0].uomid}})\\\",\\r\\n    \\\"tax\\\": {{#var.order.items[#var.index].tax_amount}}\\r\\n}\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Add order product to created order\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_11aievh\",\"Type\":1,\"Parameters\":{\"input\":{\"ClientId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientId\"},\"TenantId\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365TenantId\"},\"ClientSecret\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365ClientSecret\"},\"Dynamics365Url\":{\"mode\":\"csharp\",\"value\":\"#var.Dynamics365Url\"},\"Method\":{\"mode\":\"select\",\"value\":\"DELETE\"},\"Path\":{\"mode\":\"text\",\"value\":\"salesorders({{#result[Get created order from Dynamics365].Data.value[0].salesorderid}})\"},\"Payload\":{\"mode\":\"text\",\"value\":\"\"}},\"options\":{\"ApiVersion\":{\"mode\":\"text\",\"value\":\"v9.1\"},\"ThrowExceptionOnErrorResponse\":{\"mode\":\"toggle\",\"value\":false}},\"cancellationToken\":null},\"SelectedTypeId\":\"/ProcessTask/81e6cd26-703c-4622-bbad-9743db2a6ae6/v2\",\"PromoteResultAs\":null,\"Name\":\"Delete the created order\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":false,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_1tkwy54\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.Success && #result.Data.value.Count > 0\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Product information gotten successfully?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0lcyhoi\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_0xt54e1\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#result.Success\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Order product added successfully?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_0cku1vj\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.index += 1\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_0lc0x56\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.linesProcessingFinished = true\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"DataStoreReference_1b9n4bv\",\"Type\":22,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Dynamics365\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_1cjxt28\",\"Type\":12,\"Parameters\":{\"variableName\":\"index\",\"variableExpression\":{\"mode\":\"csharp\",\"value\":\"0\"},\"shouldAssignVariable\":{\"mode\":\"toggle\",\"value\":true}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Initialize loop index\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_1mcq9ri\",\"Type\":11,\"Parameters\":{\"maxIterations\":{\"mode\":\"integer\",\"value\":\"10000\"},\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.linesProcessingFinished == false\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Process order lines\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Gateway_05h2njg\",\"Type\":2,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.index == #var.order.items.Count - 1\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"All lines processed?\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Event_0afkaim\",\"Type\":5,\"Parameters\":{\"expression\":{\"mode\":\"csharp\",\"value\":\"#var.linesProcessingFinished = true\"}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":null,\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0fsf42v\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_1pnnn1j\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_0ta0j1v\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"yes\",\"Description\":null,\"IsDefault\":false,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_1ev31fu\",\"Type\":12,\"Parameters\":{\"variableName\":\"\",\"variableExpression\":{\"mode\":\"csharp\",\"value\":\"#var.insertedCount++\"},\"shouldAssignVariable\":{\"mode\":\"toggle\",\"value\":false}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Increment insert count\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_12xmh3s\",\"Type\":12,\"Parameters\":{\"variableName\":\"insertedCount\",\"variableExpression\":{\"mode\":\"csharp\",\"value\":\"0\"},\"shouldAssignVariable\":{\"mode\":\"toggle\",\"value\":true}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Initialize insert count\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_00yje9n\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_069d16b\",\"Type\":12,\"Parameters\":{\"variableName\":\"variable\",\"variableExpression\":{\"mode\":\"csharp\",\"value\":\"#var.errors += #result.ErrorMessage != null ? $\\\"\\\\nCould not get product information in Dynamics365 for the product from Magento with id: {#var.order.items[#var.index].product_id}. Error message: {#result.ErrorMessage}\\\" : $\\\"\\\\nCould not find a product in Dynamics365 matching the product from Magento with id: {#var.order.items[#var.index].product_id}.\\\"\"},\"shouldAssignVariable\":{\"mode\":\"toggle\",\"value\":true}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Add error to error variable\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Activity_067pldp\",\"Type\":12,\"Parameters\":{\"variableName\":\"\",\"variableExpression\":{\"mode\":\"csharp\",\"value\":\"#var.errors += $\\\"\\\\nCould not insert product {#var.order.items[#var.index].sku} into the order from Magento with id {#var.order.entity_id}. The partially completed order was deleted from Dynamics365. Error message: {#result[Add order product to created order].ErrorMessage}\\\"\"},\"shouldAssignVariable\":{\"mode\":\"toggle\",\"value\":false}},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"Add error to errors variable\",\"Description\":null,\"IsDefault\":null,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null},{\"Id\":\"Flow_1sch0kb\",\"Type\":4,\"Parameters\":{},\"SelectedTypeId\":null,\"PromoteResultAs\":null,\"Name\":\"no\",\"Description\":null,\"IsDefault\":true,\"ShouldRetry\":null,\"MaxRetryCount\":null,\"ShouldNotLogResult\":null,\"ShouldDispose\":null}]",
					"ManualTriggerJson": "[]",
					"IsSubprocess": false,
					"TriggersJson": "[{\"$type\":\"ManualTrigger\",\"config\":{},\"name\":\"Manual\",\"id\":\"StartEvent_1\",\"shouldNotLogParameters\":null}]",
					"AssemblyName": null,
					"PackageId": null,
					"PackageVersion": null,
					"UsedTasksJson": "[\"/ProcessTask/D2F2020E-4CE6-4E5F-879F-EF34E57C9FCA/v1\",\"/ProcessTask/81E6CD26-703C-4622-BBAD-9743DB2A6AE6/v2\"]",
					"UsedSubprocessesJson": "{}",
					"ProcessExecutionVersion": "",
					"FrendsVersion": "5.7.3.1743",
					"TargetFramework": "net8.0",
					"StaticRequiredEnvironmentVariables": [],
					"RequiredEnvironmentVariables": [],
					"PromotedResultVariablesJson": "[]",
					"MajorVersion": 1,
					"MinorVersion": 0,
					"IsForMonitoringRule": false,
					"ProcessVariablesJson": null
				},
				"LinkedTasks": {
					"5a27ab14-b300-4acb-8e0b-8daf6aeac783": [
						{
							"Id": "d2f2020e-4ce6-4e5f-879f-ef34e57c9fca",
							"PackageId": "Frends.HTTP.Request",
							"PackageVersion": "1.1.2",
							"Name": "Frends.HTTP.Request.HTTP.Request(Input, Options, CancellationToken)",
							"FrameworkIdentifier": ".NETCoreApp"
						},
						{
							"Id": "81e6cd26-703c-4622-bbad-9743db2a6ae6",
							"PackageId": "Frends.MicrosoftDynamics365.Request",
							"PackageVersion": "1.1.0",
							"Name": "Frends.MicrosoftDynamics365.Request.MicrosoftDynamics365.Request(Input, Options, CancellationToken)",
							"FrameworkIdentifier": ".NETCoreApp"
						}
					]
				},
				"LinkedSubProcess": {},
				"Version": "Acc41"
			}
		}
	]
}