Skip to content

Paths for task

Entry points that interact with Task entities.

/api/v1/tasks

GET

Return an array of all tasks.

Note

When the authorization feature is activated (available in the Enterprise edition only), this endpoint requires TAIPY_READER role.

Code example:

  curl -X GET http://localhost:5000/api/v1/tasks

Responses

POST

Create a new task from its config_id. If the config does not exist, a 404 error is returned.

Note

When the authorization feature is activated (available in the Enterprise edition only), this endpoint requires TAIPY_EDITOR role.

Code example:

  curl -X POST http://localhost:5000/api/v1/tasks?config_id=my_task_config

Parameters

Name Type Required Description
config_id string Yes The identifier of the task configuration.

Responses

/api/v1/tasks/submit/{task_id}

POST

Execute a task by task_id. If the task does not exist, a 404 error is returned.

Note

When the authorization feature is activated (available in the Enterprise edition only), this endpoint requires TAIPY_EXECUTOR role.

Code example:

  curl -X POST http://localhost:5000/api/v1/tasks/submit/TASK_my_config_75750ed8-4e09-4e00-958d-e352ee426cc9

Parameters

Name Type Required Description
task_id string Yes -

Responses

/api/v1/tasks/{task_id}

DELETE

Delete a task. If the task does not exist, a 404 error is returned.

Note

When the authorization feature is activated (available in the Enterprise edition only), this endpoint requires TAIPY_EDITOR role.

Code example:

  curl -X DELETE http://localhost:5000/api/v1/tasks/TASK_my_config_75750ed8-4e09-4e00-958d-e352ee426cc9

Parameters

Name Type Required Description
task_id string Yes The identifier of the task.

Responses

  • 200
    Status: OK

    Name Type
    message string
  • 404
    Status: Not Found

    No task has the task_id identifier.

GET

Return a single task by task_id. If the task does not exist, a 404 error is returned.

Note

When the authorization feature is activated (available in the Enterprise edition only), this endpoint requires TAIPY_READER role.

Code example:

  curl -X GET http://localhost:5000/api/v1/tasks/TASK_my_config_75750ed8-4e09-4e00-958d-e352ee426cc9

Parameters

Name Type Required Description
task_id string Yes The identifier of the task.

Responses