Autogenerated update (2020-01-29)

Update:
- firebasehosting_v1beta1
- ml_v1
- pagespeedonline_v5
- spanner_v1
- sql_v1beta4
This commit is contained in:
Google APIs 2020-01-29 00:37:31 +00:00
parent 8432b95ecd
commit 845091fb43
15 changed files with 1147 additions and 768 deletions

View File

@ -27,7 +27,7 @@ module Google
# @see https://firebase.google.com/docs/hosting/
module FirebasehostingV1beta1
VERSION = 'V1beta1'
REVISION = '20191122'
REVISION = '20200127'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -102,6 +102,45 @@ module Google
end
end
# The request sent to CloneVersion.
class CloneVersionRequest
include Google::Apis::Core::Hashable
# A representation of filter path.
# Corresponds to the JSON property `exclude`
# @return [Google::Apis::FirebasehostingV1beta1::PathFilter]
attr_accessor :exclude
# If true, immediately finalize the version after cloning is complete.
# Corresponds to the JSON property `finalize`
# @return [Boolean]
attr_accessor :finalize
alias_method :finalize?, :finalize
# A representation of filter path.
# Corresponds to the JSON property `include`
# @return [Google::Apis::FirebasehostingV1beta1::PathFilter]
attr_accessor :include
# Required. The name of the version to be cloned, in the format:
# `sites/`site`/versions/`version``
# Corresponds to the JSON property `sourceVersion`
# @return [String]
attr_accessor :source_version
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@exclude = args[:exclude] if args.key?(:exclude)
@finalize = args[:finalize] if args.key?(:finalize)
@include = args[:include] if args.key?(:include)
@source_version = args[:source_version] if args.key?(:source_version)
end
end
# A configured rewrite that directs requests to a Cloud Run service. If the
# Cloud Run service does not exist when setting or updating your Firebase
# Hosting configuration, then the request fails. Any errors from the Cloud Run
@ -430,6 +469,89 @@ module Google
end
end
# This resource represents a long-running operation that is the result of a
# network API call.
class Operation
include Google::Apis::Core::Hashable
# If the value is `false`, it means the operation is still in progress.
# If `true`, the operation is completed, and either `error` or `response` is
# available.
# Corresponds to the JSON property `done`
# @return [Boolean]
attr_accessor :done
alias_method :done?, :done
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
# Corresponds to the JSON property `error`
# @return [Google::Apis::FirebasehostingV1beta1::Status]
attr_accessor :error
# Service-specific metadata associated with the operation. It typically
# contains progress information and common metadata such as create time.
# Some services might not provide such metadata. Any method that returns a
# long-running operation should document the metadata type, if any.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,Object>]
attr_accessor :metadata
# The server-assigned name, which is only unique within the same service that
# originally returns it. If you use the default HTTP mapping, the
# `name` should be a resource name ending with `operations/`unique_id``.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The normal response of the operation in case of success. If the original
# method returns no data on success, such as `Delete`, the response is
# `google.protobuf.Empty`. If the original method is standard
# `Get`/`Create`/`Update`, the response should be the resource. For other
# methods, the response should have the type `XxxResponse`, where `Xxx`
# is the original method name. For example, if the original method name
# is `TakeSnapshot()`, the inferred response type is
# `TakeSnapshotResponse`.
# Corresponds to the JSON property `response`
# @return [Hash<String,Object>]
attr_accessor :response
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@done = args[:done] if args.key?(:done)
@error = args[:error] if args.key?(:error)
@metadata = args[:metadata] if args.key?(:metadata)
@name = args[:name] if args.key?(:name)
@response = args[:response] if args.key?(:response)
end
end
# A representation of filter path.
class PathFilter
include Google::Apis::Core::Hashable
# An array of regexes to filter by.
# Corresponds to the JSON property `regexes`
# @return [Array<String>]
attr_accessor :regexes
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@regexes = args[:regexes] if args.key?(:regexes)
end
end
#
class PopulateVersionFilesRequest
include Google::Apis::Core::Hashable
@ -761,6 +883,45 @@ module Google
end
end
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
class Status
include Google::Apis::Core::Hashable
# The status code, which should be an enum value of google.rpc.Code.
# Corresponds to the JSON property `code`
# @return [Fixnum]
attr_accessor :code
# A list of messages that carry the error details. There is a common set of
# message types for APIs to use.
# Corresponds to the JSON property `details`
# @return [Array<Hash<String,Object>>]
attr_accessor :details
# A developer-facing error message, which should be in English. Any
# user-facing error message should be localized and sent in the
# google.rpc.Status.details field, or localized by the client.
# Corresponds to the JSON property `message`
# @return [String]
attr_accessor :message
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@code = args[:code] if args.key?(:code)
@details = args[:details] if args.key?(:details)
@message = args[:message] if args.key?(:message)
end
end
# A `Version` is the collection of configuration and
# [static files](sites.versions.files) that determine how a site is displayed.
class Version

View File

@ -40,6 +40,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class CloneVersionRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CloudRunRewrite
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -100,6 +106,18 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PathFilter
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PopulateVersionFilesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -148,6 +166,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Version
class Representation < Google::Apis::Core::JsonRepresentation; end
@ -184,6 +208,18 @@ module Google
end
end
class CloneVersionRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :exclude, as: 'exclude', class: Google::Apis::FirebasehostingV1beta1::PathFilter, decorator: Google::Apis::FirebasehostingV1beta1::PathFilter::Representation
property :finalize, as: 'finalize'
property :include, as: 'include', class: Google::Apis::FirebasehostingV1beta1::PathFilter, decorator: Google::Apis::FirebasehostingV1beta1::PathFilter::Representation
property :source_version, as: 'sourceVersion'
end
end
class CloudRunRewrite
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -281,6 +317,25 @@ module Google
end
end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :done, as: 'done'
property :error, as: 'error', class: Google::Apis::FirebasehostingV1beta1::Status, decorator: Google::Apis::FirebasehostingV1beta1::Status::Representation
hash :metadata, as: 'metadata'
property :name, as: 'name'
hash :response, as: 'response'
end
end
class PathFilter
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :regexes, as: 'regexes'
end
end
class PopulateVersionFilesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -363,6 +418,15 @@ module Google
end
end
class Status
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :code, as: 'code'
collection :details, as: 'details'
property :message, as: 'message'
end
end
class Version
# @private
class Representation < Google::Apis::Core::JsonRepresentation

View File

