Skip to main content

api_revisions

Creates, updates, deletes, gets or lists an api_revisions resource.

Overview​

Nameapi_revisions
TypeResource
Idovh.account.api_revisions

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
available_revisionsarrayAvailable API revisions to transition to (wire: availableRevisions)
current_stateobjectCurrent state of the API revision (wire: currentState)
target_specobjectTarget specification for the API revision (wire: targetSpec)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectGet the current and available API revisions (Alpha version)
updateupdatetarget_specUpdate the current API revision (Alpha version)

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"}})

SELECT examples​

Get the current and available API revisions (Alpha version)

SELECT
available_revisions,
current_state,
target_spec
FROM ovh.account.api_revisions
;

UPDATE examples​

Update the current API revision (Alpha version)

UPDATE ovh.account.api_revisions
SET
target_spec = '{{ target_spec }}'
WHERE
target_spec = '{{ target_spec }}' --required
RETURNING
available_revisions,
current_state,
target_spec;