1 // Copyright 2024 Google LLC. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 // Code generated file. DO NOT EDIT. 6 7 // Package playdeveloperreporting provides access to the Google Play Developer Reporting API. 8 // 9 // For product documentation, see: https://developers.google.com/play/developer/reporting 10 // 11 // # Library status 12 // 13 // These client libraries are officially supported by Google. However, this 14 // library is considered complete and is in maintenance mode. This means 15 // that we will address critical bugs and security issues but will not add 16 // any new features. 17 // 18 // When possible, we recommend using our newer 19 // [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go) 20 // that are still actively being worked and iterated on. 21 // 22 // # Creating a client 23 // 24 // Usage example: 25 // 26 // import "google.golang.org/api/playdeveloperreporting/v1beta1" 27 // ... 28 // ctx := context.Background() 29 // playdeveloperreportingService, err := playdeveloperreporting.NewService(ctx) 30 // 31 // In this example, Google Application Default Credentials are used for 32 // authentication. For information on how to create and obtain Application 33 // Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials. 34 // 35 // # Other authentication options 36 // 37 // To use an API key for authentication (note: some APIs do not support API 38 // keys), use [google.golang.org/api/option.WithAPIKey]: 39 // 40 // playdeveloperreportingService, err := playdeveloperreporting.NewService(ctx, option.WithAPIKey("AIza...")) 41 // 42 // To use an OAuth token (e.g., a user token obtained via a three-legged OAuth 43 // flow, use [google.golang.org/api/option.WithTokenSource]: 44 // 45 // config := &oauth2.Config{...} 46 // // ... 47 // token, err := config.Exchange(ctx, ...) 48 // playdeveloperreportingService, err := playdeveloperreporting.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token))) 49 // 50 // See [google.golang.org/api/option.ClientOption] for details on options. 51 package playdeveloperreporting // import "google.golang.org/api/playdeveloperreporting/v1beta1" 52 53 import ( 54 "bytes" 55 "context" 56 "encoding/json" 57 "errors" 58 "fmt" 59 "io" 60 "net/http" 61 "net/url" 62 "strconv" 63 "strings" 64 65 googleapi "google.golang.org/api/googleapi" 66 internal "google.golang.org/api/internal" 67 gensupport "google.golang.org/api/internal/gensupport" 68 option "google.golang.org/api/option" 69 internaloption "google.golang.org/api/option/internaloption" 70 htransport "google.golang.org/api/transport/http" 71 ) 72 73 // Always reference these packages, just in case the auto-generated code 74 // below doesn't. 75 var _ = bytes.NewBuffer 76 var _ = strconv.Itoa 77 var _ = fmt.Sprintf 78 var _ = json.NewDecoder 79 var _ = io.Copy 80 var _ = url.Parse 81 var _ = gensupport.MarshalJSON 82 var _ = googleapi.Version 83 var _ = errors.New 84 var _ = strings.Replace 85 var _ = context.Canceled 86 var _ = internaloption.WithDefaultEndpoint 87 var _ = internal.Version 88 89 const apiId = "playdeveloperreporting:v1beta1" 90 const apiName = "playdeveloperreporting" 91 const apiVersion = "v1beta1" 92 const basePath = "https://playdeveloperreporting.googleapis.com/" 93 const basePathTemplate = "https://playdeveloperreporting.UNIVERSE_DOMAIN/" 94 const mtlsBasePath = "https://playdeveloperreporting.mtls.googleapis.com/" 95 96 // OAuth2 scopes used by this API. 97 const ( 98 // See metrics and data about the apps in your Google Play Developer account 99 PlaydeveloperreportingScope = "https://www.googleapis.com/auth/playdeveloperreporting" 100 ) 101 102 // NewService creates a new Service. 103 func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) { 104 scopesOption := internaloption.WithDefaultScopes( 105 "https://www.googleapis.com/auth/playdeveloperreporting", 106 ) 107 // NOTE: prepend, so we don't override user-specified scopes. 108 opts = append([]option.ClientOption{scopesOption}, opts...) 109 opts = append(opts, internaloption.WithDefaultEndpoint(basePath)) 110 opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate)) 111 opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath)) 112 opts = append(opts, internaloption.EnableNewAuthLibrary()) 113 client, endpoint, err := htransport.NewClient(ctx, opts...) 114 if err != nil { 115 return nil, err 116 } 117 s, err := New(client) 118 if err != nil { 119 return nil, err 120 } 121 if endpoint != "" { 122 s.BasePath = endpoint 123 } 124 return s, nil 125 } 126 127 // New creates a new Service. It uses the provided http.Client for requests. 128 // 129 // Deprecated: please use NewService instead. 130 // To provide a custom HTTP client, use option.WithHTTPClient. 131 // If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. 132 func New(client *http.Client) (*Service, error) { 133 if client == nil { 134 return nil, errors.New("client is nil") 135 } 136 s := &Service{client: client, BasePath: basePath} 137 s.Anomalies = NewAnomaliesService(s) 138 s.Apps = NewAppsService(s) 139 s.Vitals = NewVitalsService(s) 140 return s, nil 141 } 142 143 type Service struct { 144 client *http.Client 145 BasePath string // API endpoint base URL 146 UserAgent string // optional additional User-Agent fragment 147 148 Anomalies *AnomaliesService 149 150 Apps *AppsService 151 152 Vitals *VitalsService 153 } 154 155 func (s *Service) userAgent() string { 156 if s.UserAgent == "" { 157 return googleapi.UserAgent 158 } 159 return googleapi.UserAgent + " " + s.UserAgent 160 } 161 162 func NewAnomaliesService(s *Service) *AnomaliesService { 163 rs := &AnomaliesService{s: s} 164 return rs 165 } 166 167 type AnomaliesService struct { 168 s *Service 169 } 170 171 func NewAppsService(s *Service) *AppsService { 172 rs := &AppsService{s: s} 173 return rs 174 } 175 176 type AppsService struct { 177 s *Service 178 } 179 180 func NewVitalsService(s *Service) *VitalsService { 181 rs := &VitalsService{s: s} 182 rs.Anrrate = NewVitalsAnrrateService(s) 183 rs.Crashrate = NewVitalsCrashrateService(s) 184 rs.Errors = NewVitalsErrorsService(s) 185 rs.Excessivewakeuprate = NewVitalsExcessivewakeuprateService(s) 186 rs.Slowrenderingrate = NewVitalsSlowrenderingrateService(s) 187 rs.Slowstartrate = NewVitalsSlowstartrateService(s) 188 rs.Stuckbackgroundwakelockrate = NewVitalsStuckbackgroundwakelockrateService(s) 189 return rs 190 } 191 192 type VitalsService struct { 193 s *Service 194 195 Anrrate *VitalsAnrrateService 196 197 Crashrate *VitalsCrashrateService 198 199 Errors *VitalsErrorsService 200 201 Excessivewakeuprate *VitalsExcessivewakeuprateService 202 203 Slowrenderingrate *VitalsSlowrenderingrateService 204 205 Slowstartrate *VitalsSlowstartrateService 206 207 Stuckbackgroundwakelockrate *VitalsStuckbackgroundwakelockrateService 208 } 209 210 func NewVitalsAnrrateService(s *Service) *VitalsAnrrateService { 211 rs := &VitalsAnrrateService{s: s} 212 return rs 213 } 214 215 type VitalsAnrrateService struct { 216 s *Service 217 } 218 219 func NewVitalsCrashrateService(s *Service) *VitalsCrashrateService { 220 rs := &VitalsCrashrateService{s: s} 221 return rs 222 } 223 224 type VitalsCrashrateService struct { 225 s *Service 226 } 227 228 func NewVitalsErrorsService(s *Service) *VitalsErrorsService { 229 rs := &VitalsErrorsService{s: s} 230 rs.Counts = NewVitalsErrorsCountsService(s) 231 rs.Issues = NewVitalsErrorsIssuesService(s) 232 rs.Reports = NewVitalsErrorsReportsService(s) 233 return rs 234 } 235 236 type VitalsErrorsService struct { 237 s *Service 238 239 Counts *VitalsErrorsCountsService 240 241 Issues *VitalsErrorsIssuesService 242 243 Reports *VitalsErrorsReportsService 244 } 245 246 func NewVitalsErrorsCountsService(s *Service) *VitalsErrorsCountsService { 247 rs := &VitalsErrorsCountsService{s: s} 248 return rs 249 } 250 251 type VitalsErrorsCountsService struct { 252 s *Service 253 } 254 255 func NewVitalsErrorsIssuesService(s *Service) *VitalsErrorsIssuesService { 256 rs := &VitalsErrorsIssuesService{s: s} 257 return rs 258 } 259 260 type VitalsErrorsIssuesService struct { 261 s *Service 262 } 263 264 func NewVitalsErrorsReportsService(s *Service) *VitalsErrorsReportsService { 265 rs := &VitalsErrorsReportsService{s: s} 266 return rs 267 } 268 269 type VitalsErrorsReportsService struct { 270 s *Service 271 } 272 273 func NewVitalsExcessivewakeuprateService(s *Service) *VitalsExcessivewakeuprateService { 274 rs := &VitalsExcessivewakeuprateService{s: s} 275 return rs 276 } 277 278 type VitalsExcessivewakeuprateService struct { 279 s *Service 280 } 281 282 func NewVitalsSlowrenderingrateService(s *Service) *VitalsSlowrenderingrateService { 283 rs := &VitalsSlowrenderingrateService{s: s} 284 return rs 285 } 286 287 type VitalsSlowrenderingrateService struct { 288 s *Service 289 } 290 291 func NewVitalsSlowstartrateService(s *Service) *VitalsSlowstartrateService { 292 rs := &VitalsSlowstartrateService{s: s} 293 return rs 294 } 295 296 type VitalsSlowstartrateService struct { 297 s *Service 298 } 299 300 func NewVitalsStuckbackgroundwakelockrateService(s *Service) *VitalsStuckbackgroundwakelockrateService { 301 rs := &VitalsStuckbackgroundwakelockrateService{s: s} 302 return rs 303 } 304 305 type VitalsStuckbackgroundwakelockrateService struct { 306 s *Service 307 } 308 309 // GooglePlayDeveloperReportingV1beta1Anomaly: Represents an anomaly detected 310 // in a dataset. Our anomaly detection systems flag datapoints in a time series 311 // that fall outside of and expected range derived from historical data. 312 // Although those expected ranges have an upper and a lower bound, we only flag 313 // anomalies when the data has become unexpectedly _worse_, which usually 314 // corresponds to the case where the metric crosses the upper bound. Multiple 315 // contiguous datapoints in a timeline outside of the expected range will be 316 // grouped into a single anomaly. Therefore, an anomaly represents effectively 317 // a segment of a metric's timeline. The information stored in the 318 // `timeline_spec`, `dimensions` and `metric` can be used to fetch a full 319 // timeline with extended ragne for context. **Required permissions**: to 320 // access this resource, the calling user needs the _View app information 321 // (read-only)_ permission for the app. 322 type GooglePlayDeveloperReportingV1beta1Anomaly struct { 323 // Dimensions: Combination of dimensions in which the anomaly was detected. 324 Dimensions []*GooglePlayDeveloperReportingV1beta1DimensionValue `json:"dimensions,omitempty"` 325 // Metric: Metric where the anomaly was detected, together with the anomalous 326 // value. 327 Metric *GooglePlayDeveloperReportingV1beta1MetricValue `json:"metric,omitempty"` 328 // MetricSet: Metric set resource where the anomaly was detected. 329 MetricSet string `json:"metricSet,omitempty"` 330 // Name: Identifier. Name of the anomaly. Format: 331 // apps/{app}/anomalies/{anomaly} 332 Name string `json:"name,omitempty"` 333 // TimelineSpec: Timeline specification that covers the anomaly period. 334 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 335 // ForceSendFields is a list of field names (e.g. "Dimensions") to 336 // unconditionally include in API requests. By default, fields with empty or 337 // default values are omitted from API requests. See 338 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 339 // details. 340 ForceSendFields []string `json:"-"` 341 // NullFields is a list of field names (e.g. "Dimensions") to include in API 342 // requests with the JSON null value. By default, fields with empty values are 343 // omitted from API requests. See 344 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 345 NullFields []string `json:"-"` 346 } 347 348 func (s *GooglePlayDeveloperReportingV1beta1Anomaly) MarshalJSON() ([]byte, error) { 349 type NoMethod GooglePlayDeveloperReportingV1beta1Anomaly 350 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 351 } 352 353 // GooglePlayDeveloperReportingV1beta1AnrRateMetricSet: Singleton resource 354 // representing the set of ANR (Application not responding) metrics. This 355 // metric set contains ANRs data combined with usage data to produce a 356 // normalized metric independent of user counts. **Supported aggregation 357 // periods:** * DAILY: metrics are aggregated in calendar date intervals. Due 358 // to historical constraints, the only supported timezone is 359 // `America/Los_Angeles`. * HOURLY: metrics are aggregated in hourly intervals. 360 // The default and only supported timezone is `UTC`. **Supported metrics:** * 361 // `anrRate` (`google.type.Decimal`): Percentage of distinct users in the 362 // aggregation period that experienced at least one ANR. * 363 // `anrRate7dUserWeighted` (`google.type.Decimal`): Rolling average value of 364 // `anrRate` in the last 7 days. The daily values are weighted by the count of 365 // distinct users for the day. Not supported in HOURLY granularity. * 366 // `anrRate28dUserWeighted` (`google.type.Decimal`): Rolling average value of 367 // `anrRate` in the last 28 days. The daily values are weighted by the count of 368 // distinct users for the day. Not supported in HOURLY granularity. * 369 // `userPerceivedAnrRate` (`google.type.Decimal`): Percentage of distinct users 370 // in the aggregation period that experienced at least one user-perceived ANR. 371 // User-perceived ANRs are currently those of 'Input dispatching' type. * 372 // `userPerceivedAnrRate7dUserWeighted` (`google.type.Decimal`): Rolling 373 // average value of `userPerceivedAnrRate` in the last 7 days. The daily values 374 // are weighted by the count of distinct users for the day. Not supported in 375 // HOURLY granularity. * `userPerceivedAnrRate28dUserWeighted` 376 // (`google.type.Decimal`): Rolling average value of `userPerceivedAnrRate` in 377 // the last 28 days. The daily values are weighted by the count of distinct 378 // users for the day. * `distinctUsers` (`google.type.Decimal`): Count of 379 // distinct users in the aggregation period that were used as normalization 380 // value for the `anrRate` and `userPerceivedAnrRate` metrics. A user is 381 // counted in this metric if they used the app in the foreground during the 382 // aggregation period. Care must be taken not to aggregate this count further, 383 // as it may result in users being counted multiple times. The value is rounded 384 // to the nearest multiple of 10, 100, 1,000 or 1,000,000, depending on the 385 // magnitude of the value. **Supported dimensions:** * `apiLevel` (string): the 386 // API level of Android that was running on the user's device, e.g., 26. * 387 // `versionCode` (int64): version of the app that was running on the user's 388 // device. * `deviceModel` (string): unique identifier of the user's device 389 // model. The form of the identifier is 'deviceBrand/device', where deviceBrand 390 // corresponds to Build.BRAND and device corresponds to Build.DEVICE, e.g., 391 // google/coral. * `deviceBrand` (string): unique identifier of the user's 392 // device brand, e.g., google. * `deviceType` (string): the type (also known as 393 // form factor) of the user's device, e.g., PHONE. * `countryCode` (string): 394 // the country or region of the user's device based on their IP address, 395 // represented as a 2-letter ISO-3166 code (e.g. US for the United States). * 396 // `deviceRamBucket` (int64): RAM of the device, in MB, in buckets (3GB, 4GB, 397 // etc.). * `deviceSocMake` (string): Make of the device's primary 398 // system-on-chip, e.g., Samsung. Reference 399 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 400 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 401 // e.g., "Exynos 2100". Reference 402 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 403 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 404 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 405 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 406 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 407 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 408 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 409 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 410 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 411 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 412 // device, e.g., mdpi, hdpi. **Required permissions**: to access this resource, 413 // the calling user needs the _View app information (read-only)_ permission for 414 // the app. **Related metric sets:** * vitals.errors contains unnormalized 415 // version (absolute counts) of crashes. * vitals.errors contains normalized 416 // metrics about crashes, another stability metric. 417 type GooglePlayDeveloperReportingV1beta1AnrRateMetricSet struct { 418 // FreshnessInfo: Summary about data freshness in this resource. 419 FreshnessInfo *GooglePlayDeveloperReportingV1beta1FreshnessInfo `json:"freshnessInfo,omitempty"` 420 // Name: Identifier. The resource name. Format: apps/{app}/anrRateMetricSet 421 Name string `json:"name,omitempty"` 422 423 // ServerResponse contains the HTTP response code and headers from the server. 424 googleapi.ServerResponse `json:"-"` 425 // ForceSendFields is a list of field names (e.g. "FreshnessInfo") to 426 // unconditionally include in API requests. By default, fields with empty or 427 // default values are omitted from API requests. See 428 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 429 // details. 430 ForceSendFields []string `json:"-"` 431 // NullFields is a list of field names (e.g. "FreshnessInfo") to include in API 432 // requests with the JSON null value. By default, fields with empty values are 433 // omitted from API requests. See 434 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 435 NullFields []string `json:"-"` 436 } 437 438 func (s *GooglePlayDeveloperReportingV1beta1AnrRateMetricSet) MarshalJSON() ([]byte, error) { 439 type NoMethod GooglePlayDeveloperReportingV1beta1AnrRateMetricSet 440 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 441 } 442 443 // GooglePlayDeveloperReportingV1beta1App: A representation of an app in the 444 // Play Store. 445 type GooglePlayDeveloperReportingV1beta1App struct { 446 // DisplayName: Title of the app. This is the latest title as set in the Play 447 // Console and may not yet have been reviewed, so might not match the Play 448 // Store. Example: `Google Maps`. 449 DisplayName string `json:"displayName,omitempty"` 450 // Name: Identifier. The resource name. Format: apps/{app} 451 Name string `json:"name,omitempty"` 452 // PackageName: Package name of the app. Example: `com.example.app123`. 453 PackageName string `json:"packageName,omitempty"` 454 // ForceSendFields is a list of field names (e.g. "DisplayName") to 455 // unconditionally include in API requests. By default, fields with empty or 456 // default values are omitted from API requests. See 457 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 458 // details. 459 ForceSendFields []string `json:"-"` 460 // NullFields is a list of field names (e.g. "DisplayName") to include in API 461 // requests with the JSON null value. By default, fields with empty values are 462 // omitted from API requests. See 463 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 464 NullFields []string `json:"-"` 465 } 466 467 func (s *GooglePlayDeveloperReportingV1beta1App) MarshalJSON() ([]byte, error) { 468 type NoMethod GooglePlayDeveloperReportingV1beta1App 469 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 470 } 471 472 // GooglePlayDeveloperReportingV1beta1AppVersion: Representations of an app 473 // version. 474 type GooglePlayDeveloperReportingV1beta1AppVersion struct { 475 // VersionCode: Numeric version code of the app version (set by the app's 476 // developer). 477 VersionCode int64 `json:"versionCode,omitempty,string"` 478 // ForceSendFields is a list of field names (e.g. "VersionCode") to 479 // unconditionally include in API requests. By default, fields with empty or 480 // default values are omitted from API requests. See 481 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 482 // details. 483 ForceSendFields []string `json:"-"` 484 // NullFields is a list of field names (e.g. "VersionCode") to include in API 485 // requests with the JSON null value. By default, fields with empty values are 486 // omitted from API requests. See 487 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 488 NullFields []string `json:"-"` 489 } 490 491 func (s *GooglePlayDeveloperReportingV1beta1AppVersion) MarshalJSON() ([]byte, error) { 492 type NoMethod GooglePlayDeveloperReportingV1beta1AppVersion 493 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 494 } 495 496 // GooglePlayDeveloperReportingV1beta1CrashRateMetricSet: Singleton resource 497 // representing the set of crashrate metrics. This metric set contains crashes 498 // data combined with usage data to produce a normalized metric independent of 499 // user counts. **Supported aggregation periods:** * DAILY: metrics are 500 // aggregated in calendar date intervals. Due to historical constraints, the 501 // only supported timezone is `America/Los_Angeles`. * HOURLY: metrics are 502 // aggregated in hourly intervals. The default and only supported timezone is 503 // `UTC`. **Supported metrics:** * `crashRate` (`google.type.Decimal`): 504 // Percentage of distinct users in the aggregation period that experienced at 505 // least one crash. * `crashRate7dUserWeighted` (`google.type.Decimal`): 506 // Rolling average value of `crashRate` in the last 7 days. The daily values 507 // are weighted by the count of distinct users for the day. Not supported in 508 // HOURLY granularity. * `crashRate28dUserWeighted` (`google.type.Decimal`): 509 // Rolling average value of `crashRate` in the last 28 days. The daily values 510 // are weighted by the count of distinct users for the day. Not supported in 511 // HOURLY granularity. * `userPerceivedCrashRate` (`google.type.Decimal`): 512 // Percentage of distinct users in the aggregation period that experienced at 513 // least one crash while they were actively using your app (a user-perceived 514 // crash). An app is considered to be in active use if it is displaying any 515 // activity or executing any foreground service. * 516 // `userPerceivedCrashRate7dUserWeighted` (`google.type.Decimal`): Rolling 517 // average value of `userPerceivedCrashRate` in the last 7 days. The daily 518 // values are weighted by the count of distinct users for the day. Not 519 // supported in HOURLY granularity. * `userPerceivedCrashRate28dUserWeighted` 520 // (`google.type.Decimal`): Rolling average value of `userPerceivedCrashRate` 521 // in the last 28 days. The daily values are weighted by the count of distinct 522 // users for the day. Not supported in HOURLY granularity. * `distinctUsers` 523 // (`google.type.Decimal`): Count of distinct users in the aggregation period 524 // that were used as normalization value for the `crashRate` and 525 // `userPerceivedCrashRate` metrics. A user is counted in this metric if they 526 // used the app actively during the aggregation period. An app is considered to 527 // be in active use if it is displaying any activity or executing any 528 // foreground service. Care must be taken not to aggregate this count further, 529 // as it may result in users being counted multiple times. The value is rounded 530 // to the nearest multiple of 10, 100, 1,000 or 1,000,000, depending on the 531 // magnitude of the value. **Supported dimensions:** * `apiLevel` (string): the 532 // API level of Android that was running on the user's device, e.g., 26. * 533 // `versionCode` (int64): version of the app that was running on the user's 534 // device. * `deviceModel` (string): unique identifier of the user's device 535 // model. The form of the identifier is 'deviceBrand/device', where deviceBrand 536 // corresponds to Build.BRAND and device corresponds to Build.DEVICE, e.g., 537 // google/coral. * `deviceBrand` (string): unique identifier of the user's 538 // device brand, e.g., google. * `deviceType` (string): the type (also known as 539 // form factor) of the user's device, e.g., PHONE. * `countryCode` (string): 540 // the country or region of the user's device based on their IP address, 541 // represented as a 2-letter ISO-3166 code (e.g. US for the United States). * 542 // `deviceRamBucket` (int64): RAM of the device, in MB, in buckets (3GB, 4GB, 543 // etc.). * `deviceSocMake` (string): Make of the device's primary 544 // system-on-chip, e.g., Samsung. Reference 545 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 546 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 547 // e.g., "Exynos 2100". Reference 548 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 549 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 550 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 551 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 552 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 553 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 554 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 555 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 556 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 557 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 558 // device, e.g., mdpi, hdpi. **Required permissions**: to access this resource, 559 // the calling user needs the _View app information (read-only)_ permission for 560 // the app. **Related metric sets:** * vitals.errors contains unnormalized 561 // version (absolute counts) of crashes. * vitals.errors contains normalized 562 // metrics about ANRs, another stability metric. 563 type GooglePlayDeveloperReportingV1beta1CrashRateMetricSet struct { 564 // FreshnessInfo: Summary about data freshness in this resource. 565 FreshnessInfo *GooglePlayDeveloperReportingV1beta1FreshnessInfo `json:"freshnessInfo,omitempty"` 566 // Name: Identifier. The resource name. Format: apps/{app}/crashRateMetricSet 567 Name string `json:"name,omitempty"` 568 569 // ServerResponse contains the HTTP response code and headers from the server. 570 googleapi.ServerResponse `json:"-"` 571 // ForceSendFields is a list of field names (e.g. "FreshnessInfo") to 572 // unconditionally include in API requests. By default, fields with empty or 573 // default values are omitted from API requests. See 574 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 575 // details. 576 ForceSendFields []string `json:"-"` 577 // NullFields is a list of field names (e.g. "FreshnessInfo") to include in API 578 // requests with the JSON null value. By default, fields with empty values are 579 // omitted from API requests. See 580 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 581 NullFields []string `json:"-"` 582 } 583 584 func (s *GooglePlayDeveloperReportingV1beta1CrashRateMetricSet) MarshalJSON() ([]byte, error) { 585 type NoMethod GooglePlayDeveloperReportingV1beta1CrashRateMetricSet 586 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 587 } 588 589 // GooglePlayDeveloperReportingV1beta1DecimalConfidenceInterval: Represents the 590 // confidence interval of a metric. 591 type GooglePlayDeveloperReportingV1beta1DecimalConfidenceInterval struct { 592 // LowerBound: The confidence interval's lower bound. 593 LowerBound *GoogleTypeDecimal `json:"lowerBound,omitempty"` 594 // UpperBound: The confidence interval's upper bound. 595 UpperBound *GoogleTypeDecimal `json:"upperBound,omitempty"` 596 // ForceSendFields is a list of field names (e.g. "LowerBound") to 597 // unconditionally include in API requests. By default, fields with empty or 598 // default values are omitted from API requests. See 599 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 600 // details. 601 ForceSendFields []string `json:"-"` 602 // NullFields is a list of field names (e.g. "LowerBound") to include in API 603 // requests with the JSON null value. By default, fields with empty values are 604 // omitted from API requests. See 605 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 606 NullFields []string `json:"-"` 607 } 608 609 func (s *GooglePlayDeveloperReportingV1beta1DecimalConfidenceInterval) MarshalJSON() ([]byte, error) { 610 type NoMethod GooglePlayDeveloperReportingV1beta1DecimalConfidenceInterval 611 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 612 } 613 614 // GooglePlayDeveloperReportingV1beta1DeviceId: Identifier of a device. 615 type GooglePlayDeveloperReportingV1beta1DeviceId struct { 616 // BuildBrand: Value of Build.BRAND. 617 BuildBrand string `json:"buildBrand,omitempty"` 618 // BuildDevice: Value of Build.DEVICE. 619 BuildDevice string `json:"buildDevice,omitempty"` 620 // ForceSendFields is a list of field names (e.g. "BuildBrand") to 621 // unconditionally include in API requests. By default, fields with empty or 622 // default values are omitted from API requests. See 623 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 624 // details. 625 ForceSendFields []string `json:"-"` 626 // NullFields is a list of field names (e.g. "BuildBrand") to include in API 627 // requests with the JSON null value. By default, fields with empty values are 628 // omitted from API requests. See 629 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 630 NullFields []string `json:"-"` 631 } 632 633 func (s *GooglePlayDeveloperReportingV1beta1DeviceId) MarshalJSON() ([]byte, error) { 634 type NoMethod GooglePlayDeveloperReportingV1beta1DeviceId 635 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 636 } 637 638 // GooglePlayDeveloperReportingV1beta1DeviceModelSummary: Summary of a device 639 type GooglePlayDeveloperReportingV1beta1DeviceModelSummary struct { 640 // DeviceId: Identifier of the device. 641 DeviceId *GooglePlayDeveloperReportingV1beta1DeviceId `json:"deviceId,omitempty"` 642 // DeviceUri: Link to the device in Play Device Catalog. 643 DeviceUri string `json:"deviceUri,omitempty"` 644 // MarketingName: Display name of the device. 645 MarketingName string `json:"marketingName,omitempty"` 646 // ForceSendFields is a list of field names (e.g. "DeviceId") to 647 // unconditionally include in API requests. By default, fields with empty or 648 // default values are omitted from API requests. See 649 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 650 // details. 651 ForceSendFields []string `json:"-"` 652 // NullFields is a list of field names (e.g. "DeviceId") to include in API 653 // requests with the JSON null value. By default, fields with empty values are 654 // omitted from API requests. See 655 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 656 NullFields []string `json:"-"` 657 } 658 659 func (s *GooglePlayDeveloperReportingV1beta1DeviceModelSummary) MarshalJSON() ([]byte, error) { 660 type NoMethod GooglePlayDeveloperReportingV1beta1DeviceModelSummary 661 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 662 } 663 664 // GooglePlayDeveloperReportingV1beta1DimensionValue: Represents the value of a 665 // single dimension. 666 type GooglePlayDeveloperReportingV1beta1DimensionValue struct { 667 // Dimension: Name of the dimension. 668 Dimension string `json:"dimension,omitempty"` 669 // Int64Value: Actual value, represented as an int64. 670 Int64Value int64 `json:"int64Value,omitempty,string"` 671 // StringValue: Actual value, represented as a string. 672 StringValue string `json:"stringValue,omitempty"` 673 // ValueLabel: Optional. Human-friendly label for the value, always in English. 674 // For example, 'Spain' for the 'ES' country code. Whereas the dimension value 675 // is stable, this value label is subject to change. Do not assume that the 676 // (value, value_label) relationship is stable. For example, the ISO country 677 // code 'MK' changed its name recently to 'North Macedonia'. 678 ValueLabel string `json:"valueLabel,omitempty"` 679 // ForceSendFields is a list of field names (e.g. "Dimension") to 680 // unconditionally include in API requests. By default, fields with empty or 681 // default values are omitted from API requests. See 682 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 683 // details. 684 ForceSendFields []string `json:"-"` 685 // NullFields is a list of field names (e.g. "Dimension") to include in API 686 // requests with the JSON null value. By default, fields with empty values are 687 // omitted from API requests. See 688 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 689 NullFields []string `json:"-"` 690 } 691 692 func (s *GooglePlayDeveloperReportingV1beta1DimensionValue) MarshalJSON() ([]byte, error) { 693 type NoMethod GooglePlayDeveloperReportingV1beta1DimensionValue 694 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 695 } 696 697 // GooglePlayDeveloperReportingV1beta1ErrorCountMetricSet: Singleton resource 698 // representing the set of error report metrics. This metric set contains 699 // un-normalized error report counts. **Supported aggregation periods:** * 700 // HOURLY: metrics are aggregated in hourly intervals. The default and only 701 // supported timezone is `UTC`. * DAILY: metrics are aggregated in calendar 702 // date intervals. The default and only supported timezone is 703 // `America/Los_Angeles`. **Supported metrics:** * `errorReportCount` 704 // (`google.type.Decimal`): Absolute count of individual error reports that 705 // have been received for an app. * `distinctUsers` (`google.type.Decimal`): 706 // Count of distinct users for which reports have been received. Care must be 707 // taken not to aggregate this count further, as it may result in users being 708 // counted multiple times. This value is not rounded, however it may be an 709 // approximation. **Required dimension:** This dimension must be always 710 // specified in all requests in the `dimensions` field in query requests. * 711 // `reportType` (string): the type of error. The value should correspond to one 712 // of the possible values in ErrorType. **Supported dimensions:** * `apiLevel` 713 // (string): the API level of Android that was running on the user's device, 714 // e.g., 26. * `versionCode` (int64): version of the app that was running on 715 // the user's device. * `deviceModel` (string): unique identifier of the user's 716 // device model. The form of the identifier is 'deviceBrand/device', where 717 // deviceBrand corresponds to Build.BRAND and device corresponds to 718 // Build.DEVICE, e.g., google/coral. * `deviceType` (string): identifier of the 719 // device's form factor, e.g., PHONE. * `issueId` (string): the id an error was 720 // assigned to. The value should correspond to the `{issue}` component of the 721 // issue name. * `deviceRamBucket` (int64): RAM of the device, in MB, in 722 // buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): Make of the device's 723 // primary system-on-chip, e.g., Samsung. Reference 724 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 725 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 726 // e.g., "Exynos 2100". Reference 727 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 728 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 729 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 730 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 731 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 732 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 733 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 734 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 735 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 736 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 737 // device, e.g., mdpi, hdpi. **Required permissions**: to access this resource, 738 // the calling user needs the _View app information (read-only)_ permission for 739 // the app. **Related metric sets:** * vitals.errors.counts contains normalized 740 // metrics about Crashes, another stability metric. * vitals.errors.counts 741 // contains normalized metrics about ANRs, another stability metric. 742 type GooglePlayDeveloperReportingV1beta1ErrorCountMetricSet struct { 743 // FreshnessInfo: Summary about data freshness in this resource. 744 FreshnessInfo *GooglePlayDeveloperReportingV1beta1FreshnessInfo `json:"freshnessInfo,omitempty"` 745 // Name: The resource name. Format: apps/{app}/errorCountMetricSet 746 Name string `json:"name,omitempty"` 747 748 // ServerResponse contains the HTTP response code and headers from the server. 749 googleapi.ServerResponse `json:"-"` 750 // ForceSendFields is a list of field names (e.g. "FreshnessInfo") to 751 // unconditionally include in API requests. By default, fields with empty or 752 // default values are omitted from API requests. See 753 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 754 // details. 755 ForceSendFields []string `json:"-"` 756 // NullFields is a list of field names (e.g. "FreshnessInfo") to include in API 757 // requests with the JSON null value. By default, fields with empty values are 758 // omitted from API requests. See 759 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 760 NullFields []string `json:"-"` 761 } 762 763 func (s *GooglePlayDeveloperReportingV1beta1ErrorCountMetricSet) MarshalJSON() ([]byte, error) { 764 type NoMethod GooglePlayDeveloperReportingV1beta1ErrorCountMetricSet 765 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 766 } 767 768 // GooglePlayDeveloperReportingV1beta1ErrorIssue: A group of related 769 // ErrorReports received for an app. Similar error reports are grouped together 770 // into issues with a likely identical root cause. **Please note:** this 771 // resource is currently in Alpha. There could be changes to the issue grouping 772 // that would result in similar but more recent error reports being assigned to 773 // different issues. This could also cause some issues disappearing entirely 774 // and being replaced by new ones. **Required permissions**: to access this 775 // resource, the calling user needs the _View app information (read-only)_ 776 // permission for the app. 777 type GooglePlayDeveloperReportingV1beta1ErrorIssue struct { 778 // Cause: Cause of the issue. Depending on the type this can be either: * 779 // APPLICATION_NOT_RESPONDING: the type of ANR that occurred, e.g., 'Input 780 // dispatching timed out'. * CRASH: for Java unhandled exception errors, the 781 // type of the innermost exception that was thrown, e.g., 782 // IllegalArgumentException. For signals in native code, the signal that was 783 // raised, e.g. SIGSEGV. 784 Cause string `json:"cause,omitempty"` 785 // DistinctUsers: An estimate of the number of unique users who have 786 // experienced this issue (only considering occurrences matching the filters 787 // and within the requested time period). 788 DistinctUsers int64 `json:"distinctUsers,omitempty,string"` 789 // DistinctUsersPercent: An estimated percentage of users affected by any issue 790 // that are affected by this issue (only considering occurrences matching the 791 // filters and within the requested time period). 792 DistinctUsersPercent *GoogleTypeDecimal `json:"distinctUsersPercent,omitempty"` 793 // ErrorReportCount: The total number of error reports in this issue (only 794 // considering occurrences matching the filters and within the requested time 795 // period). 796 ErrorReportCount int64 `json:"errorReportCount,omitempty,string"` 797 // FirstAppVersion: The earliest (inclusive) app version appearing in this 798 // ErrorIssue in the requested time period (only considering occurrences 799 // matching the filters). 800 FirstAppVersion *GooglePlayDeveloperReportingV1beta1AppVersion `json:"firstAppVersion,omitempty"` 801 // FirstOsVersion: The smallest OS version in which this error cluster has 802 // occurred in the requested time period (only considering occurrences matching 803 // the filters and within the requested time period). 804 FirstOsVersion *GooglePlayDeveloperReportingV1beta1OsVersion `json:"firstOsVersion,omitempty"` 805 // IssueUri: Link to the issue in Android vitals in the Play Console. 806 IssueUri string `json:"issueUri,omitempty"` 807 // LastAppVersion: The latest (inclusive) app version appearing in this 808 // ErrorIssue in the requested time period (only considering occurrences 809 // matching the filters). 810 LastAppVersion *GooglePlayDeveloperReportingV1beta1AppVersion `json:"lastAppVersion,omitempty"` 811 // LastErrorReportTime: Start of the hour during which the last error report in 812 // this issue occurred. 813 LastErrorReportTime string `json:"lastErrorReportTime,omitempty"` 814 // LastOsVersion: The latest OS version in which this error cluster has 815 // occurred in the requested time period (only considering occurrences matching 816 // the filters and within the requested time period). 817 LastOsVersion *GooglePlayDeveloperReportingV1beta1OsVersion `json:"lastOsVersion,omitempty"` 818 // Location: Location where the issue happened. Depending on the type this can 819 // be either: * APPLICATION_NOT_RESPONDING: the name of the activity or service 820 // that stopped responding. * CRASH: the likely method name that caused the 821 // error. 822 Location string `json:"location,omitempty"` 823 // Name: Identifier. The resource name of the issue. Format: apps/{app}/{issue} 824 Name string `json:"name,omitempty"` 825 // SampleErrorReports: Output only. Sample error reports which belong to this 826 // ErrorIssue. *Note:* currently a maximum of 1 per ErrorIssue is supported. 827 // Format: "apps/{app}/{report}" 828 SampleErrorReports []string `json:"sampleErrorReports,omitempty"` 829 // Type: Type of the errors grouped in this issue. 830 // 831 // Possible values: 832 // "ERROR_TYPE_UNSPECIFIED" - Unspecified error type. 833 // "APPLICATION_NOT_RESPONDING" - Application Not Responding (ANR) error. To 834 // learn more about this type of errors visit the corresponding Android 835 // Developers documentation. 836 // "CRASH" - Crash caused by an unhandled exception in Java (or Kotlin or any 837 // other JVM language) or a signal in native code such as SIGSEGV. 838 Type string `json:"type,omitempty"` 839 // ForceSendFields is a list of field names (e.g. "Cause") to unconditionally 840 // include in API requests. By default, fields with empty or default values are 841 // omitted from API requests. See 842 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 843 // details. 844 ForceSendFields []string `json:"-"` 845 // NullFields is a list of field names (e.g. "Cause") to include in API 846 // requests with the JSON null value. By default, fields with empty values are 847 // omitted from API requests. See 848 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 849 NullFields []string `json:"-"` 850 } 851 852 func (s *GooglePlayDeveloperReportingV1beta1ErrorIssue) MarshalJSON() ([]byte, error) { 853 type NoMethod GooglePlayDeveloperReportingV1beta1ErrorIssue 854 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 855 } 856 857 // GooglePlayDeveloperReportingV1beta1ErrorReport: An error report received for 858 // an app. There reports are produced by the Android platform code when a 859 // (potentially fatal) error condition is detected. Identical reports from many 860 // users will be deduplicated and coalesced into a single ErrorReport. 861 // **Required permissions**: to access this resource, the calling user needs 862 // the _View app information (read-only)_ permission for the app. 863 type GooglePlayDeveloperReportingV1beta1ErrorReport struct { 864 // AppVersion: The app version on which an event in this error report occurred 865 // on. 866 AppVersion *GooglePlayDeveloperReportingV1beta1AppVersion `json:"appVersion,omitempty"` 867 // DeviceModel: A device model on which an event in this error report occurred 868 // on. 869 DeviceModel *GooglePlayDeveloperReportingV1beta1DeviceModelSummary `json:"deviceModel,omitempty"` 870 // EventTime: Start of the hour during which the latest event in this error 871 // report occurred. 872 EventTime string `json:"eventTime,omitempty"` 873 // Issue: The issue this report was associated with. **Please note:** this 874 // resource is currently in Alpha. There could be changes to the issue grouping 875 // that would result in similar but more recent error reports being assigned to 876 // a different issue. 877 Issue string `json:"issue,omitempty"` 878 // Name: The resource name of the report. Format: apps/{app}/{report} 879 Name string `json:"name,omitempty"` 880 // OsVersion: The OS version on which an event in this error report occurred 881 // on. 882 OsVersion *GooglePlayDeveloperReportingV1beta1OsVersion `json:"osVersion,omitempty"` 883 // ReportText: Textual representation of the error report. These textual 884 // reports are produced by the platform. The reports are then sanitized and 885 // filtered to remove any potentially sensitive information. Although their 886 // format is fairly stable, they are not entirely meant for machine consumption 887 // and we cannot guarantee that there won't be subtle changes to the formatting 888 // that may break systems trying to parse information out of the reports. 889 ReportText string `json:"reportText,omitempty"` 890 // Type: Type of the error for which this report was generated. 891 // 892 // Possible values: 893 // "ERROR_TYPE_UNSPECIFIED" - Unspecified error type. 894 // "APPLICATION_NOT_RESPONDING" - Application Not Responding (ANR) error. To 895 // learn more about this type of errors visit the corresponding Android 896 // Developers documentation. 897 // "CRASH" - Crash caused by an unhandled exception in Java (or Kotlin or any 898 // other JVM language) or a signal in native code such as SIGSEGV. 899 Type string `json:"type,omitempty"` 900 // VcsInformation: Version control system information from 901 // BUNDLE-METADATA/version-control-info.textproto or 902 // META-INF/version-control-info.textproto of the app bundle or APK, 903 // respectively. 904 VcsInformation string `json:"vcsInformation,omitempty"` 905 // ForceSendFields is a list of field names (e.g. "AppVersion") to 906 // unconditionally include in API requests. By default, fields with empty or 907 // default values are omitted from API requests. See 908 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 909 // details. 910 ForceSendFields []string `json:"-"` 911 // NullFields is a list of field names (e.g. "AppVersion") to include in API 912 // requests with the JSON null value. By default, fields with empty values are 913 // omitted from API requests. See 914 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 915 NullFields []string `json:"-"` 916 } 917 918 func (s *GooglePlayDeveloperReportingV1beta1ErrorReport) MarshalJSON() ([]byte, error) { 919 type NoMethod GooglePlayDeveloperReportingV1beta1ErrorReport 920 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 921 } 922 923 // GooglePlayDeveloperReportingV1beta1ExcessiveWakeupRateMetricSet: Singleton 924 // resource representing the set of Excessive Weakeups metrics. This metric set 925 // contains AlarmManager wakeup counts data combined with process state data to 926 // produce a normalized metric independent of user counts. **Supported 927 // aggregation periods:** * DAILY: metrics are aggregated in calendar date 928 // intervals. Due to historical constraints, the only supported timezone is 929 // `America/Los_Angeles`. **Supported metrics:** * `excessiveWakeupRate` 930 // (`google.type.Decimal`): Percentage of distinct users in the aggregation 931 // period that had more than 10 wakeups per hour. * 932 // `excessiveWakeupRate7dUserWeighted` (`google.type.Decimal`): Rolling average 933 // value of `excessiveWakeupRate` in the last 7 days. The daily values are 934 // weighted by the count of distinct users for the day. * 935 // `excessiveWakeupRate28dUserWeighted` (`google.type.Decimal`): Rolling 936 // average value of `excessiveWakeupRate` in the last 28 days. The daily values 937 // are weighted by the count of distinct users for the day. * `distinctUsers` 938 // (`google.type.Decimal`): Count of distinct users in the aggregation period 939 // that were used as normalization value for the `excessiveWakeupRate` metric. 940 // A user is counted in this metric if they app was doing any work on the 941 // device, i.e., not just active foreground usage but also background work. 942 // Care must be taken not to aggregate this count further, as it may result in 943 // users being counted multiple times. The value is rounded to the nearest 944 // multiple of 10, 100, 1,000 or 1,000,000, depending on the magnitude of the 945 // value. **Supported dimensions:** * `apiLevel` (string): the API level of 946 // Android that was running on the user's device, e.g., 26. * `versionCode` 947 // (int64): version of the app that was running on the user's device. * 948 // `deviceModel` (string): unique identifier of the user's device model. The 949 // form of the identifier is 'deviceBrand/device', where deviceBrand 950 // corresponds to Build.BRAND and device corresponds to Build.DEVICE, e.g., 951 // google/coral. * `deviceBrand` (string): unique identifier of the user's 952 // device brand, e.g., google. * `deviceType` (string): the type (also known as 953 // form factor) of the user's device, e.g., PHONE. * `countryCode` (string): 954 // the country or region of the user's device based on their IP address, 955 // represented as a 2-letter ISO-3166 code (e.g. US for the United States). * 956 // `deviceRamBucket` (int64): RAM of the device, in MB, in buckets (3GB, 4GB, 957 // etc.). * `deviceSocMake` (string): Make of the device's primary 958 // system-on-chip, e.g., Samsung. Reference 959 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 960 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 961 // e.g., "Exynos 2100". Reference 962 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 963 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 964 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 965 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 966 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 967 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 968 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 969 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 970 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 971 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 972 // device, e.g., mdpi, hdpi. **Required permissions**: to access this resource, 973 // the calling user needs the _View app information (read-only)_ permission for 974 // the app. 975 type GooglePlayDeveloperReportingV1beta1ExcessiveWakeupRateMetricSet struct { 976 // FreshnessInfo: Summary about data freshness in this resource. 977 FreshnessInfo *GooglePlayDeveloperReportingV1beta1FreshnessInfo `json:"freshnessInfo,omitempty"` 978 // Name: Identifier. The resource name. Format: 979 // apps/{app}/excessiveWakeupRateMetricSet 980 Name string `json:"name,omitempty"` 981 982 // ServerResponse contains the HTTP response code and headers from the server. 983 googleapi.ServerResponse `json:"-"` 984 // ForceSendFields is a list of field names (e.g. "FreshnessInfo") to 985 // unconditionally include in API requests. By default, fields with empty or 986 // default values are omitted from API requests. See 987 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 988 // details. 989 ForceSendFields []string `json:"-"` 990 // NullFields is a list of field names (e.g. "FreshnessInfo") to include in API 991 // requests with the JSON null value. By default, fields with empty values are 992 // omitted from API requests. See 993 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 994 NullFields []string `json:"-"` 995 } 996 997 func (s *GooglePlayDeveloperReportingV1beta1ExcessiveWakeupRateMetricSet) MarshalJSON() ([]byte, error) { 998 type NoMethod GooglePlayDeveloperReportingV1beta1ExcessiveWakeupRateMetricSet 999 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1000 } 1001 1002 // GooglePlayDeveloperReportingV1beta1FreshnessInfo: Represents the latest 1003 // available time that can be requested in a TimelineSpec. Different 1004 // aggregation periods have different freshness. For example, `DAILY` 1005 // aggregation may lag behind `HOURLY` in cases where such aggregation is 1006 // computed only once at the end of the day. 1007 type GooglePlayDeveloperReportingV1beta1FreshnessInfo struct { 1008 // Freshnesses: Information about data freshness for every supported 1009 // aggregation period. This field has set semantics, keyed by the 1010 // `aggregation_period` field. 1011 Freshnesses []*GooglePlayDeveloperReportingV1beta1FreshnessInfoFreshness `json:"freshnesses,omitempty"` 1012 // ForceSendFields is a list of field names (e.g. "Freshnesses") to 1013 // unconditionally include in API requests. By default, fields with empty or 1014 // default values are omitted from API requests. See 1015 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1016 // details. 1017 ForceSendFields []string `json:"-"` 1018 // NullFields is a list of field names (e.g. "Freshnesses") to include in API 1019 // requests with the JSON null value. By default, fields with empty values are 1020 // omitted from API requests. See 1021 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1022 NullFields []string `json:"-"` 1023 } 1024 1025 func (s *GooglePlayDeveloperReportingV1beta1FreshnessInfo) MarshalJSON() ([]byte, error) { 1026 type NoMethod GooglePlayDeveloperReportingV1beta1FreshnessInfo 1027 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1028 } 1029 1030 // GooglePlayDeveloperReportingV1beta1FreshnessInfoFreshness: Information about 1031 // data freshness for a single aggregation period. 1032 type GooglePlayDeveloperReportingV1beta1FreshnessInfoFreshness struct { 1033 // AggregationPeriod: Aggregation period for which data is available. 1034 // 1035 // Possible values: 1036 // "AGGREGATION_PERIOD_UNSPECIFIED" - Unspecified granularity. 1037 // "HOURLY" - Data is aggregated in hourly intervals. 1038 // "DAILY" - Data is aggregated in daily intervals. 1039 // "FULL_RANGE" - Data is aggregated over the full timeline range. 1040 // Effectively this produces a single value rather than a timeline. 1041 AggregationPeriod string `json:"aggregationPeriod,omitempty"` 1042 // LatestEndTime: Latest end time for which data is available, for the 1043 // aggregation period. The time is specified in the metric set's default 1044 // timezone. *Note:* time ranges in TimelineSpec are represented as 1045 // `start_time, end_time)`. For example, if the latest available timeline data 1046 // point for a `DAILY` aggregation period is `2021-06-23 00:00:00 1047 // America/Los_Angeles`, the value of this field would be `2021-06-24 00:00:00 1048 // America/Los_Angeles` so it can be easily reused in [TimelineSpec.end_time. 1049 LatestEndTime *GoogleTypeDateTime `json:"latestEndTime,omitempty"` 1050 // ForceSendFields is a list of field names (e.g. "AggregationPeriod") to 1051 // unconditionally include in API requests. By default, fields with empty or 1052 // default values are omitted from API requests. See 1053 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1054 // details. 1055 ForceSendFields []string `json:"-"` 1056 // NullFields is a list of field names (e.g. "AggregationPeriod") to include in 1057 // API requests with the JSON null value. By default, fields with empty values 1058 // are omitted from API requests. See 1059 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1060 NullFields []string `json:"-"` 1061 } 1062 1063 func (s *GooglePlayDeveloperReportingV1beta1FreshnessInfoFreshness) MarshalJSON() ([]byte, error) { 1064 type NoMethod GooglePlayDeveloperReportingV1beta1FreshnessInfoFreshness 1065 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1066 } 1067 1068 // GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse: Response with a 1069 // list of anomalies in datasets. 1070 type GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse struct { 1071 // Anomalies: Anomalies that were found. 1072 Anomalies []*GooglePlayDeveloperReportingV1beta1Anomaly `json:"anomalies,omitempty"` 1073 // NextPageToken: Continuation token to fetch the next page of data. 1074 NextPageToken string `json:"nextPageToken,omitempty"` 1075 1076 // ServerResponse contains the HTTP response code and headers from the server. 1077 googleapi.ServerResponse `json:"-"` 1078 // ForceSendFields is a list of field names (e.g. "Anomalies") to 1079 // unconditionally include in API requests. By default, fields with empty or 1080 // default values are omitted from API requests. See 1081 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1082 // details. 1083 ForceSendFields []string `json:"-"` 1084 // NullFields is a list of field names (e.g. "Anomalies") to include in API 1085 // requests with the JSON null value. By default, fields with empty values are 1086 // omitted from API requests. See 1087 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1088 NullFields []string `json:"-"` 1089 } 1090 1091 func (s *GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse) MarshalJSON() ([]byte, error) { 1092 type NoMethod GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse 1093 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1094 } 1095 1096 // GooglePlayDeveloperReportingV1beta1MetricValue: Represents the value of a 1097 // metric. 1098 type GooglePlayDeveloperReportingV1beta1MetricValue struct { 1099 // DecimalValue: Actual value, represented as a decimal number. 1100 DecimalValue *GoogleTypeDecimal `json:"decimalValue,omitempty"` 1101 // DecimalValueConfidenceInterval: Confidence interval of a value that is of 1102 // type `type.Decimal`. 1103 DecimalValueConfidenceInterval *GooglePlayDeveloperReportingV1beta1DecimalConfidenceInterval `json:"decimalValueConfidenceInterval,omitempty"` 1104 // Metric: Name of the metric. 1105 Metric string `json:"metric,omitempty"` 1106 // ForceSendFields is a list of field names (e.g. "DecimalValue") to 1107 // unconditionally include in API requests. By default, fields with empty or 1108 // default values are omitted from API requests. See 1109 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1110 // details. 1111 ForceSendFields []string `json:"-"` 1112 // NullFields is a list of field names (e.g. "DecimalValue") to include in API 1113 // requests with the JSON null value. By default, fields with empty values are 1114 // omitted from API requests. See 1115 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1116 NullFields []string `json:"-"` 1117 } 1118 1119 func (s *GooglePlayDeveloperReportingV1beta1MetricValue) MarshalJSON() ([]byte, error) { 1120 type NoMethod GooglePlayDeveloperReportingV1beta1MetricValue 1121 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1122 } 1123 1124 // GooglePlayDeveloperReportingV1beta1MetricsRow: Represents a row of 1125 // dimensions and metrics. 1126 type GooglePlayDeveloperReportingV1beta1MetricsRow struct { 1127 // AggregationPeriod: Granularity of the aggregation period of the row. 1128 // 1129 // Possible values: 1130 // "AGGREGATION_PERIOD_UNSPECIFIED" - Unspecified granularity. 1131 // "HOURLY" - Data is aggregated in hourly intervals. 1132 // "DAILY" - Data is aggregated in daily intervals. 1133 // "FULL_RANGE" - Data is aggregated over the full timeline range. 1134 // Effectively this produces a single value rather than a timeline. 1135 AggregationPeriod string `json:"aggregationPeriod,omitempty"` 1136 // Dimensions: Dimension columns in the row. 1137 Dimensions []*GooglePlayDeveloperReportingV1beta1DimensionValue `json:"dimensions,omitempty"` 1138 // Metrics: Metric columns in the row. 1139 Metrics []*GooglePlayDeveloperReportingV1beta1MetricValue `json:"metrics,omitempty"` 1140 // StartTime: Starting date (and time for hourly aggregation) of the period 1141 // covered by this row. 1142 StartTime *GoogleTypeDateTime `json:"startTime,omitempty"` 1143 // ForceSendFields is a list of field names (e.g. "AggregationPeriod") to 1144 // unconditionally include in API requests. By default, fields with empty or 1145 // default values are omitted from API requests. See 1146 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1147 // details. 1148 ForceSendFields []string `json:"-"` 1149 // NullFields is a list of field names (e.g. "AggregationPeriod") to include in 1150 // API requests with the JSON null value. By default, fields with empty values 1151 // are omitted from API requests. See 1152 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1153 NullFields []string `json:"-"` 1154 } 1155 1156 func (s *GooglePlayDeveloperReportingV1beta1MetricsRow) MarshalJSON() ([]byte, error) { 1157 type NoMethod GooglePlayDeveloperReportingV1beta1MetricsRow 1158 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1159 } 1160 1161 // GooglePlayDeveloperReportingV1beta1OsVersion: Representation of an OS 1162 // version. 1163 type GooglePlayDeveloperReportingV1beta1OsVersion struct { 1164 // ApiLevel: Numeric version code of the OS - API level 1165 ApiLevel int64 `json:"apiLevel,omitempty,string"` 1166 // ForceSendFields is a list of field names (e.g. "ApiLevel") to 1167 // unconditionally include in API requests. By default, fields with empty or 1168 // default values are omitted from API requests. See 1169 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1170 // details. 1171 ForceSendFields []string `json:"-"` 1172 // NullFields is a list of field names (e.g. "ApiLevel") to include in API 1173 // requests with the JSON null value. By default, fields with empty values are 1174 // omitted from API requests. See 1175 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1176 NullFields []string `json:"-"` 1177 } 1178 1179 func (s *GooglePlayDeveloperReportingV1beta1OsVersion) MarshalJSON() ([]byte, error) { 1180 type NoMethod GooglePlayDeveloperReportingV1beta1OsVersion 1181 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1182 } 1183 1184 // GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetRequest: Request 1185 // message for QueryAnrRateMetricSet. 1186 type GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetRequest struct { 1187 // Dimensions: Dimensions to slice the metrics by. **Supported dimensions:** * 1188 // `apiLevel` (string): the API level of Android that was running on the user's 1189 // device, e.g., 26. * `versionCode` (int64): version of the app that was 1190 // running on the user's device. * `deviceModel` (string): unique identifier of 1191 // the user's device model. The form of the identifier is 'deviceBrand/device', 1192 // where deviceBrand corresponds to Build.BRAND and device corresponds to 1193 // Build.DEVICE, e.g., google/coral. * `deviceBrand` (string): unique 1194 // identifier of the user's device brand, e.g., google. * `deviceType` 1195 // (string): the type (also known as form factor) of the user's device, e.g., 1196 // PHONE. * `countryCode` (string): the country or region of the user's device 1197 // based on their IP address, represented as a 2-letter ISO-3166 code (e.g. US 1198 // for the United States). * `deviceRamBucket` (int64): RAM of the device, in 1199 // MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): Make of the 1200 // device's primary system-on-chip, e.g., Samsung. Reference 1201 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 1202 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 1203 // e.g., "Exynos 2100". Reference 1204 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 1205 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 1206 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 1207 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 1208 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 1209 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 1210 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 1211 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 1212 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 1213 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 1214 // device, e.g., mdpi, hdpi. 1215 Dimensions []string `json:"dimensions,omitempty"` 1216 // Filter: Filters to apply to data. The filtering expression follows AIP-160 1217 // (https://google.aip.dev/160) standard and supports filtering by equality of 1218 // all breakdown dimensions. 1219 Filter string `json:"filter,omitempty"` 1220 // Metrics: Metrics to aggregate. **Supported metrics:** * `anrRate` 1221 // (`google.type.Decimal`): Percentage of distinct users in the aggregation 1222 // period that experienced at least one ANR. * `anrRate7dUserWeighted` 1223 // (`google.type.Decimal`): Rolling average value of `anrRate` in the last 7 1224 // days. The daily values are weighted by the count of distinct users for the 1225 // day. Not supported in HOURLY granularity. * `anrRate28dUserWeighted` 1226 // (`google.type.Decimal`): Rolling average value of `anrRate` in the last 28 1227 // days. The daily values are weighted by the count of distinct users for the 1228 // day. Not supported in HOURLY granularity. * `userPerceivedAnrRate` 1229 // (`google.type.Decimal`): Percentage of distinct users in the aggregation 1230 // period that experienced at least one user-perceived ANR. User-perceived ANRs 1231 // are currently those of 'Input dispatching' type. * 1232 // `userPerceivedAnrRate7dUserWeighted` (`google.type.Decimal`): Rolling 1233 // average value of `userPerceivedAnrRate` in the last 7 days. The daily values 1234 // are weighted by the count of distinct users for the day. Not supported in 1235 // HOURLY granularity. * `userPerceivedAnrRate28dUserWeighted` 1236 // (`google.type.Decimal`): Rolling average value of `userPerceivedAnrRate` in 1237 // the last 28 days. The daily values are weighted by the count of distinct 1238 // users for the day. Not . supported in HOURLY granularity. * `distinctUsers` 1239 // (`google.type.Decimal`): Count of distinct users in the aggregation period 1240 // that were used as normalization value for the `anrRate` and 1241 // `userPerceivedAnrRate` metrics. A user is counted in this metric if they 1242 // used the app in the foreground during the aggregation period. Care must be 1243 // taken not to aggregate this count further, as it may result in users being 1244 // counted multiple times. The value is rounded to the nearest multiple of 10, 1245 // 100, 1,000 or 1,000,000, depending on the magnitude of the value. 1246 Metrics []string `json:"metrics,omitempty"` 1247 // PageSize: Maximum size of the returned data. If unspecified, at most 1000 1248 // rows will be returned. The maximum value is 100,000; values above 100,000 1249 // will be coerced to 100,000. 1250 PageSize int64 `json:"pageSize,omitempty"` 1251 // PageToken: A page token, received from a previous call. Provide this to 1252 // retrieve the subsequent page. When paginating, all other parameters provided 1253 // to the request must match the call that provided the page token. 1254 PageToken string `json:"pageToken,omitempty"` 1255 // TimelineSpec: Specification of the timeline aggregation parameters. 1256 // **Supported aggregation periods:** * DAILY: metrics are aggregated in 1257 // calendar date intervals. Due to historical constraints, the default and only 1258 // supported timezone is `America/Los_Angeles`. * HOURLY: metrics are 1259 // aggregated in hourly intervals. The default and only supported timezone is 1260 // `UTC`. 1261 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 1262 // UserCohort: User view to select. The output data will correspond to the 1263 // selected view. **Supported values:** * `OS_PUBLIC` To select data from all 1264 // publicly released Android versions. This is the default. Supports all the 1265 // above dimensions. * `APP_TESTERS` To select data from users who have opted 1266 // in to be testers. Supports all the above dimensions. * `OS_BETA` To select 1267 // data from beta android versions only, excluding data from released android 1268 // versions. Only the following dimensions are supported: * `versionCode` 1269 // (int64): version of the app that was running on the user's device. * 1270 // `osBuild` (string): OS build of the user's device, e.g., "T1B2.220916.004". 1271 // 1272 // Possible values: 1273 // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will 1274 // automatically choose the default value. 1275 // "OS_PUBLIC" - This is default view. Contains data from public released 1276 // android versions only. 1277 // "OS_BETA" - This is the view with just android beta data excluding 1278 // released OS version data. 1279 // "APP_TESTERS" - This is the view with data only from users who have opted 1280 // in to be testers for a given app, excluding OS beta data. 1281 UserCohort string `json:"userCohort,omitempty"` 1282 // ForceSendFields is a list of field names (e.g. "Dimensions") to 1283 // unconditionally include in API requests. By default, fields with empty or 1284 // default values are omitted from API requests. See 1285 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1286 // details. 1287 ForceSendFields []string `json:"-"` 1288 // NullFields is a list of field names (e.g. "Dimensions") to include in API 1289 // requests with the JSON null value. By default, fields with empty values are 1290 // omitted from API requests. See 1291 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1292 NullFields []string `json:"-"` 1293 } 1294 1295 func (s *GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetRequest) MarshalJSON() ([]byte, error) { 1296 type NoMethod GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetRequest 1297 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1298 } 1299 1300 // GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse: Response 1301 // message for QueryAnrRateMetricSet. 1302 type GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse struct { 1303 // NextPageToken: Continuation token to fetch the next page of data. 1304 NextPageToken string `json:"nextPageToken,omitempty"` 1305 // Rows: Returned rows of data. 1306 Rows []*GooglePlayDeveloperReportingV1beta1MetricsRow `json:"rows,omitempty"` 1307 1308 // ServerResponse contains the HTTP response code and headers from the server. 1309 googleapi.ServerResponse `json:"-"` 1310 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 1311 // unconditionally include in API requests. By default, fields with empty or 1312 // default values are omitted from API requests. See 1313 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1314 // details. 1315 ForceSendFields []string `json:"-"` 1316 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 1317 // requests with the JSON null value. By default, fields with empty values are 1318 // omitted from API requests. See 1319 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1320 NullFields []string `json:"-"` 1321 } 1322 1323 func (s *GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse) MarshalJSON() ([]byte, error) { 1324 type NoMethod GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse 1325 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1326 } 1327 1328 // GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetRequest: Request 1329 // message for QueryCrashRateMetricSet. 1330 type GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetRequest struct { 1331 // Dimensions: Dimensions to slice the metrics by. **Supported dimensions:** * 1332 // `apiLevel` (string): the API level of Android that was running on the user's 1333 // device, e.g., 26. * `versionCode` (int64): version of the app that was 1334 // running on the user's device. * `deviceModel` (string): unique identifier of 1335 // the user's device model. The form of the identifier is 'deviceBrand/device', 1336 // where deviceBrand corresponds to Build.BRAND and device corresponds to 1337 // Build.DEVICE, e.g., google/coral. * `deviceBrand` (string): unique 1338 // identifier of the user's device brand, e.g., google. * `deviceType` 1339 // (string): the type (also known as form factor) of the user's device, e.g., 1340 // PHONE. * `countryCode` (string): the country or region of the user's device 1341 // based on their IP address, represented as a 2-letter ISO-3166 code (e.g. US 1342 // for the United States). * `deviceRamBucket` (int64): RAM of the device, in 1343 // MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): Make of the 1344 // device's primary system-on-chip, e.g., Samsung. Reference 1345 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 1346 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 1347 // e.g., "Exynos 2100". Reference 1348 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 1349 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 1350 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 1351 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 1352 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 1353 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 1354 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 1355 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 1356 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 1357 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 1358 // device, e.g., mdpi, hdpi. 1359 Dimensions []string `json:"dimensions,omitempty"` 1360 // Filter: Filters to apply to data. The filtering expression follows AIP-160 1361 // (https://google.aip.dev/160) standard and supports filtering by equality of 1362 // all breakdown dimensions. 1363 Filter string `json:"filter,omitempty"` 1364 // Metrics: Metrics to aggregate. **Supported metrics:** * `crashRate` 1365 // (`google.type.Decimal`): Percentage of distinct users in the aggregation 1366 // period that experienced at least one crash. * `crashRate7dUserWeighted` 1367 // (`google.type.Decimal`): Rolling average value of `crashRate` in the last 7 1368 // days. The daily values are weighted by the count of distinct users for the 1369 // day. * `crashRate28dUserWeighted` (`google.type.Decimal`): Rolling average 1370 // value of `crashRate` in the last 28 days. The daily values are weighted by 1371 // the count of distinct users for the day. Not supported in HOURLY 1372 // granularity. * `userPerceivedCrashRate` (`google.type.Decimal`): Percentage 1373 // of distinct users in the aggregation period that experienced at least one 1374 // crash while they were actively using your app (a user-perceived crash). An 1375 // app is considered to be in active use if it is displaying any activity or 1376 // executing any foreground service. * `userPerceivedCrashRate7dUserWeighted` 1377 // (`google.type.Decimal`): Rolling average value of `userPerceivedCrashRate` 1378 // in the last 7 days. The daily values are weighted by the count of distinct 1379 // users for the day. Not supported in HOURLY granularity. * 1380 // `userPerceivedCrashRate28dUserWeighted` (`google.type.Decimal`): Rolling 1381 // average value of `userPerceivedCrashRate` in the last 28 days. The daily 1382 // values are weighted by the count of distinct users for the day. Not 1383 // supported in HOURLY granularity. * `distinctUsers` (`google.type.Decimal`): 1384 // Count of distinct users in the aggregation period that were used as 1385 // normalization value for the `crashRate` and `userPerceivedCrashRate` 1386 // metrics. A user is counted in this metric if they used the app actively 1387 // during the aggregation period. An app is considered to be in active use if 1388 // it is displaying any activity or executing any foreground service. Care must 1389 // be taken not to aggregate this count further, as it may result in users 1390 // being counted multiple times. The value is rounded to the nearest multiple 1391 // of 10, 100, 1,000 or 1,000,000, depending on the magnitude of the value. 1392 Metrics []string `json:"metrics,omitempty"` 1393 // PageSize: Maximum size of the returned data. If unspecified, at most 1000 1394 // rows will be returned. The maximum value is 100,000; values above 100,000 1395 // will be coerced to 100,000. 1396 PageSize int64 `json:"pageSize,omitempty"` 1397 // PageToken: A page token, received from a previous call. Provide this to 1398 // retrieve the subsequent page. When paginating, all other parameters provided 1399 // to the request must match the call that provided the page token. 1400 PageToken string `json:"pageToken,omitempty"` 1401 // TimelineSpec: Specification of the timeline aggregation parameters. 1402 // **Supported aggregation periods:** * DAILY: metrics are aggregated in 1403 // calendar date intervals. Due to historical constraints, the default and only 1404 // supported timezone is `America/Los_Angeles`. * HOURLY: metrics are 1405 // aggregated in hourly intervals. The default and only supported timezone is 1406 // `UTC`. 1407 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 1408 // UserCohort: User view to select. The output data will correspond to the 1409 // selected view. **Supported values:** * `OS_PUBLIC` To select data from all 1410 // publicly released Android versions. This is the default. Supports all the 1411 // above dimensions. * `APP_TESTERS` To select data from users who have opted 1412 // in to be testers. Supports all the above dimensions. * `OS_BETA` To select 1413 // data from beta android versions only, excluding data from released android 1414 // versions. Only the following dimensions are supported: * `versionCode` 1415 // (int64): version of the app that was running on the user's device. * 1416 // `osBuild` (string): OS build of the user's device, e.g., "T1B2.220916.004". 1417 // 1418 // Possible values: 1419 // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will 1420 // automatically choose the default value. 1421 // "OS_PUBLIC" - This is default view. Contains data from public released 1422 // android versions only. 1423 // "OS_BETA" - This is the view with just android beta data excluding 1424 // released OS version data. 1425 // "APP_TESTERS" - This is the view with data only from users who have opted 1426 // in to be testers for a given app, excluding OS beta data. 1427 UserCohort string `json:"userCohort,omitempty"` 1428 // ForceSendFields is a list of field names (e.g. "Dimensions") to 1429 // unconditionally include in API requests. By default, fields with empty or 1430 // default values are omitted from API requests. See 1431 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1432 // details. 1433 ForceSendFields []string `json:"-"` 1434 // NullFields is a list of field names (e.g. "Dimensions") to include in API 1435 // requests with the JSON null value. By default, fields with empty values are 1436 // omitted from API requests. See 1437 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1438 NullFields []string `json:"-"` 1439 } 1440 1441 func (s *GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetRequest) MarshalJSON() ([]byte, error) { 1442 type NoMethod GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetRequest 1443 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1444 } 1445 1446 // GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse: Response 1447 // message for QueryCrashRateMetricSet. 1448 type GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse struct { 1449 // NextPageToken: Continuation token to fetch the next page of data. 1450 NextPageToken string `json:"nextPageToken,omitempty"` 1451 // Rows: Returned rows of data. 1452 Rows []*GooglePlayDeveloperReportingV1beta1MetricsRow `json:"rows,omitempty"` 1453 1454 // ServerResponse contains the HTTP response code and headers from the server. 1455 googleapi.ServerResponse `json:"-"` 1456 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 1457 // unconditionally include in API requests. By default, fields with empty or 1458 // default values are omitted from API requests. See 1459 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1460 // details. 1461 ForceSendFields []string `json:"-"` 1462 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 1463 // requests with the JSON null value. By default, fields with empty values are 1464 // omitted from API requests. See 1465 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1466 NullFields []string `json:"-"` 1467 } 1468 1469 func (s *GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse) MarshalJSON() ([]byte, error) { 1470 type NoMethod GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse 1471 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1472 } 1473 1474 // GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetRequest: Request 1475 // message for QueryErrorCountMetricSet. 1476 type GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetRequest struct { 1477 // Dimensions: Dimensions to slice the data by. **Supported dimensions:** * 1478 // `apiLevel` (string): the API level of Android that was running on the user's 1479 // device, e.g., 26. * `versionCode` (int64): unique identifier of the user's 1480 // device model. The form of the identifier is 'deviceBrand/device', where 1481 // deviceBrand corresponds to Build.BRAND and device corresponds to 1482 // Build.DEVICE, e.g., google/coral. * `deviceModel` (string): unique 1483 // identifier of the user's device model. * `deviceType` (string): identifier 1484 // of the device's form factor, e.g., PHONE. * `reportType` (string): the type 1485 // of error. The value should correspond to one of the possible values in 1486 // ErrorType. * `isUserPerceived` (string): denotes whether error is user 1487 // perceived or not, USER_PERCEIVED or NOT_USER_PERCEIVED. * `issueId` 1488 // (string): the id an error was assigned to. The value should correspond to 1489 // the `{issue}` component of the issue name. * `deviceRamBucket` (int64): RAM 1490 // of the device, in MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` 1491 // (string): Make of the device's primary system-on-chip, e.g., Samsung. 1492 // Reference 1493 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 1494 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 1495 // e.g., "Exynos 2100". Reference 1496 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 1497 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 1498 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 1499 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 1500 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 1501 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 1502 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 1503 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 1504 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 1505 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 1506 // device, e.g., mdpi, hdpi. 1507 Dimensions []string `json:"dimensions,omitempty"` 1508 // Filter: Filters to apply to data. The filtering expression follows AIP-160 1509 // (https://google.aip.dev/160) standard and supports filtering by equality of 1510 // all breakdown dimensions. 1511 Filter string `json:"filter,omitempty"` 1512 // Metrics: Metrics to aggregate. **Supported metrics:** * `errorReportCount` 1513 // (`google.type.Decimal`): Absolute count of individual error reports that 1514 // have been received for an app. * `distinctUsers` (`google.type.Decimal`): 1515 // Count of distinct users for which reports have been received. Care must be 1516 // taken not to aggregate this count further, as it may result in users being 1517 // counted multiple times. This value is not rounded, however it may be an 1518 // approximation. 1519 Metrics []string `json:"metrics,omitempty"` 1520 // PageSize: Maximum size of the returned data. If unspecified, at most 1000 1521 // rows will be returned. The maximum value is 100000; values above 100000 will 1522 // be coerced to 100000. 1523 PageSize int64 `json:"pageSize,omitempty"` 1524 // PageToken: A page token, received from a previous call. Provide this to 1525 // retrieve the subsequent page. When paginating, all other parameters provided 1526 // to the request must match the call that provided the page token. 1527 PageToken string `json:"pageToken,omitempty"` 1528 // TimelineSpec: Specification of the timeline aggregation parameters. 1529 // **Supported aggregation periods:** * DAILY: metrics are aggregated in 1530 // calendar date intervals. The default and only supported timezone is 1531 // `America/Los_Angeles`. 1532 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 1533 // ForceSendFields is a list of field names (e.g. "Dimensions") to 1534 // unconditionally include in API requests. By default, fields with empty or 1535 // default values are omitted from API requests. See 1536 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1537 // details. 1538 ForceSendFields []string `json:"-"` 1539 // NullFields is a list of field names (e.g. "Dimensions") to include in API 1540 // requests with the JSON null value. By default, fields with empty values are 1541 // omitted from API requests. See 1542 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1543 NullFields []string `json:"-"` 1544 } 1545 1546 func (s *GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetRequest) MarshalJSON() ([]byte, error) { 1547 type NoMethod GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetRequest 1548 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1549 } 1550 1551 // GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse: Error 1552 // counts query response. 1553 type GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse struct { 1554 // NextPageToken: Continuation token to fetch the next page of data. 1555 NextPageToken string `json:"nextPageToken,omitempty"` 1556 // Rows: Returned rows. 1557 Rows []*GooglePlayDeveloperReportingV1beta1MetricsRow `json:"rows,omitempty"` 1558 1559 // ServerResponse contains the HTTP response code and headers from the server. 1560 googleapi.ServerResponse `json:"-"` 1561 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 1562 // unconditionally include in API requests. By default, fields with empty or 1563 // default values are omitted from API requests. See 1564 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1565 // details. 1566 ForceSendFields []string `json:"-"` 1567 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 1568 // requests with the JSON null value. By default, fields with empty values are 1569 // omitted from API requests. See 1570 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1571 NullFields []string `json:"-"` 1572 } 1573 1574 func (s *GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse) MarshalJSON() ([]byte, error) { 1575 type NoMethod GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse 1576 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1577 } 1578 1579 // GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetRequest: 1580 // Request message for QueryExcessiveWakeupRateMetricSet. 1581 type GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetRequest struct { 1582 // Dimensions: Dimensions to slice the data by. **Supported dimensions:** * 1583 // `apiLevel` (string): the API level of Android that was running on the user's 1584 // device, e.g., 26. * `versionCode` (int64): version of the app that was 1585 // running on the user's device. * `deviceModel` (string): unique identifier of 1586 // the user's device model. The form of the identifier is 'deviceBrand/device', 1587 // where deviceBrand corresponds to Build.BRAND and device corresponds to 1588 // Build.DEVICE, e.g., google/coral. * `deviceBrand` (string): unique 1589 // identifier of the user's device brand, e.g., google. * `deviceType` 1590 // (string): the type (also known as form factor) of the user's device, e.g., 1591 // PHONE. * `countryCode` (string): the country or region of the user's device 1592 // based on their IP address, represented as a 2-letter ISO-3166 code (e.g. US 1593 // for the United States). * `deviceRamBucket` (int64): RAM of the device, in 1594 // MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): Make of the 1595 // device's primary system-on-chip, e.g., Samsung. Reference 1596 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 1597 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 1598 // e.g., "Exynos 2100". Reference 1599 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 1600 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 1601 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 1602 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 1603 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 1604 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 1605 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 1606 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 1607 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 1608 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 1609 // device, e.g., mdpi, hdpi. 1610 Dimensions []string `json:"dimensions,omitempty"` 1611 // Filter: Filters to apply to data. The filtering expression follows AIP-160 1612 // (https://google.aip.dev/160) standard and supports filtering by equality of 1613 // all breakdown dimensions. 1614 Filter string `json:"filter,omitempty"` 1615 // Metrics: Metrics to aggregate. **Supported metrics:** * 1616 // `excessiveWakeupRate` (`google.type.Decimal`): Percentage of distinct users 1617 // in the aggregation period that had more than 10 wakeups per hour. * 1618 // `excessiveWakeupRate7dUserWeighted` (`google.type.Decimal`): Rolling average 1619 // value of `excessiveWakeupRate` in the last 7 days. The daily values are 1620 // weighted by the count of distinct users for the day. * 1621 // `excessiveWakeupRate28dUserWeighted` (`google.type.Decimal`): Rolling 1622 // average value of `excessiveWakeupRate` in the last 28 days. The daily values 1623 // are weighted by the count of distinct users for the day. * `distinctUsers` 1624 // (`google.type.Decimal`): Count of distinct users in the aggregation period 1625 // that were used as normalization value for the `excessiveWakeupRate` metric. 1626 // A user is counted in this metric if they app was doing any work on the 1627 // device, i.e., not just active foreground usage but also background work. 1628 // Care must be taken not to aggregate this count further, as it may result in 1629 // users being counted multiple times. The value is rounded to the nearest 1630 // multiple of 10, 100, 1,000 or 1,000,000, depending on the magnitude of the 1631 // value. 1632 Metrics []string `json:"metrics,omitempty"` 1633 // PageSize: Maximum size of the returned data. If unspecified, at most 1000 1634 // rows will be returned. The maximum value is 100000; values above 100000 will 1635 // be coerced to 100000. 1636 PageSize int64 `json:"pageSize,omitempty"` 1637 // PageToken: A page token, received from a previous call. Provide this to 1638 // retrieve the subsequent page. When paginating, all other parameters provided 1639 // to the request must match the call that provided the page token. 1640 PageToken string `json:"pageToken,omitempty"` 1641 // TimelineSpec: Specification of the timeline aggregation parameters. 1642 // **Supported aggregation periods:** * DAILY: metrics are aggregated in 1643 // calendar date intervals. Due to historical constraints, the only supported 1644 // timezone is `America/Los_Angeles`. 1645 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 1646 // UserCohort: User view to select. The output data will correspond to the 1647 // selected view. **Supported values:** * `OS_PUBLIC` To select data from all 1648 // publicly released Android versions. This is the default. Supports all the 1649 // above dimensions. * `APP_TESTERS` To select data from users who have opted 1650 // in to be testers. Supports all the above dimensions. * `OS_BETA` To select 1651 // data from beta android versions only, excluding data from released android 1652 // versions. Only the following dimensions are supported: * `versionCode` 1653 // (int64): version of the app that was running on the user's device. * 1654 // `osBuild` (string): OS build of the user's device, e.g., "T1B2.220916.004". 1655 // 1656 // Possible values: 1657 // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will 1658 // automatically choose the default value. 1659 // "OS_PUBLIC" - This is default view. Contains data from public released 1660 // android versions only. 1661 // "OS_BETA" - This is the view with just android beta data excluding 1662 // released OS version data. 1663 // "APP_TESTERS" - This is the view with data only from users who have opted 1664 // in to be testers for a given app, excluding OS beta data. 1665 UserCohort string `json:"userCohort,omitempty"` 1666 // ForceSendFields is a list of field names (e.g. "Dimensions") to 1667 // unconditionally include in API requests. By default, fields with empty or 1668 // default values are omitted from API requests. See 1669 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1670 // details. 1671 ForceSendFields []string `json:"-"` 1672 // NullFields is a list of field names (e.g. "Dimensions") to include in API 1673 // requests with the JSON null value. By default, fields with empty values are 1674 // omitted from API requests. See 1675 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1676 NullFields []string `json:"-"` 1677 } 1678 1679 func (s *GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetRequest) MarshalJSON() ([]byte, error) { 1680 type NoMethod GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetRequest 1681 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1682 } 1683 1684 // GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse: 1685 // 1686 // Response message for QueryExcessiveWakeupRateMetricSet. 1687 type GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse struct { 1688 // NextPageToken: Continuation token to fetch the next page of data. 1689 NextPageToken string `json:"nextPageToken,omitempty"` 1690 // Rows: Returned rows of data. 1691 Rows []*GooglePlayDeveloperReportingV1beta1MetricsRow `json:"rows,omitempty"` 1692 1693 // ServerResponse contains the HTTP response code and headers from the server. 1694 googleapi.ServerResponse `json:"-"` 1695 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 1696 // unconditionally include in API requests. By default, fields with empty or 1697 // default values are omitted from API requests. See 1698 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1699 // details. 1700 ForceSendFields []string `json:"-"` 1701 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 1702 // requests with the JSON null value. By default, fields with empty values are 1703 // omitted from API requests. See 1704 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1705 NullFields []string `json:"-"` 1706 } 1707 1708 func (s *GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse) MarshalJSON() ([]byte, error) { 1709 type NoMethod GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse 1710 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1711 } 1712 1713 // GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetRequest: 1714 // Request message for QuerySlowRenderingRateMetricSet. 1715 type GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetRequest struct { 1716 // Dimensions: Dimensions to slice the data by. **Supported dimensions:** * 1717 // `apiLevel` (string): the API level of Android that was running on the user's 1718 // device, e.g., 26. * `versionCode` (int64): version of the app that was 1719 // running on the user's device. * `deviceModel` (string): unique identifier of 1720 // the user's device model. The form of the identifier is 'deviceBrand/device', 1721 // where deviceBrand corresponds to Build.BRAND and device corresponds to 1722 // Build.DEVICE, e.g., google/coral. * `deviceBrand` (string): unique 1723 // identifier of the user's device brand, e.g., google. * `deviceType` 1724 // (string): the type (also known as form factor) of the user's device, e.g., 1725 // PHONE. * `countryCode` (string): the country or region of the user's device 1726 // based on their IP address, represented as a 2-letter ISO-3166 code (e.g. US 1727 // for the United States). * `deviceRamBucket` (int64): RAM of the device, in 1728 // MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): Make of the 1729 // device's primary system-on-chip, e.g., Samsung. Reference 1730 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 1731 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 1732 // e.g., "Exynos 2100". Reference 1733 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 1734 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 1735 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 1736 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 1737 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 1738 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 1739 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 1740 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 1741 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 1742 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 1743 // device, e.g., mdpi, hdpi. 1744 Dimensions []string `json:"dimensions,omitempty"` 1745 // Filter: Filters to apply to data. The filtering expression follows AIP-160 1746 // (https://google.aip.dev/160) standard and supports filtering by equality of 1747 // all breakdown dimensions. 1748 Filter string `json:"filter,omitempty"` 1749 // Metrics: Metrics to aggregate. **Supported metrics:** * 1750 // `slowRenderingRate20Fps` (`google.type.Decimal`): Percentage of distinct 1751 // users in the aggregation period that had a slow rendering. * 1752 // `slowRenderingRate20Fps7dUserWeighted` (`google.type.Decimal`): Rolling 1753 // average value of `slowRenderingRate20Fps` in the last 7 days. The daily 1754 // values are weighted by the count of distinct users for the day. * 1755 // `slowRenderingRate20Fps28dUserWeighted` (`google.type.Decimal`): Rolling 1756 // average value of `slowRenderingRate20Fps` in the last 28 days. The daily 1757 // values are weighted by the count of distinct users for the day. * 1758 // `slowRenderingRate30Fps` (`google.type.Decimal`): Percentage of distinct 1759 // users in the aggregation period that had a slow rendering. * 1760 // `slowRenderingRate30Fps7dUserWeighted` (`google.type.Decimal`): Rolling 1761 // average value of `slowRenderingRate30Fps` in the last 7 days. The daily 1762 // values are weighted by the count of distinct users for the day. * 1763 // `slowRenderingRate30Fps28dUserWeighted` (`google.type.Decimal`): Rolling 1764 // average value of `slowRenderingRate30Fps` in the last 28 days. The daily 1765 // values are weighted by the count of distinct users for the day. * 1766 // `distinctUsers` (`google.type.Decimal`): Count of distinct users in the 1767 // aggregation period that were used as normalization value for the 1768 // `slowRenderingRate20Fps`/`slowRenderingRate30Fps` metric. A user is counted 1769 // in this metric if their app was launched in the device. Care must be taken 1770 // not to aggregate this count further, as it may result in users being counted 1771 // multiple times. The value is rounded to the nearest multiple of 10, 100, 1772 // 1,000 or 1,000,000, depending on the magnitude of the value. 1773 Metrics []string `json:"metrics,omitempty"` 1774 // PageSize: Maximum size of the returned data. If unspecified, at most 1000 1775 // rows will be returned. The maximum value is 100000; values above 100000 will 1776 // be coerced to 100000. 1777 PageSize int64 `json:"pageSize,omitempty"` 1778 // PageToken: A page token, received from a previous call. Provide this to 1779 // retrieve the subsequent page. When paginating, all other parameters provided 1780 // to the request must match the call that provided the page token. 1781 PageToken string `json:"pageToken,omitempty"` 1782 // TimelineSpec: Specification of the timeline aggregation parameters. 1783 // **Supported aggregation periods:** * DAILY: metrics are aggregated in 1784 // calendar date intervals. Due to historical constraints, the only supported 1785 // timezone is `America/Los_Angeles`. 1786 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 1787 // UserCohort: User view to select. The output data will correspond to the 1788 // selected view. **Supported values:** * `OS_PUBLIC` To select data from all 1789 // publicly released Android versions. This is the default. Supports all the 1790 // above dimensions. * `APP_TESTERS` To select data from users who have opted 1791 // in to be testers. Supports all the above dimensions. * `OS_BETA` To select 1792 // data from beta Android versions only, excluding data from released Android 1793 // versions. Only the following dimensions are supported: * `versionCode` 1794 // (int64): version of the app that was running on the user's device. * 1795 // `osBuild` (string): OS build of the user's device, e.g., "T1B2.220916.004". 1796 // 1797 // Possible values: 1798 // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will 1799 // automatically choose the default value. 1800 // "OS_PUBLIC" - This is default view. Contains data from public released 1801 // android versions only. 1802 // "OS_BETA" - This is the view with just android beta data excluding 1803 // released OS version data. 1804 // "APP_TESTERS" - This is the view with data only from users who have opted 1805 // in to be testers for a given app, excluding OS beta data. 1806 UserCohort string `json:"userCohort,omitempty"` 1807 // ForceSendFields is a list of field names (e.g. "Dimensions") to 1808 // unconditionally include in API requests. By default, fields with empty or 1809 // default values are omitted from API requests. See 1810 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1811 // details. 1812 ForceSendFields []string `json:"-"` 1813 // NullFields is a list of field names (e.g. "Dimensions") to include in API 1814 // requests with the JSON null value. By default, fields with empty values are 1815 // omitted from API requests. See 1816 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1817 NullFields []string `json:"-"` 1818 } 1819 1820 func (s *GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetRequest) MarshalJSON() ([]byte, error) { 1821 type NoMethod GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetRequest 1822 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1823 } 1824 1825 // GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse: 1826 // Response message for QuerySlowRenderingRateMetricSet. 1827 type GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse struct { 1828 // NextPageToken: Continuation token to fetch the next page of data. 1829 NextPageToken string `json:"nextPageToken,omitempty"` 1830 // Rows: Returned rows of data. 1831 Rows []*GooglePlayDeveloperReportingV1beta1MetricsRow `json:"rows,omitempty"` 1832 1833 // ServerResponse contains the HTTP response code and headers from the server. 1834 googleapi.ServerResponse `json:"-"` 1835 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 1836 // unconditionally include in API requests. By default, fields with empty or 1837 // default values are omitted from API requests. See 1838 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1839 // details. 1840 ForceSendFields []string `json:"-"` 1841 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 1842 // requests with the JSON null value. By default, fields with empty values are 1843 // omitted from API requests. See 1844 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1845 NullFields []string `json:"-"` 1846 } 1847 1848 func (s *GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse) MarshalJSON() ([]byte, error) { 1849 type NoMethod GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse 1850 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1851 } 1852 1853 // GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetRequest: 1854 // Request message for QuerySlowStartRateMetricSet. 1855 type GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetRequest struct { 1856 // Dimensions: Dimensions to slice the data by. **Supported dimensions:** * 1857 // `apiLevel` (string): the API level of Android that was running on the user's 1858 // device, e.g., 26. * `versionCode` (int64): version of the app that was 1859 // running on the user's device. * `deviceModel` (string): unique identifier of 1860 // the user's device model. The form of the identifier is 'deviceBrand/device', 1861 // where deviceBrand corresponds to Build.BRAND and device corresponds to 1862 // Build.DEVICE, e.g., google/coral. * `deviceBrand` (string): unique 1863 // identifier of the user's device brand, e.g., google. * `deviceType` 1864 // (string): the type (also known as form factor) of the user's device, e.g., 1865 // PHONE. * `countryCode` (string): the country or region of the user's device 1866 // based on their IP address, represented as a 2-letter ISO-3166 code (e.g. US 1867 // for the United States). * `deviceRamBucket` (int64): RAM of the device, in 1868 // MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): Make of the 1869 // device's primary system-on-chip, e.g., Samsung. Reference 1870 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 1871 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 1872 // e.g., "Exynos 2100". Reference 1873 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 1874 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 1875 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 1876 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 1877 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 1878 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 1879 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 1880 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 1881 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 1882 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 1883 // device, e.g., mdpi, hdpi. 1884 Dimensions []string `json:"dimensions,omitempty"` 1885 // Filter: Filters to apply to data. The filtering expression follows AIP-160 1886 // (https://google.aip.dev/160) standard and supports filtering by equality of 1887 // all breakdown dimensions. 1888 Filter string `json:"filter,omitempty"` 1889 // Metrics: Metrics to aggregate. **Supported metrics:** * `slowStartRate` 1890 // (`google.type.Decimal`): Percentage of distinct users in the aggregation 1891 // period that had a slow start. * `slowStartRate7dUserWeighted` 1892 // (`google.type.Decimal`): Rolling average value of `slowStartRate` in the 1893 // last 7 days. The daily values are weighted by the count of distinct users 1894 // for the day. * `slowStartRate28dUserWeighted` (`google.type.Decimal`): 1895 // Rolling average value of `slowStartRate` in the last 28 days. The daily 1896 // values are weighted by the count of distinct users for the day. * 1897 // `distinctUsers` (`google.type.Decimal`): Count of distinct users in the 1898 // aggregation period that were used as normalization value for the 1899 // `slowStartRate` metric. A user is counted in this metric if their app was 1900 // launched in the device. Care must be taken not to aggregate this count 1901 // further, as it may result in users being counted multiple times. The value 1902 // is rounded to the nearest multiple of 10, 100, 1,000 or 1,000,000, depending 1903 // on the magnitude of the value. 1904 Metrics []string `json:"metrics,omitempty"` 1905 // PageSize: Maximum size of the returned data. If unspecified, at most 1000 1906 // rows will be returned. The maximum value is 100000; values above 100000 will 1907 // be coerced to 100000. 1908 PageSize int64 `json:"pageSize,omitempty"` 1909 // PageToken: A page token, received from a previous call. Provide this to 1910 // retrieve the subsequent page. When paginating, all other parameters provided 1911 // to the request must match the call that provided the page token. 1912 PageToken string `json:"pageToken,omitempty"` 1913 // TimelineSpec: Specification of the timeline aggregation parameters. 1914 // **Supported aggregation periods:** * DAILY: metrics are aggregated in 1915 // calendar date intervals. Due to historical constraints, the only supported 1916 // timezone is `America/Los_Angeles`. 1917 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 1918 // UserCohort: User view to select. The output data will correspond to the 1919 // selected view. **Supported values:** * `OS_PUBLIC` To select data from all 1920 // publicly released Android versions. This is the default. Supports all the 1921 // above dimensions. * `APP_TESTERS` To select data from users who have opted 1922 // in to be testers. Supports all the above dimensions. * `OS_BETA` To select 1923 // data from beta Android versions only, excluding data from released Android 1924 // versions. Only the following dimensions are supported: * `versionCode` 1925 // (int64): version of the app that was running on the user's device. * 1926 // `osBuild` (string): OS build of the user's device, e.g., "T1B2.220916.004". 1927 // 1928 // Possible values: 1929 // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will 1930 // automatically choose the default value. 1931 // "OS_PUBLIC" - This is default view. Contains data from public released 1932 // android versions only. 1933 // "OS_BETA" - This is the view with just android beta data excluding 1934 // released OS version data. 1935 // "APP_TESTERS" - This is the view with data only from users who have opted 1936 // in to be testers for a given app, excluding OS beta data. 1937 UserCohort string `json:"userCohort,omitempty"` 1938 // ForceSendFields is a list of field names (e.g. "Dimensions") to 1939 // unconditionally include in API requests. By default, fields with empty or 1940 // default values are omitted from API requests. See 1941 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1942 // details. 1943 ForceSendFields []string `json:"-"` 1944 // NullFields is a list of field names (e.g. "Dimensions") to include in API 1945 // requests with the JSON null value. By default, fields with empty values are 1946 // omitted from API requests. See 1947 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1948 NullFields []string `json:"-"` 1949 } 1950 1951 func (s *GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetRequest) MarshalJSON() ([]byte, error) { 1952 type NoMethod GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetRequest 1953 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1954 } 1955 1956 // GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse: 1957 // Response message for QuerySlowStartRateMetricSet. 1958 type GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse struct { 1959 // NextPageToken: Continuation token to fetch the next page of data. 1960 NextPageToken string `json:"nextPageToken,omitempty"` 1961 // Rows: Returned rows of data. 1962 Rows []*GooglePlayDeveloperReportingV1beta1MetricsRow `json:"rows,omitempty"` 1963 1964 // ServerResponse contains the HTTP response code and headers from the server. 1965 googleapi.ServerResponse `json:"-"` 1966 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 1967 // unconditionally include in API requests. By default, fields with empty or 1968 // default values are omitted from API requests. See 1969 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1970 // details. 1971 ForceSendFields []string `json:"-"` 1972 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 1973 // requests with the JSON null value. By default, fields with empty values are 1974 // omitted from API requests. See 1975 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1976 NullFields []string `json:"-"` 1977 } 1978 1979 func (s *GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse) MarshalJSON() ([]byte, error) { 1980 type NoMethod GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse 1981 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1982 } 1983 1984 // GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetR 1985 // equest: Request message for QueryStuckBackgroundWakelockRateMetricSet. 1986 type GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetRequest struct { 1987 // Dimensions: Dimensions to slice the data by. **Supported dimensions:** * 1988 // `apiLevel` (string): the API level of Android that was running on the user's 1989 // device, e.g., 26. * `versionCode` (int64): version of the app that was 1990 // running on the user's device. * `deviceModel` (string): unique identifier of 1991 // the user's device model. The form of the identifier is 'deviceBrand/device', 1992 // where deviceBrand corresponds to Build.BRAND and device corresponds to 1993 // Build.DEVICE, e.g., google/coral. * `deviceBrand` (string): unique 1994 // identifier of the user's device brand, e.g., google. * `deviceType` 1995 // (string): the type (also known as form factor) of the user's device, e.g., 1996 // PHONE. * `countryCode` (string): the country or region of the user's device 1997 // based on their IP address, represented as a 2-letter ISO-3166 code (e.g. US 1998 // for the United States). * `deviceRamBucket` (int64): RAM of the device, in 1999 // MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): Make of the 2000 // device's primary system-on-chip, e.g., Samsung. Reference 2001 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 2002 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 2003 // e.g., "Exynos 2100". Reference 2004 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 2005 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 2006 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 2007 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 2008 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 2009 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 2010 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 2011 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 2012 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 2013 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 2014 // device, e.g., mdpi, hdpi. 2015 Dimensions []string `json:"dimensions,omitempty"` 2016 // Filter: Filters to apply to data. The filtering expression follows AIP-160 2017 // (https://google.aip.dev/160) standard and supports filtering by equality of 2018 // all breakdown dimensions. 2019 Filter string `json:"filter,omitempty"` 2020 // Metrics: Metrics to aggregate. **Supported metrics:** * 2021 // `stuckBgWakelockRate` (`google.type.Decimal`): Percentage of distinct users 2022 // in the aggregation period that had a wakelock held in the background for 2023 // longer than 1 hour. * `stuckBgWakelockRate7dUserWeighted` 2024 // (`google.type.Decimal`): Rolling average value of `stuckBgWakelockRate` in 2025 // the last 7 days. The daily values are weighted by the count of distinct 2026 // users for the day. * `stuckBgWakelockRate28dUserWeighted` 2027 // (`google.type.Decimal`): Rolling average value of `stuckBgWakelockRate` in 2028 // the last 28 days. The daily values are weighted by the count of distinct 2029 // users for the day. * `distinctUsers` (`google.type.Decimal`): Count of 2030 // distinct users in the aggregation period that were used as normalization 2031 // value for the `stuckBgWakelockRate` metric. A user is counted in this metric 2032 // if they app was doing any work on the device, i.e., not just active 2033 // foreground usage but also background work. Care must be taken not to 2034 // aggregate this count further, as it may result in users being counted 2035 // multiple times. The value is rounded to the nearest multiple of 10, 100, 2036 // 1,000 or 1,000,000, depending on the magnitude of the value. 2037 Metrics []string `json:"metrics,omitempty"` 2038 // PageSize: Maximum size of the returned data. If unspecified, at most 1000 2039 // rows will be returned. The maximum value is 100000; values above 100000 will 2040 // be coerced to 100000. 2041 PageSize int64 `json:"pageSize,omitempty"` 2042 // PageToken: A page token, received from a previous call. Provide this to 2043 // retrieve the subsequent page. When paginating, all other parameters provided 2044 // to the request must match the call that provided the page token. 2045 PageToken string `json:"pageToken,omitempty"` 2046 // TimelineSpec: Specification of the timeline aggregation parameters. 2047 // **Supported aggregation periods:** * DAILY: metrics are aggregated in 2048 // calendar date intervals. Due to historical constraints, the only supported 2049 // timezone is `America/Los_Angeles`. 2050 TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` 2051 // UserCohort: User view to select. The output data will correspond to the 2052 // selected view. **Supported values:** * `OS_PUBLIC` To select data from all 2053 // publicly released Android versions. This is the default. Supports all the 2054 // above dimensions. * `APP_TESTERS` To select data from users who have opted 2055 // in to be testers. Supports all the above dimensions. * `OS_BETA` To select 2056 // data from beta android versions only, excluding data from released android 2057 // versions. Only the following dimensions are supported: * `versionCode` 2058 // (int64): version of the app that was running on the user's device. * 2059 // `osBuild` (string): OS build of the user's device, e.g., "T1B2.220916.004". 2060 // 2061 // Possible values: 2062 // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will 2063 // automatically choose the default value. 2064 // "OS_PUBLIC" - This is default view. Contains data from public released 2065 // android versions only. 2066 // "OS_BETA" - This is the view with just android beta data excluding 2067 // released OS version data. 2068 // "APP_TESTERS" - This is the view with data only from users who have opted 2069 // in to be testers for a given app, excluding OS beta data. 2070 UserCohort string `json:"userCohort,omitempty"` 2071 // ForceSendFields is a list of field names (e.g. "Dimensions") to 2072 // unconditionally include in API requests. By default, fields with empty or 2073 // default values are omitted from API requests. See 2074 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2075 // details. 2076 ForceSendFields []string `json:"-"` 2077 // NullFields is a list of field names (e.g. "Dimensions") to include in API 2078 // requests with the JSON null value. By default, fields with empty values are 2079 // omitted from API requests. See 2080 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2081 NullFields []string `json:"-"` 2082 } 2083 2084 func (s *GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetRequest) MarshalJSON() ([]byte, error) { 2085 type NoMethod GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetRequest 2086 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2087 } 2088 2089 // GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetR 2090 // esponse: Response message for QueryStuckBackgroundWakelockRateMetricSet. 2091 type GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetResponse struct { 2092 // NextPageToken: Continuation token to fetch the next page of data. 2093 NextPageToken string `json:"nextPageToken,omitempty"` 2094 // Rows: Returned rows of data. 2095 Rows []*GooglePlayDeveloperReportingV1beta1MetricsRow `json:"rows,omitempty"` 2096 2097 // ServerResponse contains the HTTP response code and headers from the server. 2098 googleapi.ServerResponse `json:"-"` 2099 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 2100 // unconditionally include in API requests. By default, fields with empty or 2101 // default values are omitted from API requests. See 2102 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2103 // details. 2104 ForceSendFields []string `json:"-"` 2105 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 2106 // requests with the JSON null value. By default, fields with empty values are 2107 // omitted from API requests. See 2108 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2109 NullFields []string `json:"-"` 2110 } 2111 2112 func (s *GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetResponse) MarshalJSON() ([]byte, error) { 2113 type NoMethod GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetResponse 2114 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2115 } 2116 2117 // GooglePlayDeveloperReportingV1beta1Release: A representation of an app 2118 // release. 2119 type GooglePlayDeveloperReportingV1beta1Release struct { 2120 // DisplayName: Readable identifier of the release. 2121 DisplayName string `json:"displayName,omitempty"` 2122 // VersionCodes: The version codes contained in this release. 2123 VersionCodes googleapi.Int64s `json:"versionCodes,omitempty"` 2124 // ForceSendFields is a list of field names (e.g. "DisplayName") to 2125 // unconditionally include in API requests. By default, fields with empty or 2126 // default values are omitted from API requests. See 2127 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2128 // details. 2129 ForceSendFields []string `json:"-"` 2130 // NullFields is a list of field names (e.g. "DisplayName") to include in API 2131 // requests with the JSON null value. By default, fields with empty values are 2132 // omitted from API requests. See 2133 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2134 NullFields []string `json:"-"` 2135 } 2136 2137 func (s *GooglePlayDeveloperReportingV1beta1Release) MarshalJSON() ([]byte, error) { 2138 type NoMethod GooglePlayDeveloperReportingV1beta1Release 2139 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2140 } 2141 2142 // GooglePlayDeveloperReportingV1beta1ReleaseFilterOptions: A set of filtering 2143 // options for releases and version codes specific to an app. 2144 type GooglePlayDeveloperReportingV1beta1ReleaseFilterOptions struct { 2145 // Tracks: List of tracks to filter releases over. Provides the grouping of 2146 // version codes under releases and tracks. 2147 Tracks []*GooglePlayDeveloperReportingV1beta1Track `json:"tracks,omitempty"` 2148 2149 // ServerResponse contains the HTTP response code and headers from the server. 2150 googleapi.ServerResponse `json:"-"` 2151 // ForceSendFields is a list of field names (e.g. "Tracks") to unconditionally 2152 // include in API requests. By default, fields with empty or default values are 2153 // omitted from API requests. See 2154 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2155 // details. 2156 ForceSendFields []string `json:"-"` 2157 // NullFields is a list of field names (e.g. "Tracks") to include in API 2158 // requests with the JSON null value. By default, fields with empty values are 2159 // omitted from API requests. See 2160 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2161 NullFields []string `json:"-"` 2162 } 2163 2164 func (s *GooglePlayDeveloperReportingV1beta1ReleaseFilterOptions) MarshalJSON() ([]byte, error) { 2165 type NoMethod GooglePlayDeveloperReportingV1beta1ReleaseFilterOptions 2166 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2167 } 2168 2169 // GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse: Response 2170 // message for SearchAccessibleApps. 2171 type GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse struct { 2172 // Apps: The apps accessible to the user calling the endpoint. 2173 Apps []*GooglePlayDeveloperReportingV1beta1App `json:"apps,omitempty"` 2174 // NextPageToken: A token, which can be sent as `page_token` to retrieve the 2175 // next page. If this field is omitted, there are no subsequent pages. 2176 NextPageToken string `json:"nextPageToken,omitempty"` 2177 2178 // ServerResponse contains the HTTP response code and headers from the server. 2179 googleapi.ServerResponse `json:"-"` 2180 // ForceSendFields is a list of field names (e.g. "Apps") to unconditionally 2181 // include in API requests. By default, fields with empty or default values are 2182 // omitted from API requests. See 2183 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2184 // details. 2185 ForceSendFields []string `json:"-"` 2186 // NullFields is a list of field names (e.g. "Apps") to include in API requests 2187 // with the JSON null value. By default, fields with empty values are omitted 2188 // from API requests. See 2189 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2190 NullFields []string `json:"-"` 2191 } 2192 2193 func (s *GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse) MarshalJSON() ([]byte, error) { 2194 type NoMethod GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse 2195 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2196 } 2197 2198 // GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse: Response with 2199 // a paginated list of issues that matched the request. 2200 type GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse struct { 2201 // ErrorIssues: ErrorIssues that were found. 2202 ErrorIssues []*GooglePlayDeveloperReportingV1beta1ErrorIssue `json:"errorIssues,omitempty"` 2203 // NextPageToken: Continuation token to fetch the next page of data. 2204 NextPageToken string `json:"nextPageToken,omitempty"` 2205 2206 // ServerResponse contains the HTTP response code and headers from the server. 2207 googleapi.ServerResponse `json:"-"` 2208 // ForceSendFields is a list of field names (e.g. "ErrorIssues") to 2209 // unconditionally include in API requests. By default, fields with empty or 2210 // default values are omitted from API requests. See 2211 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2212 // details. 2213 ForceSendFields []string `json:"-"` 2214 // NullFields is a list of field names (e.g. "ErrorIssues") to include in API 2215 // requests with the JSON null value. By default, fields with empty values are 2216 // omitted from API requests. See 2217 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2218 NullFields []string `json:"-"` 2219 } 2220 2221 func (s *GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse) MarshalJSON() ([]byte, error) { 2222 type NoMethod GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse 2223 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2224 } 2225 2226 // GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse: Response with 2227 // a paginated list of error reports matching the search query. 2228 type GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse struct { 2229 // ErrorReports: Error reports that were found. 2230 ErrorReports []*GooglePlayDeveloperReportingV1beta1ErrorReport `json:"errorReports,omitempty"` 2231 // NextPageToken: Page token to fetch the next page of reports. 2232 NextPageToken string `json:"nextPageToken,omitempty"` 2233 2234 // ServerResponse contains the HTTP response code and headers from the server. 2235 googleapi.ServerResponse `json:"-"` 2236 // ForceSendFields is a list of field names (e.g. "ErrorReports") to 2237 // unconditionally include in API requests. By default, fields with empty or 2238 // default values are omitted from API requests. See 2239 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2240 // details. 2241 ForceSendFields []string `json:"-"` 2242 // NullFields is a list of field names (e.g. "ErrorReports") to include in API 2243 // requests with the JSON null value. By default, fields with empty values are 2244 // omitted from API requests. See 2245 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2246 NullFields []string `json:"-"` 2247 } 2248 2249 func (s *GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse) MarshalJSON() ([]byte, error) { 2250 type NoMethod GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse 2251 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2252 } 2253 2254 // GooglePlayDeveloperReportingV1beta1SlowRenderingRateMetricSet: Singleton 2255 // resource representing the set of Slow Rendering metrics. This metric set 2256 // contains low-level rendering data captured by SurafeFlinger. Sessions are 2257 // evaluated based on the present-to-present histogram of frames handled by any 2258 // SurfaceFlinger layer owned by the app. A slow session is a session where 2259 // more than 25% of frames for the session did not meet the metric's target 2260 // frame rate (either 20fps, or 30fps). *NOTE:* This metric set is only 2261 // available for games. **Supported aggregation periods:** * DAILY: metrics are 2262 // aggregated in calendar date intervals. Due to historical constraints, the 2263 // only supported timezone is `America/Los_Angeles`. **Supported metrics:** * 2264 // `slowRenderingRate20Fps` (`google.type.Decimal`): Percentage of distinct 2265 // users in the aggregation period that had slow rendering. * 2266 // `slowRenderingRate20Fps7dUserWeighted` (`google.type.Decimal`): Rolling 2267 // average value of `slowRenderingRate20Fps` in the last 7 days. The daily 2268 // values are weighted by the count of distinct users for the day. * 2269 // `slowRenderingRate20Fps28dUserWeighted` (`google.type.Decimal`): Rolling 2270 // average value of `slowRenderingRate20Fps` in the last 28 days. The daily 2271 // values are weighted by the count of distinct users for the day. * 2272 // `slowRenderingRate30Fps` (`google.type.Decimal`): Percentage of distinct 2273 // users in the aggregation period that had slow rendering. * 2274 // `slowRenderingRate30Fps7dUserWeighted` (`google.type.Decimal`): Rolling 2275 // average value of `slowRenderingRate30Fps` in the last 7 days. The daily 2276 // values are weighted by the count of distinct users for the day. * 2277 // `slowRenderingRate30Fps28dUserWeighted` (`google.type.Decimal`): Rolling 2278 // average value of `slowRenderingRate30Fps` in the last 28 days. The daily 2279 // values are weighted by the count of distinct users for the day. * 2280 // `distinctUsers` (`google.type.Decimal`): Count of distinct users in the 2281 // aggregation period that were used as normalization value for the 2282 // `slowRenderingRate20Fps`/`slowRenderingRate30Fps` metric. A user is counted 2283 // in this metric if their app rendered any frames. Care must be taken not to 2284 // aggregate this count further, as it may result in users being counted 2285 // multiple times. The value is rounded to the nearest multiple of 10, 100, 2286 // 1,000 or 1,000,000, depending on the magnitude of the value. **Supported 2287 // dimensions:** * `apiLevel` (string): the API level of Android that was 2288 // running on the user's device, e.g., 26. * `versionCode` (int64): version of 2289 // the app that was running on the user's device. * `deviceModel` (string): 2290 // unique identifier of the user's device model. The form of the identifier is 2291 // 'deviceBrand/device', where deviceBrand corresponds to Build.BRAND and 2292 // device corresponds to Build.DEVICE, e.g., google/coral. * `deviceBrand` 2293 // (string): unique identifier of the user's device brand, e.g., google. * 2294 // `deviceType` (string): the type (also known as form factor) of the user's 2295 // device, e.g., PHONE. * `countryCode` (string): the country or region of the 2296 // user's device based on their IP address, represented as a 2-letter ISO-3166 2297 // code (e.g. US for the United States). * `deviceRamBucket` (int64): RAM of 2298 // the device, in MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): 2299 // Make of the device's primary system-on-chip, e.g., Samsung. Reference 2300 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 2301 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 2302 // e.g., "Exynos 2100". Reference 2303 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 2304 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 2305 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 2306 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 2307 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 2308 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 2309 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 2310 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 2311 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 2312 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 2313 // device, e.g., mdpi, hdpi. **Required permissions**: to access this resource, 2314 // the calling user needs the _View app information (read-only)_ permission for 2315 // the app. 2316 type GooglePlayDeveloperReportingV1beta1SlowRenderingRateMetricSet struct { 2317 // FreshnessInfo: Summary about data freshness in this resource. 2318 FreshnessInfo *GooglePlayDeveloperReportingV1beta1FreshnessInfo `json:"freshnessInfo,omitempty"` 2319 // Name: Identifier. The resource name. Format: 2320 // apps/{app}/slowRenderingRateMetricSet 2321 Name string `json:"name,omitempty"` 2322 2323 // ServerResponse contains the HTTP response code and headers from the server. 2324 googleapi.ServerResponse `json:"-"` 2325 // ForceSendFields is a list of field names (e.g. "FreshnessInfo") to 2326 // unconditionally include in API requests. By default, fields with empty or 2327 // default values are omitted from API requests. See 2328 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2329 // details. 2330 ForceSendFields []string `json:"-"` 2331 // NullFields is a list of field names (e.g. "FreshnessInfo") to include in API 2332 // requests with the JSON null value. By default, fields with empty values are 2333 // omitted from API requests. See 2334 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2335 NullFields []string `json:"-"` 2336 } 2337 2338 func (s *GooglePlayDeveloperReportingV1beta1SlowRenderingRateMetricSet) MarshalJSON() ([]byte, error) { 2339 type NoMethod GooglePlayDeveloperReportingV1beta1SlowRenderingRateMetricSet 2340 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2341 } 2342 2343 // GooglePlayDeveloperReportingV1beta1SlowStartRateMetricSet: Singleton 2344 // resource representing the set of Slow Start metrics. This metric set 2345 // contains Activity start duration data. **Supported aggregation periods:** * 2346 // DAILY: metrics are aggregated in calendar date intervals. Due to historical 2347 // constraints, the only supported timezone is `America/Los_Angeles`. 2348 // **Supported metrics:** * `slowStartRate` (`google.type.Decimal`): Percentage 2349 // of distinct users in the aggregation period that had a slow start. * 2350 // `slowStartRate7dUserWeighted` (`google.type.Decimal`): Rolling average value 2351 // of `slowStartRate` in the last 7 days. The daily values are weighted by the 2352 // count of distinct users for the day. * `slowStartRate28dUserWeighted` 2353 // (`google.type.Decimal`): Rolling average value of `slowStartRate` in the 2354 // last 28 days. The daily values are weighted by the count of distinct users 2355 // for the day. * `distinctUsers` (`google.type.Decimal`): Count of distinct 2356 // users in the aggregation period that were used as normalization value for 2357 // the `slowStartRate` metric. A user is counted in this metric if their app 2358 // was launched in the device. Care must be taken not to aggregate this count 2359 // further, as it may result in users being counted multiple times. The value 2360 // is rounded to the nearest multiple of 10, 100, 1,000 or 1,000,000, depending 2361 // on the magnitude of the value. **Required dimension:** This dimension must 2362 // be specified with each request for the request to be valid. * `startType` 2363 // (string): the type of start that was measured. Valid types are `HOT`, `WARM` 2364 // and `COLD`. **Supported dimensions:** * `apiLevel` (string): the API level 2365 // of Android that was running on the user's device, e.g., 26. * `versionCode` 2366 // (int64): version of the app that was running on the user's device. * 2367 // `deviceModel` (string): unique identifier of the user's device model. The 2368 // form of the identifier is 'deviceBrand/device', where deviceBrand 2369 // corresponds to Build.BRAND and device corresponds to Build.DEVICE, e.g., 2370 // google/coral. * `deviceBrand` (string): unique identifier of the user's 2371 // device brand, e.g., google. * `deviceType` (string): the type (also known as 2372 // form factor) of the user's device, e.g., PHONE. * `countryCode` (string): 2373 // the country or region of the user's device based on their IP address, 2374 // represented as a 2-letter ISO-3166 code (e.g. US for the United States). * 2375 // `deviceRamBucket` (int64): RAM of the device, in MB, in buckets (3GB, 4GB, 2376 // etc.). * `deviceSocMake` (string): Make of the device's primary 2377 // system-on-chip, e.g., Samsung. Reference 2378 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 2379 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 2380 // e.g., "Exynos 2100". Reference 2381 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 2382 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 2383 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 2384 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 2385 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 2386 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 2387 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 2388 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 2389 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 2390 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 2391 // device, e.g., mdpi, hdpi. **Required permissions**: to access this resource, 2392 // the calling user needs the _View app information (read-only)_ permission for 2393 // the app. 2394 type GooglePlayDeveloperReportingV1beta1SlowStartRateMetricSet struct { 2395 // FreshnessInfo: Summary about data freshness in this resource. 2396 FreshnessInfo *GooglePlayDeveloperReportingV1beta1FreshnessInfo `json:"freshnessInfo,omitempty"` 2397 // Name: Identifier. The resource name. Format: 2398 // apps/{app}/slowStartRateMetricSet 2399 Name string `json:"name,omitempty"` 2400 2401 // ServerResponse contains the HTTP response code and headers from the server. 2402 googleapi.ServerResponse `json:"-"` 2403 // ForceSendFields is a list of field names (e.g. "FreshnessInfo") to 2404 // unconditionally include in API requests. By default, fields with empty or 2405 // default values are omitted from API requests. See 2406 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2407 // details. 2408 ForceSendFields []string `json:"-"` 2409 // NullFields is a list of field names (e.g. "FreshnessInfo") to include in API 2410 // requests with the JSON null value. By default, fields with empty values are 2411 // omitted from API requests. See 2412 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2413 NullFields []string `json:"-"` 2414 } 2415 2416 func (s *GooglePlayDeveloperReportingV1beta1SlowStartRateMetricSet) MarshalJSON() ([]byte, error) { 2417 type NoMethod GooglePlayDeveloperReportingV1beta1SlowStartRateMetricSet 2418 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2419 } 2420 2421 // GooglePlayDeveloperReportingV1beta1StuckBackgroundWakelockRateMetricSet: 2422 // Singleton resource representing the set of Stuck Background Wakelocks 2423 // metrics. This metric set contains PowerManager wakelock duration data 2424 // combined with process state data to produce a normalized metric independent 2425 // of user counts. **Supported aggregation periods:** * DAILY: metrics are 2426 // aggregated in calendar date intervals. Due to historical constraints, the 2427 // only supported timezone is `America/Los_Angeles`. **Supported metrics:** * 2428 // `stuckBgWakelockRate` (`google.type.Decimal`): Percentage of distinct users 2429 // in the aggregation period that had a wakelock held in the background for 2430 // longer than 1 hour. * `stuckBgWakelockRate7dUserWeighted` 2431 // (`google.type.Decimal`): Rolling average value of `stuckBgWakelockRate` in 2432 // the last 7 days. The daily values are weighted by the count of distinct 2433 // users for the day. * `stuckBgWakelockRate28dUserWeighted` 2434 // (`google.type.Decimal`): Rolling average value of `stuckBgWakelockRate` in 2435 // the last 28 days. The daily values are weighted by the count of distinct 2436 // users for the day. * `distinctUsers` (`google.type.Decimal`): Count of 2437 // distinct users in the aggregation period that were used as normalization 2438 // value for the `stuckBgWakelockRate` metric. A user is counted in this metric 2439 // if their app was doing any work on the device, i.e., not just active 2440 // foreground usage but also background work. Care must be taken not to 2441 // aggregate this count further, as it may result in users being counted 2442 // multiple times. The value is rounded to the nearest multiple of 10, 100, 2443 // 1,000 or 1,000,000, depending on the magnitude of the value. **Supported 2444 // dimensions:** * `apiLevel` (string): the API level of Android that was 2445 // running on the user's device, e.g., 26. * `versionCode` (int64): version of 2446 // the app that was running on the user's device. * `deviceModel` (string): 2447 // unique identifier of the user's device model. The form of the identifier is 2448 // 'deviceBrand/device', where deviceBrand corresponds to Build.BRAND and 2449 // device corresponds to Build.DEVICE, e.g., google/coral. * `deviceBrand` 2450 // (string): unique identifier of the user's device brand, e.g., google. * 2451 // `deviceType` (string): the type (also known as form factor) of the user's 2452 // device, e.g., PHONE. * `countryCode` (string): the country or region of the 2453 // user's device based on their IP address, represented as a 2-letter ISO-3166 2454 // code (e.g. US for the United States). * `deviceRamBucket` (int64): RAM of 2455 // the device, in MB, in buckets (3GB, 4GB, etc.). * `deviceSocMake` (string): 2456 // Make of the device's primary system-on-chip, e.g., Samsung. Reference 2457 // (https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER) 2458 // * `deviceSocModel` (string): Model of the device's primary system-on-chip, 2459 // e.g., "Exynos 2100". Reference 2460 // (https://developer.android.com/reference/android/os/Build#SOC_MODEL) * 2461 // `deviceCpuMake` (string): Make of the device's CPU, e.g., Qualcomm. * 2462 // `deviceCpuModel` (string): Model of the device's CPU, e.g., "Kryo 240". * 2463 // `deviceGpuMake` (string): Make of the device's GPU, e.g., ARM. * 2464 // `deviceGpuModel` (string): Model of the device's GPU, e.g., Mali. * 2465 // `deviceGpuVersion` (string): Version of the device's GPU, e.g., T750. * 2466 // `deviceVulkanVersion` (string): Vulkan version of the device, e.g., 2467 // "4198400". * `deviceGlEsVersion` (string): OpenGL ES version of the device, 2468 // e.g., "196610". * `deviceScreenSize` (string): Screen size of the device, 2469 // e.g., NORMAL, LARGE. * `deviceScreenDpi` (string): Screen density of the 2470 // device, e.g., mdpi, hdpi. **Required permissions**: to access this resource, 2471 // the calling user needs the _View app information (read-only)_ permission for 2472 // the app. 2473 type GooglePlayDeveloperReportingV1beta1StuckBackgroundWakelockRateMetricSet struct { 2474 // FreshnessInfo: Summary about data freshness in this resource. 2475 FreshnessInfo *GooglePlayDeveloperReportingV1beta1FreshnessInfo `json:"freshnessInfo,omitempty"` 2476 // Name: Identifier. The resource name. Format: 2477 // apps/{app}/stuckBackgroundWakelockRateMetricSet 2478 Name string `json:"name,omitempty"` 2479 2480 // ServerResponse contains the HTTP response code and headers from the server. 2481 googleapi.ServerResponse `json:"-"` 2482 // ForceSendFields is a list of field names (e.g. "FreshnessInfo") to 2483 // unconditionally include in API requests. By default, fields with empty or 2484 // default values are omitted from API requests. See 2485 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2486 // details. 2487 ForceSendFields []string `json:"-"` 2488 // NullFields is a list of field names (e.g. "FreshnessInfo") to include in API 2489 // requests with the JSON null value. By default, fields with empty values are 2490 // omitted from API requests. See 2491 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2492 NullFields []string `json:"-"` 2493 } 2494 2495 func (s *GooglePlayDeveloperReportingV1beta1StuckBackgroundWakelockRateMetricSet) MarshalJSON() ([]byte, error) { 2496 type NoMethod GooglePlayDeveloperReportingV1beta1StuckBackgroundWakelockRateMetricSet 2497 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2498 } 2499 2500 // GooglePlayDeveloperReportingV1beta1TimelineSpec: Specification of the 2501 // time-related aggregation parameters of a timeline. Timelines have an 2502 // aggregation period (`DAILY`, `HOURLY`, etc) which defines how events are 2503 // aggregated in metrics. The points in a timeline are defined by the starting 2504 // DateTime of the aggregation period. The duration is implicit in the 2505 // AggregationPeriod. Hourly aggregation periods, when supported by a metric 2506 // set, are always specified in UTC to avoid ambiguities around daylight saving 2507 // time transitions, where an hour is skipped when adopting DST, and repeated 2508 // when abandoning DST. For example, the timestamp '2021-11-07 01:00:00 2509 // America/Los_Angeles' is ambiguous since it can correspond to '2021-11-07 2510 // 08:00:00 UTC' or '2021-11-07 09:00:00 UTC'. Daily aggregation periods 2511 // require specifying a timezone which will determine the precise instants of 2512 // the start and the end of the day. Not all metric sets support all timezones, 2513 // so make sure to check which timezones are supported by the metric set you 2514 // want to query. 2515 type GooglePlayDeveloperReportingV1beta1TimelineSpec struct { 2516 // AggregationPeriod: Type of the aggregation period of the datapoints in the 2517 // timeline. Intervals are identified by the date and time at the start of the 2518 // interval. 2519 // 2520 // Possible values: 2521 // "AGGREGATION_PERIOD_UNSPECIFIED" - Unspecified granularity. 2522 // "HOURLY" - Data is aggregated in hourly intervals. 2523 // "DAILY" - Data is aggregated in daily intervals. 2524 // "FULL_RANGE" - Data is aggregated over the full timeline range. 2525 // Effectively this produces a single value rather than a timeline. 2526 AggregationPeriod string `json:"aggregationPeriod,omitempty"` 2527 // EndTime: Ending datapoint of the timeline (exclusive). See start_time for 2528 // restrictions. The timezone of the end point must match the timezone of the 2529 // start point. 2530 EndTime *GoogleTypeDateTime `json:"endTime,omitempty"` 2531 // StartTime: Starting datapoint of the timeline (inclusive). Must be aligned 2532 // to the aggregation period as follows: * HOURLY: the 'minutes', 'seconds' and 2533 // 'nanos' fields must be unset. The time_zone can be left unset (defaults to 2534 // UTC) or set explicitly to "UTC". Setting any other utc_offset or timezone id 2535 // will result in a validation error. * DAILY: the 'hours', 'minutes', 2536 // 'seconds' and 'nanos' fields must be unset. Different metric sets support 2537 // different timezones. It can be left unset to use the default timezone 2538 // specified by the metric set. The timezone of the end point must match the 2539 // timezone of the start point. 2540 StartTime *GoogleTypeDateTime `json:"startTime,omitempty"` 2541 // ForceSendFields is a list of field names (e.g. "AggregationPeriod") to 2542 // unconditionally include in API requests. By default, fields with empty or 2543 // default values are omitted from API requests. See 2544 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2545 // details. 2546 ForceSendFields []string `json:"-"` 2547 // NullFields is a list of field names (e.g. "AggregationPeriod") to include in 2548 // API requests with the JSON null value. By default, fields with empty values 2549 // are omitted from API requests. See 2550 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2551 NullFields []string `json:"-"` 2552 } 2553 2554 func (s *GooglePlayDeveloperReportingV1beta1TimelineSpec) MarshalJSON() ([]byte, error) { 2555 type NoMethod GooglePlayDeveloperReportingV1beta1TimelineSpec 2556 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2557 } 2558 2559 // GooglePlayDeveloperReportingV1beta1Track: A representation of a Play release 2560 // track. 2561 type GooglePlayDeveloperReportingV1beta1Track struct { 2562 // DisplayName: Readable identifier of the track. 2563 DisplayName string `json:"displayName,omitempty"` 2564 // ServingReleases: Represents all active releases in the track. 2565 ServingReleases []*GooglePlayDeveloperReportingV1beta1Release `json:"servingReleases,omitempty"` 2566 // Type: The type of the track. 2567 Type string `json:"type,omitempty"` 2568 // ForceSendFields is a list of field names (e.g. "DisplayName") to 2569 // unconditionally include in API requests. By default, fields with empty or 2570 // default values are omitted from API requests. See 2571 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2572 // details. 2573 ForceSendFields []string `json:"-"` 2574 // NullFields is a list of field names (e.g. "DisplayName") to include in API 2575 // requests with the JSON null value. By default, fields with empty values are 2576 // omitted from API requests. See 2577 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2578 NullFields []string `json:"-"` 2579 } 2580 2581 func (s *GooglePlayDeveloperReportingV1beta1Track) MarshalJSON() ([]byte, error) { 2582 type NoMethod GooglePlayDeveloperReportingV1beta1Track 2583 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2584 } 2585 2586 // GoogleTypeDateTime: Represents civil time (or occasionally physical time). 2587 // This type can represent a civil time in one of a few possible ways: * When 2588 // utc_offset is set and time_zone is unset: a civil time on a calendar day 2589 // with a particular offset from UTC. * When time_zone is set and utc_offset is 2590 // unset: a civil time on a calendar day in a particular time zone. * When 2591 // neither time_zone nor utc_offset is set: a civil time on a calendar day in 2592 // local time. The date is relative to the Proleptic Gregorian Calendar. If 2593 // year, month, or day are 0, the DateTime is considered not to have a specific 2594 // year, month, or day respectively. This type may also be used to represent a 2595 // physical time if all the date and time fields are set and either case of the 2596 // `time_offset` oneof is set. Consider using `Timestamp` message for physical 2597 // time instead. If your use case also would like to store the user's timezone, 2598 // that can be done in another field. This type is more flexible than some 2599 // applications may want. Make sure to document and validate your application's 2600 // limitations. 2601 type GoogleTypeDateTime struct { 2602 // Day: Optional. Day of month. Must be from 1 to 31 and valid for the year and 2603 // month, or 0 if specifying a datetime without a day. 2604 Day int64 `json:"day,omitempty"` 2605 // Hours: Optional. Hours of day in 24 hour format. Should be from 0 to 23, 2606 // defaults to 0 (midnight). An API may choose to allow the value "24:00:00" 2607 // for scenarios like business closing time. 2608 Hours int64 `json:"hours,omitempty"` 2609 // Minutes: Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 2610 // 0. 2611 Minutes int64 `json:"minutes,omitempty"` 2612 // Month: Optional. Month of year. Must be from 1 to 12, or 0 if specifying a 2613 // datetime without a month. 2614 Month int64 `json:"month,omitempty"` 2615 // Nanos: Optional. Fractions of seconds in nanoseconds. Must be from 0 to 2616 // 999,999,999, defaults to 0. 2617 Nanos int64 `json:"nanos,omitempty"` 2618 // Seconds: Optional. Seconds of minutes of the time. Must normally be from 0 2619 // to 59, defaults to 0. An API may allow the value 60 if it allows 2620 // leap-seconds. 2621 Seconds int64 `json:"seconds,omitempty"` 2622 // TimeZone: Time zone. 2623 TimeZone *GoogleTypeTimeZone `json:"timeZone,omitempty"` 2624 // UtcOffset: UTC offset. Must be whole seconds, between -18 hours and +18 2625 // hours. For example, a UTC offset of -4:00 would be represented as { seconds: 2626 // -14400 }. 2627 UtcOffset string `json:"utcOffset,omitempty"` 2628 // Year: Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a 2629 // datetime without a year. 2630 Year int64 `json:"year,omitempty"` 2631 // ForceSendFields is a list of field names (e.g. "Day") to unconditionally 2632 // include in API requests. By default, fields with empty or default values are 2633 // omitted from API requests. See 2634 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2635 // details. 2636 ForceSendFields []string `json:"-"` 2637 // NullFields is a list of field names (e.g. "Day") to include in API requests 2638 // with the JSON null value. By default, fields with empty values are omitted 2639 // from API requests. See 2640 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2641 NullFields []string `json:"-"` 2642 } 2643 2644 func (s *GoogleTypeDateTime) MarshalJSON() ([]byte, error) { 2645 type NoMethod GoogleTypeDateTime 2646 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2647 } 2648 2649 // GoogleTypeDecimal: A representation of a decimal value, such as 2.5. Clients 2650 // may convert values into language-native decimal formats, such as Java's 2651 // BigDecimal or Python's decimal.Decimal. [BigDecimal]: 2652 // https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/math/BigDecimal.html 2653 // [decimal.Decimal]: https://docs.python.org/3/library/decimal.html 2654 type GoogleTypeDecimal struct { 2655 // Value: The decimal value, as a string. The string representation consists of 2656 // an optional sign, `+` (`U+002B`) or `-` (`U+002D`), followed by a sequence 2657 // of zero or more decimal digits ("the integer"), optionally followed by a 2658 // fraction, optionally followed by an exponent. An empty string **should** be 2659 // interpreted as `0`. The fraction consists of a decimal point followed by 2660 // zero or more decimal digits. The string must contain at least one digit in 2661 // either the integer or the fraction. The number formed by the sign, the 2662 // integer and the fraction is referred to as the significand. The exponent 2663 // consists of the character `e` (`U+0065`) or `E` (`U+0045`) followed by one 2664 // or more decimal digits. Services **should** normalize decimal values before 2665 // storing them by: - Removing an explicitly-provided `+` sign (`+2.5` -> 2666 // `2.5`). - Replacing a zero-length integer value with `0` (`.5` -> `0.5`). - 2667 // Coercing the exponent character to upper-case, with explicit sign (`2.5e8` 2668 // -> `2.5E+8`). - Removing an explicitly-provided zero exponent (`2.5E0` -> 2669 // `2.5`). Services **may** perform additional normalization based on its own 2670 // needs and the internal decimal implementation selected, such as shifting the 2671 // decimal point and exponent value together (example: `2.5E-1` <-> `0.25`). 2672 // Additionally, services **may** preserve trailing zeroes in the fraction to 2673 // indicate increased precision, but are not required to do so. Note that only 2674 // the `.` character is supported to divide the integer and the fraction; `,` 2675 // **should not** be supported regardless of locale. Additionally, thousand 2676 // separators **should not** be supported. If a service does support them, 2677 // values **must** be normalized. The ENBF grammar is: DecimalString = '' | 2678 // [Sign] Significand [Exponent]; Sign = '+' | '-'; Significand = Digits '.' | 2679 // [Digits] '.' Digits; Exponent = ('e' | 'E') [Sign] Digits; Digits = { '0' | 2680 // '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' }; Services **should** 2681 // clearly document the range of supported values, the maximum supported 2682 // precision (total number of digits), and, if applicable, the scale (number of 2683 // digits after the decimal point), as well as how it behaves when receiving 2684 // out-of-bounds values. Services **may** choose to accept values passed as 2685 // input even when the value has a higher precision or scale than the service 2686 // supports, and **should** round the value to fit the supported scale. 2687 // Alternatively, the service **may** error with `400 Bad Request` 2688 // (`INVALID_ARGUMENT` in gRPC) if precision would be lost. Services **should** 2689 // error with `400 Bad Request` (`INVALID_ARGUMENT` in gRPC) if the service 2690 // receives a value outside of the supported range. 2691 Value string `json:"value,omitempty"` 2692 // ForceSendFields is a list of field names (e.g. "Value") to unconditionally 2693 // include in API requests. By default, fields with empty or default values are 2694 // omitted from API requests. See 2695 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2696 // details. 2697 ForceSendFields []string `json:"-"` 2698 // NullFields is a list of field names (e.g. "Value") to include in API 2699 // requests with the JSON null value. By default, fields with empty values are 2700 // omitted from API requests. See 2701 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2702 NullFields []string `json:"-"` 2703 } 2704 2705 func (s *GoogleTypeDecimal) MarshalJSON() ([]byte, error) { 2706 type NoMethod GoogleTypeDecimal 2707 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2708 } 2709 2710 // GoogleTypeTimeZone: Represents a time zone from the IANA Time Zone Database 2711 // (https://www.iana.org/time-zones). 2712 type GoogleTypeTimeZone struct { 2713 // Id: IANA Time Zone Database time zone, e.g. "America/New_York". 2714 Id string `json:"id,omitempty"` 2715 // Version: Optional. IANA Time Zone Database version number, e.g. "2019a". 2716 Version string `json:"version,omitempty"` 2717 // ForceSendFields is a list of field names (e.g. "Id") to unconditionally 2718 // include in API requests. By default, fields with empty or default values are 2719 // omitted from API requests. See 2720 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2721 // details. 2722 ForceSendFields []string `json:"-"` 2723 // NullFields is a list of field names (e.g. "Id") to include in API requests 2724 // with the JSON null value. By default, fields with empty values are omitted 2725 // from API requests. See 2726 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2727 NullFields []string `json:"-"` 2728 } 2729 2730 func (s *GoogleTypeTimeZone) MarshalJSON() ([]byte, error) { 2731 type NoMethod GoogleTypeTimeZone 2732 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2733 } 2734 2735 type AnomaliesListCall struct { 2736 s *Service 2737 parent string 2738 urlParams_ gensupport.URLParams 2739 ifNoneMatch_ string 2740 ctx_ context.Context 2741 header_ http.Header 2742 } 2743 2744 // List: Lists anomalies in any of the datasets. 2745 // 2746 // - parent: Parent app for which anomalies were detected. Format: apps/{app}. 2747 func (r *AnomaliesService) List(parent string) *AnomaliesListCall { 2748 c := &AnomaliesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} 2749 c.parent = parent 2750 return c 2751 } 2752 2753 // Filter sets the optional parameter "filter": Filtering criteria for 2754 // anomalies. For basic filter guidance, please check: 2755 // https://google.aip.dev/160. **Supported functions:** * 2756 // `activeBetween(startTime, endTime)`: If specified, only list anomalies that 2757 // were active in between `startTime` (inclusive) and `endTime` (exclusive). 2758 // Both parameters are expected to conform to an RFC-3339 formatted string 2759 // (e.g. `2012-04-21T11:30:00-04:00`). UTC offsets are supported. Both 2760 // `startTime` and `endTime` accept the special value `UNBOUNDED`, to signify 2761 // intervals with no lower or upper bound, respectively. Examples: * 2762 // `activeBetween("2021-04-21T11:30:00Z", "2021-07-21T00:00:00Z")` * 2763 // `activeBetween(UNBOUNDED, "2021-11-21T00:00:00-04:00")` * 2764 // `activeBetween("2021-07-21T00:00:00-04:00", UNBOUNDED)` 2765 func (c *AnomaliesListCall) Filter(filter string) *AnomaliesListCall { 2766 c.urlParams_.Set("filter", filter) 2767 return c 2768 } 2769 2770 // PageSize sets the optional parameter "pageSize": Maximum size of the 2771 // returned data. If unspecified, at most 10 anomalies will be returned. The 2772 // maximum value is 100; values above 100 will be coerced to 100. 2773 func (c *AnomaliesListCall) PageSize(pageSize int64) *AnomaliesListCall { 2774 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) 2775 return c 2776 } 2777 2778 // PageToken sets the optional parameter "pageToken": A page token, received 2779 // from a previous `ListErrorReports` call. Provide this to retrieve the 2780 // subsequent page. When paginating, all other parameters provided to 2781 // `ListErrorReports` must match the call that provided the page token. 2782 func (c *AnomaliesListCall) PageToken(pageToken string) *AnomaliesListCall { 2783 c.urlParams_.Set("pageToken", pageToken) 2784 return c 2785 } 2786 2787 // Fields allows partial responses to be retrieved. See 2788 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 2789 // details. 2790 func (c *AnomaliesListCall) Fields(s ...googleapi.Field) *AnomaliesListCall { 2791 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 2792 return c 2793 } 2794 2795 // IfNoneMatch sets an optional parameter which makes the operation fail if the 2796 // object's ETag matches the given value. This is useful for getting updates 2797 // only after the object has changed since the last request. 2798 func (c *AnomaliesListCall) IfNoneMatch(entityTag string) *AnomaliesListCall { 2799 c.ifNoneMatch_ = entityTag 2800 return c 2801 } 2802 2803 // Context sets the context to be used in this call's Do method. 2804 func (c *AnomaliesListCall) Context(ctx context.Context) *AnomaliesListCall { 2805 c.ctx_ = ctx 2806 return c 2807 } 2808 2809 // Header returns a http.Header that can be modified by the caller to add 2810 // headers to the request. 2811 func (c *AnomaliesListCall) Header() http.Header { 2812 if c.header_ == nil { 2813 c.header_ = make(http.Header) 2814 } 2815 return c.header_ 2816 } 2817 2818 func (c *AnomaliesListCall) doRequest(alt string) (*http.Response, error) { 2819 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 2820 if c.ifNoneMatch_ != "" { 2821 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 2822 } 2823 var body io.Reader = nil 2824 c.urlParams_.Set("alt", alt) 2825 c.urlParams_.Set("prettyPrint", "false") 2826 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/anomalies") 2827 urls += "?" + c.urlParams_.Encode() 2828 req, err := http.NewRequest("GET", urls, body) 2829 if err != nil { 2830 return nil, err 2831 } 2832 req.Header = reqHeaders 2833 googleapi.Expand(req.URL, map[string]string{ 2834 "parent": c.parent, 2835 }) 2836 return gensupport.SendRequest(c.ctx_, c.s.client, req) 2837 } 2838 2839 // Do executes the "playdeveloperreporting.anomalies.list" call. 2840 // Any non-2xx status code is an error. Response headers are in either 2841 // *GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse.ServerResponse.Head 2842 // er or (if a response was returned at all) in 2843 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 2844 // whether the returned error was because http.StatusNotModified was returned. 2845 func (c *AnomaliesListCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse, error) { 2846 gensupport.SetOptions(c.urlParams_, opts...) 2847 res, err := c.doRequest("json") 2848 if res != nil && res.StatusCode == http.StatusNotModified { 2849 if res.Body != nil { 2850 res.Body.Close() 2851 } 2852 return nil, gensupport.WrapError(&googleapi.Error{ 2853 Code: res.StatusCode, 2854 Header: res.Header, 2855 }) 2856 } 2857 if err != nil { 2858 return nil, err 2859 } 2860 defer googleapi.CloseBody(res) 2861 if err := googleapi.CheckResponse(res); err != nil { 2862 return nil, gensupport.WrapError(err) 2863 } 2864 ret := &GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse{ 2865 ServerResponse: googleapi.ServerResponse{ 2866 Header: res.Header, 2867 HTTPStatusCode: res.StatusCode, 2868 }, 2869 } 2870 target := &ret 2871 if err := gensupport.DecodeResponse(target, res); err != nil { 2872 return nil, err 2873 } 2874 return ret, nil 2875 } 2876 2877 // Pages invokes f for each page of results. 2878 // A non-nil error returned from f will halt the iteration. 2879 // The provided context supersedes any context provided to the Context method. 2880 func (c *AnomaliesListCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1ListAnomaliesResponse) error) error { 2881 c.ctx_ = ctx 2882 defer c.PageToken(c.urlParams_.Get("pageToken")) 2883 for { 2884 x, err := c.Do() 2885 if err != nil { 2886 return err 2887 } 2888 if err := f(x); err != nil { 2889 return err 2890 } 2891 if x.NextPageToken == "" { 2892 return nil 2893 } 2894 c.PageToken(x.NextPageToken) 2895 } 2896 } 2897 2898 type AppsFetchReleaseFilterOptionsCall struct { 2899 s *Service 2900 name string 2901 urlParams_ gensupport.URLParams 2902 ifNoneMatch_ string 2903 ctx_ context.Context 2904 header_ http.Header 2905 } 2906 2907 // FetchReleaseFilterOptions: Describes filtering options for releases. 2908 // 2909 // - name: Name of the resource, i.e. app the filtering options are for. 2910 // Format: apps/{app}. 2911 func (r *AppsService) FetchReleaseFilterOptions(name string) *AppsFetchReleaseFilterOptionsCall { 2912 c := &AppsFetchReleaseFilterOptionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} 2913 c.name = name 2914 return c 2915 } 2916 2917 // Fields allows partial responses to be retrieved. See 2918 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 2919 // details. 2920 func (c *AppsFetchReleaseFilterOptionsCall) Fields(s ...googleapi.Field) *AppsFetchReleaseFilterOptionsCall { 2921 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 2922 return c 2923 } 2924 2925 // IfNoneMatch sets an optional parameter which makes the operation fail if the 2926 // object's ETag matches the given value. This is useful for getting updates 2927 // only after the object has changed since the last request. 2928 func (c *AppsFetchReleaseFilterOptionsCall) IfNoneMatch(entityTag string) *AppsFetchReleaseFilterOptionsCall { 2929 c.ifNoneMatch_ = entityTag 2930 return c 2931 } 2932 2933 // Context sets the context to be used in this call's Do method. 2934 func (c *AppsFetchReleaseFilterOptionsCall) Context(ctx context.Context) *AppsFetchReleaseFilterOptionsCall { 2935 c.ctx_ = ctx 2936 return c 2937 } 2938 2939 // Header returns a http.Header that can be modified by the caller to add 2940 // headers to the request. 2941 func (c *AppsFetchReleaseFilterOptionsCall) Header() http.Header { 2942 if c.header_ == nil { 2943 c.header_ = make(http.Header) 2944 } 2945 return c.header_ 2946 } 2947 2948 func (c *AppsFetchReleaseFilterOptionsCall) doRequest(alt string) (*http.Response, error) { 2949 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 2950 if c.ifNoneMatch_ != "" { 2951 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 2952 } 2953 var body io.Reader = nil 2954 c.urlParams_.Set("alt", alt) 2955 c.urlParams_.Set("prettyPrint", "false") 2956 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:fetchReleaseFilterOptions") 2957 urls += "?" + c.urlParams_.Encode() 2958 req, err := http.NewRequest("GET", urls, body) 2959 if err != nil { 2960 return nil, err 2961 } 2962 req.Header = reqHeaders 2963 googleapi.Expand(req.URL, map[string]string{ 2964 "name": c.name, 2965 }) 2966 return gensupport.SendRequest(c.ctx_, c.s.client, req) 2967 } 2968 2969 // Do executes the "playdeveloperreporting.apps.fetchReleaseFilterOptions" call. 2970 // Any non-2xx status code is an error. Response headers are in either 2971 // *GooglePlayDeveloperReportingV1beta1ReleaseFilterOptions.ServerResponse.Heade 2972 // r or (if a response was returned at all) in error.(*googleapi.Error).Header. 2973 // Use googleapi.IsNotModified to check whether the returned error was because 2974 // http.StatusNotModified was returned. 2975 func (c *AppsFetchReleaseFilterOptionsCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1ReleaseFilterOptions, error) { 2976 gensupport.SetOptions(c.urlParams_, opts...) 2977 res, err := c.doRequest("json") 2978 if res != nil && res.StatusCode == http.StatusNotModified { 2979 if res.Body != nil { 2980 res.Body.Close() 2981 } 2982 return nil, gensupport.WrapError(&googleapi.Error{ 2983 Code: res.StatusCode, 2984 Header: res.Header, 2985 }) 2986 } 2987 if err != nil { 2988 return nil, err 2989 } 2990 defer googleapi.CloseBody(res) 2991 if err := googleapi.CheckResponse(res); err != nil { 2992 return nil, gensupport.WrapError(err) 2993 } 2994 ret := &GooglePlayDeveloperReportingV1beta1ReleaseFilterOptions{ 2995 ServerResponse: googleapi.ServerResponse{ 2996 Header: res.Header, 2997 HTTPStatusCode: res.StatusCode, 2998 }, 2999 } 3000 target := &ret 3001 if err := gensupport.DecodeResponse(target, res); err != nil { 3002 return nil, err 3003 } 3004 return ret, nil 3005 } 3006 3007 type AppsSearchCall struct { 3008 s *Service 3009 urlParams_ gensupport.URLParams 3010 ifNoneMatch_ string 3011 ctx_ context.Context 3012 header_ http.Header 3013 } 3014 3015 // Search: Searches for Apps accessible by the user. 3016 func (r *AppsService) Search() *AppsSearchCall { 3017 c := &AppsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3018 return c 3019 } 3020 3021 // PageSize sets the optional parameter "pageSize": The maximum number of apps 3022 // to return. The service may return fewer than this value. If unspecified, at 3023 // most 50 apps will be returned. The maximum value is 1000; values above 1000 3024 // will be coerced to 1000. 3025 func (c *AppsSearchCall) PageSize(pageSize int64) *AppsSearchCall { 3026 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) 3027 return c 3028 } 3029 3030 // PageToken sets the optional parameter "pageToken": A page token, received 3031 // from a previous `SearchAccessibleApps` call. Provide this to retrieve the 3032 // subsequent page. When paginating, all other parameters provided to 3033 // `SearchAccessibleApps` must match the call that provided the page token. 3034 func (c *AppsSearchCall) PageToken(pageToken string) *AppsSearchCall { 3035 c.urlParams_.Set("pageToken", pageToken) 3036 return c 3037 } 3038 3039 // Fields allows partial responses to be retrieved. See 3040 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 3041 // details. 3042 func (c *AppsSearchCall) Fields(s ...googleapi.Field) *AppsSearchCall { 3043 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 3044 return c 3045 } 3046 3047 // IfNoneMatch sets an optional parameter which makes the operation fail if the 3048 // object's ETag matches the given value. This is useful for getting updates 3049 // only after the object has changed since the last request. 3050 func (c *AppsSearchCall) IfNoneMatch(entityTag string) *AppsSearchCall { 3051 c.ifNoneMatch_ = entityTag 3052 return c 3053 } 3054 3055 // Context sets the context to be used in this call's Do method. 3056 func (c *AppsSearchCall) Context(ctx context.Context) *AppsSearchCall { 3057 c.ctx_ = ctx 3058 return c 3059 } 3060 3061 // Header returns a http.Header that can be modified by the caller to add 3062 // headers to the request. 3063 func (c *AppsSearchCall) Header() http.Header { 3064 if c.header_ == nil { 3065 c.header_ = make(http.Header) 3066 } 3067 return c.header_ 3068 } 3069 3070 func (c *AppsSearchCall) doRequest(alt string) (*http.Response, error) { 3071 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 3072 if c.ifNoneMatch_ != "" { 3073 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 3074 } 3075 var body io.Reader = nil 3076 c.urlParams_.Set("alt", alt) 3077 c.urlParams_.Set("prettyPrint", "false") 3078 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/apps:search") 3079 urls += "?" + c.urlParams_.Encode() 3080 req, err := http.NewRequest("GET", urls, body) 3081 if err != nil { 3082 return nil, err 3083 } 3084 req.Header = reqHeaders 3085 return gensupport.SendRequest(c.ctx_, c.s.client, req) 3086 } 3087 3088 // Do executes the "playdeveloperreporting.apps.search" call. 3089 // Any non-2xx status code is an error. Response headers are in either 3090 // *GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse.ServerRespon 3091 // se.Header or (if a response was returned at all) in 3092 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 3093 // whether the returned error was because http.StatusNotModified was returned. 3094 func (c *AppsSearchCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse, error) { 3095 gensupport.SetOptions(c.urlParams_, opts...) 3096 res, err := c.doRequest("json") 3097 if res != nil && res.StatusCode == http.StatusNotModified { 3098 if res.Body != nil { 3099 res.Body.Close() 3100 } 3101 return nil, gensupport.WrapError(&googleapi.Error{ 3102 Code: res.StatusCode, 3103 Header: res.Header, 3104 }) 3105 } 3106 if err != nil { 3107 return nil, err 3108 } 3109 defer googleapi.CloseBody(res) 3110 if err := googleapi.CheckResponse(res); err != nil { 3111 return nil, gensupport.WrapError(err) 3112 } 3113 ret := &GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse{ 3114 ServerResponse: googleapi.ServerResponse{ 3115 Header: res.Header, 3116 HTTPStatusCode: res.StatusCode, 3117 }, 3118 } 3119 target := &ret 3120 if err := gensupport.DecodeResponse(target, res); err != nil { 3121 return nil, err 3122 } 3123 return ret, nil 3124 } 3125 3126 // Pages invokes f for each page of results. 3127 // A non-nil error returned from f will halt the iteration. 3128 // The provided context supersedes any context provided to the Context method. 3129 func (c *AppsSearchCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1SearchAccessibleAppsResponse) error) error { 3130 c.ctx_ = ctx 3131 defer c.PageToken(c.urlParams_.Get("pageToken")) 3132 for { 3133 x, err := c.Do() 3134 if err != nil { 3135 return err 3136 } 3137 if err := f(x); err != nil { 3138 return err 3139 } 3140 if x.NextPageToken == "" { 3141 return nil 3142 } 3143 c.PageToken(x.NextPageToken) 3144 } 3145 } 3146 3147 type VitalsAnrrateGetCall struct { 3148 s *Service 3149 name string 3150 urlParams_ gensupport.URLParams 3151 ifNoneMatch_ string 3152 ctx_ context.Context 3153 header_ http.Header 3154 } 3155 3156 // Get: Describes the properties of the metric set. 3157 // 3158 // - name: The resource name. Format: apps/{app}/anrRateMetricSet. 3159 func (r *VitalsAnrrateService) Get(name string) *VitalsAnrrateGetCall { 3160 c := &VitalsAnrrateGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3161 c.name = name 3162 return c 3163 } 3164 3165 // Fields allows partial responses to be retrieved. See 3166 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 3167 // details. 3168 func (c *VitalsAnrrateGetCall) Fields(s ...googleapi.Field) *VitalsAnrrateGetCall { 3169 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 3170 return c 3171 } 3172 3173 // IfNoneMatch sets an optional parameter which makes the operation fail if the 3174 // object's ETag matches the given value. This is useful for getting updates 3175 // only after the object has changed since the last request. 3176 func (c *VitalsAnrrateGetCall) IfNoneMatch(entityTag string) *VitalsAnrrateGetCall { 3177 c.ifNoneMatch_ = entityTag 3178 return c 3179 } 3180 3181 // Context sets the context to be used in this call's Do method. 3182 func (c *VitalsAnrrateGetCall) Context(ctx context.Context) *VitalsAnrrateGetCall { 3183 c.ctx_ = ctx 3184 return c 3185 } 3186 3187 // Header returns a http.Header that can be modified by the caller to add 3188 // headers to the request. 3189 func (c *VitalsAnrrateGetCall) Header() http.Header { 3190 if c.header_ == nil { 3191 c.header_ = make(http.Header) 3192 } 3193 return c.header_ 3194 } 3195 3196 func (c *VitalsAnrrateGetCall) doRequest(alt string) (*http.Response, error) { 3197 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 3198 if c.ifNoneMatch_ != "" { 3199 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 3200 } 3201 var body io.Reader = nil 3202 c.urlParams_.Set("alt", alt) 3203 c.urlParams_.Set("prettyPrint", "false") 3204 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") 3205 urls += "?" + c.urlParams_.Encode() 3206 req, err := http.NewRequest("GET", urls, body) 3207 if err != nil { 3208 return nil, err 3209 } 3210 req.Header = reqHeaders 3211 googleapi.Expand(req.URL, map[string]string{ 3212 "name": c.name, 3213 }) 3214 return gensupport.SendRequest(c.ctx_, c.s.client, req) 3215 } 3216 3217 // Do executes the "playdeveloperreporting.vitals.anrrate.get" call. 3218 // Any non-2xx status code is an error. Response headers are in either 3219 // *GooglePlayDeveloperReportingV1beta1AnrRateMetricSet.ServerResponse.Header 3220 // or (if a response was returned at all) in error.(*googleapi.Error).Header. 3221 // Use googleapi.IsNotModified to check whether the returned error was because 3222 // http.StatusNotModified was returned. 3223 func (c *VitalsAnrrateGetCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1AnrRateMetricSet, error) { 3224 gensupport.SetOptions(c.urlParams_, opts...) 3225 res, err := c.doRequest("json") 3226 if res != nil && res.StatusCode == http.StatusNotModified { 3227 if res.Body != nil { 3228 res.Body.Close() 3229 } 3230 return nil, gensupport.WrapError(&googleapi.Error{ 3231 Code: res.StatusCode, 3232 Header: res.Header, 3233 }) 3234 } 3235 if err != nil { 3236 return nil, err 3237 } 3238 defer googleapi.CloseBody(res) 3239 if err := googleapi.CheckResponse(res); err != nil { 3240 return nil, gensupport.WrapError(err) 3241 } 3242 ret := &GooglePlayDeveloperReportingV1beta1AnrRateMetricSet{ 3243 ServerResponse: googleapi.ServerResponse{ 3244 Header: res.Header, 3245 HTTPStatusCode: res.StatusCode, 3246 }, 3247 } 3248 target := &ret 3249 if err := gensupport.DecodeResponse(target, res); err != nil { 3250 return nil, err 3251 } 3252 return ret, nil 3253 } 3254 3255 type VitalsAnrrateQueryCall struct { 3256 s *Service 3257 name string 3258 googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetRequest 3259 urlParams_ gensupport.URLParams 3260 ctx_ context.Context 3261 header_ http.Header 3262 } 3263 3264 // Query: Queries the metrics in the metric set. 3265 // 3266 // - name: The resource name. Format: apps/{app}/anrRateMetricSet. 3267 func (r *VitalsAnrrateService) Query(name string, googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetRequest) *VitalsAnrrateQueryCall { 3268 c := &VitalsAnrrateQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3269 c.name = name 3270 c.googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest = googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest 3271 return c 3272 } 3273 3274 // Fields allows partial responses to be retrieved. See 3275 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 3276 // details. 3277 func (c *VitalsAnrrateQueryCall) Fields(s ...googleapi.Field) *VitalsAnrrateQueryCall { 3278 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 3279 return c 3280 } 3281 3282 // Context sets the context to be used in this call's Do method. 3283 func (c *VitalsAnrrateQueryCall) Context(ctx context.Context) *VitalsAnrrateQueryCall { 3284 c.ctx_ = ctx 3285 return c 3286 } 3287 3288 // Header returns a http.Header that can be modified by the caller to add 3289 // headers to the request. 3290 func (c *VitalsAnrrateQueryCall) Header() http.Header { 3291 if c.header_ == nil { 3292 c.header_ = make(http.Header) 3293 } 3294 return c.header_ 3295 } 3296 3297 func (c *VitalsAnrrateQueryCall) doRequest(alt string) (*http.Response, error) { 3298 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 3299 var body io.Reader = nil 3300 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest) 3301 if err != nil { 3302 return nil, err 3303 } 3304 c.urlParams_.Set("alt", alt) 3305 c.urlParams_.Set("prettyPrint", "false") 3306 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:query") 3307 urls += "?" + c.urlParams_.Encode() 3308 req, err := http.NewRequest("POST", urls, body) 3309 if err != nil { 3310 return nil, err 3311 } 3312 req.Header = reqHeaders 3313 googleapi.Expand(req.URL, map[string]string{ 3314 "name": c.name, 3315 }) 3316 return gensupport.SendRequest(c.ctx_, c.s.client, req) 3317 } 3318 3319 // Do executes the "playdeveloperreporting.vitals.anrrate.query" call. 3320 // Any non-2xx status code is an error. Response headers are in either 3321 // *GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse.ServerRespo 3322 // nse.Header or (if a response was returned at all) in 3323 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 3324 // whether the returned error was because http.StatusNotModified was returned. 3325 func (c *VitalsAnrrateQueryCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse, error) { 3326 gensupport.SetOptions(c.urlParams_, opts...) 3327 res, err := c.doRequest("json") 3328 if res != nil && res.StatusCode == http.StatusNotModified { 3329 if res.Body != nil { 3330 res.Body.Close() 3331 } 3332 return nil, gensupport.WrapError(&googleapi.Error{ 3333 Code: res.StatusCode, 3334 Header: res.Header, 3335 }) 3336 } 3337 if err != nil { 3338 return nil, err 3339 } 3340 defer googleapi.CloseBody(res) 3341 if err := googleapi.CheckResponse(res); err != nil { 3342 return nil, gensupport.WrapError(err) 3343 } 3344 ret := &GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse{ 3345 ServerResponse: googleapi.ServerResponse{ 3346 Header: res.Header, 3347 HTTPStatusCode: res.StatusCode, 3348 }, 3349 } 3350 target := &ret 3351 if err := gensupport.DecodeResponse(target, res); err != nil { 3352 return nil, err 3353 } 3354 return ret, nil 3355 } 3356 3357 // Pages invokes f for each page of results. 3358 // A non-nil error returned from f will halt the iteration. 3359 // The provided context supersedes any context provided to the Context method. 3360 func (c *VitalsAnrrateQueryCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetResponse) error) error { 3361 c.ctx_ = ctx 3362 defer func(pt string) { c.googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest.PageToken = pt }(c.googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest.PageToken) 3363 for { 3364 x, err := c.Do() 3365 if err != nil { 3366 return err 3367 } 3368 if err := f(x); err != nil { 3369 return err 3370 } 3371 if x.NextPageToken == "" { 3372 return nil 3373 } 3374 c.googleplaydeveloperreportingv1beta1queryanrratemetricsetrequest.PageToken = x.NextPageToken 3375 } 3376 } 3377 3378 type VitalsCrashrateGetCall struct { 3379 s *Service 3380 name string 3381 urlParams_ gensupport.URLParams 3382 ifNoneMatch_ string 3383 ctx_ context.Context 3384 header_ http.Header 3385 } 3386 3387 // Get: Describes the properties of the metric set. 3388 // 3389 // - name: The resource name. Format: apps/{app}/crashRateMetricSet. 3390 func (r *VitalsCrashrateService) Get(name string) *VitalsCrashrateGetCall { 3391 c := &VitalsCrashrateGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3392 c.name = name 3393 return c 3394 } 3395 3396 // Fields allows partial responses to be retrieved. See 3397 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 3398 // details. 3399 func (c *VitalsCrashrateGetCall) Fields(s ...googleapi.Field) *VitalsCrashrateGetCall { 3400 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 3401 return c 3402 } 3403 3404 // IfNoneMatch sets an optional parameter which makes the operation fail if the 3405 // object's ETag matches the given value. This is useful for getting updates 3406 // only after the object has changed since the last request. 3407 func (c *VitalsCrashrateGetCall) IfNoneMatch(entityTag string) *VitalsCrashrateGetCall { 3408 c.ifNoneMatch_ = entityTag 3409 return c 3410 } 3411 3412 // Context sets the context to be used in this call's Do method. 3413 func (c *VitalsCrashrateGetCall) Context(ctx context.Context) *VitalsCrashrateGetCall { 3414 c.ctx_ = ctx 3415 return c 3416 } 3417 3418 // Header returns a http.Header that can be modified by the caller to add 3419 // headers to the request. 3420 func (c *VitalsCrashrateGetCall) Header() http.Header { 3421 if c.header_ == nil { 3422 c.header_ = make(http.Header) 3423 } 3424 return c.header_ 3425 } 3426 3427 func (c *VitalsCrashrateGetCall) doRequest(alt string) (*http.Response, error) { 3428 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 3429 if c.ifNoneMatch_ != "" { 3430 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 3431 } 3432 var body io.Reader = nil 3433 c.urlParams_.Set("alt", alt) 3434 c.urlParams_.Set("prettyPrint", "false") 3435 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") 3436 urls += "?" + c.urlParams_.Encode() 3437 req, err := http.NewRequest("GET", urls, body) 3438 if err != nil { 3439 return nil, err 3440 } 3441 req.Header = reqHeaders 3442 googleapi.Expand(req.URL, map[string]string{ 3443 "name": c.name, 3444 }) 3445 return gensupport.SendRequest(c.ctx_, c.s.client, req) 3446 } 3447 3448 // Do executes the "playdeveloperreporting.vitals.crashrate.get" call. 3449 // Any non-2xx status code is an error. Response headers are in either 3450 // *GooglePlayDeveloperReportingV1beta1CrashRateMetricSet.ServerResponse.Header 3451 // or (if a response was returned at all) in error.(*googleapi.Error).Header. 3452 // Use googleapi.IsNotModified to check whether the returned error was because 3453 // http.StatusNotModified was returned. 3454 func (c *VitalsCrashrateGetCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1CrashRateMetricSet, error) { 3455 gensupport.SetOptions(c.urlParams_, opts...) 3456 res, err := c.doRequest("json") 3457 if res != nil && res.StatusCode == http.StatusNotModified { 3458 if res.Body != nil { 3459 res.Body.Close() 3460 } 3461 return nil, gensupport.WrapError(&googleapi.Error{ 3462 Code: res.StatusCode, 3463 Header: res.Header, 3464 }) 3465 } 3466 if err != nil { 3467 return nil, err 3468 } 3469 defer googleapi.CloseBody(res) 3470 if err := googleapi.CheckResponse(res); err != nil { 3471 return nil, gensupport.WrapError(err) 3472 } 3473 ret := &GooglePlayDeveloperReportingV1beta1CrashRateMetricSet{ 3474 ServerResponse: googleapi.ServerResponse{ 3475 Header: res.Header, 3476 HTTPStatusCode: res.StatusCode, 3477 }, 3478 } 3479 target := &ret 3480 if err := gensupport.DecodeResponse(target, res); err != nil { 3481 return nil, err 3482 } 3483 return ret, nil 3484 } 3485 3486 type VitalsCrashrateQueryCall struct { 3487 s *Service 3488 name string 3489 googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetRequest 3490 urlParams_ gensupport.URLParams 3491 ctx_ context.Context 3492 header_ http.Header 3493 } 3494 3495 // Query: Queries the metrics in the metric set. 3496 // 3497 // - name: The resource name. Format: apps/{app}/crashRateMetricSet. 3498 func (r *VitalsCrashrateService) Query(name string, googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetRequest) *VitalsCrashrateQueryCall { 3499 c := &VitalsCrashrateQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3500 c.name = name 3501 c.googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest = googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest 3502 return c 3503 } 3504 3505 // Fields allows partial responses to be retrieved. See 3506 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 3507 // details. 3508 func (c *VitalsCrashrateQueryCall) Fields(s ...googleapi.Field) *VitalsCrashrateQueryCall { 3509 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 3510 return c 3511 } 3512 3513 // Context sets the context to be used in this call's Do method. 3514 func (c *VitalsCrashrateQueryCall) Context(ctx context.Context) *VitalsCrashrateQueryCall { 3515 c.ctx_ = ctx 3516 return c 3517 } 3518 3519 // Header returns a http.Header that can be modified by the caller to add 3520 // headers to the request. 3521 func (c *VitalsCrashrateQueryCall) Header() http.Header { 3522 if c.header_ == nil { 3523 c.header_ = make(http.Header) 3524 } 3525 return c.header_ 3526 } 3527 3528 func (c *VitalsCrashrateQueryCall) doRequest(alt string) (*http.Response, error) { 3529 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 3530 var body io.Reader = nil 3531 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest) 3532 if err != nil { 3533 return nil, err 3534 } 3535 c.urlParams_.Set("alt", alt) 3536 c.urlParams_.Set("prettyPrint", "false") 3537 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:query") 3538 urls += "?" + c.urlParams_.Encode() 3539 req, err := http.NewRequest("POST", urls, body) 3540 if err != nil { 3541 return nil, err 3542 } 3543 req.Header = reqHeaders 3544 googleapi.Expand(req.URL, map[string]string{ 3545 "name": c.name, 3546 }) 3547 return gensupport.SendRequest(c.ctx_, c.s.client, req) 3548 } 3549 3550 // Do executes the "playdeveloperreporting.vitals.crashrate.query" call. 3551 // Any non-2xx status code is an error. Response headers are in either 3552 // *GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse.ServerRes 3553 // ponse.Header or (if a response was returned at all) in 3554 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 3555 // whether the returned error was because http.StatusNotModified was returned. 3556 func (c *VitalsCrashrateQueryCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse, error) { 3557 gensupport.SetOptions(c.urlParams_, opts...) 3558 res, err := c.doRequest("json") 3559 if res != nil && res.StatusCode == http.StatusNotModified { 3560 if res.Body != nil { 3561 res.Body.Close() 3562 } 3563 return nil, gensupport.WrapError(&googleapi.Error{ 3564 Code: res.StatusCode, 3565 Header: res.Header, 3566 }) 3567 } 3568 if err != nil { 3569 return nil, err 3570 } 3571 defer googleapi.CloseBody(res) 3572 if err := googleapi.CheckResponse(res); err != nil { 3573 return nil, gensupport.WrapError(err) 3574 } 3575 ret := &GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse{ 3576 ServerResponse: googleapi.ServerResponse{ 3577 Header: res.Header, 3578 HTTPStatusCode: res.StatusCode, 3579 }, 3580 } 3581 target := &ret 3582 if err := gensupport.DecodeResponse(target, res); err != nil { 3583 return nil, err 3584 } 3585 return ret, nil 3586 } 3587 3588 // Pages invokes f for each page of results. 3589 // A non-nil error returned from f will halt the iteration. 3590 // The provided context supersedes any context provided to the Context method. 3591 func (c *VitalsCrashrateQueryCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetResponse) error) error { 3592 c.ctx_ = ctx 3593 defer func(pt string) { c.googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest.PageToken = pt }(c.googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest.PageToken) 3594 for { 3595 x, err := c.Do() 3596 if err != nil { 3597 return err 3598 } 3599 if err := f(x); err != nil { 3600 return err 3601 } 3602 if x.NextPageToken == "" { 3603 return nil 3604 } 3605 c.googleplaydeveloperreportingv1beta1querycrashratemetricsetrequest.PageToken = x.NextPageToken 3606 } 3607 } 3608 3609 type VitalsErrorsCountsGetCall struct { 3610 s *Service 3611 name string 3612 urlParams_ gensupport.URLParams 3613 ifNoneMatch_ string 3614 ctx_ context.Context 3615 header_ http.Header 3616 } 3617 3618 // Get: Describes the properties of the metrics set. 3619 // 3620 // - name: Name of the errors metric set. Format: 3621 // apps/{app}/errorCountMetricSet. 3622 func (r *VitalsErrorsCountsService) Get(name string) *VitalsErrorsCountsGetCall { 3623 c := &VitalsErrorsCountsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3624 c.name = name 3625 return c 3626 } 3627 3628 // Fields allows partial responses to be retrieved. See 3629 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 3630 // details. 3631 func (c *VitalsErrorsCountsGetCall) Fields(s ...googleapi.Field) *VitalsErrorsCountsGetCall { 3632 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 3633 return c 3634 } 3635 3636 // IfNoneMatch sets an optional parameter which makes the operation fail if the 3637 // object's ETag matches the given value. This is useful for getting updates 3638 // only after the object has changed since the last request. 3639 func (c *VitalsErrorsCountsGetCall) IfNoneMatch(entityTag string) *VitalsErrorsCountsGetCall { 3640 c.ifNoneMatch_ = entityTag 3641 return c 3642 } 3643 3644 // Context sets the context to be used in this call's Do method. 3645 func (c *VitalsErrorsCountsGetCall) Context(ctx context.Context) *VitalsErrorsCountsGetCall { 3646 c.ctx_ = ctx 3647 return c 3648 } 3649 3650 // Header returns a http.Header that can be modified by the caller to add 3651 // headers to the request. 3652 func (c *VitalsErrorsCountsGetCall) Header() http.Header { 3653 if c.header_ == nil { 3654 c.header_ = make(http.Header) 3655 } 3656 return c.header_ 3657 } 3658 3659 func (c *VitalsErrorsCountsGetCall) doRequest(alt string) (*http.Response, error) { 3660 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 3661 if c.ifNoneMatch_ != "" { 3662 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 3663 } 3664 var body io.Reader = nil 3665 c.urlParams_.Set("alt", alt) 3666 c.urlParams_.Set("prettyPrint", "false") 3667 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") 3668 urls += "?" + c.urlParams_.Encode() 3669 req, err := http.NewRequest("GET", urls, body) 3670 if err != nil { 3671 return nil, err 3672 } 3673 req.Header = reqHeaders 3674 googleapi.Expand(req.URL, map[string]string{ 3675 "name": c.name, 3676 }) 3677 return gensupport.SendRequest(c.ctx_, c.s.client, req) 3678 } 3679 3680 // Do executes the "playdeveloperreporting.vitals.errors.counts.get" call. 3681 // Any non-2xx status code is an error. Response headers are in either 3682 // *GooglePlayDeveloperReportingV1beta1ErrorCountMetricSet.ServerResponse.Header 3683 // 3684 // or (if a response was returned at all) in error.(*googleapi.Error).Header. 3685 // 3686 // Use googleapi.IsNotModified to check whether the returned error was because 3687 // http.StatusNotModified was returned. 3688 func (c *VitalsErrorsCountsGetCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1ErrorCountMetricSet, error) { 3689 gensupport.SetOptions(c.urlParams_, opts...) 3690 res, err := c.doRequest("json") 3691 if res != nil && res.StatusCode == http.StatusNotModified { 3692 if res.Body != nil { 3693 res.Body.Close() 3694 } 3695 return nil, gensupport.WrapError(&googleapi.Error{ 3696 Code: res.StatusCode, 3697 Header: res.Header, 3698 }) 3699 } 3700 if err != nil { 3701 return nil, err 3702 } 3703 defer googleapi.CloseBody(res) 3704 if err := googleapi.CheckResponse(res); err != nil { 3705 return nil, gensupport.WrapError(err) 3706 } 3707 ret := &GooglePlayDeveloperReportingV1beta1ErrorCountMetricSet{ 3708 ServerResponse: googleapi.ServerResponse{ 3709 Header: res.Header, 3710 HTTPStatusCode: res.StatusCode, 3711 }, 3712 } 3713 target := &ret 3714 if err := gensupport.DecodeResponse(target, res); err != nil { 3715 return nil, err 3716 } 3717 return ret, nil 3718 } 3719 3720 type VitalsErrorsCountsQueryCall struct { 3721 s *Service 3722 name string 3723 googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetRequest 3724 urlParams_ gensupport.URLParams 3725 ctx_ context.Context 3726 header_ http.Header 3727 } 3728 3729 // Query: Queries the metrics in the metrics set. 3730 // 3731 // - name: The resource name. Format: apps/{app}/errorCountMetricSet. 3732 func (r *VitalsErrorsCountsService) Query(name string, googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetRequest) *VitalsErrorsCountsQueryCall { 3733 c := &VitalsErrorsCountsQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3734 c.name = name 3735 c.googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest = googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest 3736 return c 3737 } 3738 3739 // Fields allows partial responses to be retrieved. See 3740 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 3741 // details. 3742 func (c *VitalsErrorsCountsQueryCall) Fields(s ...googleapi.Field) *VitalsErrorsCountsQueryCall { 3743 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 3744 return c 3745 } 3746 3747 // Context sets the context to be used in this call's Do method. 3748 func (c *VitalsErrorsCountsQueryCall) Context(ctx context.Context) *VitalsErrorsCountsQueryCall { 3749 c.ctx_ = ctx 3750 return c 3751 } 3752 3753 // Header returns a http.Header that can be modified by the caller to add 3754 // headers to the request. 3755 func (c *VitalsErrorsCountsQueryCall) Header() http.Header { 3756 if c.header_ == nil { 3757 c.header_ = make(http.Header) 3758 } 3759 return c.header_ 3760 } 3761 3762 func (c *VitalsErrorsCountsQueryCall) doRequest(alt string) (*http.Response, error) { 3763 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 3764 var body io.Reader = nil 3765 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest) 3766 if err != nil { 3767 return nil, err 3768 } 3769 c.urlParams_.Set("alt", alt) 3770 c.urlParams_.Set("prettyPrint", "false") 3771 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:query") 3772 urls += "?" + c.urlParams_.Encode() 3773 req, err := http.NewRequest("POST", urls, body) 3774 if err != nil { 3775 return nil, err 3776 } 3777 req.Header = reqHeaders 3778 googleapi.Expand(req.URL, map[string]string{ 3779 "name": c.name, 3780 }) 3781 return gensupport.SendRequest(c.ctx_, c.s.client, req) 3782 } 3783 3784 // Do executes the "playdeveloperreporting.vitals.errors.counts.query" call. 3785 // Any non-2xx status code is an error. Response headers are in either 3786 // *GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse.ServerRe 3787 // sponse.Header or (if a response was returned at all) in 3788 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 3789 // whether the returned error was because http.StatusNotModified was returned. 3790 func (c *VitalsErrorsCountsQueryCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse, error) { 3791 gensupport.SetOptions(c.urlParams_, opts...) 3792 res, err := c.doRequest("json") 3793 if res != nil && res.StatusCode == http.StatusNotModified { 3794 if res.Body != nil { 3795 res.Body.Close() 3796 } 3797 return nil, gensupport.WrapError(&googleapi.Error{ 3798 Code: res.StatusCode, 3799 Header: res.Header, 3800 }) 3801 } 3802 if err != nil { 3803 return nil, err 3804 } 3805 defer googleapi.CloseBody(res) 3806 if err := googleapi.CheckResponse(res); err != nil { 3807 return nil, gensupport.WrapError(err) 3808 } 3809 ret := &GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse{ 3810 ServerResponse: googleapi.ServerResponse{ 3811 Header: res.Header, 3812 HTTPStatusCode: res.StatusCode, 3813 }, 3814 } 3815 target := &ret 3816 if err := gensupport.DecodeResponse(target, res); err != nil { 3817 return nil, err 3818 } 3819 return ret, nil 3820 } 3821 3822 // Pages invokes f for each page of results. 3823 // A non-nil error returned from f will halt the iteration. 3824 // The provided context supersedes any context provided to the Context method. 3825 func (c *VitalsErrorsCountsQueryCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1QueryErrorCountMetricSetResponse) error) error { 3826 c.ctx_ = ctx 3827 defer func(pt string) { c.googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest.PageToken = pt }(c.googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest.PageToken) 3828 for { 3829 x, err := c.Do() 3830 if err != nil { 3831 return err 3832 } 3833 if err := f(x); err != nil { 3834 return err 3835 } 3836 if x.NextPageToken == "" { 3837 return nil 3838 } 3839 c.googleplaydeveloperreportingv1beta1queryerrorcountmetricsetrequest.PageToken = x.NextPageToken 3840 } 3841 } 3842 3843 type VitalsErrorsIssuesSearchCall struct { 3844 s *Service 3845 parent string 3846 urlParams_ gensupport.URLParams 3847 ifNoneMatch_ string 3848 ctx_ context.Context 3849 header_ http.Header 3850 } 3851 3852 // Search: Searches all error issues in which reports have been grouped. 3853 // 3854 // - parent: Parent resource of the error issues, indicating the application 3855 // for which they were received. Format: apps/{app}. 3856 func (r *VitalsErrorsIssuesService) Search(parent string) *VitalsErrorsIssuesSearchCall { 3857 c := &VitalsErrorsIssuesSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} 3858 c.parent = parent 3859 return c 3860 } 3861 3862 // Filter sets the optional parameter "filter": A selection predicate to 3863 // retrieve only a subset of the issues. Counts in the returned error issues 3864 // will only reflect occurrences that matched the filter. For filtering basics, 3865 // please check AIP-160 (https://google.aip.dev/160). ** Supported field 3866 // names:** * `apiLevel`: Matches error issues that occurred in the requested 3867 // Android versions (specified as the numeric API level) only. Example: 3868 // `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error issues that 3869 // occurred in the requested app version codes only. Example: `versionCode = 3870 // 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that 3871 // occurred in the requested devices. Example: `deviceModel = "google/walleye" 3872 // OR deviceModel = "google/marlin". * `deviceBrand`: Matches error issues 3873 // that occurred in the requested device brands. Example: `deviceBrand = 3874 // "Google". * `deviceType`: Matches error issues that occurred in the 3875 // requested device types. Example: `deviceType = "PHONE". * `errorIssueType`: 3876 // Matches error issues of the requested types only. Valid candidates: `CRASH`, 3877 // `ANR`. Example: `errorIssueType = CRASH OR errorIssueType = ANR`. * 3878 // `appProcessState`: Matches error issues on the process state of an app, 3879 // indicating whether an app runs in the foreground (user-visible) or 3880 // background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: 3881 // `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error issues 3882 // that are user-perceived. It is not accompanied by any operators. Example: 3883 // `isUserPerceived`. ** Supported operators:** * Comparison operators: The 3884 // only supported comparison operator is equality. The filtered field must 3885 // appear on the left hand side of the comparison. * Logical Operators: Logical 3886 // operators `AND` and `OR` can be used to build complex filters following a 3887 // conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` 3888 // operator takes precedence over `AND` so the use of parenthesis is not 3889 // necessary when building CNF. The `OR` operator is only supported to build 3890 // disjunctions that apply to the same field, e.g., `versionCode = 123 OR 3891 // errorIssueType = ANR` is not a valid filter. ** Examples ** Some valid 3892 // filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * 3893 // `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * 3894 // `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)` 3895 func (c *VitalsErrorsIssuesSearchCall) Filter(filter string) *VitalsErrorsIssuesSearchCall { 3896 c.urlParams_.Set("filter", filter) 3897 return c 3898 } 3899 3900 // IntervalEndTimeDay sets the optional parameter "interval.endTime.day": Day 3901 // of month. Must be from 1 to 31 and valid for the year and month, or 0 if 3902 // specifying a datetime without a day. 3903 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeDay(intervalEndTimeDay int64) *VitalsErrorsIssuesSearchCall { 3904 c.urlParams_.Set("interval.endTime.day", fmt.Sprint(intervalEndTimeDay)) 3905 return c 3906 } 3907 3908 // IntervalEndTimeHours sets the optional parameter "interval.endTime.hours": 3909 // Hours of day in 24 hour format. Should be from 0 to 23, defaults to 0 3910 // (midnight). An API may choose to allow the value "24:00:00" for scenarios 3911 // like business closing time. 3912 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeHours(intervalEndTimeHours int64) *VitalsErrorsIssuesSearchCall { 3913 c.urlParams_.Set("interval.endTime.hours", fmt.Sprint(intervalEndTimeHours)) 3914 return c 3915 } 3916 3917 // IntervalEndTimeMinutes sets the optional parameter 3918 // "interval.endTime.minutes": Minutes of hour of day. Must be from 0 to 59, 3919 // defaults to 0. 3920 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeMinutes(intervalEndTimeMinutes int64) *VitalsErrorsIssuesSearchCall { 3921 c.urlParams_.Set("interval.endTime.minutes", fmt.Sprint(intervalEndTimeMinutes)) 3922 return c 3923 } 3924 3925 // IntervalEndTimeMonth sets the optional parameter "interval.endTime.month": 3926 // Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a 3927 // month. 3928 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeMonth(intervalEndTimeMonth int64) *VitalsErrorsIssuesSearchCall { 3929 c.urlParams_.Set("interval.endTime.month", fmt.Sprint(intervalEndTimeMonth)) 3930 return c 3931 } 3932 3933 // IntervalEndTimeNanos sets the optional parameter "interval.endTime.nanos": 3934 // Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults 3935 // to 0. 3936 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeNanos(intervalEndTimeNanos int64) *VitalsErrorsIssuesSearchCall { 3937 c.urlParams_.Set("interval.endTime.nanos", fmt.Sprint(intervalEndTimeNanos)) 3938 return c 3939 } 3940 3941 // IntervalEndTimeSeconds sets the optional parameter 3942 // "interval.endTime.seconds": Seconds of minutes of the time. Must normally be 3943 // from 0 to 59, defaults to 0. An API may allow the value 60 if it allows 3944 // leap-seconds. 3945 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeSeconds(intervalEndTimeSeconds int64) *VitalsErrorsIssuesSearchCall { 3946 c.urlParams_.Set("interval.endTime.seconds", fmt.Sprint(intervalEndTimeSeconds)) 3947 return c 3948 } 3949 3950 // IntervalEndTimeTimeZoneId sets the optional parameter 3951 // "interval.endTime.timeZone.id": IANA Time Zone Database time zone, e.g. 3952 // "America/New_York". 3953 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeTimeZoneId(intervalEndTimeTimeZoneId string) *VitalsErrorsIssuesSearchCall { 3954 c.urlParams_.Set("interval.endTime.timeZone.id", intervalEndTimeTimeZoneId) 3955 return c 3956 } 3957 3958 // IntervalEndTimeTimeZoneVersion sets the optional parameter 3959 // "interval.endTime.timeZone.version": IANA Time Zone Database version number, 3960 // e.g. "2019a". 3961 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeTimeZoneVersion(intervalEndTimeTimeZoneVersion string) *VitalsErrorsIssuesSearchCall { 3962 c.urlParams_.Set("interval.endTime.timeZone.version", intervalEndTimeTimeZoneVersion) 3963 return c 3964 } 3965 3966 // IntervalEndTimeUtcOffset sets the optional parameter 3967 // "interval.endTime.utcOffset": UTC offset. Must be whole seconds, between -18 3968 // hours and +18 hours. For example, a UTC offset of -4:00 would be represented 3969 // as { seconds: -14400 }. 3970 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeUtcOffset(intervalEndTimeUtcOffset string) *VitalsErrorsIssuesSearchCall { 3971 c.urlParams_.Set("interval.endTime.utcOffset", intervalEndTimeUtcOffset) 3972 return c 3973 } 3974 3975 // IntervalEndTimeYear sets the optional parameter "interval.endTime.year": 3976 // Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without 3977 // a year. 3978 func (c *VitalsErrorsIssuesSearchCall) IntervalEndTimeYear(intervalEndTimeYear int64) *VitalsErrorsIssuesSearchCall { 3979 c.urlParams_.Set("interval.endTime.year", fmt.Sprint(intervalEndTimeYear)) 3980 return c 3981 } 3982 3983 // IntervalStartTimeDay sets the optional parameter "interval.startTime.day": 3984 // Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if 3985 // specifying a datetime without a day. 3986 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeDay(intervalStartTimeDay int64) *VitalsErrorsIssuesSearchCall { 3987 c.urlParams_.Set("interval.startTime.day", fmt.Sprint(intervalStartTimeDay)) 3988 return c 3989 } 3990 3991 // IntervalStartTimeHours sets the optional parameter 3992 // "interval.startTime.hours": Hours of day in 24 hour format. Should be from 0 3993 // to 23, defaults to 0 (midnight). An API may choose to allow the value 3994 // "24:00:00" for scenarios like business closing time. 3995 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeHours(intervalStartTimeHours int64) *VitalsErrorsIssuesSearchCall { 3996 c.urlParams_.Set("interval.startTime.hours", fmt.Sprint(intervalStartTimeHours)) 3997 return c 3998 } 3999 4000 // IntervalStartTimeMinutes sets the optional parameter 4001 // "interval.startTime.minutes": Minutes of hour of day. Must be from 0 to 59, 4002 // defaults to 0. 4003 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeMinutes(intervalStartTimeMinutes int64) *VitalsErrorsIssuesSearchCall { 4004 c.urlParams_.Set("interval.startTime.minutes", fmt.Sprint(intervalStartTimeMinutes)) 4005 return c 4006 } 4007 4008 // IntervalStartTimeMonth sets the optional parameter 4009 // "interval.startTime.month": Month of year. Must be from 1 to 12, or 0 if 4010 // specifying a datetime without a month. 4011 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeMonth(intervalStartTimeMonth int64) *VitalsErrorsIssuesSearchCall { 4012 c.urlParams_.Set("interval.startTime.month", fmt.Sprint(intervalStartTimeMonth)) 4013 return c 4014 } 4015 4016 // IntervalStartTimeNanos sets the optional parameter 4017 // "interval.startTime.nanos": Fractions of seconds in nanoseconds. Must be 4018 // from 0 to 999,999,999, defaults to 0. 4019 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeNanos(intervalStartTimeNanos int64) *VitalsErrorsIssuesSearchCall { 4020 c.urlParams_.Set("interval.startTime.nanos", fmt.Sprint(intervalStartTimeNanos)) 4021 return c 4022 } 4023 4024 // IntervalStartTimeSeconds sets the optional parameter 4025 // "interval.startTime.seconds": Seconds of minutes of the time. Must normally 4026 // be from 0 to 59, defaults to 0. An API may allow the value 60 if it allows 4027 // leap-seconds. 4028 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeSeconds(intervalStartTimeSeconds int64) *VitalsErrorsIssuesSearchCall { 4029 c.urlParams_.Set("interval.startTime.seconds", fmt.Sprint(intervalStartTimeSeconds)) 4030 return c 4031 } 4032 4033 // IntervalStartTimeTimeZoneId sets the optional parameter 4034 // "interval.startTime.timeZone.id": IANA Time Zone Database time zone, e.g. 4035 // "America/New_York". 4036 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeTimeZoneId(intervalStartTimeTimeZoneId string) *VitalsErrorsIssuesSearchCall { 4037 c.urlParams_.Set("interval.startTime.timeZone.id", intervalStartTimeTimeZoneId) 4038 return c 4039 } 4040 4041 // IntervalStartTimeTimeZoneVersion sets the optional parameter 4042 // "interval.startTime.timeZone.version": IANA Time Zone Database version 4043 // number, e.g. "2019a". 4044 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeTimeZoneVersion(intervalStartTimeTimeZoneVersion string) *VitalsErrorsIssuesSearchCall { 4045 c.urlParams_.Set("interval.startTime.timeZone.version", intervalStartTimeTimeZoneVersion) 4046 return c 4047 } 4048 4049 // IntervalStartTimeUtcOffset sets the optional parameter 4050 // "interval.startTime.utcOffset": UTC offset. Must be whole seconds, between 4051 // -18 hours and +18 hours. For example, a UTC offset of -4:00 would be 4052 // represented as { seconds: -14400 }. 4053 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeUtcOffset(intervalStartTimeUtcOffset string) *VitalsErrorsIssuesSearchCall { 4054 c.urlParams_.Set("interval.startTime.utcOffset", intervalStartTimeUtcOffset) 4055 return c 4056 } 4057 4058 // IntervalStartTimeYear sets the optional parameter "interval.startTime.year": 4059 // Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without 4060 // a year. 4061 func (c *VitalsErrorsIssuesSearchCall) IntervalStartTimeYear(intervalStartTimeYear int64) *VitalsErrorsIssuesSearchCall { 4062 c.urlParams_.Set("interval.startTime.year", fmt.Sprint(intervalStartTimeYear)) 4063 return c 4064 } 4065 4066 // OrderBy sets the optional parameter "orderBy": Specifies a field that will 4067 // be used to order the results. ** Supported dimensions:** * 4068 // `errorReportCount`: Orders issues by number of error reports. * 4069 // `distinctUsers`: Orders issues by number of unique affected users. ** 4070 // Supported operations:** * `asc` for ascending order. * `desc` for descending 4071 // order. Format: A field and an operation, e.g., `errorReportCount desc` 4072 // *Note:* currently only one field is supported at a time. 4073 func (c *VitalsErrorsIssuesSearchCall) OrderBy(orderBy string) *VitalsErrorsIssuesSearchCall { 4074 c.urlParams_.Set("orderBy", orderBy) 4075 return c 4076 } 4077 4078 // PageSize sets the optional parameter "pageSize": The maximum number of error 4079 // issues to return. The service may return fewer than this value. If 4080 // unspecified, at most 50 error issues will be returned. The maximum value is 4081 // 1000; values above 1000 will be coerced to 1000. 4082 func (c *VitalsErrorsIssuesSearchCall) PageSize(pageSize int64) *VitalsErrorsIssuesSearchCall { 4083 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) 4084 return c 4085 } 4086 4087 // PageToken sets the optional parameter "pageToken": A page token, received 4088 // from a previous call. Provide this to retrieve the subsequent page. When 4089 // paginating, all other parameters provided to the request must match the call 4090 // that provided the page token. 4091 func (c *VitalsErrorsIssuesSearchCall) PageToken(pageToken string) *VitalsErrorsIssuesSearchCall { 4092 c.urlParams_.Set("pageToken", pageToken) 4093 return c 4094 } 4095 4096 // SampleErrorReportLimit sets the optional parameter "sampleErrorReportLimit": 4097 // Number of sample error reports to return per ErrorIssue. If unspecified, 0 4098 // will be used. *Note:* currently only 0 and 1 are supported. 4099 func (c *VitalsErrorsIssuesSearchCall) SampleErrorReportLimit(sampleErrorReportLimit int64) *VitalsErrorsIssuesSearchCall { 4100 c.urlParams_.Set("sampleErrorReportLimit", fmt.Sprint(sampleErrorReportLimit)) 4101 return c 4102 } 4103 4104 // Fields allows partial responses to be retrieved. See 4105 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 4106 // details. 4107 func (c *VitalsErrorsIssuesSearchCall) Fields(s ...googleapi.Field) *VitalsErrorsIssuesSearchCall { 4108 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 4109 return c 4110 } 4111 4112 // IfNoneMatch sets an optional parameter which makes the operation fail if the 4113 // object's ETag matches the given value. This is useful for getting updates 4114 // only after the object has changed since the last request. 4115 func (c *VitalsErrorsIssuesSearchCall) IfNoneMatch(entityTag string) *VitalsErrorsIssuesSearchCall { 4116 c.ifNoneMatch_ = entityTag 4117 return c 4118 } 4119 4120 // Context sets the context to be used in this call's Do method. 4121 func (c *VitalsErrorsIssuesSearchCall) Context(ctx context.Context) *VitalsErrorsIssuesSearchCall { 4122 c.ctx_ = ctx 4123 return c 4124 } 4125 4126 // Header returns a http.Header that can be modified by the caller to add 4127 // headers to the request. 4128 func (c *VitalsErrorsIssuesSearchCall) Header() http.Header { 4129 if c.header_ == nil { 4130 c.header_ = make(http.Header) 4131 } 4132 return c.header_ 4133 } 4134 4135 func (c *VitalsErrorsIssuesSearchCall) doRequest(alt string) (*http.Response, error) { 4136 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 4137 if c.ifNoneMatch_ != "" { 4138 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 4139 } 4140 var body io.Reader = nil 4141 c.urlParams_.Set("alt", alt) 4142 c.urlParams_.Set("prettyPrint", "false") 4143 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/errorIssues:search") 4144 urls += "?" + c.urlParams_.Encode() 4145 req, err := http.NewRequest("GET", urls, body) 4146 if err != nil { 4147 return nil, err 4148 } 4149 req.Header = reqHeaders 4150 googleapi.Expand(req.URL, map[string]string{ 4151 "parent": c.parent, 4152 }) 4153 return gensupport.SendRequest(c.ctx_, c.s.client, req) 4154 } 4155 4156 // Do executes the "playdeveloperreporting.vitals.errors.issues.search" call. 4157 // Any non-2xx status code is an error. Response headers are in either 4158 // *GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse.ServerResponse. 4159 // Header or (if a response was returned at all) in 4160 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 4161 // whether the returned error was because http.StatusNotModified was returned. 4162 func (c *VitalsErrorsIssuesSearchCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse, error) { 4163 gensupport.SetOptions(c.urlParams_, opts...) 4164 res, err := c.doRequest("json") 4165 if res != nil && res.StatusCode == http.StatusNotModified { 4166 if res.Body != nil { 4167 res.Body.Close() 4168 } 4169 return nil, gensupport.WrapError(&googleapi.Error{ 4170 Code: res.StatusCode, 4171 Header: res.Header, 4172 }) 4173 } 4174 if err != nil { 4175 return nil, err 4176 } 4177 defer googleapi.CloseBody(res) 4178 if err := googleapi.CheckResponse(res); err != nil { 4179 return nil, gensupport.WrapError(err) 4180 } 4181 ret := &GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse{ 4182 ServerResponse: googleapi.ServerResponse{ 4183 Header: res.Header, 4184 HTTPStatusCode: res.StatusCode, 4185 }, 4186 } 4187 target := &ret 4188 if err := gensupport.DecodeResponse(target, res); err != nil { 4189 return nil, err 4190 } 4191 return ret, nil 4192 } 4193 4194 // Pages invokes f for each page of results. 4195 // A non-nil error returned from f will halt the iteration. 4196 // The provided context supersedes any context provided to the Context method. 4197 func (c *VitalsErrorsIssuesSearchCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1SearchErrorIssuesResponse) error) error { 4198 c.ctx_ = ctx 4199 defer c.PageToken(c.urlParams_.Get("pageToken")) 4200 for { 4201 x, err := c.Do() 4202 if err != nil { 4203 return err 4204 } 4205 if err := f(x); err != nil { 4206 return err 4207 } 4208 if x.NextPageToken == "" { 4209 return nil 4210 } 4211 c.PageToken(x.NextPageToken) 4212 } 4213 } 4214 4215 type VitalsErrorsReportsSearchCall struct { 4216 s *Service 4217 parent string 4218 urlParams_ gensupport.URLParams 4219 ifNoneMatch_ string 4220 ctx_ context.Context 4221 header_ http.Header 4222 } 4223 4224 // Search: Searches all error reports received for an app. 4225 // 4226 // - parent: Parent resource of the reports, indicating the application for 4227 // which they were received. Format: apps/{app}. 4228 func (r *VitalsErrorsReportsService) Search(parent string) *VitalsErrorsReportsSearchCall { 4229 c := &VitalsErrorsReportsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} 4230 c.parent = parent 4231 return c 4232 } 4233 4234 // Filter sets the optional parameter "filter": A selection predicate to 4235 // retrieve only a subset of the reports. For filtering basics, please check 4236 // AIP-160 (https://google.aip.dev/160). ** Supported field names:** * 4237 // `apiLevel`: Matches error reports that occurred in the requested Android 4238 // versions (specified as the numeric API level) only. Example: `apiLevel = 28 4239 // OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in 4240 // the requested app version codes only. Example: `versionCode = 123 OR 4241 // versionCode = 456`. * `deviceModel`: Matches error issues that occurred in 4242 // the requested devices. Example: `deviceModel = "google/walleye" OR 4243 // deviceModel = "google/marlin". * `deviceBrand`: Matches error issues that 4244 // occurred in the requested device brands. Example: `deviceBrand = "Google". * 4245 // `deviceType`: Matches error reports that occurred in the requested device 4246 // types. Example: `deviceType = "PHONE". * `errorIssueType`: Matches error 4247 // reports of the requested types only. Valid candidates: `JAVA_CRASH`, 4248 // `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR 4249 // errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports 4250 // belonging to the requested error issue ids only. Example: `errorIssueId = 4251 // 1234 OR errorIssueId = 4567`. * `errorReportId`: Matches error reports with 4252 // the requested error report id. Example: `errorReportId = 1234 OR 4253 // errorReportId = 4567`. * `appProcessState`: Matches error reports on the 4254 // process state of an app, indicating whether an app runs in the foreground 4255 // (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. 4256 // Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error 4257 // reports that are user-perceived. It is not accompanied by any operators. 4258 // Example: `isUserPerceived`. ** Supported operators:** * Comparison 4259 // operators: The only supported comparison operator is equality. The filtered 4260 // field must appear on the left hand side of the comparison. * Logical 4261 // Operators: Logical operators `AND` and `OR` can be used to build complex 4262 // filters following a conjunctive normal form (CNF), i.e., conjunctions of 4263 // disjunctions. The `OR` operator takes precedence over `AND` so the use of 4264 // parenthesis is not necessary when building CNF. The `OR` operator is only 4265 // supported to build disjunctions that apply to the same field, e.g., 4266 // `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode 4267 // = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid 4268 // filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * 4269 // `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * 4270 // `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)` 4271 func (c *VitalsErrorsReportsSearchCall) Filter(filter string) *VitalsErrorsReportsSearchCall { 4272 c.urlParams_.Set("filter", filter) 4273 return c 4274 } 4275 4276 // IntervalEndTimeDay sets the optional parameter "interval.endTime.day": Day 4277 // of month. Must be from 1 to 31 and valid for the year and month, or 0 if 4278 // specifying a datetime without a day. 4279 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeDay(intervalEndTimeDay int64) *VitalsErrorsReportsSearchCall { 4280 c.urlParams_.Set("interval.endTime.day", fmt.Sprint(intervalEndTimeDay)) 4281 return c 4282 } 4283 4284 // IntervalEndTimeHours sets the optional parameter "interval.endTime.hours": 4285 // Hours of day in 24 hour format. Should be from 0 to 23, defaults to 0 4286 // (midnight). An API may choose to allow the value "24:00:00" for scenarios 4287 // like business closing time. 4288 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeHours(intervalEndTimeHours int64) *VitalsErrorsReportsSearchCall { 4289 c.urlParams_.Set("interval.endTime.hours", fmt.Sprint(intervalEndTimeHours)) 4290 return c 4291 } 4292 4293 // IntervalEndTimeMinutes sets the optional parameter 4294 // "interval.endTime.minutes": Minutes of hour of day. Must be from 0 to 59, 4295 // defaults to 0. 4296 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeMinutes(intervalEndTimeMinutes int64) *VitalsErrorsReportsSearchCall { 4297 c.urlParams_.Set("interval.endTime.minutes", fmt.Sprint(intervalEndTimeMinutes)) 4298 return c 4299 } 4300 4301 // IntervalEndTimeMonth sets the optional parameter "interval.endTime.month": 4302 // Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a 4303 // month. 4304 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeMonth(intervalEndTimeMonth int64) *VitalsErrorsReportsSearchCall { 4305 c.urlParams_.Set("interval.endTime.month", fmt.Sprint(intervalEndTimeMonth)) 4306 return c 4307 } 4308 4309 // IntervalEndTimeNanos sets the optional parameter "interval.endTime.nanos": 4310 // Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults 4311 // to 0. 4312 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeNanos(intervalEndTimeNanos int64) *VitalsErrorsReportsSearchCall { 4313 c.urlParams_.Set("interval.endTime.nanos", fmt.Sprint(intervalEndTimeNanos)) 4314 return c 4315 } 4316 4317 // IntervalEndTimeSeconds sets the optional parameter 4318 // "interval.endTime.seconds": Seconds of minutes of the time. Must normally be 4319 // from 0 to 59, defaults to 0. An API may allow the value 60 if it allows 4320 // leap-seconds. 4321 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeSeconds(intervalEndTimeSeconds int64) *VitalsErrorsReportsSearchCall { 4322 c.urlParams_.Set("interval.endTime.seconds", fmt.Sprint(intervalEndTimeSeconds)) 4323 return c 4324 } 4325 4326 // IntervalEndTimeTimeZoneId sets the optional parameter 4327 // "interval.endTime.timeZone.id": IANA Time Zone Database time zone, e.g. 4328 // "America/New_York". 4329 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeTimeZoneId(intervalEndTimeTimeZoneId string) *VitalsErrorsReportsSearchCall { 4330 c.urlParams_.Set("interval.endTime.timeZone.id", intervalEndTimeTimeZoneId) 4331 return c 4332 } 4333 4334 // IntervalEndTimeTimeZoneVersion sets the optional parameter 4335 // "interval.endTime.timeZone.version": IANA Time Zone Database version number, 4336 // e.g. "2019a". 4337 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeTimeZoneVersion(intervalEndTimeTimeZoneVersion string) *VitalsErrorsReportsSearchCall { 4338 c.urlParams_.Set("interval.endTime.timeZone.version", intervalEndTimeTimeZoneVersion) 4339 return c 4340 } 4341 4342 // IntervalEndTimeUtcOffset sets the optional parameter 4343 // "interval.endTime.utcOffset": UTC offset. Must be whole seconds, between -18 4344 // hours and +18 hours. For example, a UTC offset of -4:00 would be represented 4345 // as { seconds: -14400 }. 4346 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeUtcOffset(intervalEndTimeUtcOffset string) *VitalsErrorsReportsSearchCall { 4347 c.urlParams_.Set("interval.endTime.utcOffset", intervalEndTimeUtcOffset) 4348 return c 4349 } 4350 4351 // IntervalEndTimeYear sets the optional parameter "interval.endTime.year": 4352 // Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without 4353 // a year. 4354 func (c *VitalsErrorsReportsSearchCall) IntervalEndTimeYear(intervalEndTimeYear int64) *VitalsErrorsReportsSearchCall { 4355 c.urlParams_.Set("interval.endTime.year", fmt.Sprint(intervalEndTimeYear)) 4356 return c 4357 } 4358 4359 // IntervalStartTimeDay sets the optional parameter "interval.startTime.day": 4360 // Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if 4361 // specifying a datetime without a day. 4362 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeDay(intervalStartTimeDay int64) *VitalsErrorsReportsSearchCall { 4363 c.urlParams_.Set("interval.startTime.day", fmt.Sprint(intervalStartTimeDay)) 4364 return c 4365 } 4366 4367 // IntervalStartTimeHours sets the optional parameter 4368 // "interval.startTime.hours": Hours of day in 24 hour format. Should be from 0 4369 // to 23, defaults to 0 (midnight). An API may choose to allow the value 4370 // "24:00:00" for scenarios like business closing time. 4371 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeHours(intervalStartTimeHours int64) *VitalsErrorsReportsSearchCall { 4372 c.urlParams_.Set("interval.startTime.hours", fmt.Sprint(intervalStartTimeHours)) 4373 return c 4374 } 4375 4376 // IntervalStartTimeMinutes sets the optional parameter 4377 // "interval.startTime.minutes": Minutes of hour of day. Must be from 0 to 59, 4378 // defaults to 0. 4379 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeMinutes(intervalStartTimeMinutes int64) *VitalsErrorsReportsSearchCall { 4380 c.urlParams_.Set("interval.startTime.minutes", fmt.Sprint(intervalStartTimeMinutes)) 4381 return c 4382 } 4383 4384 // IntervalStartTimeMonth sets the optional parameter 4385 // "interval.startTime.month": Month of year. Must be from 1 to 12, or 0 if 4386 // specifying a datetime without a month. 4387 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeMonth(intervalStartTimeMonth int64) *VitalsErrorsReportsSearchCall { 4388 c.urlParams_.Set("interval.startTime.month", fmt.Sprint(intervalStartTimeMonth)) 4389 return c 4390 } 4391 4392 // IntervalStartTimeNanos sets the optional parameter 4393 // "interval.startTime.nanos": Fractions of seconds in nanoseconds. Must be 4394 // from 0 to 999,999,999, defaults to 0. 4395 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeNanos(intervalStartTimeNanos int64) *VitalsErrorsReportsSearchCall { 4396 c.urlParams_.Set("interval.startTime.nanos", fmt.Sprint(intervalStartTimeNanos)) 4397 return c 4398 } 4399 4400 // IntervalStartTimeSeconds sets the optional parameter 4401 // "interval.startTime.seconds": Seconds of minutes of the time. Must normally 4402 // be from 0 to 59, defaults to 0. An API may allow the value 60 if it allows 4403 // leap-seconds. 4404 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeSeconds(intervalStartTimeSeconds int64) *VitalsErrorsReportsSearchCall { 4405 c.urlParams_.Set("interval.startTime.seconds", fmt.Sprint(intervalStartTimeSeconds)) 4406 return c 4407 } 4408 4409 // IntervalStartTimeTimeZoneId sets the optional parameter 4410 // "interval.startTime.timeZone.id": IANA Time Zone Database time zone, e.g. 4411 // "America/New_York". 4412 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeTimeZoneId(intervalStartTimeTimeZoneId string) *VitalsErrorsReportsSearchCall { 4413 c.urlParams_.Set("interval.startTime.timeZone.id", intervalStartTimeTimeZoneId) 4414 return c 4415 } 4416 4417 // IntervalStartTimeTimeZoneVersion sets the optional parameter 4418 // "interval.startTime.timeZone.version": IANA Time Zone Database version 4419 // number, e.g. "2019a". 4420 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeTimeZoneVersion(intervalStartTimeTimeZoneVersion string) *VitalsErrorsReportsSearchCall { 4421 c.urlParams_.Set("interval.startTime.timeZone.version", intervalStartTimeTimeZoneVersion) 4422 return c 4423 } 4424 4425 // IntervalStartTimeUtcOffset sets the optional parameter 4426 // "interval.startTime.utcOffset": UTC offset. Must be whole seconds, between 4427 // -18 hours and +18 hours. For example, a UTC offset of -4:00 would be 4428 // represented as { seconds: -14400 }. 4429 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeUtcOffset(intervalStartTimeUtcOffset string) *VitalsErrorsReportsSearchCall { 4430 c.urlParams_.Set("interval.startTime.utcOffset", intervalStartTimeUtcOffset) 4431 return c 4432 } 4433 4434 // IntervalStartTimeYear sets the optional parameter "interval.startTime.year": 4435 // Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without 4436 // a year. 4437 func (c *VitalsErrorsReportsSearchCall) IntervalStartTimeYear(intervalStartTimeYear int64) *VitalsErrorsReportsSearchCall { 4438 c.urlParams_.Set("interval.startTime.year", fmt.Sprint(intervalStartTimeYear)) 4439 return c 4440 } 4441 4442 // PageSize sets the optional parameter "pageSize": The maximum number of 4443 // reports to return. The service may return fewer than this value. If 4444 // unspecified, at most 50 reports will be returned. The maximum value is 100; 4445 // values above 100 will be coerced to 100. 4446 func (c *VitalsErrorsReportsSearchCall) PageSize(pageSize int64) *VitalsErrorsReportsSearchCall { 4447 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) 4448 return c 4449 } 4450 4451 // PageToken sets the optional parameter "pageToken": A page token, received 4452 // from a previous `SearchErrorReports` call. Provide this to retrieve the 4453 // subsequent page. When paginating, all other parameters provided to 4454 // `SearchErrorReports` must match the call that provided the page token. 4455 func (c *VitalsErrorsReportsSearchCall) PageToken(pageToken string) *VitalsErrorsReportsSearchCall { 4456 c.urlParams_.Set("pageToken", pageToken) 4457 return c 4458 } 4459 4460 // Fields allows partial responses to be retrieved. See 4461 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 4462 // details. 4463 func (c *VitalsErrorsReportsSearchCall) Fields(s ...googleapi.Field) *VitalsErrorsReportsSearchCall { 4464 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 4465 return c 4466 } 4467 4468 // IfNoneMatch sets an optional parameter which makes the operation fail if the 4469 // object's ETag matches the given value. This is useful for getting updates 4470 // only after the object has changed since the last request. 4471 func (c *VitalsErrorsReportsSearchCall) IfNoneMatch(entityTag string) *VitalsErrorsReportsSearchCall { 4472 c.ifNoneMatch_ = entityTag 4473 return c 4474 } 4475 4476 // Context sets the context to be used in this call's Do method. 4477 func (c *VitalsErrorsReportsSearchCall) Context(ctx context.Context) *VitalsErrorsReportsSearchCall { 4478 c.ctx_ = ctx 4479 return c 4480 } 4481 4482 // Header returns a http.Header that can be modified by the caller to add 4483 // headers to the request. 4484 func (c *VitalsErrorsReportsSearchCall) Header() http.Header { 4485 if c.header_ == nil { 4486 c.header_ = make(http.Header) 4487 } 4488 return c.header_ 4489 } 4490 4491 func (c *VitalsErrorsReportsSearchCall) doRequest(alt string) (*http.Response, error) { 4492 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 4493 if c.ifNoneMatch_ != "" { 4494 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 4495 } 4496 var body io.Reader = nil 4497 c.urlParams_.Set("alt", alt) 4498 c.urlParams_.Set("prettyPrint", "false") 4499 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/errorReports:search") 4500 urls += "?" + c.urlParams_.Encode() 4501 req, err := http.NewRequest("GET", urls, body) 4502 if err != nil { 4503 return nil, err 4504 } 4505 req.Header = reqHeaders 4506 googleapi.Expand(req.URL, map[string]string{ 4507 "parent": c.parent, 4508 }) 4509 return gensupport.SendRequest(c.ctx_, c.s.client, req) 4510 } 4511 4512 // Do executes the "playdeveloperreporting.vitals.errors.reports.search" call. 4513 // Any non-2xx status code is an error. Response headers are in either 4514 // *GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse.ServerResponse 4515 // .Header or (if a response was returned at all) in 4516 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 4517 // whether the returned error was because http.StatusNotModified was returned. 4518 func (c *VitalsErrorsReportsSearchCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse, error) { 4519 gensupport.SetOptions(c.urlParams_, opts...) 4520 res, err := c.doRequest("json") 4521 if res != nil && res.StatusCode == http.StatusNotModified { 4522 if res.Body != nil { 4523 res.Body.Close() 4524 } 4525 return nil, gensupport.WrapError(&googleapi.Error{ 4526 Code: res.StatusCode, 4527 Header: res.Header, 4528 }) 4529 } 4530 if err != nil { 4531 return nil, err 4532 } 4533 defer googleapi.CloseBody(res) 4534 if err := googleapi.CheckResponse(res); err != nil { 4535 return nil, gensupport.WrapError(err) 4536 } 4537 ret := &GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse{ 4538 ServerResponse: googleapi.ServerResponse{ 4539 Header: res.Header, 4540 HTTPStatusCode: res.StatusCode, 4541 }, 4542 } 4543 target := &ret 4544 if err := gensupport.DecodeResponse(target, res); err != nil { 4545 return nil, err 4546 } 4547 return ret, nil 4548 } 4549 4550 // Pages invokes f for each page of results. 4551 // A non-nil error returned from f will halt the iteration. 4552 // The provided context supersedes any context provided to the Context method. 4553 func (c *VitalsErrorsReportsSearchCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1SearchErrorReportsResponse) error) error { 4554 c.ctx_ = ctx 4555 defer c.PageToken(c.urlParams_.Get("pageToken")) 4556 for { 4557 x, err := c.Do() 4558 if err != nil { 4559 return err 4560 } 4561 if err := f(x); err != nil { 4562 return err 4563 } 4564 if x.NextPageToken == "" { 4565 return nil 4566 } 4567 c.PageToken(x.NextPageToken) 4568 } 4569 } 4570 4571 type VitalsExcessivewakeuprateGetCall struct { 4572 s *Service 4573 name string 4574 urlParams_ gensupport.URLParams 4575 ifNoneMatch_ string 4576 ctx_ context.Context 4577 header_ http.Header 4578 } 4579 4580 // Get: Describes the properties of the metric set. 4581 // 4582 // - name: The resource name. Format: apps/{app}/excessiveWakeupRateMetricSet. 4583 func (r *VitalsExcessivewakeuprateService) Get(name string) *VitalsExcessivewakeuprateGetCall { 4584 c := &VitalsExcessivewakeuprateGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 4585 c.name = name 4586 return c 4587 } 4588 4589 // Fields allows partial responses to be retrieved. See 4590 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 4591 // details. 4592 func (c *VitalsExcessivewakeuprateGetCall) Fields(s ...googleapi.Field) *VitalsExcessivewakeuprateGetCall { 4593 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 4594 return c 4595 } 4596 4597 // IfNoneMatch sets an optional parameter which makes the operation fail if the 4598 // object's ETag matches the given value. This is useful for getting updates 4599 // only after the object has changed since the last request. 4600 func (c *VitalsExcessivewakeuprateGetCall) IfNoneMatch(entityTag string) *VitalsExcessivewakeuprateGetCall { 4601 c.ifNoneMatch_ = entityTag 4602 return c 4603 } 4604 4605 // Context sets the context to be used in this call's Do method. 4606 func (c *VitalsExcessivewakeuprateGetCall) Context(ctx context.Context) *VitalsExcessivewakeuprateGetCall { 4607 c.ctx_ = ctx 4608 return c 4609 } 4610 4611 // Header returns a http.Header that can be modified by the caller to add 4612 // headers to the request. 4613 func (c *VitalsExcessivewakeuprateGetCall) Header() http.Header { 4614 if c.header_ == nil { 4615 c.header_ = make(http.Header) 4616 } 4617 return c.header_ 4618 } 4619 4620 func (c *VitalsExcessivewakeuprateGetCall) doRequest(alt string) (*http.Response, error) { 4621 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 4622 if c.ifNoneMatch_ != "" { 4623 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 4624 } 4625 var body io.Reader = nil 4626 c.urlParams_.Set("alt", alt) 4627 c.urlParams_.Set("prettyPrint", "false") 4628 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") 4629 urls += "?" + c.urlParams_.Encode() 4630 req, err := http.NewRequest("GET", urls, body) 4631 if err != nil { 4632 return nil, err 4633 } 4634 req.Header = reqHeaders 4635 googleapi.Expand(req.URL, map[string]string{ 4636 "name": c.name, 4637 }) 4638 return gensupport.SendRequest(c.ctx_, c.s.client, req) 4639 } 4640 4641 // Do executes the "playdeveloperreporting.vitals.excessivewakeuprate.get" call. 4642 // Any non-2xx status code is an error. Response headers are in either 4643 // *GooglePlayDeveloperReportingV1beta1ExcessiveWakeupRateMetricSet.ServerRespon 4644 // se.Header or (if a response was returned at all) in 4645 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 4646 // whether the returned error was because http.StatusNotModified was returned. 4647 func (c *VitalsExcessivewakeuprateGetCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1ExcessiveWakeupRateMetricSet, error) { 4648 gensupport.SetOptions(c.urlParams_, opts...) 4649 res, err := c.doRequest("json") 4650 if res != nil && res.StatusCode == http.StatusNotModified { 4651 if res.Body != nil { 4652 res.Body.Close() 4653 } 4654 return nil, gensupport.WrapError(&googleapi.Error{ 4655 Code: res.StatusCode, 4656 Header: res.Header, 4657 }) 4658 } 4659 if err != nil { 4660 return nil, err 4661 } 4662 defer googleapi.CloseBody(res) 4663 if err := googleapi.CheckResponse(res); err != nil { 4664 return nil, gensupport.WrapError(err) 4665 } 4666 ret := &GooglePlayDeveloperReportingV1beta1ExcessiveWakeupRateMetricSet{ 4667 ServerResponse: googleapi.ServerResponse{ 4668 Header: res.Header, 4669 HTTPStatusCode: res.StatusCode, 4670 }, 4671 } 4672 target := &ret 4673 if err := gensupport.DecodeResponse(target, res); err != nil { 4674 return nil, err 4675 } 4676 return ret, nil 4677 } 4678 4679 type VitalsExcessivewakeuprateQueryCall struct { 4680 s *Service 4681 name string 4682 googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetRequest 4683 urlParams_ gensupport.URLParams 4684 ctx_ context.Context 4685 header_ http.Header 4686 } 4687 4688 // Query: Queries the metrics in the metric set. 4689 // 4690 // - name: The resource name. Format: apps/{app}/excessiveWakeupRateMetricSet. 4691 func (r *VitalsExcessivewakeuprateService) Query(name string, googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetRequest) *VitalsExcessivewakeuprateQueryCall { 4692 c := &VitalsExcessivewakeuprateQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} 4693 c.name = name 4694 c.googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest = googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest 4695 return c 4696 } 4697 4698 // Fields allows partial responses to be retrieved. See 4699 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 4700 // details. 4701 func (c *VitalsExcessivewakeuprateQueryCall) Fields(s ...googleapi.Field) *VitalsExcessivewakeuprateQueryCall { 4702 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 4703 return c 4704 } 4705 4706 // Context sets the context to be used in this call's Do method. 4707 func (c *VitalsExcessivewakeuprateQueryCall) Context(ctx context.Context) *VitalsExcessivewakeuprateQueryCall { 4708 c.ctx_ = ctx 4709 return c 4710 } 4711 4712 // Header returns a http.Header that can be modified by the caller to add 4713 // headers to the request. 4714 func (c *VitalsExcessivewakeuprateQueryCall) Header() http.Header { 4715 if c.header_ == nil { 4716 c.header_ = make(http.Header) 4717 } 4718 return c.header_ 4719 } 4720 4721 func (c *VitalsExcessivewakeuprateQueryCall) doRequest(alt string) (*http.Response, error) { 4722 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 4723 var body io.Reader = nil 4724 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest) 4725 if err != nil { 4726 return nil, err 4727 } 4728 c.urlParams_.Set("alt", alt) 4729 c.urlParams_.Set("prettyPrint", "false") 4730 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:query") 4731 urls += "?" + c.urlParams_.Encode() 4732 req, err := http.NewRequest("POST", urls, body) 4733 if err != nil { 4734 return nil, err 4735 } 4736 req.Header = reqHeaders 4737 googleapi.Expand(req.URL, map[string]string{ 4738 "name": c.name, 4739 }) 4740 return gensupport.SendRequest(c.ctx_, c.s.client, req) 4741 } 4742 4743 // Do executes the "playdeveloperreporting.vitals.excessivewakeuprate.query" call. 4744 // Any non-2xx status code is an error. Response headers are in either 4745 // *GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse 4746 // .ServerResponse.Header or (if a response was returned at all) in 4747 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 4748 // whether the returned error was because http.StatusNotModified was returned. 4749 func (c *VitalsExcessivewakeuprateQueryCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse, error) { 4750 gensupport.SetOptions(c.urlParams_, opts...) 4751 res, err := c.doRequest("json") 4752 if res != nil && res.StatusCode == http.StatusNotModified { 4753 if res.Body != nil { 4754 res.Body.Close() 4755 } 4756 return nil, gensupport.WrapError(&googleapi.Error{ 4757 Code: res.StatusCode, 4758 Header: res.Header, 4759 }) 4760 } 4761 if err != nil { 4762 return nil, err 4763 } 4764 defer googleapi.CloseBody(res) 4765 if err := googleapi.CheckResponse(res); err != nil { 4766 return nil, gensupport.WrapError(err) 4767 } 4768 ret := &GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse{ 4769 ServerResponse: googleapi.ServerResponse{ 4770 Header: res.Header, 4771 HTTPStatusCode: res.StatusCode, 4772 }, 4773 } 4774 target := &ret 4775 if err := gensupport.DecodeResponse(target, res); err != nil { 4776 return nil, err 4777 } 4778 return ret, nil 4779 } 4780 4781 // Pages invokes f for each page of results. 4782 // A non-nil error returned from f will halt the iteration. 4783 // The provided context supersedes any context provided to the Context method. 4784 func (c *VitalsExcessivewakeuprateQueryCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetResponse) error) error { 4785 c.ctx_ = ctx 4786 defer func(pt string) { 4787 c.googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest.PageToken = pt 4788 }(c.googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest.PageToken) 4789 for { 4790 x, err := c.Do() 4791 if err != nil { 4792 return err 4793 } 4794 if err := f(x); err != nil { 4795 return err 4796 } 4797 if x.NextPageToken == "" { 4798 return nil 4799 } 4800 c.googleplaydeveloperreportingv1beta1queryexcessivewakeupratemetricsetrequest.PageToken = x.NextPageToken 4801 } 4802 } 4803 4804 type VitalsSlowrenderingrateGetCall struct { 4805 s *Service 4806 name string 4807 urlParams_ gensupport.URLParams 4808 ifNoneMatch_ string 4809 ctx_ context.Context 4810 header_ http.Header 4811 } 4812 4813 // Get: Describes the properties of the metric set. 4814 // 4815 // - name: The resource name. Format: apps/{app}/slowRenderingRateMetricSet. 4816 func (r *VitalsSlowrenderingrateService) Get(name string) *VitalsSlowrenderingrateGetCall { 4817 c := &VitalsSlowrenderingrateGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 4818 c.name = name 4819 return c 4820 } 4821 4822 // Fields allows partial responses to be retrieved. See 4823 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 4824 // details. 4825 func (c *VitalsSlowrenderingrateGetCall) Fields(s ...googleapi.Field) *VitalsSlowrenderingrateGetCall { 4826 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 4827 return c 4828 } 4829 4830 // IfNoneMatch sets an optional parameter which makes the operation fail if the 4831 // object's ETag matches the given value. This is useful for getting updates 4832 // only after the object has changed since the last request. 4833 func (c *VitalsSlowrenderingrateGetCall) IfNoneMatch(entityTag string) *VitalsSlowrenderingrateGetCall { 4834 c.ifNoneMatch_ = entityTag 4835 return c 4836 } 4837 4838 // Context sets the context to be used in this call's Do method. 4839 func (c *VitalsSlowrenderingrateGetCall) Context(ctx context.Context) *VitalsSlowrenderingrateGetCall { 4840 c.ctx_ = ctx 4841 return c 4842 } 4843 4844 // Header returns a http.Header that can be modified by the caller to add 4845 // headers to the request. 4846 func (c *VitalsSlowrenderingrateGetCall) Header() http.Header { 4847 if c.header_ == nil { 4848 c.header_ = make(http.Header) 4849 } 4850 return c.header_ 4851 } 4852 4853 func (c *VitalsSlowrenderingrateGetCall) doRequest(alt string) (*http.Response, error) { 4854 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 4855 if c.ifNoneMatch_ != "" { 4856 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 4857 } 4858 var body io.Reader = nil 4859 c.urlParams_.Set("alt", alt) 4860 c.urlParams_.Set("prettyPrint", "false") 4861 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") 4862 urls += "?" + c.urlParams_.Encode() 4863 req, err := http.NewRequest("GET", urls, body) 4864 if err != nil { 4865 return nil, err 4866 } 4867 req.Header = reqHeaders 4868 googleapi.Expand(req.URL, map[string]string{ 4869 "name": c.name, 4870 }) 4871 return gensupport.SendRequest(c.ctx_, c.s.client, req) 4872 } 4873 4874 // Do executes the "playdeveloperreporting.vitals.slowrenderingrate.get" call. 4875 // Any non-2xx status code is an error. Response headers are in either 4876 // *GooglePlayDeveloperReportingV1beta1SlowRenderingRateMetricSet.ServerResponse 4877 // .Header or (if a response was returned at all) in 4878 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 4879 // whether the returned error was because http.StatusNotModified was returned. 4880 func (c *VitalsSlowrenderingrateGetCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1SlowRenderingRateMetricSet, error) { 4881 gensupport.SetOptions(c.urlParams_, opts...) 4882 res, err := c.doRequest("json") 4883 if res != nil && res.StatusCode == http.StatusNotModified { 4884 if res.Body != nil { 4885 res.Body.Close() 4886 } 4887 return nil, gensupport.WrapError(&googleapi.Error{ 4888 Code: res.StatusCode, 4889 Header: res.Header, 4890 }) 4891 } 4892 if err != nil { 4893 return nil, err 4894 } 4895 defer googleapi.CloseBody(res) 4896 if err := googleapi.CheckResponse(res); err != nil { 4897 return nil, gensupport.WrapError(err) 4898 } 4899 ret := &GooglePlayDeveloperReportingV1beta1SlowRenderingRateMetricSet{ 4900 ServerResponse: googleapi.ServerResponse{ 4901 Header: res.Header, 4902 HTTPStatusCode: res.StatusCode, 4903 }, 4904 } 4905 target := &ret 4906 if err := gensupport.DecodeResponse(target, res); err != nil { 4907 return nil, err 4908 } 4909 return ret, nil 4910 } 4911 4912 type VitalsSlowrenderingrateQueryCall struct { 4913 s *Service 4914 name string 4915 googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetRequest 4916 urlParams_ gensupport.URLParams 4917 ctx_ context.Context 4918 header_ http.Header 4919 } 4920 4921 // Query: Queries the metrics in the metric set. 4922 // 4923 // - name: The resource name. Format: apps/{app}/slowRenderingRateMetricSet. 4924 func (r *VitalsSlowrenderingrateService) Query(name string, googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetRequest) *VitalsSlowrenderingrateQueryCall { 4925 c := &VitalsSlowrenderingrateQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} 4926 c.name = name 4927 c.googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest = googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest 4928 return c 4929 } 4930 4931 // Fields allows partial responses to be retrieved. See 4932 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 4933 // details. 4934 func (c *VitalsSlowrenderingrateQueryCall) Fields(s ...googleapi.Field) *VitalsSlowrenderingrateQueryCall { 4935 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 4936 return c 4937 } 4938 4939 // Context sets the context to be used in this call's Do method. 4940 func (c *VitalsSlowrenderingrateQueryCall) Context(ctx context.Context) *VitalsSlowrenderingrateQueryCall { 4941 c.ctx_ = ctx 4942 return c 4943 } 4944 4945 // Header returns a http.Header that can be modified by the caller to add 4946 // headers to the request. 4947 func (c *VitalsSlowrenderingrateQueryCall) Header() http.Header { 4948 if c.header_ == nil { 4949 c.header_ = make(http.Header) 4950 } 4951 return c.header_ 4952 } 4953 4954 func (c *VitalsSlowrenderingrateQueryCall) doRequest(alt string) (*http.Response, error) { 4955 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 4956 var body io.Reader = nil 4957 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest) 4958 if err != nil { 4959 return nil, err 4960 } 4961 c.urlParams_.Set("alt", alt) 4962 c.urlParams_.Set("prettyPrint", "false") 4963 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:query") 4964 urls += "?" + c.urlParams_.Encode() 4965 req, err := http.NewRequest("POST", urls, body) 4966 if err != nil { 4967 return nil, err 4968 } 4969 req.Header = reqHeaders 4970 googleapi.Expand(req.URL, map[string]string{ 4971 "name": c.name, 4972 }) 4973 return gensupport.SendRequest(c.ctx_, c.s.client, req) 4974 } 4975 4976 // Do executes the "playdeveloperreporting.vitals.slowrenderingrate.query" call. 4977 // Any non-2xx status code is an error. Response headers are in either 4978 // *GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse.S 4979 // erverResponse.Header or (if a response was returned at all) in 4980 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 4981 // whether the returned error was because http.StatusNotModified was returned. 4982 func (c *VitalsSlowrenderingrateQueryCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse, error) { 4983 gensupport.SetOptions(c.urlParams_, opts...) 4984 res, err := c.doRequest("json") 4985 if res != nil && res.StatusCode == http.StatusNotModified { 4986 if res.Body != nil { 4987 res.Body.Close() 4988 } 4989 return nil, gensupport.WrapError(&googleapi.Error{ 4990 Code: res.StatusCode, 4991 Header: res.Header, 4992 }) 4993 } 4994 if err != nil { 4995 return nil, err 4996 } 4997 defer googleapi.CloseBody(res) 4998 if err := googleapi.CheckResponse(res); err != nil { 4999 return nil, gensupport.WrapError(err) 5000 } 5001 ret := &GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse{ 5002 ServerResponse: googleapi.ServerResponse{ 5003 Header: res.Header, 5004 HTTPStatusCode: res.StatusCode, 5005 }, 5006 } 5007 target := &ret 5008 if err := gensupport.DecodeResponse(target, res); err != nil { 5009 return nil, err 5010 } 5011 return ret, nil 5012 } 5013 5014 // Pages invokes f for each page of results. 5015 // A non-nil error returned from f will halt the iteration. 5016 // The provided context supersedes any context provided to the Context method. 5017 func (c *VitalsSlowrenderingrateQueryCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1QuerySlowRenderingRateMetricSetResponse) error) error { 5018 c.ctx_ = ctx 5019 defer func(pt string) { 5020 c.googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest.PageToken = pt 5021 }(c.googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest.PageToken) 5022 for { 5023 x, err := c.Do() 5024 if err != nil { 5025 return err 5026 } 5027 if err := f(x); err != nil { 5028 return err 5029 } 5030 if x.NextPageToken == "" { 5031 return nil 5032 } 5033 c.googleplaydeveloperreportingv1beta1queryslowrenderingratemetricsetrequest.PageToken = x.NextPageToken 5034 } 5035 } 5036 5037 type VitalsSlowstartrateGetCall struct { 5038 s *Service 5039 name string 5040 urlParams_ gensupport.URLParams 5041 ifNoneMatch_ string 5042 ctx_ context.Context 5043 header_ http.Header 5044 } 5045 5046 // Get: Describes the properties of the metric set. 5047 // 5048 // - name: The resource name. Format: apps/{app}/slowStartRateMetricSet. 5049 func (r *VitalsSlowstartrateService) Get(name string) *VitalsSlowstartrateGetCall { 5050 c := &VitalsSlowstartrateGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 5051 c.name = name 5052 return c 5053 } 5054 5055 // Fields allows partial responses to be retrieved. See 5056 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 5057 // details. 5058 func (c *VitalsSlowstartrateGetCall) Fields(s ...googleapi.Field) *VitalsSlowstartrateGetCall { 5059 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 5060 return c 5061 } 5062 5063 // IfNoneMatch sets an optional parameter which makes the operation fail if the 5064 // object's ETag matches the given value. This is useful for getting updates 5065 // only after the object has changed since the last request. 5066 func (c *VitalsSlowstartrateGetCall) IfNoneMatch(entityTag string) *VitalsSlowstartrateGetCall { 5067 c.ifNoneMatch_ = entityTag 5068 return c 5069 } 5070 5071 // Context sets the context to be used in this call's Do method. 5072 func (c *VitalsSlowstartrateGetCall) Context(ctx context.Context) *VitalsSlowstartrateGetCall { 5073 c.ctx_ = ctx 5074 return c 5075 } 5076 5077 // Header returns a http.Header that can be modified by the caller to add 5078 // headers to the request. 5079 func (c *VitalsSlowstartrateGetCall) Header() http.Header { 5080 if c.header_ == nil { 5081 c.header_ = make(http.Header) 5082 } 5083 return c.header_ 5084 } 5085 5086 func (c *VitalsSlowstartrateGetCall) doRequest(alt string) (*http.Response, error) { 5087 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 5088 if c.ifNoneMatch_ != "" { 5089 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 5090 } 5091 var body io.Reader = nil 5092 c.urlParams_.Set("alt", alt) 5093 c.urlParams_.Set("prettyPrint", "false") 5094 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") 5095 urls += "?" + c.urlParams_.Encode() 5096 req, err := http.NewRequest("GET", urls, body) 5097 if err != nil { 5098 return nil, err 5099 } 5100 req.Header = reqHeaders 5101 googleapi.Expand(req.URL, map[string]string{ 5102 "name": c.name, 5103 }) 5104 return gensupport.SendRequest(c.ctx_, c.s.client, req) 5105 } 5106 5107 // Do executes the "playdeveloperreporting.vitals.slowstartrate.get" call. 5108 // Any non-2xx status code is an error. Response headers are in either 5109 // *GooglePlayDeveloperReportingV1beta1SlowStartRateMetricSet.ServerResponse.Hea 5110 // der or (if a response was returned at all) in 5111 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 5112 // whether the returned error was because http.StatusNotModified was returned. 5113 func (c *VitalsSlowstartrateGetCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1SlowStartRateMetricSet, error) { 5114 gensupport.SetOptions(c.urlParams_, opts...) 5115 res, err := c.doRequest("json") 5116 if res != nil && res.StatusCode == http.StatusNotModified { 5117 if res.Body != nil { 5118 res.Body.Close() 5119 } 5120 return nil, gensupport.WrapError(&googleapi.Error{ 5121 Code: res.StatusCode, 5122 Header: res.Header, 5123 }) 5124 } 5125 if err != nil { 5126 return nil, err 5127 } 5128 defer googleapi.CloseBody(res) 5129 if err := googleapi.CheckResponse(res); err != nil { 5130 return nil, gensupport.WrapError(err) 5131 } 5132 ret := &GooglePlayDeveloperReportingV1beta1SlowStartRateMetricSet{ 5133 ServerResponse: googleapi.ServerResponse{ 5134 Header: res.Header, 5135 HTTPStatusCode: res.StatusCode, 5136 }, 5137 } 5138 target := &ret 5139 if err := gensupport.DecodeResponse(target, res); err != nil { 5140 return nil, err 5141 } 5142 return ret, nil 5143 } 5144 5145 type VitalsSlowstartrateQueryCall struct { 5146 s *Service 5147 name string 5148 googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetRequest 5149 urlParams_ gensupport.URLParams 5150 ctx_ context.Context 5151 header_ http.Header 5152 } 5153 5154 // Query: Queries the metrics in the metric set. 5155 // 5156 // - name: The resource name. Format: apps/{app}/slowStartRateMetricSet. 5157 func (r *VitalsSlowstartrateService) Query(name string, googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetRequest) *VitalsSlowstartrateQueryCall { 5158 c := &VitalsSlowstartrateQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} 5159 c.name = name 5160 c.googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest = googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest 5161 return c 5162 } 5163 5164 // Fields allows partial responses to be retrieved. See 5165 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 5166 // details. 5167 func (c *VitalsSlowstartrateQueryCall) Fields(s ...googleapi.Field) *VitalsSlowstartrateQueryCall { 5168 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 5169 return c 5170 } 5171 5172 // Context sets the context to be used in this call's Do method. 5173 func (c *VitalsSlowstartrateQueryCall) Context(ctx context.Context) *VitalsSlowstartrateQueryCall { 5174 c.ctx_ = ctx 5175 return c 5176 } 5177 5178 // Header returns a http.Header that can be modified by the caller to add 5179 // headers to the request. 5180 func (c *VitalsSlowstartrateQueryCall) Header() http.Header { 5181 if c.header_ == nil { 5182 c.header_ = make(http.Header) 5183 } 5184 return c.header_ 5185 } 5186 5187 func (c *VitalsSlowstartrateQueryCall) doRequest(alt string) (*http.Response, error) { 5188 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 5189 var body io.Reader = nil 5190 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest) 5191 if err != nil { 5192 return nil, err 5193 } 5194 c.urlParams_.Set("alt", alt) 5195 c.urlParams_.Set("prettyPrint", "false") 5196 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:query") 5197 urls += "?" + c.urlParams_.Encode() 5198 req, err := http.NewRequest("POST", urls, body) 5199 if err != nil { 5200 return nil, err 5201 } 5202 req.Header = reqHeaders 5203 googleapi.Expand(req.URL, map[string]string{ 5204 "name": c.name, 5205 }) 5206 return gensupport.SendRequest(c.ctx_, c.s.client, req) 5207 } 5208 5209 // Do executes the "playdeveloperreporting.vitals.slowstartrate.query" call. 5210 // Any non-2xx status code is an error. Response headers are in either 5211 // *GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse.Serve 5212 // rResponse.Header or (if a response was returned at all) in 5213 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 5214 // whether the returned error was because http.StatusNotModified was returned. 5215 func (c *VitalsSlowstartrateQueryCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse, error) { 5216 gensupport.SetOptions(c.urlParams_, opts...) 5217 res, err := c.doRequest("json") 5218 if res != nil && res.StatusCode == http.StatusNotModified { 5219 if res.Body != nil { 5220 res.Body.Close() 5221 } 5222 return nil, gensupport.WrapError(&googleapi.Error{ 5223 Code: res.StatusCode, 5224 Header: res.Header, 5225 }) 5226 } 5227 if err != nil { 5228 return nil, err 5229 } 5230 defer googleapi.CloseBody(res) 5231 if err := googleapi.CheckResponse(res); err != nil { 5232 return nil, gensupport.WrapError(err) 5233 } 5234 ret := &GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse{ 5235 ServerResponse: googleapi.ServerResponse{ 5236 Header: res.Header, 5237 HTTPStatusCode: res.StatusCode, 5238 }, 5239 } 5240 target := &ret 5241 if err := gensupport.DecodeResponse(target, res); err != nil { 5242 return nil, err 5243 } 5244 return ret, nil 5245 } 5246 5247 // Pages invokes f for each page of results. 5248 // A non-nil error returned from f will halt the iteration. 5249 // The provided context supersedes any context provided to the Context method. 5250 func (c *VitalsSlowstartrateQueryCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1QuerySlowStartRateMetricSetResponse) error) error { 5251 c.ctx_ = ctx 5252 defer func(pt string) { 5253 c.googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest.PageToken = pt 5254 }(c.googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest.PageToken) 5255 for { 5256 x, err := c.Do() 5257 if err != nil { 5258 return err 5259 } 5260 if err := f(x); err != nil { 5261 return err 5262 } 5263 if x.NextPageToken == "" { 5264 return nil 5265 } 5266 c.googleplaydeveloperreportingv1beta1queryslowstartratemetricsetrequest.PageToken = x.NextPageToken 5267 } 5268 } 5269 5270 type VitalsStuckbackgroundwakelockrateGetCall struct { 5271 s *Service 5272 name string 5273 urlParams_ gensupport.URLParams 5274 ifNoneMatch_ string 5275 ctx_ context.Context 5276 header_ http.Header 5277 } 5278 5279 // Get: Describes the properties of the metric set. 5280 // 5281 // - name: The resource name. Format: 5282 // apps/{app}/stuckBackgroundWakelockRateMetricSet. 5283 func (r *VitalsStuckbackgroundwakelockrateService) Get(name string) *VitalsStuckbackgroundwakelockrateGetCall { 5284 c := &VitalsStuckbackgroundwakelockrateGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 5285 c.name = name 5286 return c 5287 } 5288 5289 // Fields allows partial responses to be retrieved. See 5290 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 5291 // details. 5292 func (c *VitalsStuckbackgroundwakelockrateGetCall) Fields(s ...googleapi.Field) *VitalsStuckbackgroundwakelockrateGetCall { 5293 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 5294 return c 5295 } 5296 5297 // IfNoneMatch sets an optional parameter which makes the operation fail if the 5298 // object's ETag matches the given value. This is useful for getting updates 5299 // only after the object has changed since the last request. 5300 func (c *VitalsStuckbackgroundwakelockrateGetCall) IfNoneMatch(entityTag string) *VitalsStuckbackgroundwakelockrateGetCall { 5301 c.ifNoneMatch_ = entityTag 5302 return c 5303 } 5304 5305 // Context sets the context to be used in this call's Do method. 5306 func (c *VitalsStuckbackgroundwakelockrateGetCall) Context(ctx context.Context) *VitalsStuckbackgroundwakelockrateGetCall { 5307 c.ctx_ = ctx 5308 return c 5309 } 5310 5311 // Header returns a http.Header that can be modified by the caller to add 5312 // headers to the request. 5313 func (c *VitalsStuckbackgroundwakelockrateGetCall) Header() http.Header { 5314 if c.header_ == nil { 5315 c.header_ = make(http.Header) 5316 } 5317 return c.header_ 5318 } 5319 5320 func (c *VitalsStuckbackgroundwakelockrateGetCall) doRequest(alt string) (*http.Response, error) { 5321 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 5322 if c.ifNoneMatch_ != "" { 5323 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 5324 } 5325 var body io.Reader = nil 5326 c.urlParams_.Set("alt", alt) 5327 c.urlParams_.Set("prettyPrint", "false") 5328 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") 5329 urls += "?" + c.urlParams_.Encode() 5330 req, err := http.NewRequest("GET", urls, body) 5331 if err != nil { 5332 return nil, err 5333 } 5334 req.Header = reqHeaders 5335 googleapi.Expand(req.URL, map[string]string{ 5336 "name": c.name, 5337 }) 5338 return gensupport.SendRequest(c.ctx_, c.s.client, req) 5339 } 5340 5341 // Do executes the "playdeveloperreporting.vitals.stuckbackgroundwakelockrate.get" call. 5342 // Any non-2xx status code is an error. Response headers are in either 5343 // *GooglePlayDeveloperReportingV1beta1StuckBackgroundWakelockRateMetricSet.Serv 5344 // erResponse.Header or (if a response was returned at all) in 5345 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 5346 // whether the returned error was because http.StatusNotModified was returned. 5347 func (c *VitalsStuckbackgroundwakelockrateGetCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1StuckBackgroundWakelockRateMetricSet, error) { 5348 gensupport.SetOptions(c.urlParams_, opts...) 5349 res, err := c.doRequest("json") 5350 if res != nil && res.StatusCode == http.StatusNotModified { 5351 if res.Body != nil { 5352 res.Body.Close() 5353 } 5354 return nil, gensupport.WrapError(&googleapi.Error{ 5355 Code: res.StatusCode, 5356 Header: res.Header, 5357 }) 5358 } 5359 if err != nil { 5360 return nil, err 5361 } 5362 defer googleapi.CloseBody(res) 5363 if err := googleapi.CheckResponse(res); err != nil { 5364 return nil, gensupport.WrapError(err) 5365 } 5366 ret := &GooglePlayDeveloperReportingV1beta1StuckBackgroundWakelockRateMetricSet{ 5367 ServerResponse: googleapi.ServerResponse{ 5368 Header: res.Header, 5369 HTTPStatusCode: res.StatusCode, 5370 }, 5371 } 5372 target := &ret 5373 if err := gensupport.DecodeResponse(target, res); err != nil { 5374 return nil, err 5375 } 5376 return ret, nil 5377 } 5378 5379 type VitalsStuckbackgroundwakelockrateQueryCall struct { 5380 s *Service 5381 name string 5382 googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetRequest 5383 urlParams_ gensupport.URLParams 5384 ctx_ context.Context 5385 header_ http.Header 5386 } 5387 5388 // Query: Queries the metrics in the metric set. 5389 // 5390 // - name: The resource name. Format: 5391 // apps/{app}/stuckBackgroundWakelockRateMetricSet. 5392 func (r *VitalsStuckbackgroundwakelockrateService) Query(name string, googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest *GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetRequest) *VitalsStuckbackgroundwakelockrateQueryCall { 5393 c := &VitalsStuckbackgroundwakelockrateQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} 5394 c.name = name 5395 c.googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest = googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest 5396 return c 5397 } 5398 5399 // Fields allows partial responses to be retrieved. See 5400 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 5401 // details. 5402 func (c *VitalsStuckbackgroundwakelockrateQueryCall) Fields(s ...googleapi.Field) *VitalsStuckbackgroundwakelockrateQueryCall { 5403 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 5404 return c 5405 } 5406 5407 // Context sets the context to be used in this call's Do method. 5408 func (c *VitalsStuckbackgroundwakelockrateQueryCall) Context(ctx context.Context) *VitalsStuckbackgroundwakelockrateQueryCall { 5409 c.ctx_ = ctx 5410 return c 5411 } 5412 5413 // Header returns a http.Header that can be modified by the caller to add 5414 // headers to the request. 5415 func (c *VitalsStuckbackgroundwakelockrateQueryCall) Header() http.Header { 5416 if c.header_ == nil { 5417 c.header_ = make(http.Header) 5418 } 5419 return c.header_ 5420 } 5421 5422 func (c *VitalsStuckbackgroundwakelockrateQueryCall) doRequest(alt string) (*http.Response, error) { 5423 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 5424 var body io.Reader = nil 5425 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest) 5426 if err != nil { 5427 return nil, err 5428 } 5429 c.urlParams_.Set("alt", alt) 5430 c.urlParams_.Set("prettyPrint", "false") 5431 urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:query") 5432 urls += "?" + c.urlParams_.Encode() 5433 req, err := http.NewRequest("POST", urls, body) 5434 if err != nil { 5435 return nil, err 5436 } 5437 req.Header = reqHeaders 5438 googleapi.Expand(req.URL, map[string]string{ 5439 "name": c.name, 5440 }) 5441 return gensupport.SendRequest(c.ctx_, c.s.client, req) 5442 } 5443 5444 // Do executes the "playdeveloperreporting.vitals.stuckbackgroundwakelockrate.query" call. 5445 // Any non-2xx status code is an error. Response headers are in either 5446 // *GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSet 5447 // Response.ServerResponse.Header or (if a response was returned at all) in 5448 // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check 5449 // whether the returned error was because http.StatusNotModified was returned. 5450 func (c *VitalsStuckbackgroundwakelockrateQueryCall) Do(opts ...googleapi.CallOption) (*GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetResponse, error) { 5451 gensupport.SetOptions(c.urlParams_, opts...) 5452 res, err := c.doRequest("json") 5453 if res != nil && res.StatusCode == http.StatusNotModified { 5454 if res.Body != nil { 5455 res.Body.Close() 5456 } 5457 return nil, gensupport.WrapError(&googleapi.Error{ 5458 Code: res.StatusCode, 5459 Header: res.Header, 5460 }) 5461 } 5462 if err != nil { 5463 return nil, err 5464 } 5465 defer googleapi.CloseBody(res) 5466 if err := googleapi.CheckResponse(res); err != nil { 5467 return nil, gensupport.WrapError(err) 5468 } 5469 ret := &GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetResponse{ 5470 ServerResponse: googleapi.ServerResponse{ 5471 Header: res.Header, 5472 HTTPStatusCode: res.StatusCode, 5473 }, 5474 } 5475 target := &ret 5476 if err := gensupport.DecodeResponse(target, res); err != nil { 5477 return nil, err 5478 } 5479 return ret, nil 5480 } 5481 5482 // Pages invokes f for each page of results. 5483 // A non-nil error returned from f will halt the iteration. 5484 // The provided context supersedes any context provided to the Context method. 5485 func (c *VitalsStuckbackgroundwakelockrateQueryCall) Pages(ctx context.Context, f func(*GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSetResponse) error) error { 5486 c.ctx_ = ctx 5487 defer func(pt string) { 5488 c.googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest.PageToken = pt 5489 }(c.googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest.PageToken) 5490 for { 5491 x, err := c.Do() 5492 if err != nil { 5493 return err 5494 } 5495 if err := f(x); err != nil { 5496 return err 5497 } 5498 if x.NextPageToken == "" { 5499 return nil 5500 } 5501 c.googleplaydeveloperreportingv1beta1querystuckbackgroundwakelockratemetricsetrequest.PageToken = x.NextPageToken 5502 } 5503 } 5504