@ -49,6 +49,38 @@ module Google
@batch_path = 'batch'
end
# Gets the latest state of a long-running operation. Clients can use this
# method to poll the operation result at intervals as recommended by the API
# service.
# @param [String] name
# The name of the operation resource.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::FirebasehostingV1beta1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebasehostingV1beta1::Operation]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def get_project_operation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1beta1/{+name}', options)
command.response_representation = Google::Apis::FirebasehostingV1beta1::Operation::Representation
command.response_class = Google::Apis::FirebasehostingV1beta1::Operation
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Gets the Hosting metadata for a specific site.
# @param [String] name
# Required. The site for which to get the SiteConfig, in the format:
@ -368,6 +400,41 @@ module Google
execute_or_queue_command(command, &block)
end
# Creates a new version on the target site using the content
# of the specified version.
# @param [String] parent
# Required. The target site where the cloned version will reside,
# in the format: `sites/`site``
# @param [Google::Apis::FirebasehostingV1beta1::CloneVersionRequest] clone_version_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::FirebasehostingV1beta1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebasehostingV1beta1::Operation]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def clone_version(parent, clone_version_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1beta1/{+parent}/versions:clone', options)
command.request_representation = Google::Apis::FirebasehostingV1beta1::CloneVersionRequest::Representation
command.request_object = clone_version_request_object
command.response_representation = Google::Apis::FirebasehostingV1beta1::Operation::Representation
command.response_class = Google::Apis::FirebasehostingV1beta1::Operation
command.params['parent'] = parent unless parent.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Creates a new version for a site.
# @param [String] parent
# Required. The parent to create the version for, in the format:

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/ml/
module MlV1
VERSION = 'V1'
REVISION = '20200124'
REVISION = '20200125'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -1350,7 +1350,7 @@ module Google
# Required. Fully qualified BigQuery table name in the following format:
# "<var>project_id</var>.<var>dataset_name</var>.<var>table_name</var>"
# The specifcied table must already exist, and the "Cloud ML Service Agent"
# The specified table must already exist, and the "Cloud ML Service Agent"
# for your project must have permission to write to it. The table must have
# the following [schema](/bigquery/docs/schemas):
# <table>
@ -2135,10 +2135,28 @@ module Google
class GoogleIamV1Binding
include Google::Apis::Core::Hashable
# Represents an expression text. Example:
# title: "User account presence"
# description: "Determines whether the request has a user account"
# expression: "size(request.user) > 0"
# Represents a textual expression in the Common Expression Language (CEL)
# syntax. CEL is a C-like expression language. The syntax and semantics of CEL
# are documented at https://github.com/google/cel-spec.
# Example (Comparison):
# title: "Summary size limit"
# description: "Determines if a summary is less than 100 chars"
# expression: "document.summary.size() < 100"
# Example (Equality):
# title: "Requestor is owner"
# description: "Determines if requestor is the document owner"
# expression: "document.owner == request.auth.claims.email"
# Example (Logic):
# title: "Public documents"
# description: "Determine whether the document should be publicly visible"
# expression: "document.type != 'private' && document.type != 'internal'"
# Example (Data Manipulation):
# title: "Notification string"
# description: "Create a notification string with a timestamp."
# expression: "'New message received at ' + string(document.create_time)"
# The exact variables and functions that may be referenced within an expression
# are determined by the service that evaluates it. See the service
# documentation for additional information.
# Corresponds to the JSON property `condition`
# @return [Google::Apis::MlV1::GoogleTypeExpr]
attr_accessor :condition
@ -2589,34 +2607,50 @@ module Google
end
end
# Represents an expression text. Example:
# title: "User account presence"
# description: "Determines whether the request has a user account"
# expression: "size(request.user) > 0"
# Represents a textual expression in the Common Expression Language (CEL)
# syntax. CEL is a C-like expression language. The syntax and semantics of CEL
# are documented at https://github.com/google/cel-spec.
# Example (Comparison):
# title: "Summary size limit"
# description: "Determines if a summary is less than 100 chars"
# expression: "document.summary.size() < 100"
# Example (Equality):
# title: "Requestor is owner"
# description: "Determines if requestor is the document owner"
# expression: "document.owner == request.auth.claims.email"
# Example (Logic):
# title: "Public documents"
# description: "Determine whether the document should be publicly visible"
# expression: "document.type != 'private' && document.type != 'internal'"
# Example (Data Manipulation):
# title: "Notification string"
# description: "Create a notification string with a timestamp."
# expression: "'New message received at ' + string(document.create_time)"
# The exact variables and functions that may be referenced within an expression
# are determined by the service that evaluates it. See the service
# documentation for additional information.
class GoogleTypeExpr
include Google::Apis::Core::Hashable
# An optional description of the expression. This is a longer text which
# Optional. Description of the expression. This is a longer text which
# describes the expression, e.g. when hovered over it in a UI.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
# Textual representation of an expression in
# Common Expression Language syntax.
# The application context of the containing message determines which
# well-known feature set of CEL is supported.
# Textual representation of an expression in Common Expression Language
# syntax.
# Corresponds to the JSON property `expression`
# @return [String]
attr_accessor :expression
# An optional string indicating the location of the expression for error
# Optional. String indicating the location of the expression for error
# reporting, e.g. a file name and a position in the file.
# Corresponds to the JSON property `location`
# @return [String]
attr_accessor :location
# An optional title for the expression, i.e. a short string describing
# Optional. Title for the expression, i.e. a short string describing
# its purpose. This can be used e.g. in UIs which allow to enter the
# expression.
# Corresponds to the JSON property `title`

View File

@ -20,13 +20,18 @@ module Google
module Apis
# PageSpeed Insights API
#
# Analyzes the performance of a web page and provides tailored suggestions to
# make that page faster.
# The PageSpeed Insights API lets you analyze the performance of your website
# with a simple API. It offers tailored suggestions for how you can optimize
# your site, and lets you easily integrate PageSpeed Insights analysis into your
# development tools and workflow.
#
# @see https://developers.google.com/speed/docs/insights/v5/get-started
# @see https://developers.google.com/speed/docs/insights/v5/about
module PagespeedonlineV5
VERSION = 'V5'
REVISION = '20191028'
REVISION = '20200117'
# Associate you with your personal info on Google
PENID = 'openid'
end
end
end

View File

