HEX
Server: Apache/2.4.65 (Ubuntu)
System: Linux ielts-store-v2 6.8.0-1036-gcp #38~22.04.1-Ubuntu SMP Thu Aug 14 01:19:18 UTC 2025 x86_64
User: root (0)
PHP: 7.2.34-54+ubuntu20.04.1+deb.sury.org+1
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
Upload Files
File: //snap/google-cloud-cli/396/help/man/man1/gcloud_alpha_dlp_text_redact.1
.TH "GCLOUD_ALPHA_DLP_TEXT_REDACT" 1



.SH "NAME"
.HP
gcloud alpha dlp text redact \- redact potentially sensitive data from text content



.SH "SYNOPSIS"
.HP
\f5gcloud alpha dlp text redact\fR \fB\-\-info\-types\fR=[\fIINFOTYPE\fR,...] (\fB\-\-content\fR=\fICONTENT\fR\ |\ \fB\-\-content\-file\fR=\fIPATH_TO_FILE\fR) (\fB\-\-remove\-findings\fR\ |\ \fB\-\-replace\-with\-info\-type\fR\ |\ \fB\-\-replacement\-text\fR=\fIREPLACEMENT_TEXT\fR) [\fB\-\-min\-likelihood\fR=\fIMIN_LIKELIHOOD\fR;\ default="possible"] [\fB\-\-output\-file\fR=\fIOUTPUT_FILE\fR] [\fIGCLOUD_WIDE_FLAG\ ...\fR]



.SH "DESCRIPTION"

\fB(ALPHA)\fR Redacts potentially sensitive data from text content.



.SH "EXAMPLES"

To redact email addresses from a file named my\-data.csv and write the redacted
contents to my\-redacted\-data.csv, run:

.RS 2m
$ gcloud alpha dlp text redact \-\-info\-types EMAIL_ADDRESS \e
    \-\-replace\-with\-info\-type \-\-content\-file my\-data.csv \e
    \-\-output\-file my\-redacted\-data.csv
.RE



.SH "REQUIRED FLAGS"

.RS 2m
.TP 2m
\fB\-\-info\-types\fR=[\fIINFOTYPE\fR,...]

Which infoTypes to scan input for. The values must correspond to infoType values
found in documentation. For more information about valid infoTypes, see
infoTypes Reference (https://cloud.google.com/dlp/docs/infotypes\-reference)

.TP 2m

Exactly one of these must be specified:


.RS 2m
.TP 2m
\fB\-\-content\fR=\fICONTENT\fR

Text content to redact sensitive data from.

.TP 2m
\fB\-\-content\-file\fR=\fIPATH_TO_FILE\fR

Text file to scan for sensitive data to redact. Can also be a CSV file
specifying tabular data. For CSV files, up to 50,000 values per request are
allowed. To read from stdin pass '\-' as the file name. Use a full or relative
path to a local file containing the value of content_file.

.RE
.sp
.TP 2m

Exactly one of these must be specified:


.RS 2m
.TP 2m
\fB\-\-remove\-findings\fR

If specified, all sensitive data will be removed, instead of replaced.

.TP 2m
\fB\-\-replace\-with\-info\-type\fR

If specified, all sensitive data will be replaced with its infoType. For
example, 'email:guest@example.com' would become 'email:[EMAIL_ADDRESS]'.

.TP 2m
\fB\-\-replacement\-text\fR=\fIREPLACEMENT_TEXT\fR

Text to replace each sensitive data finding with.


.RE
.RE
.sp

.SH "OPTIONAL FLAGS"

.RS 2m
.TP 2m
\fB\-\-min\-likelihood\fR=\fIMIN_LIKELIHOOD\fR; default="possible"

Only return findings equal to or above this threshold. \fIMIN_LIKELIHOOD\fR must
be one of: \fBlikely\fR, \fBpossible\fR, \fBunlikely\fR, \fBvery\-likely\fR,
\fBvery\-unlikely\fR.

.TP 2m
\fB\-\-output\-file\fR=\fIOUTPUT_FILE\fR

Path to the file to write redacted contents to.


.RE
.sp

.SH "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 \fB$ gcloud help\fR for details.



.SH "API REFERENCE"

This command uses the \fBdlp/v2\fR API. The full documentation for this API can
be found at: https://cloud.google.com/sensitive\-data\-protection/docs/



.SH "NOTES"

This command is currently in alpha and might change without notice. If this
command fails with API permission errors despite specifying the correct project,
you might be trying to access an API with an invitation\-only early access
allowlist.