profiles
Creates, updates, deletes, gets or lists a profiles resource.
Overview
| Name | profiles |
| Type | Resource |
| Id | cloudflare.zero_trust.profiles |
Fields
The following fields are returned by SELECT queries:
- get
- list
Get profile response.
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | The id of the profile (uuid). |
name | string | The name of the profile. |
ai_context_enabled | boolean | |
allowed_match_count | integer (int32) | Related DLP policies will trigger when the match count exceeds the number set. |
confidence_threshold | string | (low, medium, high, very_high) (default: low) |
context_awareness | object | Scan the context of predefined entries to only return matches surrounded by keywords. |
created_at | string (date-time) | When the profile was created. |
data_classes | array | Data classes associated with this profile. |
data_tags | array | Data tags associated with this profile. |
description | string | The description of the profile. |
entries | array | |
ocr_enabled | boolean | |
open_access | boolean | Whether this profile can be accessed by anyone. |
sensitivity_levels | array | Sensitivity levels associated with this profile. |
shared_entries | array | (x-stainless-terraform-configurability: computed) |
type | string | (custom) |
updated_at | string (date-time) | When the profile was lasted updated. |
List all profiles response.
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | The id of the profile (uuid). |
name | string | The name of the profile. |
ai_context_enabled | boolean | |
allowed_match_count | integer (int32) | Related DLP policies will trigger when the match count exceeds the number set. |
confidence_threshold | string | (low, medium, high, very_high) (default: low) |
context_awareness | object | Scan the context of predefined entries to only return matches surrounded by keywords. |
created_at | string (date-time) | When the profile was created. |
data_classes | array | Data classes associated with this profile. |
data_tags | array | Data tags associated with this profile. |
description | string | The description of the profile. |
entries | array | |
ocr_enabled | boolean | |
open_access | boolean | Whether this profile can be accessed by anyone. |
sensitivity_levels | array | Sensitivity levels associated with this profile. |
shared_entries | array | (x-stainless-terraform-configurability: computed) |
type | string | (custom) |
updated_at | string (date-time) | When the profile was lasted updated. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | account_id, profile_id | Fetches a DLP profile by ID. | |
list | select | account_id | all | Lists all DLP profiles in an account. |
update_predefined | exec | account_id, profile_id | Updates a DLP predefined profile. Only supports enabling/disabling entries. | |
create_config | exec | account_id, profile_id | This is similar to update_predefined but only returns entries that are enabled. This is needed for our terraform API Creates a DLP predefined profile. Only supports enabling/disabling entries. |
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 |
|---|---|---|
account_id | string | The Cloudflare account ID. |
profile_id | string (uuid) | |
all | boolean | Return all profiles, including those that current account does not have access to. |
SELECT examples
- get
- list
Fetches a DLP profile by ID.
SELECT
id,
name,
ai_context_enabled,
allowed_match_count,
confidence_threshold,
context_awareness,
created_at,
data_classes,
data_tags,
description,
entries,
ocr_enabled,
open_access,
sensitivity_levels,
shared_entries,
type,
updated_at
FROM cloudflare.zero_trust.profiles
WHERE account_id = '{{ account_id }}' -- required
AND profile_id = '{{ profile_id }}' -- required
;
Lists all DLP profiles in an account.
SELECT
id,
name,
ai_context_enabled,
allowed_match_count,
confidence_threshold,
context_awareness,
created_at,
data_classes,
data_tags,
description,
entries,
ocr_enabled,
open_access,
sensitivity_levels,
shared_entries,
type,
updated_at
FROM cloudflare.zero_trust.profiles
WHERE account_id = '{{ account_id }}' -- required
AND all = '{{ all }}'
;
Lifecycle Methods
- update_predefined
- create_config
Updates a DLP predefined profile. Only supports enabling/disabling entries.
EXEC cloudflare.zero_trust.profiles.update_predefined
@account_id='{{ account_id }}' --required,
@profile_id='{{ profile_id }}' --required
@@json=
'{
"ai_context_enabled": {{ ai_context_enabled }},
"allowed_match_count": {{ allowed_match_count }},
"confidence_threshold": "{{ confidence_threshold }}",
"context_awareness": "{{ context_awareness }}",
"entries": "{{ entries }}",
"ocr_enabled": {{ ocr_enabled }}
}'
;
This is similar to update_predefined but only returns entries that are enabled. This is needed for our terraform API Creates a DLP predefined profile. Only supports enabling/disabling entries.
EXEC cloudflare.zero_trust.profiles.create_config
@account_id='{{ account_id }}' --required,
@profile_id='{{ profile_id }}' --required
@@json=
'{
"ai_context_enabled": {{ ai_context_enabled }},
"allowed_match_count": {{ allowed_match_count }},
"confidence_threshold": "{{ confidence_threshold }}",
"enabled_entries": "{{ enabled_entries }}",
"entries": "{{ entries }}",
"ocr_enabled": {{ ocr_enabled }}
}'
;