@ -22,7 +22,228 @@ module Google
module Apis
module PagespeedonlineV5
#
# A light reference to an audit by id, used to group and weight audits in a
# given category.
class AuditRefs
include Google::Apis::Core::Hashable
# The category group that the audit belongs to (optional).
# Corresponds to the JSON property `group`
# @return [String]
attr_accessor :group
# The audit ref id.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# The weight this audit's score has on the overall category score.
# Corresponds to the JSON property `weight`
# @return [Float]
attr_accessor :weight
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@group = args[:group] if args.key?(:group)
@id = args[:id] if args.key?(:id)
@weight = args[:weight] if args.key?(:weight)
end
end
# A proportion of data in the total distribution, bucketed by a min/max
# percentage. Each bucket's range is bounded by min <= x < max, In
# millisecond.
class Bucket
include Google::Apis::Core::Hashable
# Upper bound for a bucket's range.
# Corresponds to the JSON property `max`
# @return [Fixnum]
attr_accessor :max
# Lower bound for a bucket's range.
# Corresponds to the JSON property `min`
# @return [Fixnum]
attr_accessor :min
# The proportion of data in this bucket.
# Corresponds to the JSON property `proportion`
# @return [Float]
attr_accessor :proportion
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@max = args[:max] if args.key?(:max)
@min = args[:min] if args.key?(:min)
@proportion = args[:proportion] if args.key?(:proportion)
end
end
# The categories in a Lighthouse run.
class Categories
include Google::Apis::Core::Hashable
# A Lighthouse category.
# Corresponds to the JSON property `accessibility`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :accessibility
# A Lighthouse category.
# Corresponds to the JSON property `best-practices`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :best_practices
# A Lighthouse category.
# Corresponds to the JSON property `performance`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :performance
# A Lighthouse category.
# Corresponds to the JSON property `pwa`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :pwa
# A Lighthouse category.
# Corresponds to the JSON property `seo`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :seo
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@accessibility = args[:accessibility] if args.key?(:accessibility)
@best_practices = args[:best_practices] if args.key?(:best_practices)
@performance = args[:performance] if args.key?(:performance)
@pwa = args[:pwa] if args.key?(:pwa)
@seo = args[:seo] if args.key?(:seo)
end
end
# Message containing a category
class CategoryGroupV5
include Google::Apis::Core::Hashable
# The description of what the category is grouping
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
# The human readable title of the group
# Corresponds to the JSON property `title`
# @return [String]
attr_accessor :title
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@description = args[:description] if args.key?(:description)
@title = args[:title] if args.key?(:title)
end
end
# Message containing the configuration settings for the Lighthouse run.
class ConfigSettings
include Google::Apis::Core::Hashable
# How Lighthouse was run, e.g. from the Chrome extension or from the npm
# module.
# Corresponds to the JSON property `channel`
# @return [String]
attr_accessor :channel
# The form factor the emulation should use.
# Corresponds to the JSON property `emulatedFormFactor`
# @return [String]
attr_accessor :emulated_form_factor
# The locale setting.
# Corresponds to the JSON property `locale`
# @return [String]
attr_accessor :locale
# List of categories of audits the run should conduct.
# Corresponds to the JSON property `onlyCategories`
# @return [Object]
attr_accessor :only_categories
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@channel = args[:channel] if args.key?(:channel)
@emulated_form_factor = args[:emulated_form_factor] if args.key?(:emulated_form_factor)
@locale = args[:locale] if args.key?(:locale)
@only_categories = args[:only_categories] if args.key?(:only_categories)
end
end
# Message containing environment configuration for a Lighthouse run.
class Environment
include Google::Apis::Core::Hashable
# The benchmark index number that indicates rough device class.
# Corresponds to the JSON property `benchmarkIndex`
# @return [Float]
attr_accessor :benchmark_index
# The user agent string of the version of Chrome used.
# Corresponds to the JSON property `hostUserAgent`
# @return [String]
attr_accessor :host_user_agent
# The user agent string that was sent over the network.
# Corresponds to the JSON property `networkUserAgent`
# @return [String]
attr_accessor :network_user_agent
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@benchmark_index = args[:benchmark_index] if args.key?(:benchmark_index)
@host_user_agent = args[:host_user_agent] if args.key?(:host_user_agent)
@network_user_agent = args[:network_user_agent] if args.key?(:network_user_agent)
end
end
# Message containing the i18n data for the LHR - Version 1.
class I18n
include Google::Apis::Core::Hashable
# Message holding the formatted strings used in the renderer.
# Corresponds to the JSON property `rendererFormattedStrings`
# @return [Google::Apis::PagespeedonlineV5::RendererFormattedStrings]
attr_accessor :renderer_formatted_strings
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@renderer_formatted_strings = args[:renderer_formatted_strings] if args.key?(:renderer_formatted_strings)
end
end
# An audit's result object in a Lighthouse result.
class LighthouseAuditResultV5
include Google::Apis::Core::Hashable
@ -56,14 +277,14 @@ module Google
# @return [String]
attr_accessor :id
# A numeric value that has a meaning specific to the audit, e.g. the number of
# nodes in the DOM or the timestamp of a specific load event. More information
# can be found in the audit details, if present.
# A numeric value that has a meaning specific to the audit, e.g. the number
# of nodes in the DOM or the timestamp of a specific load event. More
# information can be found in the audit details, if present.
# Corresponds to the JSON property `numericValue`
# @return [Float]
attr_accessor :numeric_value
#
# The score of the audit, can be null.
# Corresponds to the JSON property `score`
# @return [Object]
attr_accessor :score
@ -78,7 +299,7 @@ module Google
# @return [String]
attr_accessor :title
#
# Possible warnings that occurred in the audit, can be null.
# Corresponds to the JSON property `warnings`
# @return [Object]
attr_accessor :warnings
@ -103,13 +324,13 @@ module Google
end
end
#
# A Lighthouse category.
class LighthouseCategoryV5
include Google::Apis::Core::Hashable
# An array of references to all the audit members of this category.
# Corresponds to the JSON property `auditRefs`
# @return [Array<Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::AuditRef>]
# @return [Array<Google::Apis::PagespeedonlineV5::AuditRefs>]
attr_accessor :audit_refs
# A more detailed description of the category and its importance.
@ -127,7 +348,8 @@ module Google
# @return [String]
attr_accessor :manual_description
#
# The overall score of the category, the weighted average of all its audits.
# (The category's score, can be null.)
# Corresponds to the JSON property `score`
# @return [Object]
attr_accessor :score
@ -150,40 +372,9 @@ module Google
@score = args[:score] if args.key?(:score)
@title = args[:title] if args.key?(:title)
end
#
class AuditRef
include Google::Apis::Core::Hashable
# The category group that the audit belongs to (optional).
# Corresponds to the JSON property `group`
# @return [String]
attr_accessor :group
# The audit ref id.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# The weight this audit's score has on the overall category score.
# Corresponds to the JSON property `weight`
# @return [Float]
attr_accessor :weight
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@group = args[:group] if args.key?(:group)
@id = args[:id] if args.key?(:id)
@weight = args[:weight] if args.key?(:weight)
end
end
end
#
# The Lighthouse result object.
class LighthouseResultV5
include Google::Apis::Core::Hashable
@ -192,24 +383,24 @@ module Google
# @return [Hash<String,Google::Apis::PagespeedonlineV5::LighthouseAuditResultV5>]
attr_accessor :audits
# Map of categories in the LHR.
# The categories in a Lighthouse run.
# Corresponds to the JSON property `categories`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5::Categories]
# @return [Google::Apis::PagespeedonlineV5::Categories]
attr_accessor :categories
# Map of category groups in the LHR.
# Corresponds to the JSON property `categoryGroups`
# @return [Hash<String,Google::Apis::PagespeedonlineV5::LighthouseResultV5::CategoryGroup>]
# @return [Hash<String,Google::Apis::PagespeedonlineV5::CategoryGroupV5>]
attr_accessor :category_groups
# The configuration settings for this LHR.
# Message containing the configuration settings for the Lighthouse run.
# Corresponds to the JSON property `configSettings`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5::ConfigSettings]
# @return [Google::Apis::PagespeedonlineV5::ConfigSettings]
attr_accessor :config_settings
# Environment settings that were used when making this LHR.
# Message containing environment configuration for a Lighthouse run.
# Corresponds to the JSON property `environment`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5::Environment]
# @return [Google::Apis::PagespeedonlineV5::Environment]
attr_accessor :environment
# The time that this run was fetched.
@ -222,9 +413,9 @@ module Google
# @return [String]
attr_accessor :final_url
# The internationalization strings that are required to render the LHR.
# Message containing the i18n data for the LHR - Version 1.
# Corresponds to the JSON property `i18n`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5::I18n]
# @return [Google::Apis::PagespeedonlineV5::I18n]
attr_accessor :i18n
# The lighthouse version that was used to generate this LHR.
@ -242,20 +433,19 @@ module Google
# @return [Array<Object>]
attr_accessor :run_warnings
# A top-level error message that, if present, indicates a serious enough problem
# that this Lighthouse result may need to be discarded.
# Message containing a runtime error config.
# Corresponds to the JSON property `runtimeError`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5::RuntimeError]
# @return [Google::Apis::PagespeedonlineV5::RuntimeError]
attr_accessor :runtime_error
# The Stack Pack advice strings.
# Corresponds to the JSON property `stackPacks`
# @return [Array<Google::Apis::PagespeedonlineV5::LighthouseResultV5::StackPack>]
# @return [Array<Google::Apis::PagespeedonlineV5::StackPack>]
attr_accessor :stack_packs
# Timing information for this LHR.
# Message containing the performance timing data for the Lighthouse run.
# Corresponds to the JSON property `timing`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5::Timing]
# @return [Google::Apis::PagespeedonlineV5::Timing]
attr_accessor :timing
# The user agent that was used to run this LHR.
@ -285,36 +475,31 @@ module Google
@timing = args[:timing] if args.key?(:timing)
@user_agent = args[:user_agent] if args.key?(:user_agent)
end
end
# Map of categories in the LHR.
class Categories
# The CrUX loading experience object that contains CrUX data breakdowns.
class PagespeedApiLoadingExperienceV5
include Google::Apis::Core::Hashable
# The accessibility category, containing all accessibility related audits.
# Corresponds to the JSON property `accessibility`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :accessibility
# The url, pattern or origin which the metrics are on.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# The best practices category, containing all web best practice related audits.
# Corresponds to the JSON property `best-practices`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :best_practices
# The requested URL, which may differ from the resolved "id".
# Corresponds to the JSON property `initial_url`
# @return [String]
attr_accessor :initial_url
# The performance category, containing all performance related audits.
# Corresponds to the JSON property `performance`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :performance
# The map of <metrics, data>.
# Corresponds to the JSON property `metrics`
# @return [Hash<String,Google::Apis::PagespeedonlineV5::UserPageLoadMetricV5>]
attr_accessor :metrics
# The Progressive-Web-App (PWA) category, containing all pwa related audits.
# Corresponds to the JSON property `pwa`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :pwa
# The Search-Engine-Optimization (SEO) category, containing all seo related
# audits.
# Corresponds to the JSON property `seo`
# @return [Google::Apis::PagespeedonlineV5::LighthouseCategoryV5]
attr_accessor :seo
# The human readable speed "category" of the id.
# Corresponds to the JSON property `overall_category`
# @return [String]
attr_accessor :overall_category
def initialize(**args)
update!(**args)
@ -322,27 +507,57 @@ module Google
# Update properties of this object
def update!(**args)
@accessibility = args[:accessibility] if args.key?(:accessibility)
@best_practices = args[:best_practices] if args.key?(:best_practices)
@performance = args[:performance] if args.key?(:performance)
@pwa = args[:pwa] if args.key?(:pwa)
@seo = args[:seo] if args.key?(:seo)
@id = args[:id] if args.key?(:id)
@initial_url = args[:initial_url] if args.key?(:initial_url)
@metrics = args[:metrics] if args.key?(:metrics)
@overall_category = args[:overall_category] if args.key?(:overall_category)
end
end
# A grouping contained in a category that groups similar audits together.
class CategoryGroup
# The Pagespeed API response object.
class PagespeedApiPagespeedResponseV5
include Google::Apis::Core::Hashable
# An optional human readable description of the category group.
# Corresponds to the JSON property `description`
# The UTC timestamp of this analysis.
# Corresponds to the JSON property `analysisUTCTimestamp`
# @return [String]
attr_accessor :description
attr_accessor :analysis_utc_timestamp
# The title of the category group.
# Corresponds to the JSON property `title`
# The captcha verify result
# Corresponds to the JSON property `captchaResult`
# @return [String]
attr_accessor :title
attr_accessor :captcha_result
# Canonicalized and final URL for the document, after following page
# redirects (if any).
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# Kind of result.
# Corresponds to the JSON property `kind`
# @return [String]
attr_accessor :kind
# The Lighthouse result object.
# Corresponds to the JSON property `lighthouseResult`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5]
attr_accessor :lighthouse_result
# The CrUX loading experience object that contains CrUX data breakdowns.
# Corresponds to the JSON property `loadingExperience`
# @return [Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5]
attr_accessor :loading_experience
# The CrUX loading experience object that contains CrUX data breakdowns.
# Corresponds to the JSON property `originLoadingExperience`
# @return [Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5]
attr_accessor :origin_loading_experience
# The Pagespeed Version object.
# Corresponds to the JSON property `version`
# @return [Google::Apis::PagespeedonlineV5::PagespeedVersion]
attr_accessor :version
def initialize(**args)
update!(**args)
@ -350,29 +565,30 @@ module Google
# Update properties of this object
def update!(**args)
@description = args[:description] if args.key?(:description)
@title = args[:title] if args.key?(:title)
@analysis_utc_timestamp = args[:analysis_utc_timestamp] if args.key?(:analysis_utc_timestamp)
@captcha_result = args[:captcha_result] if args.key?(:captcha_result)
@id = args[:id] if args.key?(:id)
@kind = args[:kind] if args.key?(:kind)
@lighthouse_result = args[:lighthouse_result] if args.key?(:lighthouse_result)
@loading_experience = args[:loading_experience] if args.key?(:loading_experience)
@origin_loading_experience = args[:origin_loading_experience] if args.key?(:origin_loading_experience)
@version = args[:version] if args.key?(:version)
end
end
# The configuration settings for this LHR.
class ConfigSettings
# The Pagespeed Version object.
class PagespeedVersion
include Google::Apis::Core::Hashable
# The form factor the emulation should use.
# Corresponds to the JSON property `emulatedFormFactor`
# The major version number of PageSpeed used to generate these results.
# Corresponds to the JSON property `major`
# @return [String]
attr_accessor :emulated_form_factor
attr_accessor :major
# The locale setting.
# Corresponds to the JSON property `locale`
# The minor version number of PageSpeed used to generate these results.
# Corresponds to the JSON property `minor`
# @return [String]
attr_accessor :locale
#
# Corresponds to the JSON property `onlyCategories`
# @return [Object]
attr_accessor :only_categories
attr_accessor :minor
def initialize(**args)
update!(**args)
@ -380,62 +596,12 @@ module Google
# Update properties of this object
def update!(**args)
@emulated_form_factor = args[:emulated_form_factor] if args.key?(:emulated_form_factor)
@locale = args[:locale] if args.key?(:locale)
@only_categories = args[:only_categories] if args.key?(:only_categories)
@major = args[:major] if args.key?(:major)
@minor = args[:minor] if args.key?(:minor)
end
end
# Environment settings that were used when making this LHR.
class Environment
include Google::Apis::Core::Hashable
# The benchmark index number that indicates rough device class.
# Corresponds to the JSON property `benchmarkIndex`
# @return [Float]
attr_accessor :benchmark_index
# The user agent string of the version of Chrome used.
# Corresponds to the JSON property `hostUserAgent`
# @return [String]
attr_accessor :host_user_agent
# The user agent string that was sent over the network.
# Corresponds to the JSON property `networkUserAgent`
# @return [String]
attr_accessor :network_user_agent
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@benchmark_index = args[:benchmark_index] if args.key?(:benchmark_index)
@host_user_agent = args[:host_user_agent] if args.key?(:host_user_agent)
@network_user_agent = args[:network_user_agent] if args.key?(:network_user_agent)
end
end
# The internationalization strings that are required to render the LHR.
class I18n
include Google::Apis::Core::Hashable
# Internationalized strings that are formatted to the locale in configSettings.
# Corresponds to the JSON property `rendererFormattedStrings`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5::I18n::RendererFormattedStrings]
attr_accessor :renderer_formatted_strings
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@renderer_formatted_strings = args[:renderer_formatted_strings] if args.key?(:renderer_formatted_strings)
end
# Internationalized strings that are formatted to the locale in configSettings.
# Message holding the formatted strings used in the renderer.
class RendererFormattedStrings
include Google::Apis::Core::Hashable
@ -469,12 +635,14 @@ module Google
# @return [String]
attr_accessor :lab_data_title
# The disclaimer shown under performance explaning that the network can vary.
# The disclaimer shown under performance explaning that the network can
# vary.
# Corresponds to the JSON property `lsPerformanceCategoryDescription`
# @return [String]
attr_accessor :ls_performance_category_description
# The heading shown above a list of audits that were not computerd in the run.
# The heading shown above a list of audits that were not computerd in the
# run.
# Corresponds to the JSON property `manualAuditsGroupTitle`
# @return [String]
attr_accessor :manual_audits_group_title
@ -484,7 +652,8 @@ module Google
# @return [String]
attr_accessor :not_applicable_audits_group_title
# The heading for the estimated page load savings opportunity of an audit.
# The heading for the estimated page load savings opportunity of an
# audit.
# Corresponds to the JSON property `opportunityResourceColumnLabel`
# @return [String]
attr_accessor :opportunity_resource_column_label
@ -504,8 +673,8 @@ module Google
# @return [String]
attr_accessor :scorescale_label
# The label shown preceding important warnings that may have invalidated an
# entire report.
# The label shown preceding important warnings that may have invalidated
# an entire report.
# Corresponds to the JSON property `toplevelWarningsMessage`
# @return [String]
attr_accessor :toplevel_warnings_message
@ -544,10 +713,8 @@ module Google
@warning_header = args[:warning_header] if args.key?(:warning_header)
end
end
end
# A top-level error message that, if present, indicates a serious enough problem
# that this Lighthouse result may need to be discarded.
# Message containing a runtime error config.
class RuntimeError
include Google::Apis::Core::Hashable
@ -572,7 +739,7 @@ module Google
end
end
#
# Message containing Stack Pack information.
class StackPack
include Google::Apis::Core::Hashable
@ -609,7 +776,7 @@ module Google
end
end
# Timing information for this LHR.
# Message containing the performance timing data for the Lighthouse run.
class Timing
include Google::Apis::Core::Hashable
@ -627,59 +794,39 @@ module Google
@total = args[:total] if args.key?(:total)
end
end
end
#
class PagespeedApiLoadingExperienceV5
# A CrUX metric object for a single metric and form factor.
class UserPageLoadMetricV5
include Google::Apis::Core::Hashable
# The url, pattern or origin which the metrics are on.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
#
# Corresponds to the JSON property `initial_url`
# @return [String]
attr_accessor :initial_url
#
# Corresponds to the JSON property `metrics`
# @return [Hash<String,Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Metric>]
attr_accessor :metrics
#
# Corresponds to the JSON property `overall_category`
# @return [String]
attr_accessor :overall_category
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@id = args[:id] if args.key?(:id)
@initial_url = args[:initial_url] if args.key?(:initial_url)
@metrics = args[:metrics] if args.key?(:metrics)
@overall_category = args[:overall_category] if args.key?(:overall_category)
end
# The type of the metric.
class Metric
include Google::Apis::Core::Hashable
#
# The category of the specific time metric.
# Corresponds to the JSON property `category`
# @return [String]
attr_accessor :category
#
# Metric distributions. Proportions should sum up to 1.
# Corresponds to the JSON property `distributions`
# @return [Array<Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Metric::Distribution>]
# @return [Array<Google::Apis::PagespeedonlineV5::Bucket>]
attr_accessor :distributions
#
# Identifies the form factor of the metric being collected.
# Corresponds to the JSON property `formFactor`
# @return [String]
attr_accessor :form_factor
# The median number of the metric, in millisecond.
# Corresponds to the JSON property `median`
# @return [Fixnum]
attr_accessor :median
# Identifies the type of the metric.
# Corresponds to the JSON property `metricId`
# @return [String]
attr_accessor :metric_id
# We use this field to store certain percentile value for this metric.
# For v4, this field contains pc50.
# For v5, this field contains pc90.
# Corresponds to the JSON property `percentile`
# @return [Fixnum]
attr_accessor :percentile
@ -692,127 +839,11 @@ module Google
def update!(**args)
@category = args[:category] if args.key?(:category)
@distributions = args[:distributions] if args.key?(:distributions)
@form_factor = args[:form_factor] if args.key?(:form_factor)
@median = args[:median] if args.key?(:median)
@metric_id = args[:metric_id] if args.key?(:metric_id)
@percentile = args[:percentile] if args.key?(:percentile)
end
#
class Distribution
include Google::Apis::Core::Hashable
#
# Corresponds to the JSON property `max`
# @return [Fixnum]
attr_accessor :max
#
# Corresponds to the JSON property `min`
# @return [Fixnum]
attr_accessor :min
#
# Corresponds to the JSON property `proportion`
# @return [Float]
attr_accessor :proportion
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@max = args[:max] if args.key?(:max)
@min = args[:min] if args.key?(:min)
@proportion = args[:proportion] if args.key?(:proportion)
end
end
end
end
#
class PagespeedApiPagespeedResponseV5
include Google::Apis::Core::Hashable
# The UTC timestamp of this analysis.
# Corresponds to the JSON property `analysisUTCTimestamp`
# @return [String]
attr_accessor :analysis_utc_timestamp
# The captcha verify result
# Corresponds to the JSON property `captchaResult`
# @return [String]
attr_accessor :captcha_result
# Canonicalized and final URL for the document, after following page redirects (
# if any).
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# Kind of result.
# Corresponds to the JSON property `kind`
# @return [String]
attr_accessor :kind
# Lighthouse response for the audit url as an object.
# Corresponds to the JSON property `lighthouseResult`
# @return [Google::Apis::PagespeedonlineV5::LighthouseResultV5]
attr_accessor :lighthouse_result
# Metrics of end users' page loading experience.
# Corresponds to the JSON property `loadingExperience`
# @return [Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5]
attr_accessor :loading_experience
# Metrics of the aggregated page loading experience of the origin
# Corresponds to the JSON property `originLoadingExperience`
# @return [Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5]
attr_accessor :origin_loading_experience
# The version of PageSpeed used to generate these results.
# Corresponds to the JSON property `version`
# @return [Google::Apis::PagespeedonlineV5::PagespeedApiPagespeedResponseV5::Version]
attr_accessor :version
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@analysis_utc_timestamp = args[:analysis_utc_timestamp] if args.key?(:analysis_utc_timestamp)
@captcha_result = args[:captcha_result] if args.key?(:captcha_result)
@id = args[:id] if args.key?(:id)
@kind = args[:kind] if args.key?(:kind)
@lighthouse_result = args[:lighthouse_result] if args.key?(:lighthouse_result)
@loading_experience = args[:loading_experience] if args.key?(:loading_experience)
@origin_loading_experience = args[:origin_loading_experience] if args.key?(:origin_loading_experience)
@version = args[:version] if args.key?(:version)
end
# The version of PageSpeed used to generate these results.
class Version
include Google::Apis::Core::Hashable
# The major version number of PageSpeed used to generate these results.
# Corresponds to the JSON property `major`
# @return [Fixnum]
attr_accessor :major
# The minor version number of PageSpeed used to generate these results.
# Corresponds to the JSON property `minor`
# @return [Fixnum]
attr_accessor :minor
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@major = args[:major] if args.key?(:major)
@minor = args[:minor] if args.key?(:minor)
end
end
end
end
end

