Class Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client

Client for the AnalyticsAdminService service.

Service Interface for the Analytics Admin API (GA4).

Inherits

  • Object

Methods

.configure

def self.configure() { |config| ... } -> Client::Configuration

Configure the AnalyticsAdminService Client class.

See Configuration for a description of the configuration fields.

Yields
  • (config) — Configure the Client client.
Yield Parameter
Example
# Modify the configuration for all AnalyticsAdminService clients
::Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.configure do |config|
  config.timeout = 10.0
end

#acknowledge_user_data_collection

def acknowledge_user_data_collection(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionResponse
def acknowledge_user_data_collection(property: nil, acknowledgement: nil) -> ::Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionResponse

Acknowledges the terms of user data collection for the specified property.

This acknowledgement must be completed (either in the Google Analytics UI or via this API) before MeasurementProtocolSecret resources may be created.

Overloads
def acknowledge_user_data_collection(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionResponse
Pass arguments to acknowledge_user_data_collection via a request object, either of type Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def acknowledge_user_data_collection(property: nil, acknowledgement: nil) -> ::Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionResponse
Pass arguments to acknowledge_user_data_collection via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • property (::String) — Required. The property for which to acknowledge user data collection.
  • acknowledgement (::String) — Required. An acknowledgement that the caller of this method understands the terms of user data collection.

    This field must contain the exact value: "I acknowledge that I have the necessary privacy disclosures and rights from my end users for the collection and processing of their data, including the association of such data with the visitation information Google Analytics collects from my site and/or app property."

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionRequest.new

# Call the acknowledge_user_data_collection method.
result = client.acknowledge_user_data_collection request

# The returned object is of type Google::Analytics::Admin::V1alpha::AcknowledgeUserDataCollectionResponse.
p result
def approve_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ApproveDisplayVideo360AdvertiserLinkProposalResponse
def approve_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Analytics::Admin::V1alpha::ApproveDisplayVideo360AdvertiserLinkProposalResponse

Approves a DisplayVideo360AdvertiserLinkProposal. The DisplayVideo360AdvertiserLinkProposal will be deleted and a new DisplayVideo360AdvertiserLink will be created.

Overloads
def approve_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ApproveDisplayVideo360AdvertiserLinkProposalResponse
Pass arguments to approve_display_video360_advertiser_link_proposal via a request object, either of type Google::Analytics::Admin::V1alpha::ApproveDisplayVideo360AdvertiserLinkProposalRequest or an equivalent Hash.
Parameters
def approve_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Analytics::Admin::V1alpha::ApproveDisplayVideo360AdvertiserLinkProposalResponse
Pass arguments to approve_display_video360_advertiser_link_proposal via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DisplayVideo360AdvertiserLinkProposal to approve. Example format: properties/1234/displayVideo360AdvertiserLinkProposals/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ApproveDisplayVideo360AdvertiserLinkProposalRequest.new

# Call the approve_display_video360_advertiser_link_proposal method.
result = client.approve_display_video360_advertiser_link_proposal request

# The returned object is of type Google::Analytics::Admin::V1alpha::ApproveDisplayVideo360AdvertiserLinkProposalResponse.
p result

#archive_custom_dimension

def archive_custom_dimension(request, options = nil) -> ::Google::Protobuf::Empty
def archive_custom_dimension(name: nil) -> ::Google::Protobuf::Empty

Archives a CustomDimension on a property.

Overloads
def archive_custom_dimension(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to archive_custom_dimension via a request object, either of type Google::Analytics::Admin::V1alpha::ArchiveCustomDimensionRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ArchiveCustomDimensionRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def archive_custom_dimension(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to archive_custom_dimension via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the CustomDimension to archive. Example format: properties/1234/customDimensions/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ArchiveCustomDimensionRequest.new

# Call the archive_custom_dimension method.
result = client.archive_custom_dimension request

# The returned object is of type Google::Protobuf::Empty.
p result

#archive_custom_metric

def archive_custom_metric(request, options = nil) -> ::Google::Protobuf::Empty
def archive_custom_metric(name: nil) -> ::Google::Protobuf::Empty

Archives a CustomMetric on a property.

Overloads
def archive_custom_metric(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to archive_custom_metric via a request object, either of type Google::Analytics::Admin::V1alpha::ArchiveCustomMetricRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ArchiveCustomMetricRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def archive_custom_metric(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to archive_custom_metric via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the CustomMetric to archive. Example format: properties/1234/customMetrics/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ArchiveCustomMetricRequest.new

# Call the archive_custom_metric method.
result = client.archive_custom_metric request

# The returned object is of type Google::Protobuf::Empty.
p result
def audit_user_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AuditUserLink>
def audit_user_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AuditUserLink>

Lists all user links on an account or property, including implicit ones that come from effective permissions granted by groups or organization admin roles.

If a returned user link does not have direct permissions, they cannot be removed from the account or property directly with the DeleteUserLink command. They have to be removed from the group/etc that gives them permissions, which is currently only usable/discoverable in the GA or GMP UIs.

Overloads
def audit_user_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AuditUserLink>
Pass arguments to audit_user_links via a request object, either of type Google::Analytics::Admin::V1alpha::AuditUserLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::AuditUserLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def audit_user_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AuditUserLink>
Pass arguments to audit_user_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: accounts/1234
  • page_size (::Integer) — The maximum number of user links to return. The service may return fewer than this value. If unspecified, at most 1000 user links will be returned. The maximum value is 5000; values above 5000 will be coerced to 5000.
  • page_token (::String) — A page token, received from a previous AuditUserLinks call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to AuditUserLinks must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::AuditUserLinksRequest.new

# Call the audit_user_links method.
result = client.audit_user_links request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::AuditUserLink.
  p response
end
def batch_create_user_links(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::BatchCreateUserLinksResponse
def batch_create_user_links(parent: nil, notify_new_users: nil, requests: nil) -> ::Google::Analytics::Admin::V1alpha::BatchCreateUserLinksResponse

Creates information about multiple users' links to an account or property.

This method is transactional. If any UserLink cannot be created, none of the UserLinks will be created.

Overloads
def batch_create_user_links(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::BatchCreateUserLinksResponse
Pass arguments to batch_create_user_links via a request object, either of type BatchCreateUserLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::BatchCreateUserLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def batch_create_user_links(parent: nil, notify_new_users: nil, requests: nil) -> ::Google::Analytics::Admin::V1alpha::BatchCreateUserLinksResponse
Pass arguments to batch_create_user_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The account or property that all user links in the request are for. This field is required. The parent field in the CreateUserLinkRequest messages must either be empty or match this field. Example format: accounts/1234
  • notify_new_users (::Boolean) — Optional. If set, then email the new users notifying them that they've been granted permissions to the resource. Regardless of whether this is set or not, notify_new_user field inside each individual request is ignored.
  • requests (::Array<::Google::Analytics::Admin::V1alpha::CreateUserLinkRequest, ::Hash>) — Required. The requests specifying the user links to create. A maximum of 1000 user links can be created in a batch.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::BatchCreateUserLinksRequest.new

# Call the batch_create_user_links method.
result = client.batch_create_user_links request

# The returned object is of type Google::Analytics::Admin::V1alpha::BatchCreateUserLinksResponse.
p result
def batch_delete_user_links(request, options = nil) -> ::Google::Protobuf::Empty
def batch_delete_user_links(parent: nil, requests: nil) -> ::Google::Protobuf::Empty

Deletes information about multiple users' links to an account or property.

Overloads
def batch_delete_user_links(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to batch_delete_user_links via a request object, either of type BatchDeleteUserLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::BatchDeleteUserLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def batch_delete_user_links(parent: nil, requests: nil) -> ::Google::Protobuf::Empty
Pass arguments to batch_delete_user_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The account or property that all user links in the request are for. The parent of all values for user link names to delete must match this field. Example format: accounts/1234
  • requests (::Array<::Google::Analytics::Admin::V1alpha::DeleteUserLinkRequest, ::Hash>) — Required. The requests specifying the user links to update. A maximum of 1000 user links can be updated in a batch.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::BatchDeleteUserLinksRequest.new

# Call the batch_delete_user_links method.
result = client.batch_delete_user_links request

# The returned object is of type Google::Protobuf::Empty.
p result
def batch_get_user_links(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::BatchGetUserLinksResponse
def batch_get_user_links(parent: nil, names: nil) -> ::Google::Analytics::Admin::V1alpha::BatchGetUserLinksResponse

Gets information about multiple users' links to an account or property.

Overloads
def batch_get_user_links(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::BatchGetUserLinksResponse
Pass arguments to batch_get_user_links via a request object, either of type BatchGetUserLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::BatchGetUserLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def batch_get_user_links(parent: nil, names: nil) -> ::Google::Analytics::Admin::V1alpha::BatchGetUserLinksResponse
Pass arguments to batch_get_user_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The account or property that all user links in the request are for. The parent of all provided values for the 'names' field must match this field. Example format: accounts/1234
  • names (::Array<::String>) — Required. The names of the user links to retrieve. A maximum of 1000 user links can be retrieved in a batch. Format: accounts/{accountId}/userLinks/{userLinkId}
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::BatchGetUserLinksRequest.new

# Call the batch_get_user_links method.
result = client.batch_get_user_links request

# The returned object is of type Google::Analytics::Admin::V1alpha::BatchGetUserLinksResponse.
p result
def batch_update_user_links(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::BatchUpdateUserLinksResponse
def batch_update_user_links(parent: nil, requests: nil) -> ::Google::Analytics::Admin::V1alpha::BatchUpdateUserLinksResponse

Updates information about multiple users' links to an account or property.

Overloads
def batch_update_user_links(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::BatchUpdateUserLinksResponse
Pass arguments to batch_update_user_links via a request object, either of type BatchUpdateUserLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::BatchUpdateUserLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def batch_update_user_links(parent: nil, requests: nil) -> ::Google::Analytics::Admin::V1alpha::BatchUpdateUserLinksResponse
Pass arguments to batch_update_user_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The account or property that all user links in the request are for. The parent field in the UpdateUserLinkRequest messages must either be empty or match this field. Example format: accounts/1234
  • requests (::Array<::Google::Analytics::Admin::V1alpha::UpdateUserLinkRequest, ::Hash>) — Required. The requests specifying the user links to update. A maximum of 1000 user links can be updated in a batch.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::BatchUpdateUserLinksRequest.new

# Call the batch_update_user_links method.
result = client.batch_update_user_links request

# The returned object is of type Google::Analytics::Admin::V1alpha::BatchUpdateUserLinksResponse.
p result
def cancel_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
def cancel_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal

Cancels a DisplayVideo360AdvertiserLinkProposal. Cancelling can mean either:

  • Declining a proposal initiated from Display & Video 360
  • Withdrawing a proposal initiated from Google Analytics After being cancelled, a proposal will eventually be deleted automatically.
Overloads
def cancel_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
Pass arguments to cancel_display_video360_advertiser_link_proposal via a request object, either of type CancelDisplayVideo360AdvertiserLinkProposalRequest or an equivalent Hash.
Parameters
def cancel_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
Pass arguments to cancel_display_video360_advertiser_link_proposal via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DisplayVideo360AdvertiserLinkProposal to cancel. Example format: properties/1234/displayVideo360AdvertiserLinkProposals/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CancelDisplayVideo360AdvertiserLinkProposalRequest.new

# Call the cancel_display_video360_advertiser_link_proposal method.
result = client.cancel_display_video360_advertiser_link_proposal request

# The returned object is of type Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal.
p result

#configure

def configure() { |config| ... } -> Client::Configuration

Configure the AnalyticsAdminService Client instance.

The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on Client.configure.

See Configuration for a description of the configuration fields.

Yields
  • (config) — Configure the Client client.
Yield Parameter

#create_conversion_event

def create_conversion_event(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent
def create_conversion_event(conversion_event: nil, parent: nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent

Creates a conversion event with the specified attributes.

Overloads
def create_conversion_event(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent
Pass arguments to create_conversion_event via a request object, either of type CreateConversionEventRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateConversionEventRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_conversion_event(conversion_event: nil, parent: nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent
Pass arguments to create_conversion_event via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • conversion_event (::Google::Analytics::Admin::V1alpha::ConversionEvent, ::Hash) — Required. The conversion event to create.
  • parent (::String) — Required. The resource name of the parent property where this conversion event will be created. Format: properties/123
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateConversionEventRequest.new

# Call the create_conversion_event method.
result = client.create_conversion_event request

# The returned object is of type Google::Analytics::Admin::V1alpha::ConversionEvent.
p result

#create_custom_dimension

def create_custom_dimension(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
def create_custom_dimension(parent: nil, custom_dimension: nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension

Creates a CustomDimension.

Overloads
def create_custom_dimension(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
Pass arguments to create_custom_dimension via a request object, either of type CreateCustomDimensionRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateCustomDimensionRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_custom_dimension(parent: nil, custom_dimension: nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
Pass arguments to create_custom_dimension via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateCustomDimensionRequest.new

# Call the create_custom_dimension method.
result = client.create_custom_dimension request

# The returned object is of type Google::Analytics::Admin::V1alpha::CustomDimension.
p result

#create_custom_metric

def create_custom_metric(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
def create_custom_metric(parent: nil, custom_metric: nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric

Creates a CustomMetric.

Overloads
def create_custom_metric(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
Pass arguments to create_custom_metric via a request object, either of type CreateCustomMetricRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateCustomMetricRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_custom_metric(parent: nil, custom_metric: nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
Pass arguments to create_custom_metric via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateCustomMetricRequest.new

# Call the create_custom_metric method.
result = client.create_custom_metric request

# The returned object is of type Google::Analytics::Admin::V1alpha::CustomMetric.
p result

#create_data_stream

def create_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
def create_data_stream(parent: nil, data_stream: nil) -> ::Google::Analytics::Admin::V1alpha::DataStream

Creates a DataStream.

Overloads
def create_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
Pass arguments to create_data_stream via a request object, either of type CreateDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_data_stream(parent: nil, data_stream: nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
Pass arguments to create_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateDataStreamRequest.new

# Call the create_data_stream method.
result = client.create_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::DataStream.
p result
def create_display_video360_advertiser_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
def create_display_video360_advertiser_link(parent: nil, display_video_360_advertiser_link: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink

Creates a DisplayVideo360AdvertiserLink. This can only be utilized by users who have proper authorization both on the Google Analytics property and on the Display & Video 360 advertiser. Users who do not have access to the Display & Video 360 advertiser should instead seek to create a DisplayVideo360LinkProposal.

Overloads
def create_display_video360_advertiser_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
Pass arguments to create_display_video360_advertiser_link via a request object, either of type CreateDisplayVideo360AdvertiserLinkRequest or an equivalent Hash.
Parameters
def create_display_video360_advertiser_link(parent: nil, display_video_360_advertiser_link: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
Pass arguments to create_display_video360_advertiser_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateDisplayVideo360AdvertiserLinkRequest.new

# Call the create_display_video360_advertiser_link method.
result = client.create_display_video360_advertiser_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink.
p result
def create_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
def create_display_video360_advertiser_link_proposal(parent: nil, display_video_360_advertiser_link_proposal: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal

Creates a DisplayVideo360AdvertiserLinkProposal.

Overloads
def create_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
Pass arguments to create_display_video360_advertiser_link_proposal via a request object, either of type CreateDisplayVideo360AdvertiserLinkProposalRequest or an equivalent Hash.
Parameters
def create_display_video360_advertiser_link_proposal(parent: nil, display_video_360_advertiser_link_proposal: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
Pass arguments to create_display_video360_advertiser_link_proposal via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateDisplayVideo360AdvertiserLinkProposalRequest.new

# Call the create_display_video360_advertiser_link_proposal method.
result = client.create_display_video360_advertiser_link_proposal request

# The returned object is of type Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal.
p result
def create_firebase_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::FirebaseLink
def create_firebase_link(parent: nil, firebase_link: nil) -> ::Google::Analytics::Admin::V1alpha::FirebaseLink

Creates a FirebaseLink.

Properties can have at most one FirebaseLink.

Overloads
def create_firebase_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::FirebaseLink
Pass arguments to create_firebase_link via a request object, either of type CreateFirebaseLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateFirebaseLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_firebase_link(parent: nil, firebase_link: nil) -> ::Google::Analytics::Admin::V1alpha::FirebaseLink
Pass arguments to create_firebase_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateFirebaseLinkRequest.new

# Call the create_firebase_link method.
result = client.create_firebase_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::FirebaseLink.
p result
def create_google_ads_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink
def create_google_ads_link(parent: nil, google_ads_link: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink

Creates a GoogleAdsLink.

Overloads
def create_google_ads_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink
Pass arguments to create_google_ads_link via a request object, either of type CreateGoogleAdsLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateGoogleAdsLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_google_ads_link(parent: nil, google_ads_link: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink
Pass arguments to create_google_ads_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateGoogleAdsLinkRequest.new

# Call the create_google_ads_link method.
result = client.create_google_ads_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::GoogleAdsLink.
p result

#create_measurement_protocol_secret

def create_measurement_protocol_secret(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
def create_measurement_protocol_secret(parent: nil, measurement_protocol_secret: nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret

Creates a measurement protocol secret.

Overloads
def create_measurement_protocol_secret(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
Pass arguments to create_measurement_protocol_secret via a request object, either of type CreateMeasurementProtocolSecretRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateMeasurementProtocolSecretRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_measurement_protocol_secret(parent: nil, measurement_protocol_secret: nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
Pass arguments to create_measurement_protocol_secret via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The parent resource where this secret will be created. Any type of stream (WebDataStream, IosAppDataStream, AndroidAppDataStream) may be a parent. Format: properties/{property}/webDataStreams/{webDataStream}
  • measurement_protocol_secret (::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret, ::Hash) — Required. The measurement protocol secret to create.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateMeasurementProtocolSecretRequest.new

# Call the create_measurement_protocol_secret method.
result = client.create_measurement_protocol_secret request

# The returned object is of type Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret.
p result

#create_property

def create_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
def create_property(property: nil) -> ::Google::Analytics::Admin::V1alpha::Property

Creates an "GA4" property with the specified location and attributes.

Overloads
def create_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to create_property via a request object, either of type CreatePropertyRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreatePropertyRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_property(property: nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to create_property via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreatePropertyRequest.new

# Call the create_property method.
result = client.create_property request

# The returned object is of type Google::Analytics::Admin::V1alpha::Property.
p result
def create_user_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
def create_user_link(parent: nil, notify_new_user: nil, user_link: nil) -> ::Google::Analytics::Admin::V1alpha::UserLink

Creates a user link on an account or property.

If the user with the specified email already has permissions on the account or property, then the user's existing permissions will be unioned with the permissions specified in the new UserLink.

Overloads
def create_user_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
Pass arguments to create_user_link via a request object, either of type CreateUserLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateUserLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_user_link(parent: nil, notify_new_user: nil, user_link: nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
Pass arguments to create_user_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: accounts/1234
  • notify_new_user (::Boolean) — Optional. If set, then email the new user notifying them that they've been granted permissions to the resource.
  • user_link (::Google::Analytics::Admin::V1alpha::UserLink, ::Hash) — Required. The user link to create.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateUserLinkRequest.new

# Call the create_user_link method.
result = client.create_user_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::UserLink.
p result

#create_web_data_stream

def create_web_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
def create_web_data_stream(web_data_stream: nil, parent: nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream

Creates a web stream with the specified location and attributes.

Overloads
def create_web_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
Pass arguments to create_web_data_stream via a request object, either of type CreateWebDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::CreateWebDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_web_data_stream(web_data_stream: nil, parent: nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
Pass arguments to create_web_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::CreateWebDataStreamRequest.new

# Call the create_web_data_stream method.
result = client.create_web_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::WebDataStream.
p result

#delete_account

def delete_account(request, options = nil) -> ::Google::Protobuf::Empty
def delete_account(name: nil) -> ::Google::Protobuf::Empty

Marks target Account as soft-deleted (ie: "trashed") and returns it.

This API does not have a method to restore soft-deleted accounts. However, they can be restored using the Trash Can UI.

If the accounts are not restored before the expiration time, the account and all child resources (eg: Properties, GoogleAdsLinks, Streams, UserLinks) will be permanently purged. https://support.google.com/analytics/answer/6154772

Returns an error if the target is not found.

Overloads
def delete_account(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_account via a request object, either of type DeleteAccountRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteAccountRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_account(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_account via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the Account to soft-delete. Format: accounts/{account} Example: "accounts/100"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteAccountRequest.new

# Call the delete_account method.
result = client.delete_account request

# The returned object is of type Google::Protobuf::Empty.
p result

#delete_android_app_data_stream

def delete_android_app_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
def delete_android_app_data_stream(name: nil) -> ::Google::Protobuf::Empty

Deletes an android app stream on a property.

Overloads
def delete_android_app_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_android_app_data_stream via a request object, either of type DeleteAndroidAppDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteAndroidAppDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_android_app_data_stream(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_android_app_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the android app data stream to delete. Format: properties/{property_id}/androidAppDataStreams/{stream_id} Example: "properties/123/androidAppDataStreams/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteAndroidAppDataStreamRequest.new

# Call the delete_android_app_data_stream method.
result = client.delete_android_app_data_stream request

# The returned object is of type Google::Protobuf::Empty.
p result

#delete_conversion_event

def delete_conversion_event(request, options = nil) -> ::Google::Protobuf::Empty
def delete_conversion_event(name: nil) -> ::Google::Protobuf::Empty

Deletes a conversion event in a property.

Overloads
def delete_conversion_event(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_conversion_event via a request object, either of type DeleteConversionEventRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteConversionEventRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_conversion_event(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_conversion_event via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The resource name of the conversion event to delete. Format: properties/{property}/conversionEvents/{conversion_event} Example: "properties/123/conversionEvents/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteConversionEventRequest.new

# Call the delete_conversion_event method.
result = client.delete_conversion_event request

# The returned object is of type Google::Protobuf::Empty.
p result

#delete_data_stream

def delete_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
def delete_data_stream(name: nil) -> ::Google::Protobuf::Empty

Deletes a DataStream on a property.

Overloads
def delete_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_data_stream via a request object, either of type DeleteDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_data_stream(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DataStream to delete. Example format: properties/1234/dataStreams/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteDataStreamRequest.new

# Call the delete_data_stream method.
result = client.delete_data_stream request

# The returned object is of type Google::Protobuf::Empty.
p result
def delete_display_video360_advertiser_link(request, options = nil) -> ::Google::Protobuf::Empty
def delete_display_video360_advertiser_link(name: nil) -> ::Google::Protobuf::Empty

Deletes a DisplayVideo360AdvertiserLink on a property.

Overloads
def delete_display_video360_advertiser_link(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_display_video360_advertiser_link via a request object, either of type DeleteDisplayVideo360AdvertiserLinkRequest or an equivalent Hash.
Parameters
def delete_display_video360_advertiser_link(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_display_video360_advertiser_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DisplayVideo360AdvertiserLink to delete. Example format: properties/1234/displayVideo360AdvertiserLinks/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteDisplayVideo360AdvertiserLinkRequest.new

# Call the delete_display_video360_advertiser_link method.
result = client.delete_display_video360_advertiser_link request

# The returned object is of type Google::Protobuf::Empty.
p result
def delete_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Protobuf::Empty
def delete_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Protobuf::Empty

Deletes a DisplayVideo360AdvertiserLinkProposal on a property. This can only be used on cancelled proposals.

Overloads
def delete_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_display_video360_advertiser_link_proposal via a request object, either of type DeleteDisplayVideo360AdvertiserLinkProposalRequest or an equivalent Hash.
Parameters
def delete_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_display_video360_advertiser_link_proposal via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DisplayVideo360AdvertiserLinkProposal to delete. Example format: properties/1234/displayVideo360AdvertiserLinkProposals/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteDisplayVideo360AdvertiserLinkProposalRequest.new

# Call the delete_display_video360_advertiser_link_proposal method.
result = client.delete_display_video360_advertiser_link_proposal request

# The returned object is of type Google::Protobuf::Empty.
p result
def delete_firebase_link(request, options = nil) -> ::Google::Protobuf::Empty
def delete_firebase_link(name: nil) -> ::Google::Protobuf::Empty

Deletes a FirebaseLink on a property

Overloads
def delete_firebase_link(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_firebase_link via a request object, either of type DeleteFirebaseLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteFirebaseLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_firebase_link(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_firebase_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Format: properties/{property_id}/firebaseLinks/{firebase_link_id} Example: properties/1234/firebaseLinks/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteFirebaseLinkRequest.new

# Call the delete_firebase_link method.
result = client.delete_firebase_link request

# The returned object is of type Google::Protobuf::Empty.
p result
def delete_google_ads_link(request, options = nil) -> ::Google::Protobuf::Empty
def delete_google_ads_link(name: nil) -> ::Google::Protobuf::Empty

Deletes a GoogleAdsLink on a property

Overloads
def delete_google_ads_link(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_google_ads_link via a request object, either of type DeleteGoogleAdsLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteGoogleAdsLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_google_ads_link(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_google_ads_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Example format: properties/1234/googleAdsLinks/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteGoogleAdsLinkRequest.new

# Call the delete_google_ads_link method.
result = client.delete_google_ads_link request

# The returned object is of type Google::Protobuf::Empty.
p result

#delete_ios_app_data_stream

def delete_ios_app_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
def delete_ios_app_data_stream(name: nil) -> ::Google::Protobuf::Empty

Deletes an iOS app stream on a property.

Overloads
def delete_ios_app_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_ios_app_data_stream via a request object, either of type DeleteIosAppDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteIosAppDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_ios_app_data_stream(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_ios_app_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the iOS app data stream to delete. Format: properties/{property_id}/iosAppDataStreams/{stream_id} Example: "properties/123/iosAppDataStreams/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteIosAppDataStreamRequest.new

# Call the delete_ios_app_data_stream method.
result = client.delete_ios_app_data_stream request

# The returned object is of type Google::Protobuf::Empty.
p result

#delete_measurement_protocol_secret

def delete_measurement_protocol_secret(request, options = nil) -> ::Google::Protobuf::Empty
def delete_measurement_protocol_secret(name: nil) -> ::Google::Protobuf::Empty

Deletes target MeasurementProtocolSecret.

Overloads
def delete_measurement_protocol_secret(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_measurement_protocol_secret via a request object, either of type DeleteMeasurementProtocolSecretRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteMeasurementProtocolSecretRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_measurement_protocol_secret(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_measurement_protocol_secret via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the MeasurementProtocolSecret to delete. Format: properties/{property}/webDataStreams/{webDataStream}/measurementProtocolSecrets/{measurementProtocolSecret} Note: Any type of stream (WebDataStream, IosAppDataStream, AndroidAppDataStream) may be a parent.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteMeasurementProtocolSecretRequest.new

# Call the delete_measurement_protocol_secret method.
result = client.delete_measurement_protocol_secret request

# The returned object is of type Google::Protobuf::Empty.
p result

#delete_property

def delete_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
def delete_property(name: nil) -> ::Google::Analytics::Admin::V1alpha::Property

Marks target Property as soft-deleted (ie: "trashed") and returns it.

This API does not have a method to restore soft-deleted properties. However, they can be restored using the Trash Can UI.

If the properties are not restored before the expiration time, the Property and all child resources (eg: GoogleAdsLinks, Streams, UserLinks) will be permanently purged. https://support.google.com/analytics/answer/6154772

Returns an error if the target is not found, or is not an GA4 Property.

Overloads
def delete_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to delete_property via a request object, either of type DeletePropertyRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeletePropertyRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_property(name: nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to delete_property via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the Property to soft-delete. Format: properties/{property_id} Example: "properties/1000"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeletePropertyRequest.new

# Call the delete_property method.
result = client.delete_property request

# The returned object is of type Google::Analytics::Admin::V1alpha::Property.
p result
def delete_user_link(request, options = nil) -> ::Google::Protobuf::Empty
def delete_user_link(name: nil) -> ::Google::Protobuf::Empty

Deletes a user link on an account or property.

Overloads
def delete_user_link(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_user_link via a request object, either of type DeleteUserLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteUserLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_user_link(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_user_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Example format: accounts/1234/userLinks/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteUserLinkRequest.new

# Call the delete_user_link method.
result = client.delete_user_link request

# The returned object is of type Google::Protobuf::Empty.
p result

#delete_web_data_stream

def delete_web_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
def delete_web_data_stream(name: nil) -> ::Google::Protobuf::Empty

Deletes a web stream on a property.

Overloads
def delete_web_data_stream(request, options = nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_web_data_stream via a request object, either of type DeleteWebDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::DeleteWebDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_web_data_stream(name: nil) -> ::Google::Protobuf::Empty
Pass arguments to delete_web_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the web data stream to delete. Format: properties/{property_id}/webDataStreams/{stream_id} Example: "properties/123/webDataStreams/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::DeleteWebDataStreamRequest.new

# Call the delete_web_data_stream method.
result = client.delete_web_data_stream request

# The returned object is of type Google::Protobuf::Empty.
p result

#get_account

def get_account(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Account
def get_account(name: nil) -> ::Google::Analytics::Admin::V1alpha::Account

Lookup for a single Account.

Overloads
def get_account(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Account
Pass arguments to get_account via a request object, either of type GetAccountRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetAccountRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_account(name: nil) -> ::Google::Analytics::Admin::V1alpha::Account
Pass arguments to get_account via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the account to lookup. Format: accounts/{account} Example: "accounts/100"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetAccountRequest.new

# Call the get_account method.
result = client.get_account request

# The returned object is of type Google::Analytics::Admin::V1alpha::Account.
p result

#get_android_app_data_stream

def get_android_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream
def get_android_app_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream

Lookup for a single AndroidAppDataStream

Overloads
def get_android_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream
Pass arguments to get_android_app_data_stream via a request object, either of type GetAndroidAppDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetAndroidAppDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_android_app_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream
Pass arguments to get_android_app_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the android app data stream to lookup. Format: properties/{property_id}/androidAppDataStreams/{stream_id} Example: "properties/123/androidAppDataStreams/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetAndroidAppDataStreamRequest.new

# Call the get_android_app_data_stream method.
result = client.get_android_app_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::AndroidAppDataStream.
p result

#get_conversion_event

def get_conversion_event(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent
def get_conversion_event(name: nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent

Retrieve a single conversion event.

Overloads
def get_conversion_event(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent
Pass arguments to get_conversion_event via a request object, either of type GetConversionEventRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetConversionEventRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_conversion_event(name: nil) -> ::Google::Analytics::Admin::V1alpha::ConversionEvent
Pass arguments to get_conversion_event via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The resource name of the conversion event to retrieve. Format: properties/{property}/conversionEvents/{conversion_event} Example: "properties/123/conversionEvents/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetConversionEventRequest.new

# Call the get_conversion_event method.
result = client.get_conversion_event request

# The returned object is of type Google::Analytics::Admin::V1alpha::ConversionEvent.
p result

#get_custom_dimension

def get_custom_dimension(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
def get_custom_dimension(name: nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension

Lookup for a single CustomDimension.

Overloads
def get_custom_dimension(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
Pass arguments to get_custom_dimension via a request object, either of type GetCustomDimensionRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetCustomDimensionRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_custom_dimension(name: nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
Pass arguments to get_custom_dimension via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the CustomDimension to get. Example format: properties/1234/customDimensions/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetCustomDimensionRequest.new

# Call the get_custom_dimension method.
result = client.get_custom_dimension request

# The returned object is of type Google::Analytics::Admin::V1alpha::CustomDimension.
p result

#get_custom_metric

def get_custom_metric(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
def get_custom_metric(name: nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric

Lookup for a single CustomMetric.

Overloads
def get_custom_metric(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
Pass arguments to get_custom_metric via a request object, either of type GetCustomMetricRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetCustomMetricRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_custom_metric(name: nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
Pass arguments to get_custom_metric via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the CustomMetric to get. Example format: properties/1234/customMetrics/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetCustomMetricRequest.new

# Call the get_custom_metric method.
result = client.get_custom_metric request

# The returned object is of type Google::Analytics::Admin::V1alpha::CustomMetric.
p result

#get_data_retention_settings

def get_data_retention_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings
def get_data_retention_settings(name: nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings

Returns the singleton data retention settings for this property.

Overloads
def get_data_retention_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings
Pass arguments to get_data_retention_settings via a request object, either of type GetDataRetentionSettingsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetDataRetentionSettingsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_data_retention_settings(name: nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings
Pass arguments to get_data_retention_settings via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the settings to lookup. Format: properties/{property}/dataRetentionSettings Example: "properties/1000/dataRetentionSettings"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetDataRetentionSettingsRequest.new

# Call the get_data_retention_settings method.
result = client.get_data_retention_settings request

# The returned object is of type Google::Analytics::Admin::V1alpha::DataRetentionSettings.
p result

#get_data_sharing_settings

def get_data_sharing_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataSharingSettings
def get_data_sharing_settings(name: nil) -> ::Google::Analytics::Admin::V1alpha::DataSharingSettings

Get data sharing settings on an account. Data sharing settings are singletons.

Overloads
def get_data_sharing_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataSharingSettings
Pass arguments to get_data_sharing_settings via a request object, either of type GetDataSharingSettingsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetDataSharingSettingsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_data_sharing_settings(name: nil) -> ::Google::Analytics::Admin::V1alpha::DataSharingSettings
Pass arguments to get_data_sharing_settings via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the settings to lookup. Format: accounts/{account}/dataSharingSettings Example: "accounts/1000/dataSharingSettings"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetDataSharingSettingsRequest.new

# Call the get_data_sharing_settings method.
result = client.get_data_sharing_settings request

# The returned object is of type Google::Analytics::Admin::V1alpha::DataSharingSettings.
p result

#get_data_stream

def get_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
def get_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::DataStream

Lookup for a single DataStream.

Overloads
def get_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
Pass arguments to get_data_stream via a request object, either of type GetDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
Pass arguments to get_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DataStream to get. Example format: properties/1234/dataStreams/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetDataStreamRequest.new

# Call the get_data_stream method.
result = client.get_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::DataStream.
p result
def get_display_video360_advertiser_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
def get_display_video360_advertiser_link(name: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink

Look up a single DisplayVideo360AdvertiserLink

Overloads
def get_display_video360_advertiser_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
Pass arguments to get_display_video360_advertiser_link via a request object, either of type GetDisplayVideo360AdvertiserLinkRequest or an equivalent Hash.
Parameters
def get_display_video360_advertiser_link(name: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
Pass arguments to get_display_video360_advertiser_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DisplayVideo360AdvertiserLink to get. Example format: properties/1234/displayVideo360AdvertiserLink/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetDisplayVideo360AdvertiserLinkRequest.new

# Call the get_display_video360_advertiser_link method.
result = client.get_display_video360_advertiser_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink.
p result
def get_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
def get_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal

Lookup for a single DisplayVideo360AdvertiserLinkProposal.

Overloads
def get_display_video360_advertiser_link_proposal(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
Pass arguments to get_display_video360_advertiser_link_proposal via a request object, either of type GetDisplayVideo360AdvertiserLinkProposalRequest or an equivalent Hash.
Parameters
def get_display_video360_advertiser_link_proposal(name: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal
Pass arguments to get_display_video360_advertiser_link_proposal via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the DisplayVideo360AdvertiserLinkProposal to get. Example format: properties/1234/displayVideo360AdvertiserLinkProposals/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetDisplayVideo360AdvertiserLinkProposalRequest.new

# Call the get_display_video360_advertiser_link_proposal method.
result = client.get_display_video360_advertiser_link_proposal request

# The returned object is of type Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal.
p result

#get_global_site_tag

def get_global_site_tag(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GlobalSiteTag
def get_global_site_tag(name: nil) -> ::Google::Analytics::Admin::V1alpha::GlobalSiteTag

Returns the Site Tag for the specified web stream. Site Tags are immutable singletons.

Overloads
def get_global_site_tag(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GlobalSiteTag
Pass arguments to get_global_site_tag via a request object, either of type GetGlobalSiteTagRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetGlobalSiteTagRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_global_site_tag(name: nil) -> ::Google::Analytics::Admin::V1alpha::GlobalSiteTag
Pass arguments to get_global_site_tag via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the site tag to lookup. Note that site tags are singletons and do not have unique IDs. Format: properties/{property_id}/webDataStreams/{stream_id}/globalSiteTag Example: "properties/123/webDataStreams/456/globalSiteTag"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetGlobalSiteTagRequest.new

# Call the get_global_site_tag method.
result = client.get_global_site_tag request

# The returned object is of type Google::Analytics::Admin::V1alpha::GlobalSiteTag.
p result

#get_google_signals_settings

def get_google_signals_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings
def get_google_signals_settings(name: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings

Lookup for Google Signals settings for a property.

Overloads
def get_google_signals_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings
Pass arguments to get_google_signals_settings via a request object, either of type GetGoogleSignalsSettingsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetGoogleSignalsSettingsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_google_signals_settings(name: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings
Pass arguments to get_google_signals_settings via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the google signals settings to retrieve. Format: properties/{property}/googleSignalsSettings
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetGoogleSignalsSettingsRequest.new

# Call the get_google_signals_settings method.
result = client.get_google_signals_settings request

# The returned object is of type Google::Analytics::Admin::V1alpha::GoogleSignalsSettings.
p result

#get_ios_app_data_stream

def get_ios_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream
def get_ios_app_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream

Lookup for a single IosAppDataStream

Overloads
def get_ios_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream
Pass arguments to get_ios_app_data_stream via a request object, either of type GetIosAppDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetIosAppDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_ios_app_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream
Pass arguments to get_ios_app_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the iOS app data stream to lookup. Format: properties/{property_id}/iosAppDataStreams/{stream_id} Example: "properties/123/iosAppDataStreams/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetIosAppDataStreamRequest.new

# Call the get_ios_app_data_stream method.
result = client.get_ios_app_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::IosAppDataStream.
p result

#get_measurement_protocol_secret

def get_measurement_protocol_secret(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
def get_measurement_protocol_secret(name: nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret

Lookup for a single "GA4" MeasurementProtocolSecret.

Overloads
def get_measurement_protocol_secret(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
Pass arguments to get_measurement_protocol_secret via a request object, either of type GetMeasurementProtocolSecretRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetMeasurementProtocolSecretRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_measurement_protocol_secret(name: nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
Pass arguments to get_measurement_protocol_secret via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the measurement protocol secret to lookup. Format: properties/{property}/webDataStreams/{webDataStream}/measurementProtocolSecrets/{measurementProtocolSecret} Note: Any type of stream (WebDataStream, IosAppDataStream, AndroidAppDataStream) may be a parent.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetMeasurementProtocolSecretRequest.new

# Call the get_measurement_protocol_secret method.
result = client.get_measurement_protocol_secret request

# The returned object is of type Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret.
p result

#get_property

def get_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
def get_property(name: nil) -> ::Google::Analytics::Admin::V1alpha::Property

Lookup for a single "GA4" Property.

Overloads
def get_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to get_property via a request object, either of type GetPropertyRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetPropertyRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_property(name: nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to get_property via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the property to lookup. Format: properties/{property_id} Example: "properties/1000"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetPropertyRequest.new

# Call the get_property method.
result = client.get_property request

# The returned object is of type Google::Analytics::Admin::V1alpha::Property.
p result
def get_user_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
def get_user_link(name: nil) -> ::Google::Analytics::Admin::V1alpha::UserLink

Gets information about a user's link to an account or property.

Overloads
def get_user_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
Pass arguments to get_user_link via a request object, either of type GetUserLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetUserLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_user_link(name: nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
Pass arguments to get_user_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. Example format: accounts/1234/userLinks/5678
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetUserLinkRequest.new

# Call the get_user_link method.
result = client.get_user_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::UserLink.
p result

#get_web_data_stream

def get_web_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
def get_web_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream

Lookup for a single WebDataStream

Overloads
def get_web_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
Pass arguments to get_web_data_stream via a request object, either of type GetWebDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::GetWebDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_web_data_stream(name: nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
Pass arguments to get_web_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the web data stream to lookup. Format: properties/{property_id}/webDataStreams/{stream_id} Example: "properties/123/webDataStreams/456"
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::GetWebDataStreamRequest.new

# Call the get_web_data_stream method.
result = client.get_web_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::WebDataStream.
p result

#initialize

def initialize() { |config| ... } -> Client

Create a new AnalyticsAdminService client object.

Yields
  • (config) — Configure the AnalyticsAdminService client.
Yield Parameter
Returns
  • (Client) — a new instance of Client
Example
# Create a client using the default configuration
client = ::Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a client using a custom configuration
client = ::Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new do |config|
  config.timeout = 10.0
end

#list_account_summaries

def list_account_summaries(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AccountSummary>
def list_account_summaries(page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AccountSummary>

Returns summaries of all accounts accessible by the caller.

Overloads
def list_account_summaries(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AccountSummary>
Pass arguments to list_account_summaries via a request object, either of type ListAccountSummariesRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListAccountSummariesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_account_summaries(page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AccountSummary>
Pass arguments to list_account_summaries via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • page_size (::Integer) — The maximum number of AccountSummary resources to return. The service may return fewer than this value, even if there are additional pages. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)
  • page_token (::String) — A page token, received from a previous ListAccountSummaries call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListAccountSummaries must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListAccountSummariesRequest.new

# Call the list_account_summaries method.
result = client.list_account_summaries request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::AccountSummary.
  p response
end

#list_accounts

def list_accounts(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Account>
def list_accounts(page_size: nil, page_token: nil, show_deleted: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Account>

Returns all accounts accessible by the caller.

Note that these accounts might not currently have GA4 properties. Soft-deleted (ie: "trashed") accounts are excluded by default. Returns an empty list if no relevant accounts are found.

Overloads
def list_accounts(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Account>
Pass arguments to list_accounts via a request object, either of type ListAccountsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListAccountsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_accounts(page_size: nil, page_token: nil, show_deleted: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Account>
Pass arguments to list_accounts via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • page_size (::Integer) — The maximum number of resources to return. The service may return fewer than this value, even if there are additional pages. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)
  • page_token (::String) — A page token, received from a previous ListAccounts call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListAccounts must match the call that provided the page token.
  • show_deleted (::Boolean) — Whether to include soft-deleted (ie: "trashed") Accounts in the results. Accounts can be inspected to determine whether they are deleted or not.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListAccountsRequest.new

# Call the list_accounts method.
result = client.list_accounts request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::Account.
  p response
end

#list_android_app_data_streams

def list_android_app_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AndroidAppDataStream>
def list_android_app_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AndroidAppDataStream>

Returns child android app streams under the specified parent property.

Android app streams will be excluded if the caller does not have access. Returns an empty list if no relevant android app streams are found.

Overloads
def list_android_app_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AndroidAppDataStream>
Pass arguments to list_android_app_data_streams via a request object, either of type ListAndroidAppDataStreamsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListAndroidAppDataStreamsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_android_app_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::AndroidAppDataStream>
Pass arguments to list_android_app_data_streams via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The name of the parent property. For example, to limit results to app streams under the property with Id 123: "properties/123"
  • page_size (::Integer) — The maximum number of resources to return.

    If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)

  • page_token (::String) — A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListAndroidAppDataStreams must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListAndroidAppDataStreamsRequest.new

# Call the list_android_app_data_streams method.
result = client.list_android_app_data_streams request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream.
  p response
end

#list_conversion_events

def list_conversion_events(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ConversionEvent>
def list_conversion_events(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ConversionEvent>

Returns a list of conversion events in the specified parent property.

Returns an empty list if no conversion events are found.

Overloads
def list_conversion_events(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ConversionEvent>
Pass arguments to list_conversion_events via a request object, either of type ListConversionEventsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListConversionEventsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_conversion_events(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ConversionEvent>
Pass arguments to list_conversion_events via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The resource name of the parent property. Example: 'properties/123'
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)
  • page_token (::String) — A page token, received from a previous ListConversionEvents call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListConversionEvents must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListConversionEventsRequest.new

# Call the list_conversion_events method.
result = client.list_conversion_events request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::ConversionEvent.
  p response
end

#list_custom_dimensions

def list_custom_dimensions(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomDimension>
def list_custom_dimensions(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomDimension>

Lists CustomDimensions on a property.

Overloads
def list_custom_dimensions(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomDimension>
Pass arguments to list_custom_dimensions via a request object, either of type ListCustomDimensionsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListCustomDimensionsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_custom_dimensions(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomDimension>
Pass arguments to list_custom_dimensions via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: properties/1234
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200 (higher values will be coerced to the maximum).
  • page_token (::String) — A page token, received from a previous ListCustomDimensions call. Provide this to retrieve the subsequent page.

    When paginating, all other parameters provided to ListCustomDimensions must match the call that provided the page token.

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListCustomDimensionsRequest.new

# Call the list_custom_dimensions method.
result = client.list_custom_dimensions request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::CustomDimension.
  p response
end

#list_custom_metrics

def list_custom_metrics(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomMetric>
def list_custom_metrics(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomMetric>

Lists CustomMetrics on a property.

Overloads
def list_custom_metrics(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomMetric>
Pass arguments to list_custom_metrics via a request object, either of type ListCustomMetricsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListCustomMetricsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_custom_metrics(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::CustomMetric>
Pass arguments to list_custom_metrics via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: properties/1234
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200 (higher values will be coerced to the maximum).
  • page_token (::String) — A page token, received from a previous ListCustomMetrics call. Provide this to retrieve the subsequent page.

    When paginating, all other parameters provided to ListCustomMetrics must match the call that provided the page token.

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListCustomMetricsRequest.new

# Call the list_custom_metrics method.
result = client.list_custom_metrics request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::CustomMetric.
  p response
end

#list_data_streams

def list_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DataStream>
def list_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DataStream>

Lists DataStreams on a property.

Overloads
def list_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DataStream>
Pass arguments to list_data_streams via a request object, either of type ListDataStreamsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListDataStreamsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DataStream>
Pass arguments to list_data_streams via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: properties/1234
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200 (higher values will be coerced to the maximum).
  • page_token (::String) — A page token, received from a previous ListDataStreams call. Provide this to retrieve the subsequent page.

    When paginating, all other parameters provided to ListDataStreams must match the call that provided the page token.

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListDataStreamsRequest.new

# Call the list_data_streams method.
result = client.list_data_streams request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::DataStream.
  p response
end
def list_display_video360_advertiser_link_proposals(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal>
def list_display_video360_advertiser_link_proposals(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal>

Lists DisplayVideo360AdvertiserLinkProposals on a property.

Overloads
def list_display_video360_advertiser_link_proposals(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal>
Pass arguments to list_display_video360_advertiser_link_proposals via a request object, either of type ListDisplayVideo360AdvertiserLinkProposalsRequest or an equivalent Hash.
Parameters
def list_display_video360_advertiser_link_proposals(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal>
Pass arguments to list_display_video360_advertiser_link_proposals via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: properties/1234
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200 (higher values will be coerced to the maximum).
  • page_token (::String) — A page token, received from a previous ListDisplayVideo360AdvertiserLinkProposals call. Provide this to retrieve the subsequent page.

    When paginating, all other parameters provided to ListDisplayVideo360AdvertiserLinkProposals must match the call that provided the page token.

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListDisplayVideo360AdvertiserLinkProposalsRequest.new

# Call the list_display_video360_advertiser_link_proposals method.
result = client.list_display_video360_advertiser_link_proposals request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLinkProposal.
  p response
end
def list_display_video360_advertiser_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink>
def list_display_video360_advertiser_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink>

Lists all DisplayVideo360AdvertiserLinks on a property.

Overloads
def list_display_video360_advertiser_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink>
Pass arguments to list_display_video360_advertiser_links via a request object, either of type ListDisplayVideo360AdvertiserLinksRequest or an equivalent Hash.
Parameters
def list_display_video360_advertiser_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink>
Pass arguments to list_display_video360_advertiser_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: properties/1234
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200 (higher values will be coerced to the maximum).
  • page_token (::String) — A page token, received from a previous ListDisplayVideo360AdvertiserLinks call. Provide this to retrieve the subsequent page.

    When paginating, all other parameters provided to ListDisplayVideo360AdvertiserLinks must match the call that provided the page token.

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListDisplayVideo360AdvertiserLinksRequest.new

# Call the list_display_video360_advertiser_links method.
result = client.list_display_video360_advertiser_links request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink.
  p response
end
def list_firebase_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::FirebaseLink>
def list_firebase_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::FirebaseLink>

Lists FirebaseLinks on a property. Properties can have at most one FirebaseLink.

Overloads
def list_firebase_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::FirebaseLink>
Pass arguments to list_firebase_links via a request object, either of type ListFirebaseLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListFirebaseLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_firebase_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::FirebaseLink>
Pass arguments to list_firebase_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Format: properties/{property_id} Example: properties/1234
  • page_size (::Integer) — The maximum number of resources to return. The service may return fewer than this value, even if there are additional pages. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)
  • page_token (::String) — A page token, received from a previous ListFirebaseLinks call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListProperties must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListFirebaseLinksRequest.new

# Call the list_firebase_links method.
result = client.list_firebase_links request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::FirebaseLink.
  p response
end
def list_google_ads_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::GoogleAdsLink>
def list_google_ads_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::GoogleAdsLink>

Lists GoogleAdsLinks on a property.

Overloads
def list_google_ads_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::GoogleAdsLink>
Pass arguments to list_google_ads_links via a request object, either of type ListGoogleAdsLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListGoogleAdsLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_google_ads_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::GoogleAdsLink>
Pass arguments to list_google_ads_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: properties/1234
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200 (higher values will be coerced to the maximum).
  • page_token (::String) — A page token, received from a previous ListGoogleAdsLinks call. Provide this to retrieve the subsequent page.

    When paginating, all other parameters provided to ListGoogleAdsLinks must match the call that provided the page token.

Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListGoogleAdsLinksRequest.new

# Call the list_google_ads_links method.
result = client.list_google_ads_links request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::GoogleAdsLink.
  p response
end

#list_ios_app_data_streams

def list_ios_app_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::IosAppDataStream>
def list_ios_app_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::IosAppDataStream>

Returns child iOS app data streams under the specified parent property.

iOS app data streams will be excluded if the caller does not have access. Returns an empty list if no relevant iOS app data streams are found.

Overloads
def list_ios_app_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::IosAppDataStream>
Pass arguments to list_ios_app_data_streams via a request object, either of type ListIosAppDataStreamsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListIosAppDataStreamsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_ios_app_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::IosAppDataStream>
Pass arguments to list_ios_app_data_streams via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The name of the parent property. For example, to list results of app streams under the property with Id 123: "properties/123"
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)
  • page_token (::String) — A page token, received from a previous ListIosAppDataStreams call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListIosAppDataStreams must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListIosAppDataStreamsRequest.new

# Call the list_ios_app_data_streams method.
result = client.list_ios_app_data_streams request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::IosAppDataStream.
  p response
end

#list_measurement_protocol_secrets

def list_measurement_protocol_secrets(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret>
def list_measurement_protocol_secrets(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret>

Returns child MeasurementProtocolSecrets under the specified parent Property.

Overloads
def list_measurement_protocol_secrets(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret>
Pass arguments to list_measurement_protocol_secrets via a request object, either of type ListMeasurementProtocolSecretsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListMeasurementProtocolSecretsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_measurement_protocol_secrets(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret>
Pass arguments to list_measurement_protocol_secrets via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The resource name of the parent stream. Any type of stream (WebDataStream, IosAppDataStream, AndroidAppDataStream) may be a parent. Format: properties/{property}/webDataStreams/{webDataStream}/measurementProtocolSecrets
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 10 resources will be returned. The maximum value is 10. Higher values will be coerced to the maximum.
  • page_token (::String) — A page token, received from a previous ListMeasurementProtocolSecrets call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListMeasurementProtocolSecrets must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListMeasurementProtocolSecretsRequest.new

# Call the list_measurement_protocol_secrets method.
result = client.list_measurement_protocol_secrets request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret.
  p response
end

#list_properties

def list_properties(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Property>
def list_properties(filter: nil, page_size: nil, page_token: nil, show_deleted: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Property>

Returns child Properties under the specified parent Account.

Only "GA4" properties will be returned. Properties will be excluded if the caller does not have access. Soft-deleted (ie: "trashed") properties are excluded by default. Returns an empty list if no relevant properties are found.

Overloads
def list_properties(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Property>
Pass arguments to list_properties via a request object, either of type ListPropertiesRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListPropertiesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_properties(filter: nil, page_size: nil, page_token: nil, show_deleted: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::Property>
Pass arguments to list_properties via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • filter (::String) — Required. An expression for filtering the results of the request. Fields eligible for filtering are: parent:(The resource name of the parent account) or firebase_project:(The id or number of the linked firebase project). Some examples of filters:

    | Filter | Description | |-----------------------------|-------------------------------------------| | parent:accounts/123 | The account with account id: 123. | | firebase_project:project-id | The firebase project with id: project-id. | | firebase_project:123 | The firebase project with number: 123. |

  • page_size (::Integer) — The maximum number of resources to return. The service may return fewer than this value, even if there are additional pages. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)
  • page_token (::String) — A page token, received from a previous ListProperties call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListProperties must match the call that provided the page token.
  • show_deleted (::Boolean) — Whether to include soft-deleted (ie: "trashed") Properties in the results. Properties can be inspected to determine whether they are deleted or not.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListPropertiesRequest.new

# Call the list_properties method.
result = client.list_properties request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::Property.
  p response
end
def list_user_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::UserLink>
def list_user_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::UserLink>

Lists all user links on an account or property.

Overloads
def list_user_links(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::UserLink>
Pass arguments to list_user_links via a request object, either of type ListUserLinksRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListUserLinksRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_user_links(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::UserLink>
Pass arguments to list_user_links via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. Example format: accounts/1234
  • page_size (::Integer) — The maximum number of user links to return. The service may return fewer than this value. If unspecified, at most 200 user links will be returned. The maximum value is 500; values above 500 will be coerced to 500.
  • page_token (::String) — A page token, received from a previous ListUserLinks call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListUserLinks must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListUserLinksRequest.new

# Call the list_user_links method.
result = client.list_user_links request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::UserLink.
  p response
end

#list_web_data_streams

def list_web_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::WebDataStream>
def list_web_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::WebDataStream>

Returns child web data streams under the specified parent property.

Web data streams will be excluded if the caller does not have access. Returns an empty list if no relevant web data streams are found.

Overloads
def list_web_data_streams(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::WebDataStream>
Pass arguments to list_web_data_streams via a request object, either of type ListWebDataStreamsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ListWebDataStreamsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_web_data_streams(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::WebDataStream>
Pass arguments to list_web_data_streams via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The name of the parent property. For example, to list results of web streams under the property with Id 123: "properties/123"
  • page_size (::Integer) — The maximum number of resources to return. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)
  • page_token (::String) — A page token, received from a previous ListWebDataStreams call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListWebDataStreams must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ListWebDataStreamsRequest.new

# Call the list_web_data_streams method.
result = client.list_web_data_streams request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::WebDataStream.
  p response
end

#provision_account_ticket

def provision_account_ticket(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ProvisionAccountTicketResponse
def provision_account_ticket(account: nil, redirect_uri: nil) -> ::Google::Analytics::Admin::V1alpha::ProvisionAccountTicketResponse

Requests a ticket for creating an account.

Overloads
def provision_account_ticket(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::ProvisionAccountTicketResponse
Pass arguments to provision_account_ticket via a request object, either of type ProvisionAccountTicketRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::ProvisionAccountTicketRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def provision_account_ticket(account: nil, redirect_uri: nil) -> ::Google::Analytics::Admin::V1alpha::ProvisionAccountTicketResponse
Pass arguments to provision_account_ticket via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • account (::Google::Analytics::Admin::V1alpha::Account, ::Hash) — The account to create.
  • redirect_uri (::String) — Redirect URI where the user will be sent after accepting Terms of Service. Must be configured in Developers Console as a Redirect URI
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::ProvisionAccountTicketRequest.new

# Call the provision_account_ticket method.
result = client.provision_account_ticket request

# The returned object is of type Google::Analytics::Admin::V1alpha::ProvisionAccountTicketResponse.
p result

#search_change_history_events

def search_change_history_events(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ChangeHistoryEvent>
def search_change_history_events(account: nil, property: nil, resource_type: nil, action: nil, actor_email: nil, earliest_change_time: nil, latest_change_time: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ChangeHistoryEvent>

Searches through all changes to an account or its children given the specified set of filters.

Overloads
def search_change_history_events(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ChangeHistoryEvent>
Pass arguments to search_change_history_events via a request object, either of type SearchChangeHistoryEventsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::SearchChangeHistoryEventsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def search_change_history_events(account: nil, property: nil, resource_type: nil, action: nil, actor_email: nil, earliest_change_time: nil, latest_change_time: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ChangeHistoryEvent>
Pass arguments to search_change_history_events via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • account (::String) — Required. The account resource for which to return change history resources.
  • property (::String) — Optional. Resource name for a child property. If set, only return changes made to this property or its child resources.
  • resource_type (::Array<::Google::Analytics::Admin::V1alpha::ChangeHistoryResourceType>) — Optional. If set, only return changes if they are for a resource that matches at least one of these types.
  • action (::Array<::Google::Analytics::Admin::V1alpha::ActionType>) — Optional. If set, only return changes that match one or more of these types of actions.
  • actor_email (::Array<::String>) — Optional. If set, only return changes if they are made by a user in this list.
  • earliest_change_time (::Google::Protobuf::Timestamp, ::Hash) — Optional. If set, only return changes made after this time (inclusive).
  • latest_change_time (::Google::Protobuf::Timestamp, ::Hash) — Optional. If set, only return changes made before this time (inclusive).
  • page_size (::Integer) — Optional. The maximum number of ChangeHistoryEvent items to return. The service may return fewer than this value, even if there are additional pages. If unspecified, at most 50 items will be returned. The maximum value is 200 (higher values will be coerced to the maximum).
  • page_token (::String) — Optional. A page token, received from a previous SearchChangeHistoryEvents call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to SearchChangeHistoryEvents must match the call that provided the page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::SearchChangeHistoryEventsRequest.new

# Call the search_change_history_events method.
result = client.search_change_history_events request

# The returned object is of type Gapic::PagedEnumerable. You can
# iterate over all elements by calling #each, and the enumerable
# will lazily make API calls to fetch subsequent pages. Other
# methods are also available for managing paging directly.
result.each do |response|
  # Each element is of type ::Google::Analytics::Admin::V1alpha::ChangeHistoryEvent.
  p response
end

#update_account

def update_account(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Account
def update_account(account: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::Account

Updates an account.

Overloads
def update_account(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Account
Pass arguments to update_account via a request object, either of type UpdateAccountRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateAccountRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_account(account: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::Account
Pass arguments to update_account via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • account (::Google::Analytics::Admin::V1alpha::Account, ::Hash) — Required. The account to update. The account's name field is used to identify the account.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. The list of fields to be updated. Field names must be in snake case (e.g., "field_to_update"). Omitted fields will not be updated. To replace the entire entity, use one path with the string "*" to match all fields.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateAccountRequest.new

# Call the update_account method.
result = client.update_account request

# The returned object is of type Google::Analytics::Admin::V1alpha::Account.
p result

#update_android_app_data_stream

def update_android_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream
def update_android_app_data_stream(android_app_data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream

Updates an android app stream on a property.

Overloads
def update_android_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream
Pass arguments to update_android_app_data_stream via a request object, either of type UpdateAndroidAppDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateAndroidAppDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_android_app_data_stream(android_app_data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::AndroidAppDataStream
Pass arguments to update_android_app_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • android_app_data_stream (::Google::Analytics::Admin::V1alpha::AndroidAppDataStream, ::Hash) — Required. The android app stream to update. The name field is used to identify the android app stream to be updated.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. The list of fields to be updated. Field names must be in snake case (e.g., "field_to_update"). Omitted fields will not be updated. To replace the entire entity, use one path with the string "*" to match all fields.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateAndroidAppDataStreamRequest.new

# Call the update_android_app_data_stream method.
result = client.update_android_app_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::AndroidAppDataStream.
p result

#update_custom_dimension

def update_custom_dimension(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
def update_custom_dimension(custom_dimension: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension

Updates a CustomDimension on a property.

Overloads
def update_custom_dimension(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
Pass arguments to update_custom_dimension via a request object, either of type UpdateCustomDimensionRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateCustomDimensionRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_custom_dimension(custom_dimension: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::CustomDimension
Pass arguments to update_custom_dimension via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateCustomDimensionRequest.new

# Call the update_custom_dimension method.
result = client.update_custom_dimension request

# The returned object is of type Google::Analytics::Admin::V1alpha::CustomDimension.
p result

#update_custom_metric

def update_custom_metric(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
def update_custom_metric(custom_metric: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric

Updates a CustomMetric on a property.

Overloads
def update_custom_metric(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
Pass arguments to update_custom_metric via a request object, either of type UpdateCustomMetricRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateCustomMetricRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_custom_metric(custom_metric: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::CustomMetric
Pass arguments to update_custom_metric via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateCustomMetricRequest.new

# Call the update_custom_metric method.
result = client.update_custom_metric request

# The returned object is of type Google::Analytics::Admin::V1alpha::CustomMetric.
p result

#update_data_retention_settings

def update_data_retention_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings
def update_data_retention_settings(data_retention_settings: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings

Updates the singleton data retention settings for this property.

Overloads
def update_data_retention_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings
Pass arguments to update_data_retention_settings via a request object, either of type UpdateDataRetentionSettingsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateDataRetentionSettingsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_data_retention_settings(data_retention_settings: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::DataRetentionSettings
Pass arguments to update_data_retention_settings via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • data_retention_settings (::Google::Analytics::Admin::V1alpha::DataRetentionSettings, ::Hash) — Required. The settings to update. The name field is used to identify the settings to be updated.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. The list of fields to be updated. Field names must be in snake case (e.g., "field_to_update"). Omitted fields will not be updated. To replace the entire entity, use one path with the string "*" to match all fields.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateDataRetentionSettingsRequest.new

# Call the update_data_retention_settings method.
result = client.update_data_retention_settings request

# The returned object is of type Google::Analytics::Admin::V1alpha::DataRetentionSettings.
p result

#update_data_stream

def update_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
def update_data_stream(data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::DataStream

Updates a DataStream on a property.

Overloads
def update_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
Pass arguments to update_data_stream via a request object, either of type UpdateDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_data_stream(data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::DataStream
Pass arguments to update_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateDataStreamRequest.new

# Call the update_data_stream method.
result = client.update_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::DataStream.
p result
def update_display_video360_advertiser_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
def update_display_video360_advertiser_link(display_video_360_advertiser_link: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink

Updates a DisplayVideo360AdvertiserLink on a property.

Overloads
def update_display_video360_advertiser_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
Pass arguments to update_display_video360_advertiser_link via a request object, either of type UpdateDisplayVideo360AdvertiserLinkRequest or an equivalent Hash.
Parameters
def update_display_video360_advertiser_link(display_video_360_advertiser_link: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink
Pass arguments to update_display_video360_advertiser_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateDisplayVideo360AdvertiserLinkRequest.new

# Call the update_display_video360_advertiser_link method.
result = client.update_display_video360_advertiser_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::DisplayVideo360AdvertiserLink.
p result
def update_google_ads_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink
def update_google_ads_link(google_ads_link: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink

Updates a GoogleAdsLink on a property

Overloads
def update_google_ads_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink
Pass arguments to update_google_ads_link via a request object, either of type UpdateGoogleAdsLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateGoogleAdsLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_google_ads_link(google_ads_link: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleAdsLink
Pass arguments to update_google_ads_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateGoogleAdsLinkRequest.new

# Call the update_google_ads_link method.
result = client.update_google_ads_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::GoogleAdsLink.
p result

#update_google_signals_settings

def update_google_signals_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings
def update_google_signals_settings(google_signals_settings: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings

Updates Google Signals settings for a property.

Overloads
def update_google_signals_settings(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings
Pass arguments to update_google_signals_settings via a request object, either of type UpdateGoogleSignalsSettingsRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateGoogleSignalsSettingsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_google_signals_settings(google_signals_settings: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings
Pass arguments to update_google_signals_settings via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • google_signals_settings (::Google::Analytics::Admin::V1alpha::GoogleSignalsSettings, ::Hash) — Required. The settings to update. The name field is used to identify the settings to be updated.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. The list of fields to be updated. Field names must be in snake case (e.g., "field_to_update"). Omitted fields will not be updated. To replace the entire entity, use one path with the string "*" to match all fields.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateGoogleSignalsSettingsRequest.new

# Call the update_google_signals_settings method.
result = client.update_google_signals_settings request

# The returned object is of type Google::Analytics::Admin::V1alpha::GoogleSignalsSettings.
p result

#update_ios_app_data_stream

def update_ios_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream
def update_ios_app_data_stream(ios_app_data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream

Updates an iOS app stream on a property.

Overloads
def update_ios_app_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream
Pass arguments to update_ios_app_data_stream via a request object, either of type UpdateIosAppDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateIosAppDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_ios_app_data_stream(ios_app_data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::IosAppDataStream
Pass arguments to update_ios_app_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • ios_app_data_stream (::Google::Analytics::Admin::V1alpha::IosAppDataStream, ::Hash) — Required. The iOS app stream to update. The name field is used to identify the iOS app stream to be updated.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. The list of fields to be updated. Field names must be in snake case (e.g., "field_to_update"). Omitted fields will not be updated. To replace the entire entity, use one path with the string "*" to match all fields.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateIosAppDataStreamRequest.new

# Call the update_ios_app_data_stream method.
result = client.update_ios_app_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::IosAppDataStream.
p result

#update_measurement_protocol_secret

def update_measurement_protocol_secret(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
def update_measurement_protocol_secret(measurement_protocol_secret: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret

Updates a measurement protocol secret.

Overloads
def update_measurement_protocol_secret(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
Pass arguments to update_measurement_protocol_secret via a request object, either of type UpdateMeasurementProtocolSecretRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateMeasurementProtocolSecretRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_measurement_protocol_secret(measurement_protocol_secret: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret
Pass arguments to update_measurement_protocol_secret via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateMeasurementProtocolSecretRequest.new

# Call the update_measurement_protocol_secret method.
result = client.update_measurement_protocol_secret request

# The returned object is of type Google::Analytics::Admin::V1alpha::MeasurementProtocolSecret.
p result

#update_property

def update_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
def update_property(property: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::Property

Updates a property.

Overloads
def update_property(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to update_property via a request object, either of type UpdatePropertyRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdatePropertyRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_property(property: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::Property
Pass arguments to update_property via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • property (::Google::Analytics::Admin::V1alpha::Property, ::Hash) — Required. The property to update. The property's name field is used to identify the property to be updated.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. The list of fields to be updated. Field names must be in snake case (e.g., "field_to_update"). Omitted fields will not be updated. To replace the entire entity, use one path with the string "*" to match all fields.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdatePropertyRequest.new

# Call the update_property method.
result = client.update_property request

# The returned object is of type Google::Analytics::Admin::V1alpha::Property.
p result
def update_user_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
def update_user_link(user_link: nil) -> ::Google::Analytics::Admin::V1alpha::UserLink

Updates a user link on an account or property.

Overloads
def update_user_link(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
Pass arguments to update_user_link via a request object, either of type UpdateUserLinkRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateUserLinkRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_user_link(user_link: nil) -> ::Google::Analytics::Admin::V1alpha::UserLink
Pass arguments to update_user_link via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateUserLinkRequest.new

# Call the update_user_link method.
result = client.update_user_link request

# The returned object is of type Google::Analytics::Admin::V1alpha::UserLink.
p result

#update_web_data_stream

def update_web_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
def update_web_data_stream(web_data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream

Updates a web stream on a property.

Overloads
def update_web_data_stream(request, options = nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
Pass arguments to update_web_data_stream via a request object, either of type UpdateWebDataStreamRequest or an equivalent Hash.
Parameters
  • request (::Google::Analytics::Admin::V1alpha::UpdateWebDataStreamRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_web_data_stream(web_data_stream: nil, update_mask: nil) -> ::Google::Analytics::Admin::V1alpha::WebDataStream
Pass arguments to update_web_data_stream via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • web_data_stream (::Google::Analytics::Admin::V1alpha::WebDataStream, ::Hash) — Required. The web stream to update. The name field is used to identify the web stream to be updated.
  • update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. The list of fields to be updated. Field names must be in snake case (e.g., "field_to_update"). Omitted fields will not be updated. To replace the entire entity, use one path with the string "*" to match all fields.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/analytics/admin/v1alpha"

# Create a client object. The client can be reused for multiple calls.
client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Analytics::Admin::V1alpha::UpdateWebDataStreamRequest.new

# Call the update_web_data_stream method.
result = client.update_web_data_stream request

# The returned object is of type Google::Analytics::Admin::V1alpha::WebDataStream.
p result