Skip to content

Commit

Permalink
feat: [analyticsdata] add the SheetExportAudienceList method to the…
Browse files Browse the repository at this point in the history
… Data API v1 alpha (#10047)

- [ ] Regenerate this pull request now.

feat: add `creation_quota_tokens_charged`, `row_count`, `error_message` to the `AudienceList` resource
fix: add `optional` annotation to the `page_token` field of the `ListAudienceListsRequest` type
fix: add `optional` annotation to the `offset`, `limit` fields of the `QueryAudienceListRequest` type
fix: add `required` annotation to the `name` field of the `QueryAudienceListRequest` type
fix: add `optional` annotation to the `dimension_name` field of the `AudienceDimension` type
fix: add `optional` annotation to the `property`, `date_ranges`, `funnel`, `funnel_breakdown`, `funnel_visualization_type`, `segments`, `dimension_filter`, `return_property_quota`, `limit` fields of the `RunFunnelReportRequest` type
fix!: change the resource pattern value to `properties/{property}/audienceLists/{audience_list}` for the resource definition `analyticsdata.googleapis.com/AudienceList`
fix!: change the resource pattern value to `properties/{property}` for the resource definition `analyticsadmin.googleapis.com/Property`

PiperOrigin-RevId: 580634757

Source-Link: https://togithub.com/googleapis/googleapis/commit/a50eda1d37e6b8b8ccb37f9ccce498965f02928c

Source-Link: https://togithub.com/googleapis/googleapis-gen/commit/e55c7e473524e3df4332609aa22963180eba1c01
Copy-Tag: eyJwIjoiamF2YS1hbmFseXRpY3MtZGF0YS8uT3dsQm90LnlhbWwiLCJoIjoiZTU1YzdlNDczNTI0ZTNkZjQzMzI2MDlhYTIyOTYzMTgwZWJhMWMwMSJ9
  • Loading branch information
gcf-owl-bot[bot] authored Nov 16, 2023
1 parent a9830d9 commit a6880a0
Show file tree
Hide file tree
Showing 62 changed files with 6,181 additions and 1,184 deletions.
4 changes: 2 additions & 2 deletions java-analytics-data/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ If you are using Maven with [BOM][libraries-bom], add this to your pom.xml file:
<dependency>
<groupId>com.google.cloud</groupId>
<artifactId>libraries-bom</artifactId>
<version>26.23.0</version>
<version>26.26.0</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Expand Down Expand Up @@ -201,7 +201,7 @@ Java is a registered trademark of Oracle and/or its affiliates.
[kokoro-badge-link-5]: http://storage.googleapis.com/cloud-devrel-public/java/badges/google-cloud-java/java11.html
[stability-image]: https://img.shields.io/badge/stability-preview-yellow
[maven-version-image]: https://img.shields.io/maven-central/v/com.google.analytics/google-analytics-data.svg
[maven-version-link]: https://central.sonatype.com/artifact/com.google.analytics/google-analytics-data/0.35.0
[maven-version-link]: https://central.sonatype.com/artifact/com.google.analytics/google-analytics-data/0.41.0
[authentication]: https://github.com/googleapis/google-cloud-java#authentication
[auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes
[predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,12 @@ public UnaryCallSettings<CreateAudienceListRequest, Operation> createAudienceLis
return ((AlphaAnalyticsDataStubSettings) getStubSettings()).queryAudienceListSettings();
}

/** Returns the object with the settings used for calls to sheetExportAudienceList. */
public UnaryCallSettings<SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListSettings() {
return ((AlphaAnalyticsDataStubSettings) getStubSettings()).sheetExportAudienceListSettings();
}

/** Returns the object with the settings used for calls to getAudienceList. */
public UnaryCallSettings<GetAudienceListRequest, AudienceList> getAudienceListSettings() {
return ((AlphaAnalyticsDataStubSettings) getStubSettings()).getAudienceListSettings();
Expand Down Expand Up @@ -255,6 +261,13 @@ public Builder applyToAllUnaryMethods(
return getStubSettingsBuilder().queryAudienceListSettings();
}

/** Returns the builder for the settings used for calls to sheetExportAudienceList. */
public UnaryCallSettings.Builder<
SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListSettings() {
return getStubSettingsBuilder().sheetExportAudienceListSettings();
}

/** Returns the builder for the settings used for calls to getAudienceList. */
public UnaryCallSettings.Builder<GetAudienceListRequest, AudienceList>
getAudienceListSettings() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@
},
"RunFunnelReport": {
"methods": ["runFunnelReport", "runFunnelReportCallable"]
},
"SheetExportAudienceList": {
"methods": ["sheetExportAudienceList", "sheetExportAudienceList", "sheetExportAudienceList", "sheetExportAudienceListCallable"]
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
import com.google.analytics.data.v1alpha.QueryAudienceListResponse;
import com.google.analytics.data.v1alpha.RunFunnelReportRequest;
import com.google.analytics.data.v1alpha.RunFunnelReportResponse;
import com.google.analytics.data.v1alpha.SheetExportAudienceListRequest;
import com.google.analytics.data.v1alpha.SheetExportAudienceListResponse;
import com.google.api.core.BetaApi;
import com.google.api.gax.core.BackgroundResource;
import com.google.api.gax.rpc.OperationCallable;
Expand Down Expand Up @@ -73,6 +75,11 @@ public UnaryCallable<CreateAudienceListRequest, Operation> createAudienceListCal
throw new UnsupportedOperationException("Not implemented: queryAudienceListCallable()");
}

public UnaryCallable<SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListCallable() {
throw new UnsupportedOperationException("Not implemented: sheetExportAudienceListCallable()");
}

public UnaryCallable<GetAudienceListRequest, AudienceList> getAudienceListCallable() {
throw new UnsupportedOperationException("Not implemented: getAudienceListCallable()");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
import com.google.analytics.data.v1alpha.QueryAudienceListResponse;
import com.google.analytics.data.v1alpha.RunFunnelReportRequest;
import com.google.analytics.data.v1alpha.RunFunnelReportResponse;
import com.google.analytics.data.v1alpha.SheetExportAudienceListRequest;
import com.google.analytics.data.v1alpha.SheetExportAudienceListResponse;
import com.google.api.core.ApiFunction;
import com.google.api.core.ApiFuture;
import com.google.api.core.BetaApi;
Expand Down Expand Up @@ -113,6 +115,9 @@ public class AlphaAnalyticsDataStubSettings extends StubSettings<AlphaAnalyticsD
ImmutableList.<String>builder()
.add("https://www.googleapis.com/auth/analytics")
.add("https://www.googleapis.com/auth/analytics.readonly")
.add("https://www.googleapis.com/auth/drive")
.add("https://www.googleapis.com/auth/drive.file")
.add("https://www.googleapis.com/auth/spreadsheets")
.build();

private final UnaryCallSettings<RunFunnelReportRequest, RunFunnelReportResponse>
Expand All @@ -122,6 +127,8 @@ public class AlphaAnalyticsDataStubSettings extends StubSettings<AlphaAnalyticsD
createAudienceListOperationSettings;
private final UnaryCallSettings<QueryAudienceListRequest, QueryAudienceListResponse>
queryAudienceListSettings;
private final UnaryCallSettings<SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListSettings;
private final UnaryCallSettings<GetAudienceListRequest, AudienceList> getAudienceListSettings;
private final PagedCallSettings<
ListAudienceListsRequest, ListAudienceListsResponse, ListAudienceListsPagedResponse>
Expand Down Expand Up @@ -211,6 +218,12 @@ public UnaryCallSettings<CreateAudienceListRequest, Operation> createAudienceLis
return queryAudienceListSettings;
}

/** Returns the object with the settings used for calls to sheetExportAudienceList. */
public UnaryCallSettings<SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListSettings() {
return sheetExportAudienceListSettings;
}

/** Returns the object with the settings used for calls to getAudienceList. */
public UnaryCallSettings<GetAudienceListRequest, AudienceList> getAudienceListSettings() {
return getAudienceListSettings;
Expand Down Expand Up @@ -334,6 +347,7 @@ protected AlphaAnalyticsDataStubSettings(Builder settingsBuilder) throws IOExcep
createAudienceListOperationSettings =
settingsBuilder.createAudienceListOperationSettings().build();
queryAudienceListSettings = settingsBuilder.queryAudienceListSettings().build();
sheetExportAudienceListSettings = settingsBuilder.sheetExportAudienceListSettings().build();
getAudienceListSettings = settingsBuilder.getAudienceListSettings().build();
listAudienceListsSettings = settingsBuilder.listAudienceListsSettings().build();
}
Expand All @@ -351,6 +365,9 @@ public static class Builder
createAudienceListOperationSettings;
private final UnaryCallSettings.Builder<QueryAudienceListRequest, QueryAudienceListResponse>
queryAudienceListSettings;
private final UnaryCallSettings.Builder<
SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListSettings;
private final UnaryCallSettings.Builder<GetAudienceListRequest, AudienceList>
getAudienceListSettings;
private final PagedCallSettings.Builder<
Expand Down Expand Up @@ -408,6 +425,7 @@ protected Builder(ClientContext clientContext) {
createAudienceListSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
createAudienceListOperationSettings = OperationCallSettings.newBuilder();
queryAudienceListSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
sheetExportAudienceListSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
getAudienceListSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
listAudienceListsSettings = PagedCallSettings.newBuilder(LIST_AUDIENCE_LISTS_PAGE_STR_FACT);

Expand All @@ -416,6 +434,7 @@ protected Builder(ClientContext clientContext) {
runFunnelReportSettings,
createAudienceListSettings,
queryAudienceListSettings,
sheetExportAudienceListSettings,
getAudienceListSettings,
listAudienceListsSettings);
initDefaults(this);
Expand All @@ -429,6 +448,7 @@ protected Builder(AlphaAnalyticsDataStubSettings settings) {
createAudienceListOperationSettings =
settings.createAudienceListOperationSettings.toBuilder();
queryAudienceListSettings = settings.queryAudienceListSettings.toBuilder();
sheetExportAudienceListSettings = settings.sheetExportAudienceListSettings.toBuilder();
getAudienceListSettings = settings.getAudienceListSettings.toBuilder();
listAudienceListsSettings = settings.listAudienceListsSettings.toBuilder();

Expand All @@ -437,6 +457,7 @@ protected Builder(AlphaAnalyticsDataStubSettings settings) {
runFunnelReportSettings,
createAudienceListSettings,
queryAudienceListSettings,
sheetExportAudienceListSettings,
getAudienceListSettings,
listAudienceListsSettings);
}
Expand Down Expand Up @@ -483,6 +504,11 @@ private static Builder initDefaults(Builder builder) {
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params"));

builder
.sheetExportAudienceListSettings()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes"))
.setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params"));

builder
.getAudienceListSettings()
.setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes"))
Expand Down Expand Up @@ -562,6 +588,13 @@ public Builder applyToAllUnaryMethods(
return queryAudienceListSettings;
}

/** Returns the builder for the settings used for calls to sheetExportAudienceList. */
public UnaryCallSettings.Builder<
SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListSettings() {
return sheetExportAudienceListSettings;
}

/** Returns the builder for the settings used for calls to getAudienceList. */
public UnaryCallSettings.Builder<GetAudienceListRequest, AudienceList>
getAudienceListSettings() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
import com.google.analytics.data.v1alpha.QueryAudienceListResponse;
import com.google.analytics.data.v1alpha.RunFunnelReportRequest;
import com.google.analytics.data.v1alpha.RunFunnelReportResponse;
import com.google.analytics.data.v1alpha.SheetExportAudienceListRequest;
import com.google.analytics.data.v1alpha.SheetExportAudienceListResponse;
import com.google.api.core.BetaApi;
import com.google.api.gax.core.BackgroundResource;
import com.google.api.gax.core.BackgroundResourceAggregation;
Expand Down Expand Up @@ -88,6 +90,20 @@ public class GrpcAlphaAnalyticsDataStub extends AlphaAnalyticsDataStub {
ProtoUtils.marshaller(QueryAudienceListResponse.getDefaultInstance()))
.build();

private static final MethodDescriptor<
SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListMethodDescriptor =
MethodDescriptor
.<SheetExportAudienceListRequest, SheetExportAudienceListResponse>newBuilder()
.setType(MethodDescriptor.MethodType.UNARY)
.setFullMethodName(
"google.analytics.data.v1alpha.AlphaAnalyticsData/SheetExportAudienceList")
.setRequestMarshaller(
ProtoUtils.marshaller(SheetExportAudienceListRequest.getDefaultInstance()))
.setResponseMarshaller(
ProtoUtils.marshaller(SheetExportAudienceListResponse.getDefaultInstance()))
.build();

private static final MethodDescriptor<GetAudienceListRequest, AudienceList>
getAudienceListMethodDescriptor =
MethodDescriptor.<GetAudienceListRequest, AudienceList>newBuilder()
Expand Down Expand Up @@ -117,6 +133,8 @@ public class GrpcAlphaAnalyticsDataStub extends AlphaAnalyticsDataStub {
createAudienceListOperationCallable;
private final UnaryCallable<QueryAudienceListRequest, QueryAudienceListResponse>
queryAudienceListCallable;
private final UnaryCallable<SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListCallable;
private final UnaryCallable<GetAudienceListRequest, AudienceList> getAudienceListCallable;
private final UnaryCallable<ListAudienceListsRequest, ListAudienceListsResponse>
listAudienceListsCallable;
Expand Down Expand Up @@ -199,6 +217,18 @@ protected GrpcAlphaAnalyticsDataStub(
return builder.build();
})
.build();
GrpcCallSettings<SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListTransportSettings =
GrpcCallSettings
.<SheetExportAudienceListRequest, SheetExportAudienceListResponse>newBuilder()
.setMethodDescriptor(sheetExportAudienceListMethodDescriptor)
.setParamsExtractor(
request -> {
RequestParamsBuilder builder = RequestParamsBuilder.create();
builder.add("name", String.valueOf(request.getName()));
return builder.build();
})
.build();
GrpcCallSettings<GetAudienceListRequest, AudienceList> getAudienceListTransportSettings =
GrpcCallSettings.<GetAudienceListRequest, AudienceList>newBuilder()
.setMethodDescriptor(getAudienceListMethodDescriptor)
Expand Down Expand Up @@ -240,6 +270,11 @@ protected GrpcAlphaAnalyticsDataStub(
queryAudienceListTransportSettings,
settings.queryAudienceListSettings(),
clientContext);
this.sheetExportAudienceListCallable =
callableFactory.createUnaryCallable(
sheetExportAudienceListTransportSettings,
settings.sheetExportAudienceListSettings(),
clientContext);
this.getAudienceListCallable =
callableFactory.createUnaryCallable(
getAudienceListTransportSettings, settings.getAudienceListSettings(), clientContext);
Expand Down Expand Up @@ -284,6 +319,12 @@ public UnaryCallable<CreateAudienceListRequest, Operation> createAudienceListCal
return queryAudienceListCallable;
}

@Override
public UnaryCallable<SheetExportAudienceListRequest, SheetExportAudienceListResponse>
sheetExportAudienceListCallable() {
return sheetExportAudienceListCallable;
}

@Override
public UnaryCallable<GetAudienceListRequest, AudienceList> getAudienceListCallable() {
return getAudienceListCallable;
Expand Down
Loading

0 comments on commit a6880a0

Please sign in to comment.