Skip to main content

status

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

Overview

Namestatus
TypeResource
Idcloudflare.ddos_protection.status

Fields

The following fields are returned by SELECT queries:

Get protection status response.

NameDatatypeDescription
enabledboolean

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
listselectaccount_idGet the protection status of the account.
editupdateaccount_id, enabledUpdate the protection status of the account.

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
account_idstringThe Cloudflare account ID.

SELECT examples

Get the protection status of the account.

SELECT
enabled
FROM cloudflare.ddos_protection.status
WHERE account_id = '{{ account_id }}' -- required
;

UPDATE examples

Update the protection status of the account.

UPDATE cloudflare.ddos_protection.status
SET
enabled = {{ enabled }}
WHERE
account_id = '{{ account_id }}' --required
AND enabled = {{ enabled }} --required
RETURNING
errors,
messages,
result,
success;