Tip: If you are not already familiar with the Data360 DQ+ API, see API documentation for a general introduction.
1. Create a new pipeline
The following request creates a new pipeline called API_pipeline
in the Documentation
environment:
curl -X POST -H "Content-Type:application/json" -H "Authorization:Basic <base64-encoded value>" -H "Accept:application/json" -d '{"query":"mutation {createPipeline(input:{pipeline:{envNameOrId:\"Documentation\", name:\"API_pipeline\"}}) {envId id name }}","variables":null}' https://example.infogix.com/api
The query contains the following fields which will be returned in the response:
envId
id
name
The response shows that a new pipeline has been created with the id 132457
. The name of the pipeline is API_pipeline
, as specified in the request:
{
"data": {
"createPipeline": {
"envid": 3180,
"id": 132457,
"name": "API_pipeline"
}
}
}
2. Create a path within the pipeline
Using the pipeline id that you obtained in step 1, create a path within your new pipeline:
curl -X POST -H "Content-Type:application/json" -H "Authorization:Basic <base64-encoded value>" -H "Accept:application/json" -d '{"query":"mutation {createPath(input:{path:{name:\"API_path\", parentId:132457}}) {id name }}","variables":null}' https://example.infogix.com/api
The response includes the id
and name
of the new path:
{
"data": {
"createPath": {
"id": 132933,
"name": "API_path"
}
}
}
The new pipeline and path are visible in the Documentation environment: