resources
Creates, updates, deletes, gets or lists a resources resource.
Overview​
| Name | resources |
| Type | Resource |
| Id | ovh.managed_cms.resources |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | Unique identifier of the service |
checksum | string | Computed hash used to control concurrent modification requests. Here, it represents the current target specification value. |
current_state | object | Current state of the service (wire: currentState) |
current_tasks | array | Ongoing asynchronous tasks related to the service (wire: currentTasks) |
iam | object | IAM resource metadata |
resource_status | string | Service readiness in the system (CREATING, CREATION_PLANNED, DELETING, ERROR, OUT_OF_SYNC, READY, SUSPENDED, UNKNOWN, UPDATING) (wire: resourceStatus) |
A Managed CMS service
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | Unique identifier of the service |
checksum | string | Computed hash used to control concurrent modification requests. Here, it represents the current target specification value. |
current_state | object | Current state of the service (wire: currentState) |
current_tasks | array | Ongoing asynchronous tasks related to the service (wire: currentTasks) |
iam | object | IAM resource metadata |
resource_status | string | Service readiness in the system (CREATING, CREATION_PLANNED, DELETING, ERROR, OUT_OF_SYNC, READY, SUSPENDED, UNKNOWN, UPDATING) (wire: resourceStatus) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | service_id | Returns the plan, dashboard URLs and disk, visits and websites quotas of the service, with its running tasks. (Alpha version) | |
list | select | x_pagination_cursor, x_pagination_size, iam_tags | Returns the Managed CMS services of the account. (Alpha version) | |
update | update | service_id | Updates the service. Set flushCDNDate to a new date to flush the CDN of all its websites. (Alpha version) | |
dashboard_application_password | exec | serviceId, cms | Each call creates a new application password on the existing administrator user. The previous ones stay valid. They can be revoked from the CMS administration. (Beta version) | |
flush_cdn | exec | serviceId | Flushes the CDN cache of all the websites of the service and returns the task. Fails if a task is already running on the service. (Alpha version) | |
log_url | exec | serviceId, kind | Generates a temporary URL to read the logs of one kind. Returns the URL and its expiration date. (Beta 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.
| 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"}}) |
serviceId | string (uuid) | Service ID |
service_id | string (uuid) | Service ID (wire: serviceId) |
iam_tags | object | Filter resources on IAM tags (wire: iamTags) |
x_pagination_cursor | string | Pagination cursor (wire: X-Pagination-Cursor) |
x_pagination_size | integer | Pagination size (wire: X-Pagination-Size) |
SELECT examples​
- get
- list
Returns the plan, dashboard URLs and disk, visits and websites quotas of the service, with its running tasks. (Alpha version)
SELECT
id,
checksum,
current_state,
current_tasks,
iam,
resource_status
FROM ovh.managed_cms.resources
WHERE service_id = '{{ service_id }}' -- required
;
Returns the Managed CMS services of the account. (Alpha version)
SELECT
id,
checksum,
current_state,
current_tasks,
iam,
resource_status
FROM ovh.managed_cms.resources
WHERE x_pagination_cursor = '{{ x_pagination_cursor }}'
AND x_pagination_size = '{{ x_pagination_size }}'
AND iam_tags = '{{ iam_tags }}'
;
UPDATE examples​
- update
Updates the service. Set flushCDNDate to a new date to flush the CDN of all its websites. (Alpha version)
UPDATE ovh.managed_cms.resources
SET
target_spec = '{{ target_spec }}'
WHERE
service_id = '{{ service_id }}' --required
RETURNING
id,
checksum,
current_state,
current_tasks,
resource_status;
Lifecycle Methods​
EXEC variables use wire (API) names.
- dashboard_application_password
- flush_cdn
- log_url
Each call creates a new application password on the existing administrator user. The previous ones stay valid. They can be revoked from the CMS administration. (Beta version)
EXEC ovh.managed_cms.resources.dashboard_application_password
@serviceId='{{ serviceId }}' --required
@@json=
'{
"cms": "{{ cms }}"
}'
;
Flushes the CDN cache of all the websites of the service and returns the task. Fails if a task is already running on the service. (Alpha version)
EXEC ovh.managed_cms.resources.flush_cdn
@serviceId='{{ serviceId }}' --required
;
Generates a temporary URL to read the logs of one kind. Returns the URL and its expiration date. (Beta version)
EXEC ovh.managed_cms.resources.log_url
@serviceId='{{ serviceId }}' --required
@@json=
'{
"kind": "{{ kind }}"
}'
;