View File

@ -22,34 +22,25 @@ module Google
module Apis
module PagespeedonlineV5
class LighthouseAuditResultV5
class AuditRefs
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LighthouseCategoryV5
class Representation < Google::Apis::Core::JsonRepresentation; end
class AuditRef
class Bucket
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
include Google::Apis::Core::JsonObjectSupport
end
class LighthouseResultV5
class Representation < Google::Apis::Core::JsonRepresentation; end
class Categories
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CategoryGroup
class CategoryGroupV5
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
@ -70,12 +61,48 @@ module Google
class I18n
class Representation < Google::Apis::Core::JsonRepresentation; end
class RendererFormattedStrings
include Google::Apis::Core::JsonObjectSupport
end
class LighthouseAuditResultV5
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LighthouseCategoryV5
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LighthouseResultV5
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PagespeedApiLoadingExperienceV5
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PagespeedApiPagespeedResponseV5
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PagespeedVersion
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RendererFormattedStrings
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
@ -97,37 +124,79 @@ module Google
include Google::Apis::Core::JsonObjectSupport
end
include Google::Apis::Core::JsonObjectSupport
end
class PagespeedApiLoadingExperienceV5
class Representation < Google::Apis::Core::JsonRepresentation; end
class Metric
class Representation < Google::Apis::Core::JsonRepresentation; end
class Distribution
class UserPageLoadMetricV5
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
include Google::Apis::Core::JsonObjectSupport
class AuditRefs
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :group, as: 'group'
property :id, as: 'id'
property :weight, as: 'weight'
end
end
include Google::Apis::Core::JsonObjectSupport
class Bucket
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :max, as: 'max'
property :min, as: 'min'
property :proportion, as: 'proportion'
end
end
class PagespeedApiPagespeedResponseV5
class Representation < Google::Apis::Core::JsonRepresentation; end
class Categories
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :accessibility, as: 'accessibility', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
class Version
class Representation < Google::Apis::Core::JsonRepresentation; end
property :best_practices, as: 'best-practices', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
include Google::Apis::Core::JsonObjectSupport
property :performance, as: 'performance', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
property :pwa, as: 'pwa', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
property :seo, as: 'seo', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
end
end
include Google::Apis::Core::JsonObjectSupport
class CategoryGroupV5
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :description, as: 'description'
property :title, as: 'title'
end
end
class ConfigSettings
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :channel, as: 'channel'
property :emulated_form_factor, as: 'emulatedFormFactor'
property :locale, as: 'locale'
property :only_categories, as: 'onlyCategories'
end
end
class Environment
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :benchmark_index, as: 'benchmarkIndex'
property :host_user_agent, as: 'hostUserAgent'
property :network_user_agent, as: 'networkUserAgent'
end
end
class I18n
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :renderer_formatted_strings, as: 'rendererFormattedStrings', class: Google::Apis::PagespeedonlineV5::RendererFormattedStrings, decorator: Google::Apis::PagespeedonlineV5::RendererFormattedStrings::Representation
end
end
class LighthouseAuditResultV5
@ -150,7 +219,7 @@ module Google
class LighthouseCategoryV5
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :audit_refs, as: 'auditRefs', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::AuditRef, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::AuditRef::Representation
collection :audit_refs, as: 'auditRefs', class: Google::Apis::PagespeedonlineV5::AuditRefs, decorator: Google::Apis::PagespeedonlineV5::AuditRefs::Representation
property :description, as: 'description'
property :id, as: 'id'
@ -158,15 +227,6 @@ module Google
property :score, as: 'score'
property :title, as: 'title'
end
class AuditRef
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :group, as: 'group'
property :id, as: 'id'
property :weight, as: 'weight'
end
end
end
class LighthouseResultV5
@ -174,79 +234,68 @@ module Google
class Representation < Google::Apis::Core::JsonRepresentation
hash :audits, as: 'audits', class: Google::Apis::PagespeedonlineV5::LighthouseAuditResultV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseAuditResultV5::Representation
property :categories, as: 'categories', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Categories, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Categories::Representation
property :categories, as: 'categories', class: Google::Apis::PagespeedonlineV5::Categories, decorator: Google::Apis::PagespeedonlineV5::Categories::Representation
hash :category_groups, as: 'categoryGroups', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::CategoryGroup, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::CategoryGroup::Representation
hash :category_groups, as: 'categoryGroups', class: Google::Apis::PagespeedonlineV5::CategoryGroupV5, decorator: Google::Apis::PagespeedonlineV5::CategoryGroupV5::Representation
property :config_settings, as: 'configSettings', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::ConfigSettings, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::ConfigSettings::Representation
property :config_settings, as: 'configSettings', class: Google::Apis::PagespeedonlineV5::ConfigSettings, decorator: Google::Apis::PagespeedonlineV5::ConfigSettings::Representation
property :environment, as: 'environment', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Environment, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Environment::Representation
property :environment, as: 'environment', class: Google::Apis::PagespeedonlineV5::Environment, decorator: Google::Apis::PagespeedonlineV5::Environment::Representation
property :fetch_time, as: 'fetchTime'
property :final_url, as: 'finalUrl'
property :i18n, as: 'i18n', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::I18n, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::I18n::Representation
property :i18n, as: 'i18n', class: Google::Apis::PagespeedonlineV5::I18n, decorator: Google::Apis::PagespeedonlineV5::I18n::Representation
property :lighthouse_version, as: 'lighthouseVersion'
property :requested_url, as: 'requestedUrl'
collection :run_warnings, as: 'runWarnings'
property :runtime_error, as: 'runtimeError', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::RuntimeError, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::RuntimeError::Representation
property :runtime_error, as: 'runtimeError', class: Google::Apis::PagespeedonlineV5::RuntimeError, decorator: Google::Apis::PagespeedonlineV5::RuntimeError::Representation
collection :stack_packs, as: 'stackPacks', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::StackPack, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::StackPack::Representation
collection :stack_packs, as: 'stackPacks', class: Google::Apis::PagespeedonlineV5::StackPack, decorator: Google::Apis::PagespeedonlineV5::StackPack::Representation
property :timing, as: 'timing', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Timing, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Timing::Representation
property :timing, as: 'timing', class: Google::Apis::PagespeedonlineV5::Timing, decorator: Google::Apis::PagespeedonlineV5::Timing::Representation
property :user_agent, as: 'userAgent'
end
end
class Categories
class PagespeedApiLoadingExperienceV5
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :accessibility, as: 'accessibility', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
property :best_practices, as: 'best-practices', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
property :performance, as: 'performance', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
property :pwa, as: 'pwa', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
property :seo, as: 'seo', class: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseCategoryV5::Representation
property :id, as: 'id'
property :initial_url, as: 'initial_url'
hash :metrics, as: 'metrics', class: Google::Apis::PagespeedonlineV5::UserPageLoadMetricV5, decorator: Google::Apis::PagespeedonlineV5::UserPageLoadMetricV5::Representation
property :overall_category, as: 'overall_category'
end
end
class CategoryGroup
class PagespeedApiPagespeedResponseV5
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :description, as: 'description'
property :title, as: 'title'
property :analysis_utc_timestamp, as: 'analysisUTCTimestamp'
property :captcha_result, as: 'captchaResult'
property :id, as: 'id'
property :kind, as: 'kind'
property :lighthouse_result, as: 'lighthouseResult', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Representation
property :loading_experience, as: 'loadingExperience', class: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5, decorator: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Representation
property :origin_loading_experience, as: 'originLoadingExperience', class: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5, decorator: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Representation
property :version, as: 'version', class: Google::Apis::PagespeedonlineV5::PagespeedVersion, decorator: Google::Apis::PagespeedonlineV5::PagespeedVersion::Representation
end
end
class ConfigSettings
class PagespeedVersion
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :emulated_form_factor, as: 'emulatedFormFactor'
property :locale, as: 'locale'
property :only_categories, as: 'onlyCategories'
property :major, as: 'major'
property :minor, as: 'minor'
end
end
class Environment
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :benchmark_index, as: 'benchmarkIndex'
property :host_user_agent, as: 'hostUserAgent'
property :network_user_agent, as: 'networkUserAgent'
end
end
class I18n
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :renderer_formatted_strings, as: 'rendererFormattedStrings', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5::I18n::RendererFormattedStrings, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::I18n::RendererFormattedStrings::Representation
end
class RendererFormattedStrings
# @private
class Representation < Google::Apis::Core::JsonRepresentation
@ -268,7 +317,6 @@ module Google
property :warning_header, as: 'warningHeader'
end
end
end
class RuntimeError
# @private
@ -294,62 +342,18 @@ module Google
property :total, as: 'total'
end
end
end
class PagespeedApiLoadingExperienceV5
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
property :initial_url, as: 'initial_url'
hash :metrics, as: 'metrics', class: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Metric, decorator: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Metric::Representation
property :overall_category, as: 'overall_category'
end
class Metric
class UserPageLoadMetricV5
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :category, as: 'category'
collection :distributions, as: 'distributions', class: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Metric::Distribution, decorator: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Metric::Distribution::Representation
collection :distributions, as: 'distributions', class: Google::Apis::PagespeedonlineV5::Bucket, decorator: Google::Apis::PagespeedonlineV5::Bucket::Representation
property :form_factor, as: 'formFactor'
property :median, as: 'median'
property :metric_id, as: 'metricId'
property :percentile, as: 'percentile'
end
class Distribution
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :max, as: 'max'
property :min, as: 'min'
property :proportion, as: 'proportion'
end
end
end
end
class PagespeedApiPagespeedResponseV5
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :analysis_utc_timestamp, as: 'analysisUTCTimestamp'
property :captcha_result, as: 'captchaResult'
property :id, as: 'id'
property :kind, as: 'kind'
property :lighthouse_result, as: 'lighthouseResult', class: Google::Apis::PagespeedonlineV5::LighthouseResultV5, decorator: Google::Apis::PagespeedonlineV5::LighthouseResultV5::Representation
property :loading_experience, as: 'loadingExperience', class: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5, decorator: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Representation
property :origin_loading_experience, as: 'originLoadingExperience', class: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5, decorator: Google::Apis::PagespeedonlineV5::PagespeedApiLoadingExperienceV5::Representation
property :version, as: 'version', class: Google::Apis::PagespeedonlineV5::PagespeedApiPagespeedResponseV5::Version, decorator: Google::Apis::PagespeedonlineV5::PagespeedApiPagespeedResponseV5::Version::Representation
end
class Version
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :major, as: 'major'
property :minor, as: 'minor'
end
end
end
end
end

