configuration
Creates, updates, deletes, gets or lists a configuration resource.
Overview
| Name | configuration |
| Type | Resource |
| Id | cloudflare.billing.configuration |
Fields
The following fields are returned by SELECT queries:
- list
| Name | Datatype | Description |
|---|---|---|
bot_overrides | object | |
enabled | boolean | |
price_usd_microcents | integer |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list | select | zone_id | Gets the pay-per-crawl config for a zone including the bot configuration. | |
pay_per_crawl_create_config | insert | zone_id | Creates the pay-per-crawl config for a zone. | |
pay_per_crawl_patch_config | update | zone_id | Changes the pay-per-crawl config for a zone. |
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 |
|---|---|---|
zone_id | string | The Cloudflare zone ID. |
SELECT examples
- list
Gets the pay-per-crawl config for a zone including the bot configuration.
SELECT
bot_overrides,
enabled,
price_usd_microcents
FROM cloudflare.billing.configuration
WHERE zone_id = '{{ zone_id }}' -- required
;
INSERT examples
- pay_per_crawl_create_config
- Manifest
Creates the pay-per-crawl config for a zone.
INSERT INTO cloudflare.billing.configuration (
bot_overrides,
enabled,
price_usd_microcents,
zone_id
)
SELECT
'{{ bot_overrides }}',
{{ enabled }},
{{ price_usd_microcents }},
'{{ zone_id }}'
RETURNING
errors,
messages,
result,
result_info,
success
;
# Description fields are for documentation purposes
- name: configuration
props:
- name: zone_id
value: "{{ zone_id }}"
description: Required parameter for the configuration resource.
- name: bot_overrides
value: "{{ bot_overrides }}"
- name: enabled
value: {{ enabled }}
- name: price_usd_microcents
value: {{ price_usd_microcents }}
UPDATE examples
- pay_per_crawl_patch_config
Changes the pay-per-crawl config for a zone.
UPDATE cloudflare.billing.configuration
SET
bot_overrides = '{{ bot_overrides }}',
enabled = {{ enabled }},
price_usd_microcents = {{ price_usd_microcents }}
WHERE
zone_id = '{{ zone_id }}' --required
RETURNING
errors,
messages,
result,
result_info,
success;