tasks
Creates, updates, deletes, gets or lists a tasks resource.
Overview​
| Name | tasks |
| Type | Resource |
| Id | ovh.ip.tasks |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
task_id | integer | the id of the task (wire: taskId) |
comment | string | Details of this task |
destination | object | Destination for moveFloatingIp tasks |
done_date | string (date-time) | Completion date (wire: doneDate) |
function | string | Function name (arinBlockReassign, changeRipeOrg, checkAndReleaseIp, genericMoveFloatingIp, supernetByoipFailoverPartitioning) |
last_update | string (date-time) | last update (wire: lastUpdate) |
start_date | string (date-time) | Task Creation date (wire: startDate) |
status | string | Task status (cancelled, customerError, doing, done, init, ovhError, todo) |
IP tasks
| Name | Datatype | Description |
|---|---|---|
task_id | integer | the id of the task (wire: taskId) |
comment | string | Details of this task |
destination | object | Destination for moveFloatingIp tasks |
done_date | string (date-time) | Completion date (wire: doneDate) |
function | string | Function name (arinBlockReassign, changeRipeOrg, checkAndReleaseIp, genericMoveFloatingIp, supernetByoipFailoverPartitioning) |
last_update | string (date-time) | last update (wire: lastUpdate) |
start_date | string (date-time) | Task Creation date (wire: startDate) |
status | string | Task status (cancelled, customerError, doing, done, init, ovhError, todo) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | ip, task_id | Get a task. Returns the task's function, status, details, and its start, last update and completion dates. | |
list | select | ip | function, status, x_pagination_mode | List tasks. Returns the IDs of the block's asynchronous operations, filterable by function or status. |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
api_host | string | The OVHcloud API host. Selected by OVH_ENDPOINT (ovh-eu, ovh-ca or ovh-us; default ovh-eu). (default: api.eu.ovhcloud.com, x-stackQL-envVarSelector: {"envVar":"OVH_ENDPOINT","default":"ovh-eu","values":{"ovh-eu":"api.eu.ovhcloud.com","ovh-ca":"api.ca.ovhcloud.com","ovh-us":"api.us.ovhcloud.com"}}) |
ip | string (ip-block) | |
task_id | integer | the id of the task (wire: taskId) |
function | string | Filter the value of function property (=) |
status | string | Filter the value of status property (=) |
x_pagination_mode | string | Sent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode) |
SELECT examples​
- get
- list
Get a task. Returns the task's function, status, details, and its start, last update and completion dates.
SELECT
task_id,
comment,
destination,
done_date,
function,
last_update,
start_date,
status
FROM ovh.ip.tasks
WHERE ip = '{{ ip }}' -- required
AND task_id = '{{ task_id }}' -- required
;
List tasks. Returns the IDs of the block's asynchronous operations, filterable by function or status.
SELECT
task_id,
comment,
destination,
done_date,
function,
last_update,
start_date,
status
FROM ovh.ip.tasks
WHERE ip = '{{ ip }}' -- required
AND function = '{{ function }}'
AND status = '{{ status }}'
AND x_pagination_mode = '{{ x_pagination_mode }}'
;