Imports a workflow and its child nodes that are specified by the FlowSpec field to DataStudio.
Operation description
Note
You cannot use this API operation to import multiple workflows at a time. If you specify multiple workflows by using FlowSpec, the system imports only the first specified workflow.
Note
ImportWorkflowDefinition is an asynchronous operation. After you send a request, an asynchronous task is generated, and the system returns the ID of the asynchronous task. You can call the GetJobStatus operation to query the status of the asynchronous task.
Debugging
Authorization information
There is currently no authorization information disclosed in the API.
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
ProjectId | string | Yes | The DataWorks workspace ID. You can log on to the DataWorks console and go to the Workspace page to query the ID. You must configure this parameter to specify the DataWorks workspace to which the API operation is applied. | 123456 |
Spec | string | Yes | The FlowSpec field information about the workflow. For more information, see FlowSpec . |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "7C352CB7-CD88-50CF-9D0D-E81BDF020E7F",
"AsyncJob": {
"Completed": false,
"CreateTime": 1706581425000,
"Error": "target folder already exists: XXXX",
"Id": "1234567691239009XXXX",
"Progress": 0,
"Response": "632647691239009XXXX",
"Status": "Running",
"Type": "Create"
}
}
Error codes
For a list of error codes, visit the Service error codes.