Skip to content

Commit 8217ce5

Browse files
feat: [AnalyticsAdmin] add UserProvidedDataSettings resource and GetUserProvidedDataSettings RPC to Google Analytics (#9108)
* feat: add UserProvidedDataSettings resource and GetUserProvidedDataSettings RPC to Google Analytics chore: update resource name fields to use IDENTIFIER field behavior across Google Analytics resources chore: add plural and singular names to google.api.resource definitions for Google Analytics resources chore: mark page_size and page_token fields as OPTIONAL in Google Analytics list request messages chore: update OAuth scopes for GetUserProvidedDataSettings and GetSubpropertySyncConfig in Google Analytics docs: update documentation for GetReportingIdentitySettings to correctly describe it as returning reporting identity settings in Google Analytics docs: update copyright year to 2026 in Google Analytics proto files PiperOrigin-RevId: 899639582 Source-Link: googleapis/googleapis@fc96870 Source-Link: googleapis/googleapis-gen@a4aa3a0 Copy-Tag: eyJwIjoiQW5hbHl0aWNzQWRtaW4vLk93bEJvdC55YW1sIiwiaCI6ImE0YWEzYTA5YmU4YjA3NTg4ZGU1NTkxNDMyZDkxMzE3MjZkMzkwOWEifQ== * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent ee62764 commit 8217ce5

42 files changed

Lines changed: 840 additions & 326 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

AnalyticsAdmin/metadata/V1Alpha/AnalyticsAdmin.php

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AnalyticsAdmin/metadata/V1Alpha/Resources.php

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AnalyticsAdmin/samples/V1alpha/AnalyticsAdminServiceClient/get_reporting_identity_settings.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
use Google\ApiCore\ApiException;
3030

3131
/**
32-
* Returns the singleton data retention settings for this property.
32+
* Returns the reporting identity settings for this property.
3333
*
3434
* @param string $formattedName The name of the settings to lookup.
3535
* Format:
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
<?php
2+
/*
3+
* Copyright 2026 Google LLC
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License");
6+
* you may not use this file except in compliance with the License.
7+
* You may obtain a copy of the License at
8+
*
9+
* https://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*/
17+
18+
/*
19+
* GENERATED CODE WARNING
20+
* This file was automatically generated - do not edit!
21+
*/
22+
23+
require_once __DIR__ . '/../../../vendor/autoload.php';
24+
25+
// [START analyticsadmin_v1alpha_generated_AnalyticsAdminService_GetUserProvidedDataSettings_sync]
26+
use Google\Analytics\Admin\V1alpha\Client\AnalyticsAdminServiceClient;
27+
use Google\Analytics\Admin\V1alpha\GetUserProvidedDataSettingsRequest;
28+
use Google\Analytics\Admin\V1alpha\UserProvidedDataSettings;
29+
use Google\ApiCore\ApiException;
30+
31+
/**
32+
* Looks up settings related to user-provided data for a property.
33+
*
34+
* @param string $formattedName The name of the user provided data settings to retrieve.
35+
* Format: properties/{property}/userProvidedDataSettings
36+
* Please see {@see AnalyticsAdminServiceClient::userProvidedDataSettingsName()} for help formatting this field.
37+
*/
38+
function get_user_provided_data_settings_sample(string $formattedName): void
39+
{
40+
// Create a client.
41+
$analyticsAdminServiceClient = new AnalyticsAdminServiceClient();
42+
43+
// Prepare the request message.
44+
$request = (new GetUserProvidedDataSettingsRequest())
45+
->setName($formattedName);
46+
47+
// Call the API and handle any network failures.
48+
try {
49+
/** @var UserProvidedDataSettings $response */
50+
$response = $analyticsAdminServiceClient->getUserProvidedDataSettings($request);
51+
printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
52+
} catch (ApiException $ex) {
53+
printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
54+
}
55+
}
56+
57+
/**
58+
* Helper to execute the sample.
59+
*
60+
* This sample has been automatically generated and should be regarded as a code
61+
* template only. It will require modifications to work:
62+
* - It may require correct/in-range values for request initialization.
63+
* - It may require specifying regional endpoints when creating the service client,
64+
* please see the apiEndpoint client configuration option for more details.
65+
*/
66+
function callSample(): void
67+
{
68+
$formattedName = AnalyticsAdminServiceClient::userProvidedDataSettingsName('[PROPERTY]');
69+
70+
get_user_provided_data_settings_sample($formattedName);
71+
}
72+
// [END analyticsadmin_v1alpha_generated_AnalyticsAdminService_GetUserProvidedDataSettings_sync]

AnalyticsAdmin/src/V1alpha/Account.php

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AnalyticsAdmin/src/V1alpha/AccountSummary.php

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AnalyticsAdmin/src/V1alpha/CalculatedMetric.php

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AnalyticsAdmin/src/V1alpha/ChangeHistoryChange/ChangeHistoryResource.php

Lines changed: 33 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AnalyticsAdmin/src/V1alpha/ChangeHistoryResourceType.php

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)