analyticsadmin.properties.dataStreams.measurementProtocolSecrets.create
Creates a Measurement Protocol secret for a Google Analytics 4 data stream and returns the new secret as JSON; blocked in read-only profiles.
Instructions
Creates a measurement protocol secret [HTTP POST] — creates or triggers a change; refused under --readonly safety profiles. Returns the API's response resource as JSON — request body is a JSON GoogleAnalyticsAdminV1betaMeasurementProtocolSecret object accepting displayName, name, secretValue; pass it via params or whole via body_file Siblings over the same resource: delete, get, list, patch.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | No | Extra KEY=VALUE query pairs for endpoints whose parameters Discovery does not describe. | |
| params | No | Parameter map merged into the request; typed parameters win. | |
| parent | Yes | [URL path segment] Required. The parent resource where this secret will be created. Format: properties/{property}/dataStreams/{dataStream} | |
| dry_run | No | Return the request that would be sent, without sending it. | |
| body_file | No | Read the request body from this file ('-' for stdin) instead of building one from the parameters. The body is a JSON GoogleAnalyticsAdminV1betaMeasurementProtocolSecret object. | |
| request_body | No | Request body of type GoogleAnalyticsAdminV1betaMeasurementProtocolSecret: pass it via `params` (merged into the built body) or whole via `body_file`. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | ||
| displayName | No | ||
| secretValue | No |