Skip to main content

tasks

Creates, updates, deletes, gets or lists a tasks resource.

Overview​

Nametasks
TypeResource
Idovh.pack_xdsl.tasks

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
idinteger
functionstring
statusstringStatus of a task. (cancelled, doing, done, error, problem, todo)
update_datestring (date-time) (wire: updateDate)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectid, pack_nameGet a task of an xDSL pack. Returns the function, status and last update date of a task scheduled on the pack.
listselectpack_namefunction, status, x_pagination_modeList the tasks of an xDSL pack. Returns the IDs of the tasks scheduled on the pack. Get a task for its function, status and last update date.

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.

NameDatatypeDescription
api_hoststringThe 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"}})
idintegerId of the object
pack_namestringThe internal name of your pack (wire: packName)
functionstringFilter the value of function property (=)
statusstringFilter the value of status property (=)
x_pagination_modestringSent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode)

SELECT examples​

Get a task of an xDSL pack. Returns the function, status and last update date of a task scheduled on the pack.

SELECT
id,
function,
status,
update_date
FROM ovh.pack_xdsl.tasks
WHERE id = '{{ id }}' -- required
AND pack_name = '{{ pack_name }}' -- required
;