document_fingerprints
Creates, updates, deletes, gets or lists a document_fingerprints resource.
Overview
| Name | document_fingerprints |
| Type | Resource |
| Id | cloudflare.zero_trust.document_fingerprints |
Fields
The following fields are returned by SELECT queries:
- get
- list
Document fingerprint read was successful.
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | |
name | string | |
entry_id | string (uuid) | |
file_name | string | |
created_at | string (date-time) | |
description | string | (default: ) |
match_percent | integer (int32) | |
status | string | (empty, uploading, pending, processing, failed, complete) |
updated_at | string (date-time) | |
version | integer (int64) |
Document fingerprint read was successful.
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | |
name | string | |
entry_id | string (uuid) | |
file_name | string | |
created_at | string (date-time) | |
description | string | (default: ) |
match_percent | integer (int32) | |
status | string | (empty, uploading, pending, processing, failed, complete) |
updated_at | string (date-time) | |
version | integer (int64) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | account_id, document_fingerprint_id | ||
list | select | account_id | Lists all document fingerprints configured for DLP scanning in the account. | |
dlp_document_fingerprints_update | insert | account_id, document_fingerprint_id | Updates metadata for an existing document fingerprint, such as its name or description. | |
dlp_document_fingerprints_create | insert | account_id, name, match_percent | Creates a new document fingerprint for DLP scanning. Document fingerprints detect documents that are structurally similar to the uploaded sample. | |
dlp_document_fingerprints_upload | replace | account_id, document_fingerprint_id, file | Uploads a new document to create or update a fingerprint. The document structure is analyzed to enable detection of similar documents. | |
dlp_document_fingerprints_delete | delete | account_id, document_fingerprint_id | Removes a document fingerprint from DLP configuration. Documents matching this fingerprint will no longer be detected. |
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. |
document_fingerprint_id | string (uuid) |
SELECT examples
- get
- list
Document fingerprint read was successful.
SELECT
id,
name,
entry_id,
file_name,
created_at,
description,
match_percent,
status,
updated_at,
version
FROM cloudflare.zero_trust.document_fingerprints
WHERE account_id = '{{ account_id }}' -- required
AND document_fingerprint_id = '{{ document_fingerprint_id }}' -- required
;
Lists all document fingerprints configured for DLP scanning in the account.
SELECT
id,
name,
entry_id,
file_name,
created_at,
description,
match_percent,
status,
updated_at,
version
FROM cloudflare.zero_trust.document_fingerprints
WHERE account_id = '{{ account_id }}' -- required
;
INSERT examples
- dlp_document_fingerprints_update
- dlp_document_fingerprints_create
- Manifest
Updates metadata for an existing document fingerprint, such as its name or description.
INSERT INTO cloudflare.zero_trust.document_fingerprints (
description,
match_percent,
name,
account_id,
document_fingerprint_id
)
SELECT
'{{ description }}',
{{ match_percent }},
'{{ name }}',
'{{ account_id }}',
'{{ document_fingerprint_id }}'
RETURNING
errors,
messages,
result,
success
;
Creates a new document fingerprint for DLP scanning. Document fingerprints detect documents that are structurally similar to the uploaded sample.
INSERT INTO cloudflare.zero_trust.document_fingerprints (
description,
match_percent,
name,
account_id
)
SELECT
'{{ description }}',
{{ match_percent }} /* required */,
'{{ name }}' /* required */,
'{{ account_id }}'
RETURNING
errors,
messages,
result,
success
;
# Description fields are for documentation purposes
- name: document_fingerprints
props:
- name: account_id
value: "{{ account_id }}"
description: Required parameter for the document_fingerprints resource.
- name: document_fingerprint_id
value: "{{ document_fingerprint_id }}"
description: Required parameter for the document_fingerprints resource.
- name: description
value: "{{ description }}"
default:
- name: match_percent
value: {{ match_percent }}
- name: name
value: "{{ name }}"
REPLACE examples
- dlp_document_fingerprints_upload
Uploads a new document to create or update a fingerprint. The document structure is analyzed to enable detection of similar documents.
REPLACE cloudflare.zero_trust.document_fingerprints
SET
file = '{{ file }}'
WHERE
account_id = '{{ account_id }}' --required
AND document_fingerprint_id = '{{ document_fingerprint_id }}' --required
AND file = '{{ file }}' --required
RETURNING
errors,
messages,
result,
success;
DELETE examples
- dlp_document_fingerprints_delete
Removes a document fingerprint from DLP configuration. Documents matching this fingerprint will no longer be detected.
DELETE FROM cloudflare.zero_trust.document_fingerprints
WHERE account_id = '{{ account_id }}' --required
AND document_fingerprint_id = '{{ document_fingerprint_id }}' --required
;