Try the MCP server for Google Analytics. Install from
GitHub, and see the
announcement for more details.
Method: properties.submitUserDeletion
Stay organized with collections
Save and categorize content based on your preferences.
Submits a request for user deletion for a property.
HTTP request
POST https://analyticsadmin.googleapis.com/v1alpha/{name=properties/*}:submitUserDeletion
The URL uses gRPC Transcoding syntax.
Path parameters
Parameters |
name |
string
Required. The name of the property to submit user deletion for.
|
Request body
The request body contains data with the following structure:
JSON representation |
{
// Union field user can be only one of the following:
"userId": string,
"clientId": string,
"appInstanceId": string,
"userProvidedData": string
// End of list of possible types for union field user .
} |
Fields |
Union field user . The user to submit a deletion request for user can be only one of the following: |
userId |
string
Google Analytics user ID.
|
clientId |
string
Google Analytics client ID.
|
appInstanceId |
string
Firebase application instance ID.
|
userProvidedData |
string
User-provided data. May contain either one email address or one phone number. Email addresses should be normalized as such:
- lowercase
- remove periods before @ for gmail.com/googlemail.com addresses
- remove all spaces
Phone numbers should be normalized as such:
- remove all non digit characters
- add + prefix
|
Response body
Response message for properties.submitUserDeletion RPC.
If successful, the response body contains data with the following structure:
JSON representation |
{
"deletionRequestTime": string
} |
Fields |
deletionRequestTime |
string (Timestamp format)
Marks the moment for which all visitor data before this point should be deleted. This is set to the time at which the deletion request was received. Uses RFC 3339, where generated output will always be Z-normalized and uses 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: "2014-10-02T15:01:23Z" , "2014-10-02T15:01:23.045123456Z" or "2014-10-02T15:01:23+05:30" .
|
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/analytics.edit
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-19 UTC.
[null,null,["Last updated 2025-08-19 UTC."],[],[],null,["# Method: properties.submitUserDeletion\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n - [JSON representation](#body.SubmitUserDeletionResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nSubmits a request for user deletion for a property.\n\n### HTTP request\n\n`POST https://analyticsadmin.googleapis.com/v1alpha/{name=properties/*}:submitUserDeletion`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|--------|--------------------------------------------------------------------------|\n| `name` | `string` Required. The name of the property to submit user deletion for. |\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { // Union field `user` can be only one of the following: \"userId\": string, \"clientId\": string, \"appInstanceId\": string, \"userProvidedData\": string // End of list of possible types for union field `user`. } ``` |\n\n| Fields ||\n|--------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Union field `user`. The user to submit a deletion request for `user` can be only one of the following: ||\n| `userId` | `string` Google Analytics [user ID](https://firebase.google.com/docs/analytics/userid). |\n| `clientId` | `string` Google Analytics [client ID](https://support.google.com/analytics/answer/11593727). |\n| `appInstanceId` | `string` Firebase [application instance ID](https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics.html#getAppInstanceId). |\n| `userProvidedData` | `string` [User-provided data](https://support.google.com/analytics/answer/14077171). May contain either one email address or one phone number. Email addresses should be normalized as such: - lowercase - remove periods before @ for gmail.com/googlemail.com addresses - remove all spaces Phone numbers should be normalized as such: - remove all non digit characters - add + prefix |\n\n### Response body\n\nResponse message for properties.submitUserDeletion RPC.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|-------------------------------------------|\n| ``` { \"deletionRequestTime\": string } ``` |\n\n| Fields ||\n|-----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `deletionRequestTime` | `string (`[Timestamp](https://protobuf.dev/reference/protobuf/google.protobuf/#timestamp)` format)` Marks the moment for which all visitor data before this point should be deleted. This is set to the time at which the deletion request was received. Uses RFC 3339, where generated output will always be Z-normalized and uses 0, 3, 6 or 9 fractional digits. Offsets other than \"Z\" are also accepted. Examples: `\"2014-10-02T15:01:23Z\"`, `\"2014-10-02T15:01:23.045123456Z\"` or `\"2014-10-02T15:01:23+05:30\"`. |\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/analytics.edit`"]]