gcloud alpha dlp job-triggers create Stay organized with collections Save and categorize content based on your preferences.
- NAME
- gcloud alpha dlp job-triggers create - creates a Cloud DLP job trigger
- SYNOPSIS
gcloud alpha dlp job-triggers createJOB_TRIGGER--trigger-schedule=TRIGGER_SCHEDULE(--datastore-kind=DATASTORE_KIND|--input-table=INPUT_TABLE|--path=PATH)(--output-table=[OUTPUT_TABLE,…] |--output-topics=[OUTPUT_TOPICS,…])[--description=DESCRIPTION][--display-name=DISPLAY_NAME][--exclude-info-types][--include-quote][--info-types=[INFOTYPE,…]][--max-findings=MAX_FINDINGS][--max-findings-per-item=MAX_FINDINGS_PER_ITEM][--min-likelihood=MIN_LIKELIHOOD; default="possible"][GCLOUD_WIDE_FLAG …]
- DESCRIPTION
(ALPHA)Creates a Cloud DLP job trigger.- EXAMPLES
- The following command creates a job trigger named
my_job_trigger:gcloudalphadlpjob-triggerscreatemy_job_trigger--display-nameDaily_Inspect_Trigger--description'My New Trigger'--input-tablemyproject.mydataset.input--output-topicsmy-topic--max-findings-per-item3--max-findings1000--info-typesPHONE_NUMBER,US_DRIVERS_LICENSE--min-likelihoodvery-likely--include-quote--exclude-info-types--trigger-schedule8400s - POSITIONAL ARGUMENTS
- Job trigger resource - The Cloud DLP job trigger to create. The job trigger namecan contain uppercase and lowercase letters, numbers, and hyphens -- that is, itmust match the regular expression:
[a-zA-Z\\d-]+. The maximum lengthis 100 characters. If not supplied, the system generates one. This represents aCloud resource. (NOTE) Some attributes are not given arguments in this group butcan be set in other ways.To set the
projectattribute:- provide the argument
job_triggeron the command line with a fullyspecified name; - provide the argument
--projecton the command line; - set the property
core/project.
This must be specified.
JOB_TRIGGER- ID of the job_trigger or fully qualified identifier for the job_trigger.
To set the
job_triggerattribute:- provide the argument
job_triggeron the command line.
- provide the argument
- provide the argument
- Job trigger resource - The Cloud DLP job trigger to create. The job trigger namecan contain uppercase and lowercase letters, numbers, and hyphens -- that is, itmust match the regular expression:
- REQUIRED FLAGS
--trigger-schedule=TRIGGER_SCHEDULE- Duration specifying how often the triggered job will be run. A scheduled starttime will be skipped if the previous execution has not ended when its scheduledtime occurs. Value must be a time duration greater than or equal to 1 day andcan be no longer than 60 days.
See
$gcloud topicdatetimes for information on duration formats. - Exactly one of these must be specified:
--datastore-kind=DATASTORE_KIND- The Cloud Datastore kind or table to scan. The kind can optionally be prefixedwith the Cloud Datastore namespace ID - for example
namespace:example-kindor simplyexample-kind --input-table=INPUT_TABLE- BigQuery table to scan. BigQuery tables are uniquely identified by theirproject_id, dataset_id, and table_id in the format
<project_id>.<dataset_id>.<table_id>. --path=PATH- Google Cloud Storage URL to scan for files with optional wildcard character(
*) -- for example, gs://my-bucket/*.
- Exactly one of these must be specified:
--output-table=[OUTPUT_TABLE,…]- Publishes results of a Cloud DLP job a BigQuery table. BigQuery tables areuniquely identified by their project_id, dataset_id, and table_id in the format
<project_id>.<dataset_id>.<table_id>. --output-topics=[OUTPUT_TOPICS,…]- Publishes the results of a Cloud DLP job to one or more Cloud Pub/Sub topics.
Note: The topic must have given publishing access rights to the DLP API serviceaccount executing the Cloud DLP job.
- OPTIONAL FLAGS
--description=DESCRIPTION- User provided description (maximum 256 characters)
--display-name=DISPLAY_NAME- Display name of the job trigger (maximum 100 characters)
--exclude-info-types- Whether or not to exclude type information of the findings. Type information isincluded by default.
--include-quote- If True, a contextual quote from the data that triggered a finding is includedin the response. Even if the content is not text, it may be converted to atextual representation in the response. For example, given the input value 'Myphone number is (415) 555-0890' and a search for the infoType PHONE_NUMBER, thecontextual quote would be '(415) 555-0890.'
--info-types=[INFOTYPE,…]- Which infoTypes to scan input for. The values must correspond to infoType valuesfound in documentation. For more information about valid infoTypes, seeinfoTypesReference
--max-findings=MAX_FINDINGS- Maximum number of findings that will be returned per execution.
If not specified, no limits are applied.
--max-findings-per-item=MAX_FINDINGS_PER_ITEM- Maximum number of findings that will be returned for each item scanned.
If not specified, no limits are applied.
--min-likelihood=MIN_LIKELIHOOD; default="possible"- Only return findings equal to or above this threshold.
MIN_LIKELIHOODmust be one of:likely,possible,unlikely,very-likely,very-unlikely.
- GCLOUD WIDE FLAGS
- These flags are available to all commands:
--access-token-file,--account,--billing-project,--configuration,--flags-file,--flatten,--format,--help,--impersonate-service-account,--log-http,--project,--quiet,--trace-token,--user-output-enabled,--verbosity.Run
$gcloud helpfor details. - API REFERENCE
- This command uses the
dlp/v2API. The full documentation for thisAPI can be found at:https://cloud.google.com/sensitive-data-protection/docs/ - NOTES
- This command is currently in alpha and might change without notice. If thiscommand fails with API permission errors despite specifying the correct project,you might be trying to access an API with an invitation-only early accessallowlist.
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-05-07 UTC.