Treasure Workflow
API Documents/Treasure Workflow API//
- Set a cancel-requested flag on a running attempt
List attempts with filters
Start a workflow execution as a new session or a new attempt of an existing session
Get an attempt
List attempts of a session of a given attempt
List tasks of an attempt
Set a cancel-requested fl...
Treasure Workflow (1.0)
Download OpenAPI description
Languages
Servers
Mock server
https://docs.treasuredata.com/_mock/apis/workflow
aws
https://api-workflow.treasuredata.com
aws-tokyo
https://api-workflow.treasuredata.co.jp
eu01
https://api-workflow.eu01.treasuredata.com
ap02
https://api-workflow.ap02.treasuredata.com
ap03
https://api-workflow.ap03.treasuredata.com
- Mock serverhttps://docs.treasuredata.com/_mock/apis/workflow/api/attempts
- awshttps://api-workflow.treasuredata.com/api/attempts
- aws-tokyohttps://api-workflow.treasuredata.co.jp/api/attempts
- eu01https://api-workflow.eu01.treasuredata.com/api/attempts
- ap02https://api-workflow.ap02.treasuredata.com/api/attempts
- ap03https://api-workflow.ap03.treasuredata.com/api/attempts
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.treasuredata.com/_mock/apis/workflow/api/attempts?project=string&workflow=string&include_retried=true&last_id=0&page_size=0' \
-H 'Authorization: TD1 <YOUR_TOKEN_HERE>'Response
application/json
{ "attempts": [ { … } ] }
Request
"resume" is used to rerun an attempt. It is used in the case an attempt failed then users want to resume it from the middle.It has two modes "failed" or "from" to set the way to resume.In "failed" mode, the attempt specified by "attemptId" is resumed from the failed tasks.In "from" mode, the attempt is resumed from the task which is set in "from" field.
Security
ApiKeyAuth
project name. workflowId or (projectName and workflowName) are required
Example: "project-a"
Configuration to resume an attempt. {"mode": "failed", "attemptId": "12345"} or {"mode": "from", "attemptId": "12345", "from": "+t1"}
workflow ID. workflowId or (projectName and workflowName) are required
Example: "123456"
- Mock serverhttps://docs.treasuredata.com/_mock/apis/workflow/api/attempts
- awshttps://api-workflow.treasuredata.com/api/attempts
- aws-tokyohttps://api-workflow.treasuredata.co.jp/api/attempts
- eu01https://api-workflow.eu01.treasuredata.com/api/attempts
- ap02https://api-workflow.ap02.treasuredata.com/api/attempts
- ap03https://api-workflow.ap03.treasuredata.com/api/attempts
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
https://docs.treasuredata.com/_mock/apis/workflow/api/attempts \
-H 'Authorization: TD1 <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"allowQueueing": true,
"params": {
"key1": 12345
},
"projectName": "project-a",
"resume": {
"mode": "from",
"attemptId": "12345",
"from": "string"
},
"retryAttemptName": "string",
"sessionTime": "2023-08-17T18:56:24+09:00",
"workflowId": "123456",
"workflowName": "workflow-a"
}'Response
application/json
{ "cancelRequested": true, "createdAt": "2023-08-18T06:52:33Z", "done": true, "finishedAt": "2023-08-18T06:52:33Z", "id": "123456", "index": 1, "params": {}, "poolId": "42", "project": { "id": "123456", "name": "abcdefg" }, "retryAttemptName": "retry-12345", "sessionId": "123456", "sessionTime": "2022-12-31T23:59:00+00:00", "sessionUuid": "2b91a014-076e-4c6d-8b51-f4f91089cab2", "status": "running", "success": true, "workflow": { "id": "123456", "name": "abcdefg" } }
- Mock serverhttps://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}
- awshttps://api-workflow.treasuredata.com/api/attempts/{id}
- aws-tokyohttps://api-workflow.treasuredata.co.jp/api/attempts/{id}
- eu01https://api-workflow.eu01.treasuredata.com/api/attempts/{id}
- ap02https://api-workflow.ap02.treasuredata.com/api/attempts/{id}
- ap03https://api-workflow.ap03.treasuredata.com/api/attempts/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}' \
-H 'Authorization: TD1 <YOUR_TOKEN_HERE>'Response
application/json
{ "cancelRequested": true, "createdAt": "2023-08-18T06:52:33Z", "done": true, "finishedAt": "2023-08-18T06:52:33Z", "id": "123456", "index": 1, "params": {}, "poolId": "42", "project": { "id": "123456", "name": "abcdefg" }, "retryAttemptName": "retry-12345", "sessionId": "123456", "sessionTime": "2022-12-31T23:59:00+00:00", "sessionUuid": "2b91a014-076e-4c6d-8b51-f4f91089cab2", "status": "running", "success": true, "workflow": { "id": "123456", "name": "abcdefg" } }
- Mock serverhttps://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}/kill
- awshttps://api-workflow.treasuredata.com/api/attempts/{id}/kill
- aws-tokyohttps://api-workflow.treasuredata.co.jp/api/attempts/{id}/kill
- eu01https://api-workflow.eu01.treasuredata.com/api/attempts/{id}/kill
- ap02https://api-workflow.ap02.treasuredata.com/api/attempts/{id}/kill
- ap03https://api-workflow.ap03.treasuredata.com/api/attempts/{id}/kill
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
'https://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}/kill' \
-H 'Authorization: TD1 <YOUR_TOKEN_HERE>'Response
application/json
{ "cancelRequested": true, "createdAt": "2023-08-18T06:52:33Z", "done": true, "finishedAt": "2023-08-18T06:52:33Z", "id": "123456", "index": 1, "params": {}, "poolId": "42", "project": { "id": "123456", "name": "abcdefg" }, "retryAttemptName": "retry-12345", "sessionId": "123456", "sessionTime": "2022-12-31T23:59:00+00:00", "sessionUuid": "2b91a014-076e-4c6d-8b51-f4f91089cab2", "status": "running", "success": true, "workflow": { "id": "123456", "name": "abcdefg" } }
- Mock serverhttps://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}/retries
- awshttps://api-workflow.treasuredata.com/api/attempts/{id}/retries
- aws-tokyohttps://api-workflow.treasuredata.co.jp/api/attempts/{id}/retries
- eu01https://api-workflow.eu01.treasuredata.com/api/attempts/{id}/retries
- ap02https://api-workflow.ap02.treasuredata.com/api/attempts/{id}/retries
- ap03https://api-workflow.ap03.treasuredata.com/api/attempts/{id}/retries
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}/retries' \
-H 'Authorization: TD1 <YOUR_TOKEN_HERE>'Response
application/json
{ "attempts": [ { … } ] }
- Mock serverhttps://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}/tasks
- awshttps://api-workflow.treasuredata.com/api/attempts/{id}/tasks
- aws-tokyohttps://api-workflow.treasuredata.co.jp/api/attempts/{id}/tasks
- eu01https://api-workflow.eu01.treasuredata.com/api/attempts/{id}/tasks
- ap02https://api-workflow.ap02.treasuredata.com/api/attempts/{id}/tasks
- ap03https://api-workflow.ap03.treasuredata.com/api/attempts/{id}/tasks
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.treasuredata.com/_mock/apis/workflow/api/attempts/{id}/tasks' \
-H 'Authorization: TD1 <YOUR_TOKEN_HERE>'Response
application/json
{ "tasks": [ { … } ] }