Deploy Data Kit Components by Using Deploy Data Kit Components Flow

Deploy all standard data kit components sequentially to a target org using the Deploy Data Kit Components flow. You provide the input for the flow: data kit name, data space name, and the component payload list and send the POST request to trigger the flow. Before moving to the next component, the flow waits for the deployment status of the previous component. The response body contains the Flow_InterviewGuid.

This flow is available by using the REST API version 61.0 and later.

The basic workflow to deploy standard data kit components includes these steps.

  1. Install your package with a data kit and its components in a target org.
  2. Trigger the flow by using the REST API.
1curl https://{MyDomainName}.my.salesforce.com/services/data/v{version}/actions/custom/flow/sfdatakit__DeployDataKitComponents

Request Payload Syntax 

This is the syntax required for the request payload. The payload can be in either JSON or XML format.

HTTP Method 

POST

Authentication 

Authorization: Bearer token

Properties 

NameTypeDescription
dataKitComponentsInputsfdatakit__DeployComponentInputRequired. A collection of data kit components to deploy. The collection list contains the payload details about the components.
dataKitNameInputTextRequired. The data kit name that contains the components.
dataKitDataSpaceInputTextOptional. The name of the data space to deploy the data kit. If a data space isn’t defined, the system deploys the components in the default data space.

Request Payload Examples 

The example shows sample input payloads for different data kit components:

Data Stream Bundle

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6                    "componentType": "DataStreamBundle",
7                    "bundleConfig": {
8                        "connectorType": "CRM",
9                        "bundleName": "hello", #full Qualified Bundle Name with namespace in datakit
10                        "forceNoRefresh": false,
11                        "bundleCRMConfig": {
12                            "orgId": "org123" #Data Org Id
13                        }
14                    }
15                }
16            ],
17            "dataKitNameInput": "datakit1",
18            "dataKitDataSpaceInput" : "default"
19        }
20    ]
21}

Connector Framework

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6                    "componentType": "DataStreamBundle",
7                    "bundleConfig": {
8                        "connectorType": "MORECONNECTORS",
9                        "bundleName": "hello", #full Qualified Bundle Name with namespace in datakit
10                        "forceNoRefresh": false,
11                        "bundleConnectorFrameworkConfig": {
12                            "connectionName": "name"
13                        }
14                    }
15                }
16            ],
17            "dataKitNameInput": "datakit1",
18            "dataKitDataSpaceInput" : "default"
19        }
20    ]
21}

Ingest API

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6                    "componentType": "DataStreamBundle",
7                    "bundleConfig": {
8                        "connectorType": "INGESTAPI",
9                        "bundleName": "hello", #full Qualified Bundle Name with namespace in datakit
10                        "forceNoRefresh": false,
11                        "bundleIngestApiConfig": {
12                            "connectorName": "name" #ingestion API connector name
13                        }
14                    }
15                }
16            ],
17            "dataKitNameInput": "datakit1",
18            "dataKitDataSpaceInput" : "default"
19        }
20    ]
21}

Streaming App

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6                    "componentType": "DataStreamBundle",
7                    "bundleConfig": {
8                        "connectorType": "STREAMINGAPP",
9                        "bundleName": "hello", #full Qualified Bundle Name with namespace in datakit
10                        "forceNoRefresh": false,
11                        "bundleStreamingAppConfig": {
12                            "connectorName": "name", #Streaming app connector name
13                            "streamingAppDataConnectorType": "MobileApp" #MobileApp,WebApp
14                        }
15                    }
16                }
17            ],
18            "dataKitNameInput": "datakit1",
19            "dataKitDataSpaceInput" : "default"
20        }
21    ]
22}

Calculated Insights

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6                    "componentType": "CalculatedInsight",
7                    "calculatedInsightsConfig": {
8                        "apiName": "crm",#full Qualified CI Name with namespace in datakit
9                        "apiNameOverride": "hello", #api name of CI to be created on org
10                        "label": "lab", #label of CI to be created on org
11                        "publishInterval":"NotScheduled" #NotScheduled,One,Six,Twelve,TwentyFour
12                    }
13                }
14            ],
15            "dataKitNameInput": "datakit1",
16            "dataKitDataSpaceInput" : "default"
17        }
18    ]
19}

Data Lake Object

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6                    "componentType": "DataLakeObject",
7                    "dloConfig": {
8                        "dataSourceObjectDevName": "crm",#full Qualified DLO Name with namespace in datakit
9                        "apiName": "hello",#api name of DLO to be created on org
10                        "label": "lab"#label of DLO to be created on org
11                    }
12                }
13            ],
14            "dataKitNameInput": "datakit1",
15            "dataKitDataSpaceInput" : "default"
16        }
17    ]
18}

Data Graph

1{
2  "inputs": [
3    {
4      "dataKitComponentsInput": [
5        {
6          "components": [
7            {
8              "type": "DataGraph",
9              "config": {
10                "templateDevName": "DG1",
11                "name": "DG1",
12                "label": "DG1"
13              }
14            }
15          ]
16        }
17      ],
18      "dataKitNameInput": "datakit1",
19      "dataKitDataSpaceInput": "default"
20    }
21  ]
22}

Data Transform

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6                    "componentType": "DataTransform",
7                    "dataTransformConfig": {
8                    "dataTransformType": "BATCH", #STREAMING,BATCH
9                    "dataTransformDevName": "BatchTransformAccount",#full Qualified Transform Name with namespace in datakit
10                    "apiName":"BatchTransformAccount",#api name of Transform to be created on org
11                    "label" : "BatchTransformAccount"#label of Transform to be created on org
12                    }
13                }
14            ],
15            "dataKitNameInput": "datakit1",
16            "dataKitDataSpaceInput" : "default"
17        }
18    ]
19}

DataStream B2C Commerce

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6 "components": [
7  {
8   "type": "DataStreamBundle",
9   "config": {
10    "connectorType": "COMMERCE",
11    "bundleName": "commercebundle1",
12    "bundleConfig": {
13     "instanceId": "bjmp_prd"
14    }
15   }
16  }
17 ]
18}
19            ],
20            "dataKitNameInput": "datakit1",
21            "dataKitDataSpaceInput" : "default"
22        }
23    ]
24}

Identity Resolution

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6   "components":[
7      {
8         "type":"IdentityResolution",
9         "config":{
10            "dataSpaceName":"default",
11            "templateDevName":"Individual_1111",
12            "dataKitDevName":"DK6"
13         }
14      }
15   ]
16}
17            ],
18            "dataKitNameInput": "datakit1",
19            "dataKitDataSpaceInput" : "default"
20        }
21    ]
22}

Segment

1{
2    "inputs": [
3        {
4            "dataKitComponentsInput": [
5                {
6  "components": [
7    {
8      "type": "MarketSegment",
9      "config": {
10        "name": "datakitSegment",
11        "dataKitName": "kit01"
12      }
13    }
14  ]
15}
16            ],
17            "dataKitNameInput": "datakit1",
18            "dataKitDataSpaceInput" : "default"
19        }
20    ]
21}

To find out which Data 360 components are packageable, see Data 360 Extensibility Readiness Matrix. Deployment Example

This example request triggers the deploy data kit components flow to deploy the data stream bundle, data lake objects, and data transforms components from the ** MyTestDatakit** data kit.

curl https://{MyDomainName}.my.salesforce.com/services/data/v{version}/actions/custom/flow/sfdatakit__DeployDataKitComponents

Data Kit Request Body

1{
2  "inputs": [
3    {
4      "dataKitComponentsInput": [
5        {
6          "componentType": "DataStreamBundle",
7          "bundleConfig": {
8            "connectorType": "CRM",
9            "bundleName": "CRMBundleTest",
10            "forceNoRefresh": false,
11            "bundleCRMConfig": {
12              "orgId": "00DU200000051Q5"
13            }
14          }
15        },
16        {
17          "componentType": "DataLakeObject",
18          "dloConfig": {
19            "dataSourceObjectDevName": "Account_A_New_DLO",
20            "apiName": "Account_A_New_DLO",
21            "label": "Account A New DLO"
22          }
23        },
24        {
25          "componentType": "DataLakeObject",
26          "dloConfig": {
27            "dataSourceObjectDevName": "Account_P_New_DLO",
28            "apiName": "Account_P_New_DLO",
29            "label": "Account P New DLO"
30          }
31        },
32        {
33          "componentType": "DataTransform",
34          "dataTransformConfig": {
35            "dataTransformType": "BATCH",
36            "dataTransformDevName": "BatchTransformAccount",
37            "apiName": "BatchTransformAccount",
38            "label": "BatchTransformAccount"
39          }
40        }
41      ],
42      "dataKitNameInput": "MyTestDatakit",
43      "dataKitDataSpaceInput": "default"
44    }
45  ]
46}

Data Kit Response Body

1{
2  "actionName": "sfdatakit__DeployDataKitComponents",
3  "errors": null,
4  "invocationId": null,
5  "isSuccess": true,
6  "outputValues": {
7    "Flow__InterviewGuid": "43c0ccb801784ff02fa0c8a1919b1877f5-605b",
8    "Flow__InterviewStatus": "Waiting"
9  },
10  "sortOrder": -1,
11  "version": 1
12}

See Also