View File

@ -22,48 +22,49 @@ module Google
module PagespeedonlineV5
# PageSpeed Insights API
#
# Analyzes the performance of a web page and provides tailored suggestions to
# make that page faster.
# The PageSpeed Insights API lets you analyze the performance of your website
# with a simple API. It offers tailored suggestions for how you can optimize
# your site, and lets you easily integrate PageSpeed Insights analysis into your
# development tools and workflow.
#
# @example
# require 'google/apis/pagespeedonline_v5'
#
# Pagespeedonline = Google::Apis::PagespeedonlineV5 # Alias the module
# service = Pagespeedonline::PagespeedonlineService.new
# service = Pagespeedonline::PagespeedInsightsService.new
#
# @see https://developers.google.com/speed/docs/insights/v5/get-started
class PagespeedonlineService < Google::Apis::Core::BaseService
# @see https://developers.google.com/speed/docs/insights/v5/about
class PagespeedInsightsService < Google::Apis::Core::BaseService
# @return [String]
# API key. Your API key identifies your project and provides you with API access,
# quota, and reports. Required unless you provide an OAuth 2.0 token.
attr_accessor :key
# @return [String]
# An opaque string that represents a user for quota purposes. Must not exceed 40
# characters.
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
attr_accessor :quota_user
# @return [String]
# Deprecated. Please use quotaUser instead.
attr_accessor :user_ip
def initialize
super('https://www.googleapis.com/', 'pagespeedonline/v5/')
@batch_path = 'batch/pagespeedonline/v5'
super('https://pagespeedonline.googleapis.com/', '')
@batch_path = 'batch'
end
# Runs PageSpeed analysis on the page at the specified URL, and returns
# PageSpeed scores, a list of suggestions to make that page faster, and other
# information.
# @param [String] url
# The URL to fetch and analyze
# @param [String] captcha_token
# The captcha token passed when filling out a captcha.
# @param [Array<String>, String] category
# A Lighthouse category to run; if none are given, only Performance category
# will be run
# @param [String] locale
# The locale used to localize formatted results
# @param [String] strategy
# The analysis strategy (desktop or mobile) to use, and desktop is the default
# The analysis strategy (desktop or mobile) to use, and desktop is the
# default
# @param [String] url
# The URL to fetch and analyze
# @param [String] utm_campaign
# Campaign name for analytics.
# @param [String] utm_source
@ -71,10 +72,8 @@ module Google
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# An opaque string that represents a user for quota purposes. Must not exceed 40
# characters.
# @param [String] user_ip
# Deprecated. Please use quotaUser instead.
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
@ -87,10 +86,11 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def runpagespeed_pagespeedapi(url, category: nil, locale: nil, strategy: nil, utm_campaign: nil, utm_source: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:get, 'runPagespeed', options)
def runpagespeed_pagespeedapi(captcha_token: nil, category: nil, locale: nil, strategy: nil, url: nil, utm_campaign: nil, utm_source: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'pagespeedonline/v5/runPagespeed', options)
command.response_representation = Google::Apis::PagespeedonlineV5::PagespeedApiPagespeedResponseV5::Representation
command.response_class = Google::Apis::PagespeedonlineV5::PagespeedApiPagespeedResponseV5
command.query['captchaToken'] = captcha_token unless captcha_token.nil?
command.query['category'] = category unless category.nil?
command.query['locale'] = locale unless locale.nil?
command.query['strategy'] = strategy unless strategy.nil?
@ -99,7 +99,6 @@ module Google
command.query['utm_source'] = utm_source unless utm_source.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['userIp'] = user_ip unless user_ip.nil?
execute_or_queue_command(command, &block)
end
@ -108,7 +107,6 @@ module Google
def apply_command_defaults(command)
command.query['key'] = key unless key.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['userIp'] = user_ip unless user_ip.nil?
end
end
end

View File

@ -26,7 +26,7 @@ module Google
# @see https://cloud.google.com/spanner/
module SpannerV1
VERSION = 'V1'
REVISION = '20191216'
REVISION = '20200119'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -1370,7 +1370,7 @@ module Google
# limit.
# Active sessions use additional server resources, so it is a good idea to
# delete idle and unneeded sessions.
# Aside from explicit deletes, Cloud Spanner can delete sessions for which no
# Aside from explicit deletes, Cloud Spanner may delete sessions for which no
# operations are sent for more than an hour. If a session is deleted,
# requests to it return `NOT_FOUND`.
# Idle sessions can be kept alive by sending a trivial SQL query

View File

@ -25,7 +25,7 @@ module Google
# @see https://developers.google.com/cloud-sql/
module SqlV1beta4
VERSION = 'V1beta4'
REVISION = '20200104'
REVISION = '20200124'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -113,6 +113,12 @@ module Google
# @return [String]
attr_accessor :location
# Reserved for future use.
# Corresponds to the JSON property `pointInTimeRecoveryEnabled`
# @return [Boolean]
attr_accessor :point_in_time_recovery_enabled
alias_method :point_in_time_recovery_enabled?, :point_in_time_recovery_enabled
# Reserved for future use.
# Corresponds to the JSON property `replicationLogArchivingEnabled`
# @return [Boolean]
@ -135,6 +141,7 @@ module Google
@enabled = args[:enabled] if args.key?(:enabled)
@kind = args[:kind] if args.key?(:kind)
@location = args[:location] if args.key?(:location)
@point_in_time_recovery_enabled = args[:point_in_time_recovery_enabled] if args.key?(:point_in_time_recovery_enabled)
@replication_log_archiving_enabled = args[:replication_log_archiving_enabled] if args.key?(:replication_log_archiving_enabled)
@start_time = args[:start_time] if args.key?(:start_time)
end
@ -339,6 +346,11 @@ module Google
# @return [Fixnum]
attr_accessor :pitr_timestamp_ms
# Reserved for future use.
# Corresponds to the JSON property `pointInTime`
# @return [String]
attr_accessor :point_in_time
def initialize(**args)
update!(**args)
end
@ -349,6 +361,7 @@ module Google
@destination_instance_name = args[:destination_instance_name] if args.key?(:destination_instance_name)
@kind = args[:kind] if args.key?(:kind)
@pitr_timestamp_ms = args[:pitr_timestamp_ms] if args.key?(:pitr_timestamp_ms)
@point_in_time = args[:point_in_time] if args.key?(:point_in_time)
end
end

View File

@ -455,6 +455,7 @@ module Google
property :enabled, as: 'enabled'
property :kind, as: 'kind'
property :location, as: 'location'
property :point_in_time_recovery_enabled, as: 'pointInTimeRecoveryEnabled'
property :replication_log_archiving_enabled, as: 'replicationLogArchivingEnabled'
property :start_time, as: 'startTime'
end
@ -511,6 +512,7 @@ module Google
property :destination_instance_name, as: 'destinationInstanceName'
property :kind, as: 'kind'
property :pitr_timestamp_ms, :numeric_string => true, as: 'pitrTimestampMs'
property :point_in_time, as: 'pointInTime'
end
end