Regen APIs & bump version

This commit is contained in:
Steve Bazyl 2017-03-31 12:53:27 -07:00
parent 51b41edb1c
commit 70236aca40
174 changed files with 45619 additions and 46124 deletions

View File

@ -1,3 +1,28 @@
# 0.10.3
* Regenerate APIs
* Enable additional API:
* `acceleratedmobilepageurl:v1``
* `appengine:v1`
* `clouderrorreporting:v1beta1`
* `cloudfunctions:v1`
* `firebasedynamiclinks:v1`
* `firebaserules:v1`
* `language:v1`
* `logging:v2`
* `ml:v1`
* `runtimeconfig:v1`
* `searchconsole:v1`
* `servicecontrol:v1`
* `servicemanagement:v1`
* `serviceuser:v1`
* `sourcerepo:v1`
* `spanner:v1`
* `surveys:v2`
* `tagmanager:v2`
* `toolresults:v1beta3`
* `tracing:v1`
* `webfonts:v1`
# 0.10.2 # 0.10.2
* Regenerate APIs * Regenerate APIs

View File

@ -1429,7 +1429,7 @@
"/resourceviews:v1beta2/ZoneViewsRemoveResourcesRequest": remove_resources_request "/resourceviews:v1beta2/ZoneViewsRemoveResourcesRequest": remove_resources_request
"/resourceviews:v1beta2/ZoneViewsSetServiceRequest": set_service_request "/resourceviews:v1beta2/ZoneViewsSetServiceRequest": set_service_request
"/script:v1/ExecutionResponse/status": status "/script:v1/ExecutionResponse/status": status
"/servicemanagement:v1/servicemanagement.services.getConfig": get_service_configuration" "/servicemanagement:v1/servicemanagement.services.getConfig": get_service_configuration
"/sheets:v4/sheets.spreadsheets.sheets.copyTo": copy_spreadsheet "/sheets:v4/sheets.spreadsheets.sheets.copyTo": copy_spreadsheet
"/sheets:v4/sheets.spreadsheets.values.batchGet": batch_get_spreadsheet_values "/sheets:v4/sheets.spreadsheets.values.batchGet": batch_get_spreadsheet_values
"/sheets:v4/sheets.spreadsheets.values.get": get_spreadsheet_values "/sheets:v4/sheets.spreadsheets.values.get": get_spreadsheet_values

File diff suppressed because it is too large Load Diff

View File

@ -22,6 +22,66 @@ module Google
module Apis module Apis
module AcceleratedmobilepageurlV1 module AcceleratedmobilepageurlV1
# Batch AMP URL response.
class BatchGetAmpUrlsResponse
include Google::Apis::Core::Hashable
# For each URL in BatchAmpUrlsRequest, the URL response. The response might
# not be in the same order as URLs in the batch request.
# If BatchAmpUrlsRequest contains duplicate URLs, AmpUrl is generated
# only once.
# Corresponds to the JSON property `ampUrls`
# @return [Array<Google::Apis::AcceleratedmobilepageurlV1::AmpUrl>]
attr_accessor :amp_urls
# The errors for requested URLs that have no AMP URL.
# Corresponds to the JSON property `urlErrors`
# @return [Array<Google::Apis::AcceleratedmobilepageurlV1::AmpUrlError>]
attr_accessor :url_errors
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@amp_urls = args[:amp_urls] if args.key?(:amp_urls)
@url_errors = args[:url_errors] if args.key?(:url_errors)
end
end
# AMP URL response for a requested URL.
class AmpUrl
include Google::Apis::Core::Hashable
# The [AMP Cache URL](/amp/cache/overview#amp-cache-url-format) pointing to
# the cached document in the Google AMP Cache.
# Corresponds to the JSON property `cdnAmpUrl`
# @return [String]
attr_accessor :cdn_amp_url
# The original non-AMP URL.
# Corresponds to the JSON property `originalUrl`
# @return [String]
attr_accessor :original_url
# The AMP URL pointing to the publisher's web server.
# Corresponds to the JSON property `ampUrl`
# @return [String]
attr_accessor :amp_url
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@cdn_amp_url = args[:cdn_amp_url] if args.key?(:cdn_amp_url)
@original_url = args[:original_url] if args.key?(:original_url)
@amp_url = args[:amp_url] if args.key?(:amp_url)
end
end
# AMP URL Error resource for a requested URL that couldn't be found. # AMP URL Error resource for a requested URL that couldn't be found.
class AmpUrlError class AmpUrlError
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -79,66 +139,6 @@ module Google
@lookup_strategy = args[:lookup_strategy] if args.key?(:lookup_strategy) @lookup_strategy = args[:lookup_strategy] if args.key?(:lookup_strategy)
end end
end end
# Batch AMP URL response.
class BatchGetAmpUrlsResponse
include Google::Apis::Core::Hashable
# For each URL in BatchAmpUrlsRequest, the URL response. The response might
# not be in the same order as URLs in the batch request.
# If BatchAmpUrlsRequest contains duplicate URLs, AmpUrl is generated
# only once.
# Corresponds to the JSON property `ampUrls`
# @return [Array<Google::Apis::AcceleratedmobilepageurlV1::AmpUrl>]
attr_accessor :amp_urls
# The errors for requested URLs that have no AMP URL.
# Corresponds to the JSON property `urlErrors`
# @return [Array<Google::Apis::AcceleratedmobilepageurlV1::AmpUrlError>]
attr_accessor :url_errors
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@amp_urls = args[:amp_urls] if args.key?(:amp_urls)
@url_errors = args[:url_errors] if args.key?(:url_errors)
end
end
# AMP URL response for a requested URL.
class AmpUrl
include Google::Apis::Core::Hashable
# The original non-AMP URL.
# Corresponds to the JSON property `originalUrl`
# @return [String]
attr_accessor :original_url
# The AMP URL pointing to the publisher's web server.
# Corresponds to the JSON property `ampUrl`
# @return [String]
attr_accessor :amp_url
# The [AMP Cache URL](/amp/cache/overview#amp-cache-url-format) pointing to
# the cached document in the Google AMP Cache.
# Corresponds to the JSON property `cdnAmpUrl`
# @return [String]
attr_accessor :cdn_amp_url
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@original_url = args[:original_url] if args.key?(:original_url)
@amp_url = args[:amp_url] if args.key?(:amp_url)
@cdn_amp_url = args[:cdn_amp_url] if args.key?(:cdn_amp_url)
end
end
end end
end end
end end

View File

@ -22,6 +22,18 @@ module Google
module Apis module Apis
module AcceleratedmobilepageurlV1 module AcceleratedmobilepageurlV1
class BatchGetAmpUrlsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AmpUrl
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AmpUrlError class AmpUrlError
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -35,15 +47,22 @@ module Google
end end
class BatchGetAmpUrlsResponse class BatchGetAmpUrlsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :amp_urls, as: 'ampUrls', class: Google::Apis::AcceleratedmobilepageurlV1::AmpUrl, decorator: Google::Apis::AcceleratedmobilepageurlV1::AmpUrl::Representation
include Google::Apis::Core::JsonObjectSupport collection :url_errors, as: 'urlErrors', class: Google::Apis::AcceleratedmobilepageurlV1::AmpUrlError, decorator: Google::Apis::AcceleratedmobilepageurlV1::AmpUrlError::Representation
end
end end
class AmpUrl class AmpUrl
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :cdn_amp_url, as: 'cdnAmpUrl'
property :original_url, as: 'originalUrl'
property :amp_url, as: 'ampUrl'
end
end end
class AmpUrlError class AmpUrlError
@ -62,25 +81,6 @@ module Google
property :lookup_strategy, as: 'lookupStrategy' property :lookup_strategy, as: 'lookupStrategy'
end end
end end
class BatchGetAmpUrlsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :amp_urls, as: 'ampUrls', class: Google::Apis::AcceleratedmobilepageurlV1::AmpUrl, decorator: Google::Apis::AcceleratedmobilepageurlV1::AmpUrl::Representation
collection :url_errors, as: 'urlErrors', class: Google::Apis::AcceleratedmobilepageurlV1::AmpUrlError, decorator: Google::Apis::AcceleratedmobilepageurlV1::AmpUrlError::Representation
end
end
class AmpUrl
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :original_url, as: 'originalUrl'
property :amp_url, as: 'ampUrl'
property :cdn_amp_url, as: 'cdnAmpUrl'
end
end
end end
end end
end end

View File

@ -26,7 +26,7 @@ module Google
# @see https://developers.google.com/ad-exchange/buyer-rest/guides/client-access/ # @see https://developers.google.com/ad-exchange/buyer-rest/guides/client-access/
module Adexchangebuyer2V2beta1 module Adexchangebuyer2V2beta1
VERSION = 'V2beta1' VERSION = 'V2beta1'
REVISION = '20170329' REVISION = '20170330'
# Manage your Ad Exchange buyer account configuration # Manage your Ad Exchange buyer account configuration
AUTH_ADEXCHANGE_BUYER = 'https://www.googleapis.com/auth/adexchange.buyer' AUTH_ADEXCHANGE_BUYER = 'https://www.googleapis.com/auth/adexchange.buyer'

File diff suppressed because it is too large Load Diff

View File

@ -22,6 +22,78 @@ module Google
module Apis module Apis
module Adexchangebuyer2V2beta1 module Adexchangebuyer2V2beta1
class CreativeDealAssociation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Creative
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FilteringStats
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RemoveDealAssociationRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Client
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Correction
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AddDealAssociationRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListDealAssociationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Disapproval
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class StopWatchingCreativeRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ServingRestriction
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Date
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Empty class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -106,13 +178,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListClientUsersResponse class ListClientUserInvitationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListClientUserInvitationsResponse class ListClientUsersResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -137,75 +209,142 @@ module Google
end end
class CreativeDealAssociation class CreativeDealAssociation
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :deals_id, as: 'dealsId'
end property :account_id, as: 'accountId'
property :creative_id, as: 'creativeId'
class FilteringStats end
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class Creative class Creative
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :account_id, as: 'accountId'
property :native, as: 'native', class: Google::Apis::Adexchangebuyer2V2beta1::NativeContent, decorator: Google::Apis::Adexchangebuyer2V2beta1::NativeContent::Representation
include Google::Apis::Core::JsonObjectSupport collection :serving_restrictions, as: 'servingRestrictions', class: Google::Apis::Adexchangebuyer2V2beta1::ServingRestriction, decorator: Google::Apis::Adexchangebuyer2V2beta1::ServingRestriction::Representation
property :video, as: 'video', class: Google::Apis::Adexchangebuyer2V2beta1::VideoContent, decorator: Google::Apis::Adexchangebuyer2V2beta1::VideoContent::Representation
property :agency_id, as: 'agencyId'
collection :click_through_urls, as: 'clickThroughUrls'
property :ad_choices_destination_url, as: 'adChoicesDestinationUrl'
collection :detected_sensitive_categories, as: 'detectedSensitiveCategories'
collection :restricted_categories, as: 'restrictedCategories'
collection :corrections, as: 'corrections', class: Google::Apis::Adexchangebuyer2V2beta1::Correction, decorator: Google::Apis::Adexchangebuyer2V2beta1::Correction::Representation
property :version, as: 'version'
collection :vendor_ids, as: 'vendorIds'
collection :impression_tracking_urls, as: 'impressionTrackingUrls'
property :html, as: 'html', class: Google::Apis::Adexchangebuyer2V2beta1::HtmlContent, decorator: Google::Apis::Adexchangebuyer2V2beta1::HtmlContent::Representation
collection :detected_product_categories, as: 'detectedProductCategories'
property :deals_status, as: 'dealsStatus'
property :open_auction_status, as: 'openAuctionStatus'
property :advertiser_name, as: 'advertiserName'
collection :detected_advertiser_ids, as: 'detectedAdvertiserIds'
collection :detected_domains, as: 'detectedDomains'
property :filtering_stats, as: 'filteringStats', class: Google::Apis::Adexchangebuyer2V2beta1::FilteringStats, decorator: Google::Apis::Adexchangebuyer2V2beta1::FilteringStats::Representation
collection :attributes, as: 'attributes'
property :api_update_time, as: 'apiUpdateTime'
collection :detected_languages, as: 'detectedLanguages'
property :creative_id, as: 'creativeId'
end
end
class FilteringStats
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :reasons, as: 'reasons', class: Google::Apis::Adexchangebuyer2V2beta1::Reason, decorator: Google::Apis::Adexchangebuyer2V2beta1::Reason::Representation
property :date, as: 'date', class: Google::Apis::Adexchangebuyer2V2beta1::Date, decorator: Google::Apis::Adexchangebuyer2V2beta1::Date::Representation
end
end end
class RemoveDealAssociationRequest class RemoveDealAssociationRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :association, as: 'association', class: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation, decorator: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class Client class Client
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :visible_to_seller, as: 'visibleToSeller'
property :entity_id, as: 'entityId'
property :client_account_id, as: 'clientAccountId'
property :entity_name, as: 'entityName'
property :status, as: 'status'
property :entity_type, as: 'entityType'
property :client_name, as: 'clientName'
property :role, as: 'role'
end
end end
class Correction class Correction
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :details, as: 'details'
property :type, as: 'type'
collection :contexts, as: 'contexts', class: Google::Apis::Adexchangebuyer2V2beta1::ServingContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::ServingContext::Representation
include Google::Apis::Core::JsonObjectSupport end
end
class ListDealAssociationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class AddDealAssociationRequest class AddDealAssociationRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :association, as: 'association', class: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation, decorator: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class StopWatchingCreativeRequest class ListDealAssociationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :associations, as: 'associations', class: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation, decorator: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class Disapproval class Disapproval
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :details, as: 'details'
property :reason, as: 'reason'
end
end
include Google::Apis::Core::JsonObjectSupport class StopWatchingCreativeRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end end
class ServingRestriction class ServingRestriction
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :disapproval_reasons, as: 'disapprovalReasons', class: Google::Apis::Adexchangebuyer2V2beta1::Disapproval, decorator: Google::Apis::Adexchangebuyer2V2beta1::Disapproval::Representation
include Google::Apis::Core::JsonObjectSupport collection :contexts, as: 'contexts', class: Google::Apis::Adexchangebuyer2V2beta1::ServingContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::ServingContext::Representation
property :status, as: 'status'
end
end end
class Date class Date
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :year, as: 'year'
property :day, as: 'day'
property :month, as: 'month'
end
end end
class Empty class Empty
@ -240,11 +379,6 @@ module Google
class NativeContent class NativeContent
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :store_url, as: 'storeUrl'
property :headline, as: 'headline'
property :app_icon, as: 'appIcon', class: Google::Apis::Adexchangebuyer2V2beta1::Image, decorator: Google::Apis::Adexchangebuyer2V2beta1::Image::Representation
property :call_to_action, as: 'callToAction'
property :body, as: 'body' property :body, as: 'body'
property :star_rating, as: 'starRating' property :star_rating, as: 'starRating'
property :video_url, as: 'videoUrl' property :video_url, as: 'videoUrl'
@ -256,6 +390,11 @@ module Google
property :image, as: 'image', class: Google::Apis::Adexchangebuyer2V2beta1::Image, decorator: Google::Apis::Adexchangebuyer2V2beta1::Image::Representation property :image, as: 'image', class: Google::Apis::Adexchangebuyer2V2beta1::Image, decorator: Google::Apis::Adexchangebuyer2V2beta1::Image::Representation
property :advertiser_name, as: 'advertiserName' property :advertiser_name, as: 'advertiserName'
property :store_url, as: 'storeUrl'
property :headline, as: 'headline'
property :app_icon, as: 'appIcon', class: Google::Apis::Adexchangebuyer2V2beta1::Image, decorator: Google::Apis::Adexchangebuyer2V2beta1::Image::Representation
property :call_to_action, as: 'callToAction'
end end
end end
@ -278,15 +417,19 @@ module Google
class HtmlContent class HtmlContent
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :height, as: 'height'
property :width, as: 'width' property :width, as: 'width'
property :snippet, as: 'snippet' property :snippet, as: 'snippet'
property :height, as: 'height'
end end
end end
class ServingContext class ServingContext
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :app_type, as: 'appType', class: Google::Apis::Adexchangebuyer2V2beta1::AppContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::AppContext::Representation
property :security_type, as: 'securityType', class: Google::Apis::Adexchangebuyer2V2beta1::SecurityContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::SecurityContext::Representation
property :platform, as: 'platform', class: Google::Apis::Adexchangebuyer2V2beta1::PlatformContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::PlatformContext::Representation property :platform, as: 'platform', class: Google::Apis::Adexchangebuyer2V2beta1::PlatformContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::PlatformContext::Representation
property :location, as: 'location', class: Google::Apis::Adexchangebuyer2V2beta1::LocationContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::LocationContext::Representation property :location, as: 'location', class: Google::Apis::Adexchangebuyer2V2beta1::LocationContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::LocationContext::Representation
@ -294,27 +437,23 @@ module Google
property :auction_type, as: 'auctionType', class: Google::Apis::Adexchangebuyer2V2beta1::AuctionContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::AuctionContext::Representation property :auction_type, as: 'auctionType', class: Google::Apis::Adexchangebuyer2V2beta1::AuctionContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::AuctionContext::Representation
property :all, as: 'all' property :all, as: 'all'
property :app_type, as: 'appType', class: Google::Apis::Adexchangebuyer2V2beta1::AppContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::AppContext::Representation
property :security_type, as: 'securityType', class: Google::Apis::Adexchangebuyer2V2beta1::SecurityContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::SecurityContext::Representation
end end
end end
class Image class Image
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :height, as: 'height'
property :width, as: 'width' property :width, as: 'width'
property :url, as: 'url' property :url, as: 'url'
property :height, as: 'height'
end end
end end
class Reason class Reason
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :count, as: 'count'
property :status, as: 'status' property :status, as: 'status'
property :count, as: 'count'
end end
end end
@ -341,15 +480,6 @@ module Google
end end
end end
class ListClientUsersResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :users, as: 'users', class: Google::Apis::Adexchangebuyer2V2beta1::ClientUser, decorator: Google::Apis::Adexchangebuyer2V2beta1::ClientUser::Representation
end
end
class ListClientUserInvitationsResponse class ListClientUserInvitationsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -359,6 +489,15 @@ module Google
end end
end end
class ListClientUsersResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :users, as: 'users', class: Google::Apis::Adexchangebuyer2V2beta1::ClientUser, decorator: Google::Apis::Adexchangebuyer2V2beta1::ClientUser::Representation
end
end
class LocationContext class LocationContext
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -376,149 +515,10 @@ module Google
class ClientUser class ClientUser
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :client_account_id, as: 'clientAccountId'
property :status, as: 'status'
property :user_id, as: 'userId' property :user_id, as: 'userId'
property :email, as: 'email' property :email, as: 'email'
property :client_account_id, as: 'clientAccountId'
property :status, as: 'status'
end
end
class CreativeDealAssociation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :account_id, as: 'accountId'
property :creative_id, as: 'creativeId'
property :deals_id, as: 'dealsId'
end
end
class FilteringStats
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :date, as: 'date', class: Google::Apis::Adexchangebuyer2V2beta1::Date, decorator: Google::Apis::Adexchangebuyer2V2beta1::Date::Representation
collection :reasons, as: 'reasons', class: Google::Apis::Adexchangebuyer2V2beta1::Reason, decorator: Google::Apis::Adexchangebuyer2V2beta1::Reason::Representation
end
end
class Creative
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :agency_id, as: 'agencyId'
collection :click_through_urls, as: 'clickThroughUrls'
property :ad_choices_destination_url, as: 'adChoicesDestinationUrl'
collection :detected_sensitive_categories, as: 'detectedSensitiveCategories'
collection :restricted_categories, as: 'restrictedCategories'
collection :corrections, as: 'corrections', class: Google::Apis::Adexchangebuyer2V2beta1::Correction, decorator: Google::Apis::Adexchangebuyer2V2beta1::Correction::Representation
property :version, as: 'version'
collection :vendor_ids, as: 'vendorIds'
collection :impression_tracking_urls, as: 'impressionTrackingUrls'
property :html, as: 'html', class: Google::Apis::Adexchangebuyer2V2beta1::HtmlContent, decorator: Google::Apis::Adexchangebuyer2V2beta1::HtmlContent::Representation
collection :detected_product_categories, as: 'detectedProductCategories'
property :deals_status, as: 'dealsStatus'
property :open_auction_status, as: 'openAuctionStatus'
property :advertiser_name, as: 'advertiserName'
collection :detected_advertiser_ids, as: 'detectedAdvertiserIds'
collection :detected_domains, as: 'detectedDomains'
property :filtering_stats, as: 'filteringStats', class: Google::Apis::Adexchangebuyer2V2beta1::FilteringStats, decorator: Google::Apis::Adexchangebuyer2V2beta1::FilteringStats::Representation
collection :attributes, as: 'attributes'
property :api_update_time, as: 'apiUpdateTime'
collection :detected_languages, as: 'detectedLanguages'
property :creative_id, as: 'creativeId'
property :account_id, as: 'accountId'
property :native, as: 'native', class: Google::Apis::Adexchangebuyer2V2beta1::NativeContent, decorator: Google::Apis::Adexchangebuyer2V2beta1::NativeContent::Representation
property :video, as: 'video', class: Google::Apis::Adexchangebuyer2V2beta1::VideoContent, decorator: Google::Apis::Adexchangebuyer2V2beta1::VideoContent::Representation
collection :serving_restrictions, as: 'servingRestrictions', class: Google::Apis::Adexchangebuyer2V2beta1::ServingRestriction, decorator: Google::Apis::Adexchangebuyer2V2beta1::ServingRestriction::Representation
end
end
class RemoveDealAssociationRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :association, as: 'association', class: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation, decorator: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation::Representation
end
end
class Client
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :entity_type, as: 'entityType'
property :client_name, as: 'clientName'
property :role, as: 'role'
property :visible_to_seller, as: 'visibleToSeller'
property :entity_id, as: 'entityId'
property :client_account_id, as: 'clientAccountId'
property :entity_name, as: 'entityName'
property :status, as: 'status'
end
end
class Correction
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :contexts, as: 'contexts', class: Google::Apis::Adexchangebuyer2V2beta1::ServingContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::ServingContext::Representation
collection :details, as: 'details'
property :type, as: 'type'
end
end
class ListDealAssociationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :associations, as: 'associations', class: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation, decorator: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation::Representation
end
end
class AddDealAssociationRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :association, as: 'association', class: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation, decorator: Google::Apis::Adexchangebuyer2V2beta1::CreativeDealAssociation::Representation
end
end
class StopWatchingCreativeRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class Disapproval
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :details, as: 'details'
property :reason, as: 'reason'
end
end
class ServingRestriction
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :disapproval_reasons, as: 'disapprovalReasons', class: Google::Apis::Adexchangebuyer2V2beta1::Disapproval, decorator: Google::Apis::Adexchangebuyer2V2beta1::Disapproval::Representation
collection :contexts, as: 'contexts', class: Google::Apis::Adexchangebuyer2V2beta1::ServingContext, decorator: Google::Apis::Adexchangebuyer2V2beta1::ServingContext::Representation
property :status, as: 'status'
end
end
class Date
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :year, as: 'year'
property :day, as: 'day'
property :month, as: 'month'
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -2746,6 +2746,7 @@ module Google
# #
# Corresponds to the JSON property `referencePayload` # Corresponds to the JSON property `referencePayload`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :reference_payload attr_accessor :reference_payload

View File

@ -3015,6 +3015,7 @@ module Google
# Base64 encoded photo data # Base64 encoded photo data
# Corresponds to the JSON property `photoData` # Corresponds to the JSON property `photoData`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :photo_data attr_accessor :photo_data

View File

@ -22,83 +22,28 @@ module Google
module Apis module Apis
module AnalyticsreportingV4 module AnalyticsreportingV4
# Dynamic segment definition for defining the segment within the request.
# A segment can select users, sessions or both.
class DynamicSegment
include Google::Apis::Core::Hashable
# SegmentDefinition defines the segment to be a set of SegmentFilters which
# are combined together with a logical `AND` operation.
# Corresponds to the JSON property `sessionSegment`
# @return [Google::Apis::AnalyticsreportingV4::SegmentDefinition]
attr_accessor :session_segment
# The name of the dynamic segment.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# SegmentDefinition defines the segment to be a set of SegmentFilters which
# are combined together with a logical `AND` operation.
# Corresponds to the JSON property `userSegment`
# @return [Google::Apis::AnalyticsreportingV4::SegmentDefinition]
attr_accessor :user_segment
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@session_segment = args[:session_segment] if args.key?(:session_segment)
@name = args[:name] if args.key?(:name)
@user_segment = args[:user_segment] if args.key?(:user_segment)
end
end
# A Simple segment conditions consist of one or more dimension/metric
# conditions that can be combined.
class SimpleSegment
include Google::Apis::Core::Hashable
# A list of segment filters groups which are combined with logical `AND`
# operator.
# Corresponds to the JSON property `orFiltersForSegment`
# @return [Array<Google::Apis::AnalyticsreportingV4::OrFiltersForSegment>]
attr_accessor :or_filters_for_segment
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@or_filters_for_segment = args[:or_filters_for_segment] if args.key?(:or_filters_for_segment)
end
end
# Column headers. # Column headers.
class ColumnHeader class ColumnHeader
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The headers for the metrics.
# Corresponds to the JSON property `metricHeader`
# @return [Google::Apis::AnalyticsreportingV4::MetricHeader]
attr_accessor :metric_header
# The dimension names in the response. # The dimension names in the response.
# Corresponds to the JSON property `dimensions` # Corresponds to the JSON property `dimensions`
# @return [Array<String>] # @return [Array<String>]
attr_accessor :dimensions attr_accessor :dimensions
# The headers for the metrics.
# Corresponds to the JSON property `metricHeader`
# @return [Google::Apis::AnalyticsreportingV4::MetricHeader]
attr_accessor :metric_header
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@metric_header = args[:metric_header] if args.key?(:metric_header)
@dimensions = args[:dimensions] if args.key?(:dimensions) @dimensions = args[:dimensions] if args.key?(:dimensions)
@metric_header = args[:metric_header] if args.key?(:metric_header)
end end
end end
@ -107,6 +52,11 @@ module Google
class SegmentFilterClause class SegmentFilterClause
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Dimension filter specifies the filtering options on a dimension.
# Corresponds to the JSON property `dimensionFilter`
# @return [Google::Apis::AnalyticsreportingV4::SegmentDimensionFilter]
attr_accessor :dimension_filter
# Metric filter to be used in a segment filter clause. # Metric filter to be used in a segment filter clause.
# Corresponds to the JSON property `metricFilter` # Corresponds to the JSON property `metricFilter`
# @return [Google::Apis::AnalyticsreportingV4::SegmentMetricFilter] # @return [Google::Apis::AnalyticsreportingV4::SegmentMetricFilter]
@ -118,20 +68,15 @@ module Google
attr_accessor :not attr_accessor :not
alias_method :not?, :not alias_method :not?, :not
# Dimension filter specifies the filtering options on a dimension.
# Corresponds to the JSON property `dimensionFilter`
# @return [Google::Apis::AnalyticsreportingV4::SegmentDimensionFilter]
attr_accessor :dimension_filter
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@dimension_filter = args[:dimension_filter] if args.key?(:dimension_filter)
@metric_filter = args[:metric_filter] if args.key?(:metric_filter) @metric_filter = args[:metric_filter] if args.key?(:metric_filter)
@not = args[:not] if args.key?(:not) @not = args[:not] if args.key?(:not)
@dimension_filter = args[:dimension_filter] if args.key?(:dimension_filter)
end end
end end
@ -166,6 +111,13 @@ module Google
class Cohort class Cohort
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Type of the cohort. The only supported type as of now is
# `FIRST_VISIT_DATE`. If this field is unspecified the cohort is treated
# as `FIRST_VISIT_DATE` type cohort.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
# A unique name for the cohort. If not defined name will be auto-generated # A unique name for the cohort. If not defined name will be auto-generated
# with values cohort_[1234...]. # with values cohort_[1234...].
# Corresponds to the JSON property `name` # Corresponds to the JSON property `name`
@ -179,22 +131,15 @@ module Google
# @return [Google::Apis::AnalyticsreportingV4::DateRange] # @return [Google::Apis::AnalyticsreportingV4::DateRange]
attr_accessor :date_range attr_accessor :date_range
# Type of the cohort. The only supported type as of now is
# `FIRST_VISIT_DATE`. If this field is unspecified the cohort is treated
# as `FIRST_VISIT_DATE` type cohort.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@type = args[:type] if args.key?(:type)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@date_range = args[:date_range] if args.key?(:date_range) @date_range = args[:date_range] if args.key?(:date_range)
@type = args[:type] if args.key?(:type)
end end
end end
@ -250,24 +195,24 @@ module Google
class MetricHeader class MetricHeader
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Headers for the pivots in the response.
# Corresponds to the JSON property `pivotHeaders`
# @return [Array<Google::Apis::AnalyticsreportingV4::PivotHeader>]
attr_accessor :pivot_headers
# Headers for the metrics in the response. # Headers for the metrics in the response.
# Corresponds to the JSON property `metricHeaderEntries` # Corresponds to the JSON property `metricHeaderEntries`
# @return [Array<Google::Apis::AnalyticsreportingV4::MetricHeaderEntry>] # @return [Array<Google::Apis::AnalyticsreportingV4::MetricHeaderEntry>]
attr_accessor :metric_header_entries attr_accessor :metric_header_entries
# Headers for the pivots in the response.
# Corresponds to the JSON property `pivotHeaders`
# @return [Array<Google::Apis::AnalyticsreportingV4::PivotHeader>]
attr_accessor :pivot_headers
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@pivot_headers = args[:pivot_headers] if args.key?(:pivot_headers)
@metric_header_entries = args[:metric_header_entries] if args.key?(:metric_header_entries) @metric_header_entries = args[:metric_header_entries] if args.key?(:metric_header_entries)
@pivot_headers = args[:pivot_headers] if args.key?(:pivot_headers)
end end
end end
@ -352,6 +297,20 @@ module Google
class SegmentMetricFilter class SegmentMetricFilter
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The metric that will be filtered on. A `metricFilter` must contain a
# metric name.
# Corresponds to the JSON property `metricName`
# @return [String]
attr_accessor :metric_name
# Scope for a metric defines the level at which that metric is defined. The
# specified metric scope must be equal to or greater than its primary scope
# as defined in the data model. The primary scope is defined by if the
# segment is selecting users or sessions.
# Corresponds to the JSON property `scope`
# @return [String]
attr_accessor :scope
# Max comparison value is only used for `BETWEEN` operator. # Max comparison value is only used for `BETWEEN` operator.
# Corresponds to the JSON property `maxComparisonValue` # Corresponds to the JSON property `maxComparisonValue`
# @return [String] # @return [String]
@ -369,31 +328,17 @@ module Google
# @return [String] # @return [String]
attr_accessor :operator attr_accessor :operator
# The metric that will be filtered on. A `metricFilter` must contain a
# metric name.
# Corresponds to the JSON property `metricName`
# @return [String]
attr_accessor :metric_name
# Scope for a metric defines the level at which that metric is defined. The
# specified metric scope must be equal to or greater than its primary scope
# as defined in the data model. The primary scope is defined by if the
# segment is selecting users or sessions.
# Corresponds to the JSON property `scope`
# @return [String]
attr_accessor :scope
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@metric_name = args[:metric_name] if args.key?(:metric_name)
@scope = args[:scope] if args.key?(:scope)
@max_comparison_value = args[:max_comparison_value] if args.key?(:max_comparison_value) @max_comparison_value = args[:max_comparison_value] if args.key?(:max_comparison_value)
@comparison_value = args[:comparison_value] if args.key?(:comparison_value) @comparison_value = args[:comparison_value] if args.key?(:comparison_value)
@operator = args[:operator] if args.key?(:operator) @operator = args[:operator] if args.key?(:operator)
@metric_name = args[:metric_name] if args.key?(:metric_name)
@scope = args[:scope] if args.key?(:scope)
end end
end end
@ -514,6 +459,22 @@ module Google
class Pivot class Pivot
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# If k metrics were requested, then the response will contain some
# data-dependent multiple of k columns in the report. E.g., if you pivoted
# on the dimension `ga:browser` then you'd get k columns for "Firefox", k
# columns for "IE", k columns for "Chrome", etc. The ordering of the groups
# of columns is determined by descending order of "total" for the first of
# the k values. Ties are broken by lexicographic ordering of the first
# pivot dimension, then lexicographic ordering of the second pivot
# dimension, and so on. E.g., if the totals for the first value for
# Firefox, IE, and Chrome were 8, 2, 8, respectively, the order of columns
# would be Chrome, Firefox, IE.
# The following let you choose which of the groups of k columns are
# included in the response.
# Corresponds to the JSON property `startGroup`
# @return [Fixnum]
attr_accessor :start_group
# The pivot metrics. Pivot metrics are part of the # The pivot metrics. Pivot metrics are part of the
# restriction on total number of metrics allowed in the request. # restriction on total number of metrics allowed in the request.
# Corresponds to the JSON property `metrics` # Corresponds to the JSON property `metrics`
@ -544,33 +505,17 @@ module Google
# @return [Fixnum] # @return [Fixnum]
attr_accessor :max_group_count attr_accessor :max_group_count
# If k metrics were requested, then the response will contain some
# data-dependent multiple of k columns in the report. E.g., if you pivoted
# on the dimension `ga:browser` then you'd get k columns for "Firefox", k
# columns for "IE", k columns for "Chrome", etc. The ordering of the groups
# of columns is determined by descending order of "total" for the first of
# the k values. Ties are broken by lexicographic ordering of the first
# pivot dimension, then lexicographic ordering of the second pivot
# dimension, and so on. E.g., if the totals for the first value for
# Firefox, IE, and Chrome were 8, 2, 8, respectively, the order of columns
# would be Chrome, Firefox, IE.
# The following let you choose which of the groups of k columns are
# included in the response.
# Corresponds to the JSON property `startGroup`
# @return [Fixnum]
attr_accessor :start_group
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@start_group = args[:start_group] if args.key?(:start_group)
@metrics = args[:metrics] if args.key?(:metrics) @metrics = args[:metrics] if args.key?(:metrics)
@dimensions = args[:dimensions] if args.key?(:dimensions) @dimensions = args[:dimensions] if args.key?(:dimensions)
@dimension_filter_clauses = args[:dimension_filter_clauses] if args.key?(:dimension_filter_clauses) @dimension_filter_clauses = args[:dimension_filter_clauses] if args.key?(:dimension_filter_clauses)
@max_group_count = args[:max_group_count] if args.key?(:max_group_count) @max_group_count = args[:max_group_count] if args.key?(:max_group_count)
@start_group = args[:start_group] if args.key?(:start_group)
end end
end end
@ -686,24 +631,24 @@ module Google
class MetricHeaderEntry class MetricHeaderEntry
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The type of the metric, for example `INTEGER`.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
# The name of the header. # The name of the header.
# Corresponds to the JSON property `name` # Corresponds to the JSON property `name`
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# The type of the metric, for example `INTEGER`.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@type = args[:type] if args.key?(:type)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@type = args[:type] if args.key?(:type)
end end
end end
@ -711,6 +656,37 @@ module Google
class ReportData class ReportData
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Total number of matching rows for this query.
# Corresponds to the JSON property `rowCount`
# @return [Fixnum]
attr_accessor :row_count
# There's one ReportRow for every unique combination of dimensions.
# Corresponds to the JSON property `rows`
# @return [Array<Google::Apis::AnalyticsreportingV4::ReportRow>]
attr_accessor :rows
# Indicates if response to this request is golden or not. Data is
# golden when the exact same request will not produce any new results if
# asked at a later point in time.
# Corresponds to the JSON property `isDataGolden`
# @return [Boolean]
attr_accessor :is_data_golden
alias_method :is_data_golden?, :is_data_golden
# The last time the data in the report was refreshed. All the hits received
# before this timestamp are included in the calculation of the report.
# Corresponds to the JSON property `dataLastRefreshed`
# @return [String]
attr_accessor :data_last_refreshed
# Minimum and maximum values seen over all matching rows. These are both
# empty when `hideValueRanges` in the request is false, or when
# rowCount is zero.
# Corresponds to the JSON property `maximums`
# @return [Array<Google::Apis::AnalyticsreportingV4::DateRangeValues>]
attr_accessor :maximums
# If the results are # If the results are
# [sampled](https://support.google.com/analytics/answer/2637192), # [sampled](https://support.google.com/analytics/answer/2637192),
# this returns the total number of # this returns the total number of
@ -751,52 +727,21 @@ module Google
# @return [Array<String>] # @return [Array<String>]
attr_accessor :samples_read_counts attr_accessor :samples_read_counts
# Total number of matching rows for this query.
# Corresponds to the JSON property `rowCount`
# @return [Fixnum]
attr_accessor :row_count
# There's one ReportRow for every unique combination of dimensions.
# Corresponds to the JSON property `rows`
# @return [Array<Google::Apis::AnalyticsreportingV4::ReportRow>]
attr_accessor :rows
# Indicates if response to this request is golden or not. Data is
# golden when the exact same request will not produce any new results if
# asked at a later point in time.
# Corresponds to the JSON property `isDataGolden`
# @return [Boolean]
attr_accessor :is_data_golden
alias_method :is_data_golden?, :is_data_golden
# The last time the data in the report was refreshed. All the hits received
# before this timestamp are included in the calculation of the report.
# Corresponds to the JSON property `dataLastRefreshed`
# @return [String]
attr_accessor :data_last_refreshed
# Minimum and maximum values seen over all matching rows. These are both
# empty when `hideValueRanges` in the request is false, or when
# rowCount is zero.
# Corresponds to the JSON property `maximums`
# @return [Array<Google::Apis::AnalyticsreportingV4::DateRangeValues>]
attr_accessor :maximums
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@sampling_space_sizes = args[:sampling_space_sizes] if args.key?(:sampling_space_sizes)
@minimums = args[:minimums] if args.key?(:minimums)
@totals = args[:totals] if args.key?(:totals)
@samples_read_counts = args[:samples_read_counts] if args.key?(:samples_read_counts)
@row_count = args[:row_count] if args.key?(:row_count) @row_count = args[:row_count] if args.key?(:row_count)
@rows = args[:rows] if args.key?(:rows) @rows = args[:rows] if args.key?(:rows)
@is_data_golden = args[:is_data_golden] if args.key?(:is_data_golden) @is_data_golden = args[:is_data_golden] if args.key?(:is_data_golden)
@data_last_refreshed = args[:data_last_refreshed] if args.key?(:data_last_refreshed) @data_last_refreshed = args[:data_last_refreshed] if args.key?(:data_last_refreshed)
@maximums = args[:maximums] if args.key?(:maximums) @maximums = args[:maximums] if args.key?(:maximums)
@sampling_space_sizes = args[:sampling_space_sizes] if args.key?(:sampling_space_sizes)
@minimums = args[:minimums] if args.key?(:minimums)
@totals = args[:totals] if args.key?(:totals)
@samples_read_counts = args[:samples_read_counts] if args.key?(:samples_read_counts)
end end
end end
@ -804,12 +749,6 @@ module Google
class DimensionFilter class DimensionFilter
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Should the match be case sensitive? Default is false.
# Corresponds to the JSON property `caseSensitive`
# @return [Boolean]
attr_accessor :case_sensitive
alias_method :case_sensitive?, :case_sensitive
# The dimension to filter on. A DimensionFilter must contain a dimension. # The dimension to filter on. A DimensionFilter must contain a dimension.
# Corresponds to the JSON property `dimensionName` # Corresponds to the JSON property `dimensionName`
# @return [String] # @return [String]
@ -835,79 +774,23 @@ module Google
# @return [Array<String>] # @return [Array<String>]
attr_accessor :expressions attr_accessor :expressions
# Should the match be case sensitive? Default is false.
# Corresponds to the JSON property `caseSensitive`
# @return [Boolean]
attr_accessor :case_sensitive
alias_method :case_sensitive?, :case_sensitive
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@case_sensitive = args[:case_sensitive] if args.key?(:case_sensitive)
@dimension_name = args[:dimension_name] if args.key?(:dimension_name) @dimension_name = args[:dimension_name] if args.key?(:dimension_name)
@operator = args[:operator] if args.key?(:operator) @operator = args[:operator] if args.key?(:operator)
@not = args[:not] if args.key?(:not) @not = args[:not] if args.key?(:not)
@expressions = args[:expressions] if args.key?(:expressions) @expressions = args[:expressions] if args.key?(:expressions)
end @case_sensitive = args[:case_sensitive] if args.key?(:case_sensitive)
end
# The segment definition, if the report needs to be segmented.
# A Segment is a subset of the Analytics data. For example, of the entire
# set of users, one Segment might be users from a particular country or city.
class Segment
include Google::Apis::Core::Hashable
# Dynamic segment definition for defining the segment within the request.
# A segment can select users, sessions or both.
# Corresponds to the JSON property `dynamicSegment`
# @return [Google::Apis::AnalyticsreportingV4::DynamicSegment]
attr_accessor :dynamic_segment
# The segment ID of a built-in or custom segment, for example `gaid::-3`.
# Corresponds to the JSON property `segmentId`
# @return [String]
attr_accessor :segment_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@dynamic_segment = args[:dynamic_segment] if args.key?(:dynamic_segment)
@segment_id = args[:segment_id] if args.key?(:segment_id)
end
end
# Specifies the sorting options.
class OrderBy
include Google::Apis::Core::Hashable
# The field which to sort by. The default sort order is ascending. Example:
# `ga:browser`.
# Note, that you can only specify one field for sort here. For example,
# `ga:browser, ga:city` is not valid.
# Corresponds to the JSON property `fieldName`
# @return [String]
attr_accessor :field_name
# The order type. The default orderType is `VALUE`.
# Corresponds to the JSON property `orderType`
# @return [String]
attr_accessor :order_type
# The sorting order for the field.
# Corresponds to the JSON property `sortOrder`
# @return [String]
attr_accessor :sort_order
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@field_name = args[:field_name] if args.key?(:field_name)
@order_type = args[:order_type] if args.key?(:order_type)
@sort_order = args[:sort_order] if args.key?(:sort_order)
end end
end end
@ -961,6 +844,68 @@ module Google
end end
end end
# Specifies the sorting options.
class OrderBy
include Google::Apis::Core::Hashable
# The field which to sort by. The default sort order is ascending. Example:
# `ga:browser`.
# Note, that you can only specify one field for sort here. For example,
# `ga:browser, ga:city` is not valid.
# Corresponds to the JSON property `fieldName`
# @return [String]
attr_accessor :field_name
# The order type. The default orderType is `VALUE`.
# Corresponds to the JSON property `orderType`
# @return [String]
attr_accessor :order_type
# The sorting order for the field.
# Corresponds to the JSON property `sortOrder`
# @return [String]
attr_accessor :sort_order
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@field_name = args[:field_name] if args.key?(:field_name)
@order_type = args[:order_type] if args.key?(:order_type)
@sort_order = args[:sort_order] if args.key?(:sort_order)
end
end
# The segment definition, if the report needs to be segmented.
# A Segment is a subset of the Analytics data. For example, of the entire
# set of users, one Segment might be users from a particular country or city.
class Segment
include Google::Apis::Core::Hashable
# Dynamic segment definition for defining the segment within the request.
# A segment can select users, sessions or both.
# Corresponds to the JSON property `dynamicSegment`
# @return [Google::Apis::AnalyticsreportingV4::DynamicSegment]
attr_accessor :dynamic_segment
# The segment ID of a built-in or custom segment, for example `gaid::-3`.
# Corresponds to the JSON property `segmentId`
# @return [String]
attr_accessor :segment_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@dynamic_segment = args[:dynamic_segment] if args.key?(:dynamic_segment)
@segment_id = args[:segment_id] if args.key?(:segment_id)
end
end
# A segment sequence definition. # A segment sequence definition.
class SegmentSequenceStep class SegmentSequenceStep
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -1056,11 +1001,6 @@ module Google
class Report class Report
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Column headers.
# Corresponds to the JSON property `columnHeader`
# @return [Google::Apis::AnalyticsreportingV4::ColumnHeader]
attr_accessor :column_header
# The data part of the report. # The data part of the report.
# Corresponds to the JSON property `data` # Corresponds to the JSON property `data`
# @return [Google::Apis::AnalyticsreportingV4::ReportData] # @return [Google::Apis::AnalyticsreportingV4::ReportData]
@ -1071,15 +1011,20 @@ module Google
# @return [String] # @return [String]
attr_accessor :next_page_token attr_accessor :next_page_token
# Column headers.
# Corresponds to the JSON property `columnHeader`
# @return [Google::Apis::AnalyticsreportingV4::ColumnHeader]
attr_accessor :column_header
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@column_header = args[:column_header] if args.key?(:column_header)
@data = args[:data] if args.key?(:data) @data = args[:data] if args.key?(:data)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token) @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@column_header = args[:column_header] if args.key?(:column_header)
end end
end end
@ -1183,11 +1128,6 @@ module Google
class ReportRequest class ReportRequest
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The pivot definitions. Requests can have a maximum of 2 pivots.
# Corresponds to the JSON property `pivots`
# @return [Array<Google::Apis::AnalyticsreportingV4::Pivot>]
attr_accessor :pivots
# If set to false, the response does not include rows if all the retrieved # If set to false, the response does not include rows if all the retrieved
# metrics are equal to zero. The default is false which will exclude these # metrics are equal to zero. The default is false which will exclude these
# rows. # rows.
@ -1216,13 +1156,6 @@ module Google
# @return [Fixnum] # @return [Fixnum]
attr_accessor :page_size attr_accessor :page_size
# If set to true, hides the minimum and maximum across all matching rows.
# The default is false and the value ranges are returned.
# Corresponds to the JSON property `hideValueRanges`
# @return [Boolean]
attr_accessor :hide_value_ranges
alias_method :hide_value_ranges?, :hide_value_ranges
# If set to true, hides the total of all metrics for all the matching rows, # If set to true, hides the total of all metrics for all the matching rows,
# for every date range. The default false and will return the totals. # for every date range. The default false and will return the totals.
# Corresponds to the JSON property `hideTotals` # Corresponds to the JSON property `hideTotals`
@ -1230,17 +1163,12 @@ module Google
attr_accessor :hide_totals attr_accessor :hide_totals
alias_method :hide_totals?, :hide_totals alias_method :hide_totals?, :hide_totals
# Dimension or metric filters that restrict the data returned for your # If set to true, hides the minimum and maximum across all matching rows.
# request. To use the `filtersExpression`, supply a dimension or metric on # The default is false and the value ranges are returned.
# which to filter, followed by the filter expression. For example, the # Corresponds to the JSON property `hideValueRanges`
# following expression selects `ga:browser` dimension which starts with # @return [Boolean]
# Firefox; `ga:browser=~^Firefox`. For more information on dimensions attr_accessor :hide_value_ranges
# and metric filters, see alias_method :hide_value_ranges?, :hide_value_ranges
# [Filters reference](https://developers.google.com/analytics/devguides/
# reporting/core/v3/reference#filters).
# Corresponds to the JSON property `filtersExpression`
# @return [String]
attr_accessor :filters_expression
# Defines a cohort group. # Defines a cohort group.
# For example: # For example:
@ -1259,6 +1187,18 @@ module Google
# @return [Google::Apis::AnalyticsreportingV4::CohortGroup] # @return [Google::Apis::AnalyticsreportingV4::CohortGroup]
attr_accessor :cohort_group attr_accessor :cohort_group
# Dimension or metric filters that restrict the data returned for your
# request. To use the `filtersExpression`, supply a dimension or metric on
# which to filter, followed by the filter expression. For example, the
# following expression selects `ga:browser` dimension which starts with
# Firefox; `ga:browser=~^Firefox`. For more information on dimensions
# and metric filters, see
# [Filters reference](https://developers.google.com/analytics/devguides/
# reporting/core/v3/reference#filters).
# Corresponds to the JSON property `filtersExpression`
# @return [String]
attr_accessor :filters_expression
# The Analytics # The Analytics
# [view ID](https://support.google.com/analytics/answer/1009618) # [view ID](https://support.google.com/analytics/answer/1009618)
# from which to retrieve data. Every [ReportRequest](#ReportRequest) # from which to retrieve data. Every [ReportRequest](#ReportRequest)
@ -1338,20 +1278,24 @@ module Google
# @return [Array<Google::Apis::AnalyticsreportingV4::DateRange>] # @return [Array<Google::Apis::AnalyticsreportingV4::DateRange>]
attr_accessor :date_ranges attr_accessor :date_ranges
# The pivot definitions. Requests can have a maximum of 2 pivots.
# Corresponds to the JSON property `pivots`
# @return [Array<Google::Apis::AnalyticsreportingV4::Pivot>]
attr_accessor :pivots
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@pivots = args[:pivots] if args.key?(:pivots)
@include_empty_rows = args[:include_empty_rows] if args.key?(:include_empty_rows) @include_empty_rows = args[:include_empty_rows] if args.key?(:include_empty_rows)
@metric_filter_clauses = args[:metric_filter_clauses] if args.key?(:metric_filter_clauses) @metric_filter_clauses = args[:metric_filter_clauses] if args.key?(:metric_filter_clauses)
@page_size = args[:page_size] if args.key?(:page_size) @page_size = args[:page_size] if args.key?(:page_size)
@hide_value_ranges = args[:hide_value_ranges] if args.key?(:hide_value_ranges)
@hide_totals = args[:hide_totals] if args.key?(:hide_totals) @hide_totals = args[:hide_totals] if args.key?(:hide_totals)
@filters_expression = args[:filters_expression] if args.key?(:filters_expression) @hide_value_ranges = args[:hide_value_ranges] if args.key?(:hide_value_ranges)
@cohort_group = args[:cohort_group] if args.key?(:cohort_group) @cohort_group = args[:cohort_group] if args.key?(:cohort_group)
@filters_expression = args[:filters_expression] if args.key?(:filters_expression)
@view_id = args[:view_id] if args.key?(:view_id) @view_id = args[:view_id] if args.key?(:view_id)
@metrics = args[:metrics] if args.key?(:metrics) @metrics = args[:metrics] if args.key?(:metrics)
@dimension_filter_clauses = args[:dimension_filter_clauses] if args.key?(:dimension_filter_clauses) @dimension_filter_clauses = args[:dimension_filter_clauses] if args.key?(:dimension_filter_clauses)
@ -1361,6 +1305,7 @@ module Google
@dimensions = args[:dimensions] if args.key?(:dimensions) @dimensions = args[:dimensions] if args.key?(:dimensions)
@page_token = args[:page_token] if args.key?(:page_token) @page_token = args[:page_token] if args.key?(:page_token)
@date_ranges = args[:date_ranges] if args.key?(:date_ranges) @date_ranges = args[:date_ranges] if args.key?(:date_ranges)
@pivots = args[:pivots] if args.key?(:pivots)
end end
end end
@ -1415,6 +1360,61 @@ module Google
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
end end
end end
# Dynamic segment definition for defining the segment within the request.
# A segment can select users, sessions or both.
class DynamicSegment
include Google::Apis::Core::Hashable
# The name of the dynamic segment.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# SegmentDefinition defines the segment to be a set of SegmentFilters which
# are combined together with a logical `AND` operation.
# Corresponds to the JSON property `userSegment`
# @return [Google::Apis::AnalyticsreportingV4::SegmentDefinition]
attr_accessor :user_segment
# SegmentDefinition defines the segment to be a set of SegmentFilters which
# are combined together with a logical `AND` operation.
# Corresponds to the JSON property `sessionSegment`
# @return [Google::Apis::AnalyticsreportingV4::SegmentDefinition]
attr_accessor :session_segment
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@name = args[:name] if args.key?(:name)
@user_segment = args[:user_segment] if args.key?(:user_segment)
@session_segment = args[:session_segment] if args.key?(:session_segment)
end
end
# A Simple segment conditions consist of one or more dimension/metric
# conditions that can be combined.
class SimpleSegment
include Google::Apis::Core::Hashable
# A list of segment filters groups which are combined with logical `AND`
# operator.
# Corresponds to the JSON property `orFiltersForSegment`
# @return [Array<Google::Apis::AnalyticsreportingV4::OrFiltersForSegment>]
attr_accessor :or_filters_for_segment
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@or_filters_for_segment = args[:or_filters_for_segment] if args.key?(:or_filters_for_segment)
end
end
end end
end end
end end

View File

@ -22,18 +22,6 @@ module Google
module Apis module Apis
module AnalyticsreportingV4 module AnalyticsreportingV4
class DynamicSegment
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SimpleSegment
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ColumnHeader class ColumnHeader
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -160,7 +148,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Segment class SegmentDimensionFilter
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -172,7 +160,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class SegmentDimensionFilter class Segment
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -233,41 +221,34 @@ module Google
end end
class DynamicSegment class DynamicSegment
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :session_segment, as: 'sessionSegment', class: Google::Apis::AnalyticsreportingV4::SegmentDefinition, decorator: Google::Apis::AnalyticsreportingV4::SegmentDefinition::Representation
property :name, as: 'name' include Google::Apis::Core::JsonObjectSupport
property :user_segment, as: 'userSegment', class: Google::Apis::AnalyticsreportingV4::SegmentDefinition, decorator: Google::Apis::AnalyticsreportingV4::SegmentDefinition::Representation
end
end end
class SimpleSegment class SimpleSegment
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :or_filters_for_segment, as: 'orFiltersForSegment', class: Google::Apis::AnalyticsreportingV4::OrFiltersForSegment, decorator: Google::Apis::AnalyticsreportingV4::OrFiltersForSegment::Representation
end include Google::Apis::Core::JsonObjectSupport
end end
class ColumnHeader class ColumnHeader
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :dimensions, as: 'dimensions'
property :metric_header, as: 'metricHeader', class: Google::Apis::AnalyticsreportingV4::MetricHeader, decorator: Google::Apis::AnalyticsreportingV4::MetricHeader::Representation property :metric_header, as: 'metricHeader', class: Google::Apis::AnalyticsreportingV4::MetricHeader, decorator: Google::Apis::AnalyticsreportingV4::MetricHeader::Representation
collection :dimensions, as: 'dimensions'
end end
end end
class SegmentFilterClause class SegmentFilterClause
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :dimension_filter, as: 'dimensionFilter', class: Google::Apis::AnalyticsreportingV4::SegmentDimensionFilter, decorator: Google::Apis::AnalyticsreportingV4::SegmentDimensionFilter::Representation
property :metric_filter, as: 'metricFilter', class: Google::Apis::AnalyticsreportingV4::SegmentMetricFilter, decorator: Google::Apis::AnalyticsreportingV4::SegmentMetricFilter::Representation property :metric_filter, as: 'metricFilter', class: Google::Apis::AnalyticsreportingV4::SegmentMetricFilter, decorator: Google::Apis::AnalyticsreportingV4::SegmentMetricFilter::Representation
property :not, as: 'not' property :not, as: 'not'
property :dimension_filter, as: 'dimensionFilter', class: Google::Apis::AnalyticsreportingV4::SegmentDimensionFilter, decorator: Google::Apis::AnalyticsreportingV4::SegmentDimensionFilter::Representation
end end
end end
@ -283,10 +264,10 @@ module Google
class Cohort class Cohort
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type'
property :name, as: 'name' property :name, as: 'name'
property :date_range, as: 'dateRange', class: Google::Apis::AnalyticsreportingV4::DateRange, decorator: Google::Apis::AnalyticsreportingV4::DateRange::Representation property :date_range, as: 'dateRange', class: Google::Apis::AnalyticsreportingV4::DateRange, decorator: Google::Apis::AnalyticsreportingV4::DateRange::Representation
property :type, as: 'type'
end end
end end
@ -310,10 +291,10 @@ module Google
class MetricHeader class MetricHeader
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :pivot_headers, as: 'pivotHeaders', class: Google::Apis::AnalyticsreportingV4::PivotHeader, decorator: Google::Apis::AnalyticsreportingV4::PivotHeader::Representation
collection :metric_header_entries, as: 'metricHeaderEntries', class: Google::Apis::AnalyticsreportingV4::MetricHeaderEntry, decorator: Google::Apis::AnalyticsreportingV4::MetricHeaderEntry::Representation collection :metric_header_entries, as: 'metricHeaderEntries', class: Google::Apis::AnalyticsreportingV4::MetricHeaderEntry, decorator: Google::Apis::AnalyticsreportingV4::MetricHeaderEntry::Representation
collection :pivot_headers, as: 'pivotHeaders', class: Google::Apis::AnalyticsreportingV4::PivotHeader, decorator: Google::Apis::AnalyticsreportingV4::PivotHeader::Representation
end end
end end
@ -346,11 +327,11 @@ module Google
class SegmentMetricFilter class SegmentMetricFilter
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :metric_name, as: 'metricName'
property :scope, as: 'scope'
property :max_comparison_value, as: 'maxComparisonValue' property :max_comparison_value, as: 'maxComparisonValue'
property :comparison_value, as: 'comparisonValue' property :comparison_value, as: 'comparisonValue'
property :operator, as: 'operator' property :operator, as: 'operator'
property :metric_name, as: 'metricName'
property :scope, as: 'scope'
end end
end end
@ -383,6 +364,7 @@ module Google
class Pivot class Pivot
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :start_group, as: 'startGroup'
collection :metrics, as: 'metrics', class: Google::Apis::AnalyticsreportingV4::Metric, decorator: Google::Apis::AnalyticsreportingV4::Metric::Representation collection :metrics, as: 'metrics', class: Google::Apis::AnalyticsreportingV4::Metric, decorator: Google::Apis::AnalyticsreportingV4::Metric::Representation
collection :dimensions, as: 'dimensions', class: Google::Apis::AnalyticsreportingV4::Dimension, decorator: Google::Apis::AnalyticsreportingV4::Dimension::Representation collection :dimensions, as: 'dimensions', class: Google::Apis::AnalyticsreportingV4::Dimension, decorator: Google::Apis::AnalyticsreportingV4::Dimension::Representation
@ -390,7 +372,6 @@ module Google
collection :dimension_filter_clauses, as: 'dimensionFilterClauses', class: Google::Apis::AnalyticsreportingV4::DimensionFilterClause, decorator: Google::Apis::AnalyticsreportingV4::DimensionFilterClause::Representation collection :dimension_filter_clauses, as: 'dimensionFilterClauses', class: Google::Apis::AnalyticsreportingV4::DimensionFilterClause, decorator: Google::Apis::AnalyticsreportingV4::DimensionFilterClause::Representation
property :max_group_count, as: 'maxGroupCount' property :max_group_count, as: 'maxGroupCount'
property :start_group, as: 'startGroup'
end end
end end
@ -426,20 +407,14 @@ module Google
class MetricHeaderEntry class MetricHeaderEntry
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type'
property :name, as: 'name' property :name, as: 'name'
property :type, as: 'type'
end end
end end
class ReportData class ReportData
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :sampling_space_sizes, as: 'samplingSpaceSizes'
collection :minimums, as: 'minimums', class: Google::Apis::AnalyticsreportingV4::DateRangeValues, decorator: Google::Apis::AnalyticsreportingV4::DateRangeValues::Representation
collection :totals, as: 'totals', class: Google::Apis::AnalyticsreportingV4::DateRangeValues, decorator: Google::Apis::AnalyticsreportingV4::DateRangeValues::Representation
collection :samples_read_counts, as: 'samplesReadCounts'
property :row_count, as: 'rowCount' property :row_count, as: 'rowCount'
collection :rows, as: 'rows', class: Google::Apis::AnalyticsreportingV4::ReportRow, decorator: Google::Apis::AnalyticsreportingV4::ReportRow::Representation collection :rows, as: 'rows', class: Google::Apis::AnalyticsreportingV4::ReportRow, decorator: Google::Apis::AnalyticsreportingV4::ReportRow::Representation
@ -447,35 +422,23 @@ module Google
property :data_last_refreshed, as: 'dataLastRefreshed' property :data_last_refreshed, as: 'dataLastRefreshed'
collection :maximums, as: 'maximums', class: Google::Apis::AnalyticsreportingV4::DateRangeValues, decorator: Google::Apis::AnalyticsreportingV4::DateRangeValues::Representation collection :maximums, as: 'maximums', class: Google::Apis::AnalyticsreportingV4::DateRangeValues, decorator: Google::Apis::AnalyticsreportingV4::DateRangeValues::Representation
collection :sampling_space_sizes, as: 'samplingSpaceSizes'
collection :minimums, as: 'minimums', class: Google::Apis::AnalyticsreportingV4::DateRangeValues, decorator: Google::Apis::AnalyticsreportingV4::DateRangeValues::Representation
collection :totals, as: 'totals', class: Google::Apis::AnalyticsreportingV4::DateRangeValues, decorator: Google::Apis::AnalyticsreportingV4::DateRangeValues::Representation
collection :samples_read_counts, as: 'samplesReadCounts'
end end
end end
class DimensionFilter class DimensionFilter
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :case_sensitive, as: 'caseSensitive'
property :dimension_name, as: 'dimensionName' property :dimension_name, as: 'dimensionName'
property :operator, as: 'operator' property :operator, as: 'operator'
property :not, as: 'not' property :not, as: 'not'
collection :expressions, as: 'expressions' collection :expressions, as: 'expressions'
end property :case_sensitive, as: 'caseSensitive'
end
class Segment
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :dynamic_segment, as: 'dynamicSegment', class: Google::Apis::AnalyticsreportingV4::DynamicSegment, decorator: Google::Apis::AnalyticsreportingV4::DynamicSegment::Representation
property :segment_id, as: 'segmentId'
end
end
class OrderBy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :field_name, as: 'fieldName'
property :order_type, as: 'orderType'
property :sort_order, as: 'sortOrder'
end end
end end
@ -491,6 +454,24 @@ module Google
end end
end end
class OrderBy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :field_name, as: 'fieldName'
property :order_type, as: 'orderType'
property :sort_order, as: 'sortOrder'
end
end
class Segment
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :dynamic_segment, as: 'dynamicSegment', class: Google::Apis::AnalyticsreportingV4::DynamicSegment, decorator: Google::Apis::AnalyticsreportingV4::DynamicSegment::Representation
property :segment_id, as: 'segmentId'
end
end
class SegmentSequenceStep class SegmentSequenceStep
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -519,11 +500,11 @@ module Google
class Report class Report
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :column_header, as: 'columnHeader', class: Google::Apis::AnalyticsreportingV4::ColumnHeader, decorator: Google::Apis::AnalyticsreportingV4::ColumnHeader::Representation
property :data, as: 'data', class: Google::Apis::AnalyticsreportingV4::ReportData, decorator: Google::Apis::AnalyticsreportingV4::ReportData::Representation property :data, as: 'data', class: Google::Apis::AnalyticsreportingV4::ReportData, decorator: Google::Apis::AnalyticsreportingV4::ReportData::Representation
property :next_page_token, as: 'nextPageToken' property :next_page_token, as: 'nextPageToken'
property :column_header, as: 'columnHeader', class: Google::Apis::AnalyticsreportingV4::ColumnHeader, decorator: Google::Apis::AnalyticsreportingV4::ColumnHeader::Representation
end end
end end
@ -557,17 +538,15 @@ module Google
class ReportRequest class ReportRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :pivots, as: 'pivots', class: Google::Apis::AnalyticsreportingV4::Pivot, decorator: Google::Apis::AnalyticsreportingV4::Pivot::Representation
property :include_empty_rows, as: 'includeEmptyRows' property :include_empty_rows, as: 'includeEmptyRows'
collection :metric_filter_clauses, as: 'metricFilterClauses', class: Google::Apis::AnalyticsreportingV4::MetricFilterClause, decorator: Google::Apis::AnalyticsreportingV4::MetricFilterClause::Representation collection :metric_filter_clauses, as: 'metricFilterClauses', class: Google::Apis::AnalyticsreportingV4::MetricFilterClause, decorator: Google::Apis::AnalyticsreportingV4::MetricFilterClause::Representation
property :page_size, as: 'pageSize' property :page_size, as: 'pageSize'
property :hide_value_ranges, as: 'hideValueRanges'
property :hide_totals, as: 'hideTotals' property :hide_totals, as: 'hideTotals'
property :filters_expression, as: 'filtersExpression' property :hide_value_ranges, as: 'hideValueRanges'
property :cohort_group, as: 'cohortGroup', class: Google::Apis::AnalyticsreportingV4::CohortGroup, decorator: Google::Apis::AnalyticsreportingV4::CohortGroup::Representation property :cohort_group, as: 'cohortGroup', class: Google::Apis::AnalyticsreportingV4::CohortGroup, decorator: Google::Apis::AnalyticsreportingV4::CohortGroup::Representation
property :filters_expression, as: 'filtersExpression'
property :view_id, as: 'viewId' property :view_id, as: 'viewId'
collection :metrics, as: 'metrics', class: Google::Apis::AnalyticsreportingV4::Metric, decorator: Google::Apis::AnalyticsreportingV4::Metric::Representation collection :metrics, as: 'metrics', class: Google::Apis::AnalyticsreportingV4::Metric, decorator: Google::Apis::AnalyticsreportingV4::Metric::Representation
@ -583,6 +562,8 @@ module Google
property :page_token, as: 'pageToken' property :page_token, as: 'pageToken'
collection :date_ranges, as: 'dateRanges', class: Google::Apis::AnalyticsreportingV4::DateRange, decorator: Google::Apis::AnalyticsreportingV4::DateRange::Representation collection :date_ranges, as: 'dateRanges', class: Google::Apis::AnalyticsreportingV4::DateRange, decorator: Google::Apis::AnalyticsreportingV4::DateRange::Representation
collection :pivots, as: 'pivots', class: Google::Apis::AnalyticsreportingV4::Pivot, decorator: Google::Apis::AnalyticsreportingV4::Pivot::Representation
end end
end end
@ -593,6 +574,25 @@ module Google
property :name, as: 'name' property :name, as: 'name'
end end
end end
class DynamicSegment
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :user_segment, as: 'userSegment', class: Google::Apis::AnalyticsreportingV4::SegmentDefinition, decorator: Google::Apis::AnalyticsreportingV4::SegmentDefinition::Representation
property :session_segment, as: 'sessionSegment', class: Google::Apis::AnalyticsreportingV4::SegmentDefinition, decorator: Google::Apis::AnalyticsreportingV4::SegmentDefinition::Representation
end
end
class SimpleSegment
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :or_filters_for_segment, as: 'orFiltersForSegment', class: Google::Apis::AnalyticsreportingV4::OrFiltersForSegment, decorator: Google::Apis::AnalyticsreportingV4::OrFiltersForSegment::Representation
end
end
end end
end end
end end

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/bigquery/ # @see https://cloud.google.com/bigquery/
module BigqueryV2 module BigqueryV2
VERSION = 'V2' VERSION = 'V2'
REVISION = '20170319' REVISION = '20170324'
# View and manage your data in Google BigQuery # View and manage your data in Google BigQuery
AUTH_BIGQUERY = 'https://www.googleapis.com/auth/bigquery' AUTH_BIGQUERY = 'https://www.googleapis.com/auth/bigquery'

View File

@ -59,6 +59,7 @@ module Google
# BigQuery field identifier i.e. does not match [a-zA-Z][a-zA-Z0-9_]*, a valid # BigQuery field identifier i.e. does not match [a-zA-Z][a-zA-Z0-9_]*, a valid
# identifier must be provided as field_name. # identifier must be provided as field_name.
# Corresponds to the JSON property `qualifierEncoded` # Corresponds to the JSON property `qualifierEncoded`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :qualifier_encoded attr_accessor :qualifier_encoded
@ -1246,8 +1247,8 @@ module Google
# [Optional] Specifies a string that represents a null value in a CSV file. For # [Optional] Specifies a string that represents a null value in a CSV file. For
# example, if you specify "\N", BigQuery interprets "\N" as a null value when # example, if you specify "\N", BigQuery interprets "\N" as a null value when
# loading a CSV file. The default value is the empty string. If you set this # loading a CSV file. The default value is the empty string. If you set this
# property to a custom value, BigQuery still interprets the empty string as a # property to a custom value, BigQuery throws an error if an empty string is
# null value for all data types except for STRING and BYTE. For STRING and BYTE # present for all data types except for STRING and BYTE. For STRING and BYTE
# columns, BigQuery interprets the empty string as an empty value. # columns, BigQuery interprets the empty string as an empty value.
# Corresponds to the JSON property `nullMarker` # Corresponds to the JSON property `nullMarker`
# @return [String] # @return [String]
@ -1370,8 +1371,10 @@ module Google
class JobConfigurationQuery class JobConfigurationQuery
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# If true, allows the query to produce arbitrarily large result tables at a # [Optional] If true and query uses legacy SQL dialect, allows the query to
# slight cost in performance. Requires destinationTable to be set. # produce arbitrarily large result tables at a slight cost in performance.
# Requires destinationTable to be set. For standard SQL queries, this flag is
# ignored and large results are always allowed.
# Corresponds to the JSON property `allowLargeResults` # Corresponds to the JSON property `allowLargeResults`
# @return [Boolean] # @return [Boolean]
attr_accessor :allow_large_results attr_accessor :allow_large_results
@ -1399,8 +1402,10 @@ module Google
# @return [Google::Apis::BigqueryV2::TableReference] # @return [Google::Apis::BigqueryV2::TableReference]
attr_accessor :destination_table attr_accessor :destination_table
# [Optional] Flattens all nested and repeated fields in the query results. The # [Optional] If true and query uses legacy SQL dialect, flattens all nested and
# default value is true. allowLargeResults must be true if this is set to false. # repeated fields in the query results. allowLargeResults must be true if this
# is set to false. For standard SQL queries, this flag is ignored and results
# are never flattened.
# Corresponds to the JSON property `flattenResults` # Corresponds to the JSON property `flattenResults`
# @return [Boolean] # @return [Boolean]
attr_accessor :flatten_results attr_accessor :flatten_results

View File

@ -274,6 +274,7 @@ module Google
# Base64 encoded data for this annotation data. # Base64 encoded data for this annotation data.
# Corresponds to the JSON property `encoded_data` # Corresponds to the JSON property `encoded_data`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :encoded_data attr_accessor :encoded_data

View File

@ -25,7 +25,7 @@ module Google
# @see https://developers.google.com/google-apps/calendar/firstapp # @see https://developers.google.com/google-apps/calendar/firstapp
module CalendarV3 module CalendarV3
VERSION = 'V3' VERSION = 'V3'
REVISION = '20170321' REVISION = '20170328'
# Manage your calendars # Manage your calendars
AUTH_CALENDAR = 'https://www.googleapis.com/auth/calendar' AUTH_CALENDAR = 'https://www.googleapis.com/auth/calendar'

View File

@ -22,31 +22,351 @@ module Google
module Apis module Apis
module CloudbuildV1 module CloudbuildV1
# Source describes the location of the source in a supported storage # A generic empty message that you can re-use to avoid defining duplicated
# service. # empty messages in your APIs. A typical example is to use it as the request
class Source # or the response type of an API method. For instance:
# service Foo `
# rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
# `
# The JSON representation for `Empty` is empty JSON object ````.
class Empty
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# RepoSource describes the location of the source in a Google Cloud Source
# Repository.
# Corresponds to the JSON property `repoSource`
# @return [Google::Apis::CloudbuildV1::RepoSource]
attr_accessor :repo_source
# StorageSource describes the location of the source in an archive file in
# Google Cloud Storage.
# Corresponds to the JSON property `storageSource`
# @return [Google::Apis::CloudbuildV1::StorageSource]
attr_accessor :storage_source
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@repo_source = args[:repo_source] if args.key?(:repo_source) end
end
# Configuration for an automated build in response to source repository
# changes.
class BuildTrigger
include Google::Apis::Core::Hashable
# If true, the trigger will never result in a build.
# Corresponds to the JSON property `disabled`
# @return [Boolean]
attr_accessor :disabled
alias_method :disabled?, :disabled
# Time when the trigger was created.
# @OutputOnly
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# RepoSource describes the location of the source in a Google Cloud Source
# Repository.
# Corresponds to the JSON property `triggerTemplate`
# @return [Google::Apis::CloudbuildV1::RepoSource]
attr_accessor :trigger_template
# Path, from the source root, to a file whose contents is used for the
# template.
# Corresponds to the JSON property `filename`
# @return [String]
attr_accessor :filename
# Unique identifier of the trigger.
# @OutputOnly
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# A build resource in the Container Builder API.
# At a high level, a Build describes where to find source code, how to build
# it (for example, the builder image to run on the source), and what tag to
# apply to the built image when it is pushed to Google Container Registry.
# Fields can include the following variables which will be expanded when the
# build is created:
# - $PROJECT_ID: the project ID of the build.
# - $BUILD_ID: the autogenerated ID of the build.
# - $REPO_NAME: the source repository name specified by RepoSource.
# - $BRANCH_NAME: the branch name specified by RepoSource.
# - $TAG_NAME: the tag name specified by RepoSource.
# - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or
# resolved from the specified branch or tag.
# Corresponds to the JSON property `build`
# @return [Google::Apis::CloudbuildV1::Build]
attr_accessor :build
# Substitutions data for Build resource.
# Corresponds to the JSON property `substitutions`
# @return [Hash<String,String>]
attr_accessor :substitutions
# Human-readable description of this trigger.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@disabled = args[:disabled] if args.key?(:disabled)
@create_time = args[:create_time] if args.key?(:create_time)
@trigger_template = args[:trigger_template] if args.key?(:trigger_template)
@filename = args[:filename] if args.key?(:filename)
@id = args[:id] if args.key?(:id)
@build = args[:build] if args.key?(:build)
@substitutions = args[:substitutions] if args.key?(:substitutions)
@description = args[:description] if args.key?(:description)
end
end
# A build resource in the Container Builder API.
# At a high level, a Build describes where to find source code, how to build
# it (for example, the builder image to run on the source), and what tag to
# apply to the built image when it is pushed to Google Container Registry.
# Fields can include the following variables which will be expanded when the
# build is created:
# - $PROJECT_ID: the project ID of the build.
# - $BUILD_ID: the autogenerated ID of the build.
# - $REPO_NAME: the source repository name specified by RepoSource.
# - $BRANCH_NAME: the branch name specified by RepoSource.
# - $TAG_NAME: the tag name specified by RepoSource.
# - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or
# resolved from the specified branch or tag.
class Build
include Google::Apis::Core::Hashable
# Optional arguments to enable specific features of builds.
# Corresponds to the JSON property `options`
# @return [Google::Apis::CloudbuildV1::BuildOptions]
attr_accessor :options
# Source describes the location of the source in a supported storage
# service.
# Corresponds to the JSON property `source`
# @return [Google::Apis::CloudbuildV1::Source]
attr_accessor :source
# Customer-readable message about the current status.
# @OutputOnly
# Corresponds to the JSON property `statusDetail`
# @return [String]
attr_accessor :status_detail
# Status of the build.
# @OutputOnly
# Corresponds to the JSON property `status`
# @return [String]
attr_accessor :status
# Amount of time that this build should be allowed to run, to second
# granularity. If this amount of time elapses, work on the build will cease
# and the build status will be TIMEOUT.
# Default time is ten minutes.
# Corresponds to the JSON property `timeout`
# @return [String]
attr_accessor :timeout
# Google Cloud Storage bucket where logs should be written (see
# [Bucket Name
# Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)
# ).
# Logs file names will be of the format `$`logs_bucket`/log-$`build_id`.txt`.
# Corresponds to the JSON property `logsBucket`
# @return [String]
attr_accessor :logs_bucket
# Results describes the artifacts created by the build pipeline.
# Corresponds to the JSON property `results`
# @return [Google::Apis::CloudbuildV1::Results]
attr_accessor :results
# Describes the operations to be performed on the workspace.
# Corresponds to the JSON property `steps`
# @return [Array<Google::Apis::CloudbuildV1::BuildStep>]
attr_accessor :steps
# The ID of the BuildTrigger that triggered this build, if it was
# triggered automatically.
# @OutputOnly
# Corresponds to the JSON property `buildTriggerId`
# @return [String]
attr_accessor :build_trigger_id
# Unique identifier of the build.
# @OutputOnly
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# Time at which execution of the build was started.
# @OutputOnly
# Corresponds to the JSON property `startTime`
# @return [String]
attr_accessor :start_time
# Substitutions data for Build resource.
# Corresponds to the JSON property `substitutions`
# @return [Hash<String,String>]
attr_accessor :substitutions
# Time at which the request to create the build was received.
# @OutputOnly
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# Provenance of the source. Ways to find the original source, or verify that
# some source was used for this build.
# Corresponds to the JSON property `sourceProvenance`
# @return [Google::Apis::CloudbuildV1::SourceProvenance]
attr_accessor :source_provenance
# A list of images to be pushed upon the successful completion of all build
# steps.
# The images will be pushed using the builder service account's credentials.
# The digests of the pushed images will be stored in the Build resource's
# results field.
# If any of the images fail to be pushed, the build is marked FAILURE.
# Corresponds to the JSON property `images`
# @return [Array<String>]
attr_accessor :images
# ID of the project.
# @OutputOnly.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
# Time at which execution of the build was finished.
# The difference between finish_time and start_time is the duration of the
# build's execution.
# @OutputOnly
# Corresponds to the JSON property `finishTime`
# @return [String]
attr_accessor :finish_time
# URL to logs for this build in Google Cloud Logging.
# @OutputOnly
# Corresponds to the JSON property `logUrl`
# @return [String]
attr_accessor :log_url
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@options = args[:options] if args.key?(:options)
@source = args[:source] if args.key?(:source)
@status_detail = args[:status_detail] if args.key?(:status_detail)
@status = args[:status] if args.key?(:status)
@timeout = args[:timeout] if args.key?(:timeout)
@logs_bucket = args[:logs_bucket] if args.key?(:logs_bucket)
@results = args[:results] if args.key?(:results)
@steps = args[:steps] if args.key?(:steps)
@build_trigger_id = args[:build_trigger_id] if args.key?(:build_trigger_id)
@id = args[:id] if args.key?(:id)
@start_time = args[:start_time] if args.key?(:start_time)
@substitutions = args[:substitutions] if args.key?(:substitutions)
@create_time = args[:create_time] if args.key?(:create_time)
@source_provenance = args[:source_provenance] if args.key?(:source_provenance)
@images = args[:images] if args.key?(:images)
@project_id = args[:project_id] if args.key?(:project_id)
@finish_time = args[:finish_time] if args.key?(:finish_time)
@log_url = args[:log_url] if args.key?(:log_url)
end
end
# Request to cancel an ongoing build.
class CancelBuildRequest
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# Response including listed builds.
class ListBuildsResponse
include Google::Apis::Core::Hashable
# Token to receive the next page of results.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# Builds will be sorted by create_time, descending.
# Corresponds to the JSON property `builds`
# @return [Array<Google::Apis::CloudbuildV1::Build>]
attr_accessor :builds
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@builds = args[:builds] if args.key?(:builds)
end
end
# The response message for Operations.ListOperations.
class ListOperationsResponse
include Google::Apis::Core::Hashable
# The standard List next-page token.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# A list of operations that matches the specified filter in the request.
# Corresponds to the JSON property `operations`
# @return [Array<Google::Apis::CloudbuildV1::Operation>]
attr_accessor :operations
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@operations = args[:operations] if args.key?(:operations)
end
end
# Source describes the location of the source in a supported storage
# service.
class Source
include Google::Apis::Core::Hashable
# StorageSource describes the location of the source in an archive file in
# Google Cloud Storage.
# Corresponds to the JSON property `storageSource`
# @return [Google::Apis::CloudbuildV1::StorageSource]
attr_accessor :storage_source
# RepoSource describes the location of the source in a Google Cloud Source
# Repository.
# Corresponds to the JSON property `repoSource`
# @return [Google::Apis::CloudbuildV1::RepoSource]
attr_accessor :repo_source
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@storage_source = args[:storage_source] if args.key?(:storage_source) @storage_source = args[:storage_source] if args.key?(:storage_source)
@repo_source = args[:repo_source] if args.key?(:repo_source)
end end
end end
@ -80,12 +400,6 @@ module Google
class StorageSource class StorageSource
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Google Cloud Storage generation for the object. If the generation is
# omitted, the latest generation will be used.
# Corresponds to the JSON property `generation`
# @return [String]
attr_accessor :generation
# Google Cloud Storage bucket containing source (see # Google Cloud Storage bucket containing source (see
# [Bucket Name # [Bucket Name
# Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements) # Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)
@ -101,15 +415,21 @@ module Google
# @return [String] # @return [String]
attr_accessor :object attr_accessor :object
# Google Cloud Storage generation for the object. If the generation is
# omitted, the latest generation will be used.
# Corresponds to the JSON property `generation`
# @return [String]
attr_accessor :generation
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@generation = args[:generation] if args.key?(:generation)
@bucket = args[:bucket] if args.key?(:bucket) @bucket = args[:bucket] if args.key?(:bucket)
@object = args[:object] if args.key?(:object) @object = args[:object] if args.key?(:object)
@generation = args[:generation] if args.key?(:generation)
end end
end end
@ -223,11 +543,38 @@ module Google
end end
end end
# Response containing existing BuildTriggers.
class ListBuildTriggersResponse
include Google::Apis::Core::Hashable
# BuildTriggers for the project, sorted by create_time descending.
# Corresponds to the JSON property `triggers`
# @return [Array<Google::Apis::CloudbuildV1::BuildTrigger>]
attr_accessor :triggers
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@triggers = args[:triggers] if args.key?(:triggers)
end
end
# This resource represents a long-running operation that is the result of a # This resource represents a long-running operation that is the result of a
# network API call. # network API call.
class Operation class Operation
include Google::Apis::Core::Hashable 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 normal response of the operation in case of success. If the original # 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 # method returns no data on success, such as `Delete`, the response is
# `google.protobuf.Empty`. If the original method is standard # `google.protobuf.Empty`. If the original method is standard
@ -298,44 +645,17 @@ module Google
# @return [Hash<String,Object>] # @return [Hash<String,Object>]
attr_accessor :metadata attr_accessor :metadata
# 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
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@done = args[:done] if args.key?(:done)
@response = args[:response] if args.key?(:response) @response = args[:response] if args.key?(:response)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@error = args[:error] if args.key?(:error) @error = args[:error] if args.key?(:error)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@done = args[:done] if args.key?(:done)
end
end
# Response containing existing BuildTriggers.
class ListBuildTriggersResponse
include Google::Apis::Core::Hashable
# BuildTriggers for the project, sorted by create_time descending.
# Corresponds to the JSON property `triggers`
# @return [Array<Google::Apis::CloudbuildV1::BuildTrigger>]
attr_accessor :triggers
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@triggers = args[:triggers] if args.key?(:triggers)
end end
end end
@ -343,25 +663,70 @@ module Google
class BuiltImage class BuiltImage
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Docker Registry 2.0 digest.
# Corresponds to the JSON property `digest`
# @return [String]
attr_accessor :digest
# Name used to push the container image to Google Container Registry, as # Name used to push the container image to Google Container Registry, as
# presented to `docker push`. # presented to `docker push`.
# Corresponds to the JSON property `name` # Corresponds to the JSON property `name`
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# Docker Registry 2.0 digest.
# Corresponds to the JSON property `digest`
# @return [String]
attr_accessor :digest
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@digest = args[:digest] if args.key?(:digest)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@digest = args[:digest] if args.key?(:digest)
end
end
# RepoSource describes the location of the source in a Google Cloud Source
# Repository.
class RepoSource
include Google::Apis::Core::Hashable
# ID of the project that owns the repo. If omitted, the project ID requesting
# the build is assumed.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
# Name of the repo. If omitted, the name "default" is assumed.
# Corresponds to the JSON property `repoName`
# @return [String]
attr_accessor :repo_name
# Name of the branch to build.
# Corresponds to the JSON property `branchName`
# @return [String]
attr_accessor :branch_name
# Name of the tag to build.
# Corresponds to the JSON property `tagName`
# @return [String]
attr_accessor :tag_name
# Explicit commit SHA to build.
# Corresponds to the JSON property `commitSha`
# @return [String]
attr_accessor :commit_sha
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@project_id = args[:project_id] if args.key?(:project_id)
@repo_name = args[:repo_name] if args.key?(:repo_name)
@branch_name = args[:branch_name] if args.key?(:branch_name)
@tag_name = args[:tag_name] if args.key?(:tag_name)
@commit_sha = args[:commit_sha] if args.key?(:commit_sha)
end end
end end
@ -457,6 +822,7 @@ module Google
# The hash value. # The hash value.
# Corresponds to the JSON property `value` # Corresponds to the JSON property `value`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :value attr_accessor :value
@ -471,51 +837,6 @@ module Google
end end
end end
# RepoSource describes the location of the source in a Google Cloud Source
# Repository.
class RepoSource
include Google::Apis::Core::Hashable
# Name of the tag to build.
# Corresponds to the JSON property `tagName`
# @return [String]
attr_accessor :tag_name
# Explicit commit SHA to build.
# Corresponds to the JSON property `commitSha`
# @return [String]
attr_accessor :commit_sha
# ID of the project that owns the repo. If omitted, the project ID requesting
# the build is assumed.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
# Name of the repo. If omitted, the name "default" is assumed.
# Corresponds to the JSON property `repoName`
# @return [String]
attr_accessor :repo_name
# Name of the branch to build.
# Corresponds to the JSON property `branchName`
# @return [String]
attr_accessor :branch_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@tag_name = args[:tag_name] if args.key?(:tag_name)
@commit_sha = args[:commit_sha] if args.key?(:commit_sha)
@project_id = args[:project_id] if args.key?(:project_id)
@repo_name = args[:repo_name] if args.key?(:repo_name)
@branch_name = args[:branch_name] if args.key?(:branch_name)
end
end
# Container message for hashes of byte content of files, used in # Container message for hashes of byte content of files, used in
# SourceProvenance messages to verify integrity of source input to the build. # SourceProvenance messages to verify integrity of source input to the build.
class FileHashes class FileHashes
@ -607,326 +928,6 @@ module Google
@details = args[:details] if args.key?(:details) @details = args[:details] if args.key?(:details)
end end
end end
# A generic empty message that you can re-use to avoid defining duplicated
# empty messages in your APIs. A typical example is to use it as the request
# or the response type of an API method. For instance:
# service Foo `
# rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
# `
# The JSON representation for `Empty` is empty JSON object ````.
class Empty
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# Configuration for an automated build in response to source repository
# changes.
class BuildTrigger
include Google::Apis::Core::Hashable
# Time when the trigger was created.
# @OutputOnly
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# If true, the trigger will never result in a build.
# Corresponds to the JSON property `disabled`
# @return [Boolean]
attr_accessor :disabled
alias_method :disabled?, :disabled
# RepoSource describes the location of the source in a Google Cloud Source
# Repository.
# Corresponds to the JSON property `triggerTemplate`
# @return [Google::Apis::CloudbuildV1::RepoSource]
attr_accessor :trigger_template
# Path, from the source root, to a file whose contents is used for the
# template.
# Corresponds to the JSON property `filename`
# @return [String]
attr_accessor :filename
# Unique identifier of the trigger.
# @OutputOnly
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# A build resource in the Container Builder API.
# At a high level, a Build describes where to find source code, how to build
# it (for example, the builder image to run on the source), and what tag to
# apply to the built image when it is pushed to Google Container Registry.
# Fields can include the following variables which will be expanded when the
# build is created:
# - $PROJECT_ID: the project ID of the build.
# - $BUILD_ID: the autogenerated ID of the build.
# - $REPO_NAME: the source repository name specified by RepoSource.
# - $BRANCH_NAME: the branch name specified by RepoSource.
# - $TAG_NAME: the tag name specified by RepoSource.
# - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or
# resolved from the specified branch or tag.
# Corresponds to the JSON property `build`
# @return [Google::Apis::CloudbuildV1::Build]
attr_accessor :build
# Substitutions data for Build resource.
# Corresponds to the JSON property `substitutions`
# @return [Hash<String,String>]
attr_accessor :substitutions
# Human-readable description of this trigger.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@create_time = args[:create_time] if args.key?(:create_time)
@disabled = args[:disabled] if args.key?(:disabled)
@trigger_template = args[:trigger_template] if args.key?(:trigger_template)
@filename = args[:filename] if args.key?(:filename)
@id = args[:id] if args.key?(:id)
@build = args[:build] if args.key?(:build)
@substitutions = args[:substitutions] if args.key?(:substitutions)
@description = args[:description] if args.key?(:description)
end
end
# A build resource in the Container Builder API.
# At a high level, a Build describes where to find source code, how to build
# it (for example, the builder image to run on the source), and what tag to
# apply to the built image when it is pushed to Google Container Registry.
# Fields can include the following variables which will be expanded when the
# build is created:
# - $PROJECT_ID: the project ID of the build.
# - $BUILD_ID: the autogenerated ID of the build.
# - $REPO_NAME: the source repository name specified by RepoSource.
# - $BRANCH_NAME: the branch name specified by RepoSource.
# - $TAG_NAME: the tag name specified by RepoSource.
# - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or
# resolved from the specified branch or tag.
class Build
include Google::Apis::Core::Hashable
# Time at which the request to create the build was received.
# @OutputOnly
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# Provenance of the source. Ways to find the original source, or verify that
# some source was used for this build.
# Corresponds to the JSON property `sourceProvenance`
# @return [Google::Apis::CloudbuildV1::SourceProvenance]
attr_accessor :source_provenance
# A list of images to be pushed upon the successful completion of all build
# steps.
# The images will be pushed using the builder service account's credentials.
# The digests of the pushed images will be stored in the Build resource's
# results field.
# If any of the images fail to be pushed, the build is marked FAILURE.
# Corresponds to the JSON property `images`
# @return [Array<String>]
attr_accessor :images
# ID of the project.
# @OutputOnly.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
# Time at which execution of the build was finished.
# The difference between finish_time and start_time is the duration of the
# build's execution.
# @OutputOnly
# Corresponds to the JSON property `finishTime`
# @return [String]
attr_accessor :finish_time
# URL to logs for this build in Google Cloud Logging.
# @OutputOnly
# Corresponds to the JSON property `logUrl`
# @return [String]
attr_accessor :log_url
# Source describes the location of the source in a supported storage
# service.
# Corresponds to the JSON property `source`
# @return [Google::Apis::CloudbuildV1::Source]
attr_accessor :source
# Optional arguments to enable specific features of builds.
# Corresponds to the JSON property `options`
# @return [Google::Apis::CloudbuildV1::BuildOptions]
attr_accessor :options
# Amount of time that this build should be allowed to run, to second
# granularity. If this amount of time elapses, work on the build will cease
# and the build status will be TIMEOUT.
# Default time is ten minutes.
# Corresponds to the JSON property `timeout`
# @return [String]
attr_accessor :timeout
# Status of the build.
# @OutputOnly
# Corresponds to the JSON property `status`
# @return [String]
attr_accessor :status
# Customer-readable message about the current status.
# @OutputOnly
# Corresponds to the JSON property `statusDetail`
# @return [String]
attr_accessor :status_detail
# Google Cloud Storage bucket where logs should be written (see
# [Bucket Name
# Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)
# ).
# Logs file names will be of the format `$`logs_bucket`/log-$`build_id`.txt`.
# Corresponds to the JSON property `logsBucket`
# @return [String]
attr_accessor :logs_bucket
# Results describes the artifacts created by the build pipeline.
# Corresponds to the JSON property `results`
# @return [Google::Apis::CloudbuildV1::Results]
attr_accessor :results
# Describes the operations to be performed on the workspace.
# Corresponds to the JSON property `steps`
# @return [Array<Google::Apis::CloudbuildV1::BuildStep>]
attr_accessor :steps
# The ID of the BuildTrigger that triggered this build, if it was
# triggered automatically.
# @OutputOnly
# Corresponds to the JSON property `buildTriggerId`
# @return [String]
attr_accessor :build_trigger_id
# Unique identifier of the build.
# @OutputOnly
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# Time at which execution of the build was started.
# @OutputOnly
# Corresponds to the JSON property `startTime`
# @return [String]
attr_accessor :start_time
# Substitutions data for Build resource.
# Corresponds to the JSON property `substitutions`
# @return [Hash<String,String>]
attr_accessor :substitutions
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@create_time = args[:create_time] if args.key?(:create_time)
@source_provenance = args[:source_provenance] if args.key?(:source_provenance)
@images = args[:images] if args.key?(:images)
@project_id = args[:project_id] if args.key?(:project_id)
@finish_time = args[:finish_time] if args.key?(:finish_time)
@log_url = args[:log_url] if args.key?(:log_url)
@source = args[:source] if args.key?(:source)
@options = args[:options] if args.key?(:options)
@timeout = args[:timeout] if args.key?(:timeout)
@status = args[:status] if args.key?(:status)
@status_detail = args[:status_detail] if args.key?(:status_detail)
@logs_bucket = args[:logs_bucket] if args.key?(:logs_bucket)
@results = args[:results] if args.key?(:results)
@steps = args[:steps] if args.key?(:steps)
@build_trigger_id = args[:build_trigger_id] if args.key?(:build_trigger_id)
@id = args[:id] if args.key?(:id)
@start_time = args[:start_time] if args.key?(:start_time)
@substitutions = args[:substitutions] if args.key?(:substitutions)
end
end
# Request to cancel an ongoing build.
class CancelBuildRequest
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# Response including listed builds.
class ListBuildsResponse
include Google::Apis::Core::Hashable
# Token to receive the next page of results.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# Builds will be sorted by create_time, descending.
# Corresponds to the JSON property `builds`
# @return [Array<Google::Apis::CloudbuildV1::Build>]
attr_accessor :builds
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@builds = args[:builds] if args.key?(:builds)
end
end
# The response message for Operations.ListOperations.
class ListOperationsResponse
include Google::Apis::Core::Hashable
# The standard List next-page token.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# A list of operations that matches the specified filter in the request.
# Corresponds to the JSON property `operations`
# @return [Array<Google::Apis::CloudbuildV1::Operation>]
attr_accessor :operations
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@operations = args[:operations] if args.key?(:operations)
end
end
end end
end end
end end

View File

@ -22,6 +22,42 @@ module Google
module Apis module Apis
module CloudbuildV1 module CloudbuildV1
class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class BuildTrigger
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Build
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CancelBuildRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListBuildsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListOperationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Source class Source
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -64,24 +100,30 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListBuildTriggersResponse class ListBuildTriggersResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class BuiltImage class BuiltImage
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class RepoSource
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class BuildStep class BuildStep
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -94,12 +136,6 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class RepoSource
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FileHashes class FileHashes
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -113,48 +149,87 @@ module Google
end end
class Empty class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport end
end end
class BuildTrigger class BuildTrigger
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :disabled, as: 'disabled'
property :create_time, as: 'createTime'
property :trigger_template, as: 'triggerTemplate', class: Google::Apis::CloudbuildV1::RepoSource, decorator: Google::Apis::CloudbuildV1::RepoSource::Representation
include Google::Apis::Core::JsonObjectSupport property :filename, as: 'filename'
property :id, as: 'id'
property :build, as: 'build', class: Google::Apis::CloudbuildV1::Build, decorator: Google::Apis::CloudbuildV1::Build::Representation
hash :substitutions, as: 'substitutions'
property :description, as: 'description'
end
end end
class Build class Build
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :options, as: 'options', class: Google::Apis::CloudbuildV1::BuildOptions, decorator: Google::Apis::CloudbuildV1::BuildOptions::Representation
include Google::Apis::Core::JsonObjectSupport property :source, as: 'source', class: Google::Apis::CloudbuildV1::Source, decorator: Google::Apis::CloudbuildV1::Source::Representation
property :status_detail, as: 'statusDetail'
property :status, as: 'status'
property :timeout, as: 'timeout'
property :logs_bucket, as: 'logsBucket'
property :results, as: 'results', class: Google::Apis::CloudbuildV1::Results, decorator: Google::Apis::CloudbuildV1::Results::Representation
collection :steps, as: 'steps', class: Google::Apis::CloudbuildV1::BuildStep, decorator: Google::Apis::CloudbuildV1::BuildStep::Representation
property :build_trigger_id, as: 'buildTriggerId'
property :id, as: 'id'
property :start_time, as: 'startTime'
hash :substitutions, as: 'substitutions'
property :create_time, as: 'createTime'
property :source_provenance, as: 'sourceProvenance', class: Google::Apis::CloudbuildV1::SourceProvenance, decorator: Google::Apis::CloudbuildV1::SourceProvenance::Representation
collection :images, as: 'images'
property :project_id, as: 'projectId'
property :finish_time, as: 'finishTime'
property :log_url, as: 'logUrl'
end
end end
class CancelBuildRequest class CancelBuildRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport end
end end
class ListBuildsResponse class ListBuildsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :builds, as: 'builds', class: Google::Apis::CloudbuildV1::Build, decorator: Google::Apis::CloudbuildV1::Build::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class ListOperationsResponse class ListOperationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :operations, as: 'operations', class: Google::Apis::CloudbuildV1::Operation, decorator: Google::Apis::CloudbuildV1::Operation::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class Source class Source
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :repo_source, as: 'repoSource', class: Google::Apis::CloudbuildV1::RepoSource, decorator: Google::Apis::CloudbuildV1::RepoSource::Representation
property :storage_source, as: 'storageSource', class: Google::Apis::CloudbuildV1::StorageSource, decorator: Google::Apis::CloudbuildV1::StorageSource::Representation property :storage_source, as: 'storageSource', class: Google::Apis::CloudbuildV1::StorageSource, decorator: Google::Apis::CloudbuildV1::StorageSource::Representation
property :repo_source, as: 'repoSource', class: Google::Apis::CloudbuildV1::RepoSource, decorator: Google::Apis::CloudbuildV1::RepoSource::Representation
end end
end end
@ -169,9 +244,9 @@ module Google
class StorageSource class StorageSource
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :generation, as: 'generation'
property :bucket, as: 'bucket' property :bucket, as: 'bucket'
property :object, as: 'object' property :object, as: 'object'
property :generation, as: 'generation'
end end
end end
@ -210,18 +285,6 @@ module Google
end end
end end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :response, as: 'response'
property :name, as: 'name'
property :error, as: 'error', class: Google::Apis::CloudbuildV1::Status, decorator: Google::Apis::CloudbuildV1::Status::Representation
hash :metadata, as: 'metadata'
property :done, as: 'done'
end
end
class ListBuildTriggersResponse class ListBuildTriggersResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -230,11 +293,34 @@ module Google
end end
end end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :done, as: 'done'
hash :response, as: 'response'
property :name, as: 'name'
property :error, as: 'error', class: Google::Apis::CloudbuildV1::Status, decorator: Google::Apis::CloudbuildV1::Status::Representation
hash :metadata, as: 'metadata'
end
end
class BuiltImage class BuiltImage
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :digest, as: 'digest'
property :name, as: 'name' property :name, as: 'name'
property :digest, as: 'digest'
end
end
class RepoSource
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :project_id, as: 'projectId'
property :repo_name, as: 'repoName'
property :branch_name, as: 'branchName'
property :tag_name, as: 'tagName'
property :commit_sha, as: 'commitSha'
end end
end end
@ -259,17 +345,6 @@ module Google
end end
end end
class RepoSource
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :tag_name, as: 'tagName'
property :commit_sha, as: 'commitSha'
property :project_id, as: 'projectId'
property :repo_name, as: 'repoName'
property :branch_name, as: 'branchName'
end
end
class FileHashes class FileHashes
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -286,81 +361,6 @@ module Google
collection :details, as: 'details' collection :details, as: 'details'
end end
end end
class Empty
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class BuildTrigger
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :create_time, as: 'createTime'
property :disabled, as: 'disabled'
property :trigger_template, as: 'triggerTemplate', class: Google::Apis::CloudbuildV1::RepoSource, decorator: Google::Apis::CloudbuildV1::RepoSource::Representation
property :filename, as: 'filename'
property :id, as: 'id'
property :build, as: 'build', class: Google::Apis::CloudbuildV1::Build, decorator: Google::Apis::CloudbuildV1::Build::Representation
hash :substitutions, as: 'substitutions'
property :description, as: 'description'
end
end
class Build
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :create_time, as: 'createTime'
property :source_provenance, as: 'sourceProvenance', class: Google::Apis::CloudbuildV1::SourceProvenance, decorator: Google::Apis::CloudbuildV1::SourceProvenance::Representation
collection :images, as: 'images'
property :project_id, as: 'projectId'
property :finish_time, as: 'finishTime'
property :log_url, as: 'logUrl'
property :source, as: 'source', class: Google::Apis::CloudbuildV1::Source, decorator: Google::Apis::CloudbuildV1::Source::Representation
property :options, as: 'options', class: Google::Apis::CloudbuildV1::BuildOptions, decorator: Google::Apis::CloudbuildV1::BuildOptions::Representation
property :timeout, as: 'timeout'
property :status, as: 'status'
property :status_detail, as: 'statusDetail'
property :logs_bucket, as: 'logsBucket'
property :results, as: 'results', class: Google::Apis::CloudbuildV1::Results, decorator: Google::Apis::CloudbuildV1::Results::Representation
collection :steps, as: 'steps', class: Google::Apis::CloudbuildV1::BuildStep, decorator: Google::Apis::CloudbuildV1::BuildStep::Representation
property :build_trigger_id, as: 'buildTriggerId'
property :id, as: 'id'
property :start_time, as: 'startTime'
hash :substitutions, as: 'substitutions'
end
end
class CancelBuildRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class ListBuildsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :builds, as: 'builds', class: Google::Apis::CloudbuildV1::Build, decorator: Google::Apis::CloudbuildV1::Build::Representation
end
end
class ListOperationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :operations, as: 'operations', class: Google::Apis::CloudbuildV1::Operation, decorator: Google::Apis::CloudbuildV1::Operation::Representation
end
end
end end
end end
end end

View File

@ -46,19 +46,13 @@ module Google
super('https://cloudbuild.googleapis.com/', '') super('https://cloudbuild.googleapis.com/', '')
end end
# Starts asynchronous cancellation on a long-running operation. The server # Returns information about a previously requested build.
# makes a best effort to cancel the operation, but success is not # The Build that is returned includes its status (e.g., success or failure,
# guaranteed. If the server doesn't support this method, it returns # or in-progress), and timing information.
# `google.rpc.Code.UNIMPLEMENTED`. Clients can use # @param [String] project_id
# Operations.GetOperation or # ID of the project.
# other methods to check whether the cancellation succeeded or whether the # @param [String] id
# operation completed despite cancellation. On successful cancellation, # ID of the build.
# the operation is not deleted; instead, it becomes an operation with
# an Operation.error value with a google.rpc.Status.code of 1,
# corresponding to `Code.CANCELLED`.
# @param [String] name
# The name of the operation resource to be cancelled.
# @param [Google::Apis::CloudbuildV1::CancelOperationRequest] cancel_operation_request_object
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -68,38 +62,36 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::CloudbuildV1::Empty] parsed result object # @yieldparam result [Google::Apis::CloudbuildV1::Build] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::CloudbuildV1::Empty] # @return [Google::Apis::CloudbuildV1::Build]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def cancel_operation(name, cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def get_project_build(project_id, id, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}:cancel', options) command = make_simple_command(:get, 'v1/projects/{projectId}/builds/{id}', options)
command.request_representation = Google::Apis::CloudbuildV1::CancelOperationRequest::Representation command.response_representation = Google::Apis::CloudbuildV1::Build::Representation
command.request_object = cancel_operation_request_object command.response_class = Google::Apis::CloudbuildV1::Build
command.response_representation = Google::Apis::CloudbuildV1::Empty::Representation command.params['projectId'] = project_id unless project_id.nil?
command.response_class = Google::Apis::CloudbuildV1::Empty command.params['id'] = id unless id.nil?
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Lists operations that match the specified filter in the request. If the # Lists previously requested builds.
# server doesn't support this method, it returns `UNIMPLEMENTED`. # Previously requested builds may still be in-progress, or may have finished
# NOTE: the `name` binding below allows API services to override the binding # successfully or unsuccessfully.
# to use different resource name schemes, such as `users/*/operations`. # @param [String] project_id
# @param [String] name # ID of the project.
# The name of the operation collection.
# @param [String] filter
# The standard list filter.
# @param [String] page_token
# The standard list page token.
# @param [Fixnum] page_size # @param [Fixnum] page_size
# The standard list page size. # Number of results to return in the list.
# @param [String] filter
# The raw filter text to constrain the results.
# @param [String] page_token
# Token to provide to skip to a particular spot in the list.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -109,32 +101,34 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::CloudbuildV1::ListOperationsResponse] parsed result object # @yieldparam result [Google::Apis::CloudbuildV1::ListBuildsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::CloudbuildV1::ListOperationsResponse] # @return [Google::Apis::CloudbuildV1::ListBuildsResponse]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_operations(name, filter: nil, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block) def list_project_builds(project_id, page_size: nil, filter: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options) command = make_simple_command(:get, 'v1/projects/{projectId}/builds', options)
command.response_representation = Google::Apis::CloudbuildV1::ListOperationsResponse::Representation command.response_representation = Google::Apis::CloudbuildV1::ListBuildsResponse::Representation
command.response_class = Google::Apis::CloudbuildV1::ListOperationsResponse command.response_class = Google::Apis::CloudbuildV1::ListBuildsResponse
command.params['name'] = name unless name.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['filter'] = filter unless filter.nil? command.query['filter'] = filter unless filter.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Gets the latest state of a long-running operation. Clients can use this # Starts a build with the specified configuration.
# method to poll the operation result at intervals as recommended by the API # The long-running Operation returned by this method will include the ID of
# service. # the build, which can be passed to GetBuild to determine its status (e.g.,
# @param [String] name # success or failure).
# The name of the operation resource. # @param [String] project_id
# ID of the project.
# @param [Google::Apis::CloudbuildV1::Build] build_object
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -152,22 +146,24 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_operation(name, fields: nil, quota_user: nil, options: nil, &block) def create_project_build(project_id, build_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options) command = make_simple_command(:post, 'v1/projects/{projectId}/builds', options)
command.request_representation = Google::Apis::CloudbuildV1::Build::Representation
command.request_object = build_object
command.response_representation = Google::Apis::CloudbuildV1::Operation::Representation command.response_representation = Google::Apis::CloudbuildV1::Operation::Representation
command.response_class = Google::Apis::CloudbuildV1::Operation command.response_class = Google::Apis::CloudbuildV1::Operation
command.params['name'] = name unless name.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Deletes an BuildTrigger by its project ID and trigger ID. # Cancels a requested build in progress.
# This API is experimental.
# @param [String] project_id # @param [String] project_id
# ID of the project that owns the trigger. # ID of the project.
# @param [String] trigger_id # @param [String] id
# ID of the BuildTrigger to delete. # ID of the build.
# @param [Google::Apis::CloudbuildV1::CancelBuildRequest] cancel_build_request_object
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -177,20 +173,22 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::CloudbuildV1::Empty] parsed result object # @yieldparam result [Google::Apis::CloudbuildV1::Build] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::CloudbuildV1::Empty] # @return [Google::Apis::CloudbuildV1::Build]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_project_trigger(project_id, trigger_id, fields: nil, quota_user: nil, options: nil, &block) def cancel_build(project_id, id, cancel_build_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/projects/{projectId}/triggers/{triggerId}', options) command = make_simple_command(:post, 'v1/projects/{projectId}/builds/{id}:cancel', options)
command.response_representation = Google::Apis::CloudbuildV1::Empty::Representation command.request_representation = Google::Apis::CloudbuildV1::CancelBuildRequest::Representation
command.response_class = Google::Apis::CloudbuildV1::Empty command.request_object = cancel_build_request_object
command.response_representation = Google::Apis::CloudbuildV1::Build::Representation
command.response_class = Google::Apis::CloudbuildV1::Build
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.params['triggerId'] = trigger_id unless trigger_id.nil? command.params['id'] = id unless id.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -332,12 +330,12 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Cancels a requested build in progress. # Deletes an BuildTrigger by its project ID and trigger ID.
# This API is experimental.
# @param [String] project_id # @param [String] project_id
# ID of the project. # ID of the project that owns the trigger.
# @param [String] id # @param [String] trigger_id
# ID of the build. # ID of the BuildTrigger to delete.
# @param [Google::Apis::CloudbuildV1::CancelBuildRequest] cancel_build_request_object
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -347,73 +345,37 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::CloudbuildV1::Build] parsed result object # @yieldparam result [Google::Apis::CloudbuildV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::CloudbuildV1::Build] # @return [Google::Apis::CloudbuildV1::Empty]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def cancel_build(project_id, id, cancel_build_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def delete_project_trigger(project_id, trigger_id, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}/builds/{id}:cancel', options) command = make_simple_command(:delete, 'v1/projects/{projectId}/triggers/{triggerId}', options)
command.request_representation = Google::Apis::CloudbuildV1::CancelBuildRequest::Representation command.response_representation = Google::Apis::CloudbuildV1::Empty::Representation
command.request_object = cancel_build_request_object command.response_class = Google::Apis::CloudbuildV1::Empty
command.response_representation = Google::Apis::CloudbuildV1::Build::Representation
command.response_class = Google::Apis::CloudbuildV1::Build
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.params['id'] = id unless id.nil? command.params['triggerId'] = trigger_id unless trigger_id.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Returns information about a previously requested build. # Lists operations that match the specified filter in the request. If the
# The Build that is returned includes its status (e.g., success or failure, # server doesn't support this method, it returns `UNIMPLEMENTED`.
# or in-progress), and timing information. # NOTE: the `name` binding below allows API services to override the binding
# @param [String] project_id # to use different resource name schemes, such as `users/*/operations`.
# ID of the project. # @param [String] name
# @param [String] id # The name of the operation collection.
# ID of the build.
# @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::CloudbuildV1::Build] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudbuildV1::Build]
#
# @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_build(project_id, id, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/projects/{projectId}/builds/{id}', options)
command.response_representation = Google::Apis::CloudbuildV1::Build::Representation
command.response_class = Google::Apis::CloudbuildV1::Build
command.params['projectId'] = project_id unless project_id.nil?
command.params['id'] = id unless id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists previously requested builds.
# Previously requested builds may still be in-progress, or may have finished
# successfully or unsuccessfully.
# @param [String] project_id
# ID of the project.
# @param [String] filter
# The raw filter text to constrain the results.
# @param [String] page_token
# Token to provide to skip to a particular spot in the list.
# @param [Fixnum] page_size # @param [Fixnum] page_size
# Number of results to return in the list. # The standard list page size.
# @param [String] filter
# The standard list filter.
# @param [String] page_token
# The standard list page token.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -423,34 +385,32 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::CloudbuildV1::ListBuildsResponse] parsed result object # @yieldparam result [Google::Apis::CloudbuildV1::ListOperationsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::CloudbuildV1::ListBuildsResponse] # @return [Google::Apis::CloudbuildV1::ListOperationsResponse]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_project_builds(project_id, filter: nil, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block) def list_operations(name, page_size: nil, filter: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/projects/{projectId}/builds', options) command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::CloudbuildV1::ListBuildsResponse::Representation command.response_representation = Google::Apis::CloudbuildV1::ListOperationsResponse::Representation
command.response_class = Google::Apis::CloudbuildV1::ListBuildsResponse command.response_class = Google::Apis::CloudbuildV1::ListOperationsResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['name'] = name unless name.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['filter'] = filter unless filter.nil? command.query['filter'] = filter unless filter.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Starts a build with the specified configuration. # Gets the latest state of a long-running operation. Clients can use this
# The long-running Operation returned by this method will include the ID of # method to poll the operation result at intervals as recommended by the API
# the build, which can be passed to GetBuild to determine its status (e.g., # service.
# success or failure). # @param [String] name
# @param [String] project_id # The name of the operation resource.
# ID of the project.
# @param [Google::Apis::CloudbuildV1::Build] build_object
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -468,13 +428,53 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def create_project_build(project_id, build_object = nil, fields: nil, quota_user: nil, options: nil, &block) def get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}/builds', options) command = make_simple_command(:get, 'v1/{+name}', options)
command.request_representation = Google::Apis::CloudbuildV1::Build::Representation
command.request_object = build_object
command.response_representation = Google::Apis::CloudbuildV1::Operation::Representation command.response_representation = Google::Apis::CloudbuildV1::Operation::Representation
command.response_class = Google::Apis::CloudbuildV1::Operation command.response_class = Google::Apis::CloudbuildV1::Operation
command.params['projectId'] = project_id unless project_id.nil? 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
# Starts asynchronous cancellation on a long-running operation. The server
# makes a best effort to cancel the operation, but success is not
# guaranteed. If the server doesn't support this method, it returns
# `google.rpc.Code.UNIMPLEMENTED`. Clients can use
# Operations.GetOperation or
# other methods to check whether the cancellation succeeded or whether the
# operation completed despite cancellation. On successful cancellation,
# the operation is not deleted; instead, it becomes an operation with
# an Operation.error value with a google.rpc.Status.code of 1,
# corresponding to `Code.CANCELLED`.
# @param [String] name
# The name of the operation resource to be cancelled.
# @param [Google::Apis::CloudbuildV1::CancelOperationRequest] cancel_operation_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::CloudbuildV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudbuildV1::Empty]
#
# @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 cancel_operation(name, cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}:cancel', options)
command.request_representation = Google::Apis::CloudbuildV1::CancelOperationRequest::Representation
command.request_object = cancel_operation_request_object
command.response_representation = Google::Apis::CloudbuildV1::Empty::Representation
command.response_class = Google::Apis::CloudbuildV1::Empty
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)

View File

@ -28,11 +28,11 @@ module Google
VERSION = 'V2' VERSION = 'V2'
REVISION = '20170322' REVISION = '20170322'
# Manage cloud debugger
AUTH_CLOUD_DEBUGGER = 'https://www.googleapis.com/auth/cloud_debugger'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
# Manage cloud debugger
AUTH_CLOUD_DEBUGGER = 'https://www.googleapis.com/auth/cloud_debugger'
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -22,90 +22,6 @@ module Google
module Apis module Apis
module ClouddebuggerV2 module ClouddebuggerV2
class StatusMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GitSourceContext
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Variable
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class StackFrame
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RepoId
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FormatMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ExtendedSourceContext
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListDebuggeesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AliasContext
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SourceLocation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Debuggee
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListActiveBreakpointsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ProjectRepoId
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CloudWorkspaceSourceContext class CloudWorkspaceSourceContext
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -184,13 +100,235 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class StatusMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GitSourceContext
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Variable
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class StackFrame
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RepoId
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FormatMessage
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ExtendedSourceContext
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListDebuggeesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AliasContext
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SourceLocation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Debuggee
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ProjectRepoId
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListActiveBreakpointsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CloudWorkspaceSourceContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :snapshot_id, as: 'snapshotId'
property :workspace_id, as: 'workspaceId', class: Google::Apis::ClouddebuggerV2::CloudWorkspaceId, decorator: Google::Apis::ClouddebuggerV2::CloudWorkspaceId::Representation
end
end
class UpdateActiveBreakpointResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class GerritSourceContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :gerrit_project, as: 'gerritProject'
property :alias_context, as: 'aliasContext', class: Google::Apis::ClouddebuggerV2::AliasContext, decorator: Google::Apis::ClouddebuggerV2::AliasContext::Representation
property :host_uri, as: 'hostUri'
property :revision_id, as: 'revisionId'
property :alias_name, as: 'aliasName'
end
end
class CloudWorkspaceId
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :repo_id, as: 'repoId', class: Google::Apis::ClouddebuggerV2::RepoId, decorator: Google::Apis::ClouddebuggerV2::RepoId::Representation
end
end
class ListBreakpointsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :breakpoints, as: 'breakpoints', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
property :next_wait_token, as: 'nextWaitToken'
end
end
class Breakpoint
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
property :location, as: 'location', class: Google::Apis::ClouddebuggerV2::SourceLocation, decorator: Google::Apis::ClouddebuggerV2::SourceLocation::Representation
property :final_time, as: 'finalTime'
collection :variable_table, as: 'variableTable', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
property :create_time, as: 'createTime'
property :log_message_format, as: 'logMessageFormat'
hash :labels, as: 'labels'
collection :expressions, as: 'expressions'
collection :evaluated_expressions, as: 'evaluatedExpressions', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
property :is_final_state, as: 'isFinalState'
collection :stack_frames, as: 'stackFrames', class: Google::Apis::ClouddebuggerV2::StackFrame, decorator: Google::Apis::ClouddebuggerV2::StackFrame::Representation
property :condition, as: 'condition'
property :status, as: 'status', class: Google::Apis::ClouddebuggerV2::StatusMessage, decorator: Google::Apis::ClouddebuggerV2::StatusMessage::Representation
property :user_email, as: 'userEmail'
property :action, as: 'action'
property :log_level, as: 'logLevel'
end
end
class UpdateActiveBreakpointRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :breakpoint, as: 'breakpoint', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
end
end
class SetBreakpointResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :breakpoint, as: 'breakpoint', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
end
end
class SourceContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :gerrit, as: 'gerrit', class: Google::Apis::ClouddebuggerV2::GerritSourceContext, decorator: Google::Apis::ClouddebuggerV2::GerritSourceContext::Representation
property :cloud_repo, as: 'cloudRepo', class: Google::Apis::ClouddebuggerV2::CloudRepoSourceContext, decorator: Google::Apis::ClouddebuggerV2::CloudRepoSourceContext::Representation
property :cloud_workspace, as: 'cloudWorkspace', class: Google::Apis::ClouddebuggerV2::CloudWorkspaceSourceContext, decorator: Google::Apis::ClouddebuggerV2::CloudWorkspaceSourceContext::Representation
property :git, as: 'git', class: Google::Apis::ClouddebuggerV2::GitSourceContext, decorator: Google::Apis::ClouddebuggerV2::GitSourceContext::Representation
end
end
class CloudRepoSourceContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :alias_context, as: 'aliasContext', class: Google::Apis::ClouddebuggerV2::AliasContext, decorator: Google::Apis::ClouddebuggerV2::AliasContext::Representation
property :revision_id, as: 'revisionId'
property :alias_name, as: 'aliasName'
property :repo_id, as: 'repoId', class: Google::Apis::ClouddebuggerV2::RepoId, decorator: Google::Apis::ClouddebuggerV2::RepoId::Representation
end
end
class RegisterDebuggeeResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :debuggee, as: 'debuggee', class: Google::Apis::ClouddebuggerV2::Debuggee, decorator: Google::Apis::ClouddebuggerV2::Debuggee::Representation
end
end
class RegisterDebuggeeRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :debuggee, as: 'debuggee', class: Google::Apis::ClouddebuggerV2::Debuggee, decorator: Google::Apis::ClouddebuggerV2::Debuggee::Representation
end
end
class GetBreakpointResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :breakpoint, as: 'breakpoint', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
end
end
class StatusMessage class StatusMessage
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :refers_to, as: 'refersTo'
property :is_error, as: 'isError' property :is_error, as: 'isError'
property :description, as: 'description', class: Google::Apis::ClouddebuggerV2::FormatMessage, decorator: Google::Apis::ClouddebuggerV2::FormatMessage::Representation property :description, as: 'description', class: Google::Apis::ClouddebuggerV2::FormatMessage, decorator: Google::Apis::ClouddebuggerV2::FormatMessage::Representation
property :refers_to, as: 'refersTo'
end end
end end
@ -205,36 +343,36 @@ module Google
class Variable class Variable
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :value, as: 'value'
property :var_table_index, as: 'varTableIndex'
collection :members, as: 'members', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
property :status, as: 'status', class: Google::Apis::ClouddebuggerV2::StatusMessage, decorator: Google::Apis::ClouddebuggerV2::StatusMessage::Representation property :status, as: 'status', class: Google::Apis::ClouddebuggerV2::StatusMessage, decorator: Google::Apis::ClouddebuggerV2::StatusMessage::Representation
property :name, as: 'name' property :name, as: 'name'
property :type, as: 'type' property :type, as: 'type'
property :var_table_index, as: 'varTableIndex'
property :value, as: 'value'
collection :members, as: 'members', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
end end
end end
class StackFrame class StackFrame
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :function, as: 'function'
collection :arguments, as: 'arguments', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation collection :arguments, as: 'arguments', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
collection :locals, as: 'locals', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation collection :locals, as: 'locals', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
property :location, as: 'location', class: Google::Apis::ClouddebuggerV2::SourceLocation, decorator: Google::Apis::ClouddebuggerV2::SourceLocation::Representation property :location, as: 'location', class: Google::Apis::ClouddebuggerV2::SourceLocation, decorator: Google::Apis::ClouddebuggerV2::SourceLocation::Representation
property :function, as: 'function'
end end
end end
class RepoId class RepoId
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :uid, as: 'uid'
property :project_repo_id, as: 'projectRepoId', class: Google::Apis::ClouddebuggerV2::ProjectRepoId, decorator: Google::Apis::ClouddebuggerV2::ProjectRepoId::Representation property :project_repo_id, as: 'projectRepoId', class: Google::Apis::ClouddebuggerV2::ProjectRepoId, decorator: Google::Apis::ClouddebuggerV2::ProjectRepoId::Representation
property :uid, as: 'uid'
end end
end end
@ -288,16 +426,16 @@ module Google
class Debuggee class Debuggee
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :uniquifier, as: 'uniquifier'
property :description, as: 'description' property :description, as: 'description'
property :uniquifier, as: 'uniquifier'
collection :source_contexts, as: 'sourceContexts', class: Google::Apis::ClouddebuggerV2::SourceContext, decorator: Google::Apis::ClouddebuggerV2::SourceContext::Representation collection :source_contexts, as: 'sourceContexts', class: Google::Apis::ClouddebuggerV2::SourceContext, decorator: Google::Apis::ClouddebuggerV2::SourceContext::Representation
collection :ext_source_contexts, as: 'extSourceContexts', class: Google::Apis::ClouddebuggerV2::ExtendedSourceContext, decorator: Google::Apis::ClouddebuggerV2::ExtendedSourceContext::Representation collection :ext_source_contexts, as: 'extSourceContexts', class: Google::Apis::ClouddebuggerV2::ExtendedSourceContext, decorator: Google::Apis::ClouddebuggerV2::ExtendedSourceContext::Representation
hash :labels, as: 'labels' hash :labels, as: 'labels'
property :is_inactive, as: 'isInactive'
property :status, as: 'status', class: Google::Apis::ClouddebuggerV2::StatusMessage, decorator: Google::Apis::ClouddebuggerV2::StatusMessage::Representation property :status, as: 'status', class: Google::Apis::ClouddebuggerV2::StatusMessage, decorator: Google::Apis::ClouddebuggerV2::StatusMessage::Representation
property :is_inactive, as: 'isInactive'
property :project, as: 'project' property :project, as: 'project'
property :is_disabled, as: 'isDisabled' property :is_disabled, as: 'isDisabled'
property :agent_version, as: 'agentVersion' property :agent_version, as: 'agentVersion'
@ -305,16 +443,6 @@ module Google
end end
end end
class ListActiveBreakpointsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :breakpoints, as: 'breakpoints', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
property :wait_expired, as: 'waitExpired'
property :next_wait_token, as: 'nextWaitToken'
end
end
class ProjectRepoId class ProjectRepoId
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -323,141 +451,13 @@ module Google
end end
end end
class CloudWorkspaceSourceContext class ListActiveBreakpointsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :workspace_id, as: 'workspaceId', class: Google::Apis::ClouddebuggerV2::CloudWorkspaceId, decorator: Google::Apis::ClouddebuggerV2::CloudWorkspaceId::Representation
property :snapshot_id, as: 'snapshotId'
end
end
class UpdateActiveBreakpointResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class GerritSourceContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :host_uri, as: 'hostUri'
property :revision_id, as: 'revisionId'
property :alias_name, as: 'aliasName'
property :gerrit_project, as: 'gerritProject'
property :alias_context, as: 'aliasContext', class: Google::Apis::ClouddebuggerV2::AliasContext, decorator: Google::Apis::ClouddebuggerV2::AliasContext::Representation
end
end
class CloudWorkspaceId
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :repo_id, as: 'repoId', class: Google::Apis::ClouddebuggerV2::RepoId, decorator: Google::Apis::ClouddebuggerV2::RepoId::Representation
property :name, as: 'name'
end
end
class ListBreakpointsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_wait_token, as: 'nextWaitToken'
collection :breakpoints, as: 'breakpoints', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation collection :breakpoints, as: 'breakpoints', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
property :next_wait_token, as: 'nextWaitToken' property :wait_expired, as: 'waitExpired'
end
end
class Breakpoint
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :expressions, as: 'expressions'
collection :evaluated_expressions, as: 'evaluatedExpressions', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
property :is_final_state, as: 'isFinalState'
collection :stack_frames, as: 'stackFrames', class: Google::Apis::ClouddebuggerV2::StackFrame, decorator: Google::Apis::ClouddebuggerV2::StackFrame::Representation
property :condition, as: 'condition'
property :status, as: 'status', class: Google::Apis::ClouddebuggerV2::StatusMessage, decorator: Google::Apis::ClouddebuggerV2::StatusMessage::Representation
property :user_email, as: 'userEmail'
property :action, as: 'action'
property :log_level, as: 'logLevel'
property :id, as: 'id'
property :location, as: 'location', class: Google::Apis::ClouddebuggerV2::SourceLocation, decorator: Google::Apis::ClouddebuggerV2::SourceLocation::Representation
property :final_time, as: 'finalTime'
collection :variable_table, as: 'variableTable', class: Google::Apis::ClouddebuggerV2::Variable, decorator: Google::Apis::ClouddebuggerV2::Variable::Representation
hash :labels, as: 'labels'
property :log_message_format, as: 'logMessageFormat'
property :create_time, as: 'createTime'
end
end
class UpdateActiveBreakpointRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :breakpoint, as: 'breakpoint', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
end
end
class SetBreakpointResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :breakpoint, as: 'breakpoint', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
end
end
class SourceContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :git, as: 'git', class: Google::Apis::ClouddebuggerV2::GitSourceContext, decorator: Google::Apis::ClouddebuggerV2::GitSourceContext::Representation
property :gerrit, as: 'gerrit', class: Google::Apis::ClouddebuggerV2::GerritSourceContext, decorator: Google::Apis::ClouddebuggerV2::GerritSourceContext::Representation
property :cloud_repo, as: 'cloudRepo', class: Google::Apis::ClouddebuggerV2::CloudRepoSourceContext, decorator: Google::Apis::ClouddebuggerV2::CloudRepoSourceContext::Representation
property :cloud_workspace, as: 'cloudWorkspace', class: Google::Apis::ClouddebuggerV2::CloudWorkspaceSourceContext, decorator: Google::Apis::ClouddebuggerV2::CloudWorkspaceSourceContext::Representation
end
end
class CloudRepoSourceContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :revision_id, as: 'revisionId'
property :alias_name, as: 'aliasName'
property :repo_id, as: 'repoId', class: Google::Apis::ClouddebuggerV2::RepoId, decorator: Google::Apis::ClouddebuggerV2::RepoId::Representation
property :alias_context, as: 'aliasContext', class: Google::Apis::ClouddebuggerV2::AliasContext, decorator: Google::Apis::ClouddebuggerV2::AliasContext::Representation
end
end
class RegisterDebuggeeResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :debuggee, as: 'debuggee', class: Google::Apis::ClouddebuggerV2::Debuggee, decorator: Google::Apis::ClouddebuggerV2::Debuggee::Representation
end
end
class RegisterDebuggeeRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :debuggee, as: 'debuggee', class: Google::Apis::ClouddebuggerV2::Debuggee, decorator: Google::Apis::ClouddebuggerV2::Debuggee::Representation
end
end
class GetBreakpointResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :breakpoint, as: 'breakpoint', class: Google::Apis::ClouddebuggerV2::Breakpoint, decorator: Google::Apis::ClouddebuggerV2::Breakpoint::Representation
end end
end end
end end

View File

@ -199,9 +199,6 @@ module Google
# Lists all breakpoints for the debuggee. # Lists all breakpoints for the debuggee.
# @param [String] debuggee_id # @param [String] debuggee_id
# ID of the debuggee whose breakpoints to list. # ID of the debuggee whose breakpoints to list.
# @param [Boolean] strip_results
# This field is deprecated. The following fields are always stripped out of
# the result: `stack_frames`, `evaluated_expressions` and `variable_table`.
# @param [String] wait_token # @param [String] wait_token
# A wait token that, if specified, blocks the call until the breakpoints # A wait token that, if specified, blocks the call until the breakpoints
# list has changed, or a server selected timeout has expired. The value # list has changed, or a server selected timeout has expired. The value
@ -213,12 +210,15 @@ module Google
# @param [String] client_version # @param [String] client_version
# The client version making the call. # The client version making the call.
# Following: `domain/type/version` (e.g., `google.com/intellij/v1`). # Following: `domain/type/version` (e.g., `google.com/intellij/v1`).
# @param [Boolean] include_all_users
# When set to `true`, the response includes the list of breakpoints set by
# any user. Otherwise, it includes only breakpoints set by the caller.
# @param [Boolean] include_inactive # @param [Boolean] include_inactive
# When set to `true`, the response includes active and inactive # When set to `true`, the response includes active and inactive
# breakpoints. Otherwise, it includes only active breakpoints. # breakpoints. Otherwise, it includes only active breakpoints.
# @param [Boolean] include_all_users
# When set to `true`, the response includes the list of breakpoints set by
# any user. Otherwise, it includes only breakpoints set by the caller.
# @param [Boolean] strip_results
# This field is deprecated. The following fields are always stripped out of
# the result: `stack_frames`, `evaluated_expressions` and `variable_table`.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -236,17 +236,17 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_debugger_debuggee_breakpoints(debuggee_id, strip_results: nil, wait_token: nil, action_value: nil, client_version: nil, include_all_users: nil, include_inactive: nil, fields: nil, quota_user: nil, options: nil, &block) def list_debugger_debuggee_breakpoints(debuggee_id, wait_token: nil, action_value: nil, client_version: nil, include_inactive: nil, include_all_users: nil, strip_results: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v2/debugger/debuggees/{debuggeeId}/breakpoints', options) command = make_simple_command(:get, 'v2/debugger/debuggees/{debuggeeId}/breakpoints', options)
command.response_representation = Google::Apis::ClouddebuggerV2::ListBreakpointsResponse::Representation command.response_representation = Google::Apis::ClouddebuggerV2::ListBreakpointsResponse::Representation
command.response_class = Google::Apis::ClouddebuggerV2::ListBreakpointsResponse command.response_class = Google::Apis::ClouddebuggerV2::ListBreakpointsResponse
command.params['debuggeeId'] = debuggee_id unless debuggee_id.nil? command.params['debuggeeId'] = debuggee_id unless debuggee_id.nil?
command.query['stripResults'] = strip_results unless strip_results.nil?
command.query['waitToken'] = wait_token unless wait_token.nil? command.query['waitToken'] = wait_token unless wait_token.nil?
command.query['action.value'] = action_value unless action_value.nil? command.query['action.value'] = action_value unless action_value.nil?
command.query['clientVersion'] = client_version unless client_version.nil? command.query['clientVersion'] = client_version unless client_version.nil?
command.query['includeAllUsers'] = include_all_users unless include_all_users.nil?
command.query['includeInactive'] = include_inactive unless include_inactive.nil? command.query['includeInactive'] = include_inactive unless include_inactive.nil?
command.query['includeAllUsers'] = include_all_users unless include_all_users.nil?
command.query['stripResults'] = strip_results unless strip_results.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -289,58 +289,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Returns the list of all active breakpoints for the debuggee.
# The breakpoint specification (location, condition, and expression
# fields) is semantically immutable, although the field values may
# change. For example, an agent may update the location line number
# to reflect the actual line where the breakpoint was set, but this
# doesn't change the breakpoint semantics.
# This means that an agent does not need to check if a breakpoint has changed
# when it encounters the same breakpoint on a successive call.
# Moreover, an agent should remember the breakpoints that are completed
# until the controller removes them from the active list to avoid
# setting those breakpoints again.
# @param [String] debuggee_id
# Identifies the debuggee.
# @param [Boolean] success_on_timeout
# If set to `true`, returns `google.rpc.Code.OK` status and sets the
# `wait_expired` response field to `true` when the server-selected timeout
# has expired (recommended).
# If set to `false`, returns `google.rpc.Code.ABORTED` status when the
# server-selected timeout has expired (deprecated).
# @param [String] wait_token
# A wait token that, if specified, blocks the method call until the list
# of active breakpoints has changed, or a server selected timeout has
# expired. The value should be set from the last returned response.
# @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::ClouddebuggerV2::ListActiveBreakpointsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ClouddebuggerV2::ListActiveBreakpointsResponse]
#
# @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 list_controller_debuggee_breakpoints(debuggee_id, success_on_timeout: nil, wait_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v2/controller/debuggees/{debuggeeId}/breakpoints', options)
command.response_representation = Google::Apis::ClouddebuggerV2::ListActiveBreakpointsResponse::Representation
command.response_class = Google::Apis::ClouddebuggerV2::ListActiveBreakpointsResponse
command.params['debuggeeId'] = debuggee_id unless debuggee_id.nil?
command.query['successOnTimeout'] = success_on_timeout unless success_on_timeout.nil?
command.query['waitToken'] = wait_token unless wait_token.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Updates the breakpoint state or mutable fields. # Updates the breakpoint state or mutable fields.
# The entire Breakpoint message must be sent back to the controller # The entire Breakpoint message must be sent back to the controller
# service. # service.
@ -383,6 +331,58 @@ module Google
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Returns the list of all active breakpoints for the debuggee.
# The breakpoint specification (location, condition, and expression
# fields) is semantically immutable, although the field values may
# change. For example, an agent may update the location line number
# to reflect the actual line where the breakpoint was set, but this
# doesn't change the breakpoint semantics.
# This means that an agent does not need to check if a breakpoint has changed
# when it encounters the same breakpoint on a successive call.
# Moreover, an agent should remember the breakpoints that are completed
# until the controller removes them from the active list to avoid
# setting those breakpoints again.
# @param [String] debuggee_id
# Identifies the debuggee.
# @param [String] wait_token
# A wait token that, if specified, blocks the method call until the list
# of active breakpoints has changed, or a server selected timeout has
# expired. The value should be set from the last returned response.
# @param [Boolean] success_on_timeout
# If set to `true`, returns `google.rpc.Code.OK` status and sets the
# `wait_expired` response field to `true` when the server-selected timeout
# has expired (recommended).
# If set to `false`, returns `google.rpc.Code.ABORTED` status when the
# server-selected timeout has expired (deprecated).
# @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::ClouddebuggerV2::ListActiveBreakpointsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ClouddebuggerV2::ListActiveBreakpointsResponse]
#
# @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 list_controller_debuggee_breakpoints(debuggee_id, wait_token: nil, success_on_timeout: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v2/controller/debuggees/{debuggeeId}/breakpoints', options)
command.response_representation = Google::Apis::ClouddebuggerV2::ListActiveBreakpointsResponse::Representation
command.response_class = Google::Apis::ClouddebuggerV2::ListActiveBreakpointsResponse
command.params['debuggeeId'] = debuggee_id unless debuggee_id.nil?
command.query['waitToken'] = wait_token unless wait_token.nil?
command.query['successOnTimeout'] = success_on_timeout unless success_on_timeout.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
protected protected

View File

@ -27,19 +27,24 @@ module Google
class ErrorGroupStats class ErrorGroupStats
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Description of a group of similar error events.
# Corresponds to the JSON property `group`
# @return [Google::Apis::ClouderrorreportingV1beta1::ErrorGroup]
attr_accessor :group
# Approximate first occurrence that was ever seen for this group
# and which matches the given filter criteria, ignoring the
# time_range that was specified in the request.
# Corresponds to the JSON property `firstSeenTime`
# @return [String]
attr_accessor :first_seen_time
# Approximate total number of events in the given group that match # Approximate total number of events in the given group that match
# the filter criteria. # the filter criteria.
# Corresponds to the JSON property `count` # Corresponds to the JSON property `count`
# @return [String] # @return [String]
attr_accessor :count attr_accessor :count
# Approximate last occurrence that was ever seen for this group and
# which matches the given filter criteria, ignoring the time_range
# that was specified in the request.
# Corresponds to the JSON property `lastSeenTime`
# @return [String]
attr_accessor :last_seen_time
# Approximate number of affected users in the given group that # Approximate number of affected users in the given group that
# match the filter criteria. # match the filter criteria.
# Users are distinguished by data in the `ErrorContext` of the # Users are distinguished by data in the `ErrorContext` of the
@ -56,6 +61,13 @@ module Google
# @return [String] # @return [String]
attr_accessor :affected_users_count attr_accessor :affected_users_count
# Approximate last occurrence that was ever seen for this group and
# which matches the given filter criteria, ignoring the time_range
# that was specified in the request.
# Corresponds to the JSON property `lastSeenTime`
# @return [String]
attr_accessor :last_seen_time
# The total number of services with a non-zero error count for the given # The total number of services with a non-zero error count for the given
# filter criteria. # filter criteria.
# Corresponds to the JSON property `numAffectedServices` # Corresponds to the JSON property `numAffectedServices`
@ -83,33 +95,21 @@ module Google
# @return [Array<Google::Apis::ClouderrorreportingV1beta1::TimedCount>] # @return [Array<Google::Apis::ClouderrorreportingV1beta1::TimedCount>]
attr_accessor :timed_counts attr_accessor :timed_counts
# Description of a group of similar error events.
# Corresponds to the JSON property `group`
# @return [Google::Apis::ClouderrorreportingV1beta1::ErrorGroup]
attr_accessor :group
# Approximate first occurrence that was ever seen for this group
# and which matches the given filter criteria, ignoring the
# time_range that was specified in the request.
# Corresponds to the JSON property `firstSeenTime`
# @return [String]
attr_accessor :first_seen_time
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@group = args[:group] if args.key?(:group)
@first_seen_time = args[:first_seen_time] if args.key?(:first_seen_time)
@count = args[:count] if args.key?(:count) @count = args[:count] if args.key?(:count)
@last_seen_time = args[:last_seen_time] if args.key?(:last_seen_time)
@affected_users_count = args[:affected_users_count] if args.key?(:affected_users_count) @affected_users_count = args[:affected_users_count] if args.key?(:affected_users_count)
@last_seen_time = args[:last_seen_time] if args.key?(:last_seen_time)
@num_affected_services = args[:num_affected_services] if args.key?(:num_affected_services) @num_affected_services = args[:num_affected_services] if args.key?(:num_affected_services)
@affected_services = args[:affected_services] if args.key?(:affected_services) @affected_services = args[:affected_services] if args.key?(:affected_services)
@representative = args[:representative] if args.key?(:representative) @representative = args[:representative] if args.key?(:representative)
@timed_counts = args[:timed_counts] if args.key?(:timed_counts) @timed_counts = args[:timed_counts] if args.key?(:timed_counts)
@group = args[:group] if args.key?(:group)
@first_seen_time = args[:first_seen_time] if args.key?(:first_seen_time)
end end
end end
@ -183,6 +183,12 @@ module Google
class ErrorGroup class ErrorGroup
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The group resource name.
# Example: <code>projects/my-project-123/groups/my-groupid</code>
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Group IDs are unique for a given project. If the same kind of error # Group IDs are unique for a given project. If the same kind of error
# occurs in different service contexts, it will receive the same group ID. # occurs in different service contexts, it will receive the same group ID.
# Corresponds to the JSON property `groupId` # Corresponds to the JSON property `groupId`
@ -194,21 +200,15 @@ module Google
# @return [Array<Google::Apis::ClouderrorreportingV1beta1::TrackingIssue>] # @return [Array<Google::Apis::ClouderrorreportingV1beta1::TrackingIssue>]
attr_accessor :tracking_issues attr_accessor :tracking_issues
# The group resource name.
# Example: <code>projects/my-project-123/groups/my-groupid</code>
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@name = args[:name] if args.key?(:name)
@group_id = args[:group_id] if args.key?(:group_id) @group_id = args[:group_id] if args.key?(:group_id)
@tracking_issues = args[:tracking_issues] if args.key?(:tracking_issues) @tracking_issues = args[:tracking_issues] if args.key?(:tracking_issues)
@name = args[:name] if args.key?(:name)
end end
end end
@ -313,6 +313,21 @@ module Google
class HttpRequestContext class HttpRequestContext
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The referrer information that is provided with the request.
# Corresponds to the JSON property `referrer`
# @return [String]
attr_accessor :referrer
# The user agent information that is provided with the request.
# Corresponds to the JSON property `userAgent`
# @return [String]
attr_accessor :user_agent
# The URL of the request.
# Corresponds to the JSON property `url`
# @return [String]
attr_accessor :url
# The HTTP response status code for the request. # The HTTP response status code for the request.
# Corresponds to the JSON property `responseStatusCode` # Corresponds to the JSON property `responseStatusCode`
# @return [Fixnum] # @return [Fixnum]
@ -331,33 +346,18 @@ module Google
# @return [String] # @return [String]
attr_accessor :remote_ip attr_accessor :remote_ip
# The referrer information that is provided with the request.
# Corresponds to the JSON property `referrer`
# @return [String]
attr_accessor :referrer
# The user agent information that is provided with the request.
# Corresponds to the JSON property `userAgent`
# @return [String]
attr_accessor :user_agent
# The URL of the request.
# Corresponds to the JSON property `url`
# @return [String]
attr_accessor :url
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@response_status_code = args[:response_status_code] if args.key?(:response_status_code)
@method_prop = args[:method_prop] if args.key?(:method_prop)
@remote_ip = args[:remote_ip] if args.key?(:remote_ip)
@referrer = args[:referrer] if args.key?(:referrer) @referrer = args[:referrer] if args.key?(:referrer)
@user_agent = args[:user_agent] if args.key?(:user_agent) @user_agent = args[:user_agent] if args.key?(:user_agent)
@url = args[:url] if args.key?(:url) @url = args[:url] if args.key?(:url)
@response_status_code = args[:response_status_code] if args.key?(:response_status_code)
@method_prop = args[:method_prop] if args.key?(:method_prop)
@remote_ip = args[:remote_ip] if args.key?(:remote_ip)
end end
end end
@ -414,19 +414,6 @@ module Google
class ErrorEvent class ErrorEvent
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Describes a running service that sends errors.
# Its version changes over time and multiple versions can run in parallel.
# Corresponds to the JSON property `serviceContext`
# @return [Google::Apis::ClouderrorreportingV1beta1::ServiceContext]
attr_accessor :service_context
# Time when the event occurred as provided in the error report.
# If the report did not contain a timestamp, the time the error was received
# by the Error Reporting system is used.
# Corresponds to the JSON property `eventTime`
# @return [String]
attr_accessor :event_time
# A description of the context in which an error occurred. # A description of the context in which an error occurred.
# This data should be provided by the application when reporting an error, # This data should be provided by the application when reporting an error,
# unless the # unless the
@ -440,16 +427,29 @@ module Google
# @return [String] # @return [String]
attr_accessor :message attr_accessor :message
# Describes a running service that sends errors.
# Its version changes over time and multiple versions can run in parallel.
# Corresponds to the JSON property `serviceContext`
# @return [Google::Apis::ClouderrorreportingV1beta1::ServiceContext]
attr_accessor :service_context
# Time when the event occurred as provided in the error report.
# If the report did not contain a timestamp, the time the error was received
# by the Error Reporting system is used.
# Corresponds to the JSON property `eventTime`
# @return [String]
attr_accessor :event_time
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@service_context = args[:service_context] if args.key?(:service_context)
@event_time = args[:event_time] if args.key?(:event_time)
@context = args[:context] if args.key?(:context) @context = args[:context] if args.key?(:context)
@message = args[:message] if args.key?(:message) @message = args[:message] if args.key?(:message)
@service_context = args[:service_context] if args.key?(:service_context)
@event_time = args[:event_time] if args.key?(:event_time)
end end
end end
@ -457,13 +457,6 @@ module Google
class ReportedErrorEvent class ReportedErrorEvent
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# [Optional] Time when the event occurred.
# If not provided, the time when the event was received by the
# Error Reporting system will be used.
# Corresponds to the JSON property `eventTime`
# @return [String]
attr_accessor :event_time
# A description of the context in which an error occurred. # A description of the context in which an error occurred.
# This data should be provided by the application when reporting an error, # This data should be provided by the application when reporting an error,
# unless the # unless the
@ -506,16 +499,23 @@ module Google
# @return [Google::Apis::ClouderrorreportingV1beta1::ServiceContext] # @return [Google::Apis::ClouderrorreportingV1beta1::ServiceContext]
attr_accessor :service_context attr_accessor :service_context
# [Optional] Time when the event occurred.
# If not provided, the time when the event was received by the
# Error Reporting system will be used.
# Corresponds to the JSON property `eventTime`
# @return [String]
attr_accessor :event_time
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@event_time = args[:event_time] if args.key?(:event_time)
@context = args[:context] if args.key?(:context) @context = args[:context] if args.key?(:context)
@message = args[:message] if args.key?(:message) @message = args[:message] if args.key?(:message)
@service_context = args[:service_context] if args.key?(:service_context) @service_context = args[:service_context] if args.key?(:service_context)
@event_time = args[:event_time] if args.key?(:event_time)
end end
end end
@ -526,6 +526,14 @@ module Google
class ErrorContext class ErrorContext
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# HTTP request data that is related to a reported error.
# This data should be provided by the application when reporting an error,
# unless the
# error report has been generated automatically from Google App Engine logs.
# Corresponds to the JSON property `httpRequest`
# @return [Google::Apis::ClouderrorreportingV1beta1::HttpRequestContext]
attr_accessor :http_request
# The user who caused or was affected by the crash. # The user who caused or was affected by the crash.
# This can be a user ID, an email address, or an arbitrary token that # This can be a user ID, an email address, or an arbitrary token that
# uniquely identifies the user. # uniquely identifies the user.
@ -546,23 +554,15 @@ module Google
# @return [Google::Apis::ClouderrorreportingV1beta1::SourceLocation] # @return [Google::Apis::ClouderrorreportingV1beta1::SourceLocation]
attr_accessor :report_location attr_accessor :report_location
# HTTP request data that is related to a reported error.
# This data should be provided by the application when reporting an error,
# unless the
# error report has been generated automatically from Google App Engine logs.
# Corresponds to the JSON property `httpRequest`
# @return [Google::Apis::ClouderrorreportingV1beta1::HttpRequestContext]
attr_accessor :http_request
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@http_request = args[:http_request] if args.key?(:http_request)
@user = args[:user] if args.key?(:user) @user = args[:user] if args.key?(:user)
@report_location = args[:report_location] if args.key?(:report_location) @report_location = args[:report_location] if args.key?(:report_location)
@http_request = args[:http_request] if args.key?(:http_request)
end end
end end

View File

@ -109,9 +109,12 @@ module Google
class ErrorGroupStats class ErrorGroupStats
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :group, as: 'group', class: Google::Apis::ClouderrorreportingV1beta1::ErrorGroup, decorator: Google::Apis::ClouderrorreportingV1beta1::ErrorGroup::Representation
property :first_seen_time, as: 'firstSeenTime'
property :count, as: 'count' property :count, as: 'count'
property :last_seen_time, as: 'lastSeenTime'
property :affected_users_count, as: 'affectedUsersCount' property :affected_users_count, as: 'affectedUsersCount'
property :last_seen_time, as: 'lastSeenTime'
property :num_affected_services, as: 'numAffectedServices' property :num_affected_services, as: 'numAffectedServices'
collection :affected_services, as: 'affectedServices', class: Google::Apis::ClouderrorreportingV1beta1::ServiceContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ServiceContext::Representation collection :affected_services, as: 'affectedServices', class: Google::Apis::ClouderrorreportingV1beta1::ServiceContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ServiceContext::Representation
@ -119,9 +122,6 @@ module Google
collection :timed_counts, as: 'timedCounts', class: Google::Apis::ClouderrorreportingV1beta1::TimedCount, decorator: Google::Apis::ClouderrorreportingV1beta1::TimedCount::Representation collection :timed_counts, as: 'timedCounts', class: Google::Apis::ClouderrorreportingV1beta1::TimedCount, decorator: Google::Apis::ClouderrorreportingV1beta1::TimedCount::Representation
property :group, as: 'group', class: Google::Apis::ClouderrorreportingV1beta1::ErrorGroup, decorator: Google::Apis::ClouderrorreportingV1beta1::ErrorGroup::Representation
property :first_seen_time, as: 'firstSeenTime'
end end
end end
@ -147,10 +147,10 @@ module Google
class ErrorGroup class ErrorGroup
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :group_id, as: 'groupId' property :group_id, as: 'groupId'
collection :tracking_issues, as: 'trackingIssues', class: Google::Apis::ClouderrorreportingV1beta1::TrackingIssue, decorator: Google::Apis::ClouderrorreportingV1beta1::TrackingIssue::Representation collection :tracking_issues, as: 'trackingIssues', class: Google::Apis::ClouderrorreportingV1beta1::TrackingIssue, decorator: Google::Apis::ClouderrorreportingV1beta1::TrackingIssue::Representation
property :name, as: 'name'
end end
end end
@ -181,12 +181,12 @@ module Google
class HttpRequestContext class HttpRequestContext
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :response_status_code, as: 'responseStatusCode'
property :method_prop, as: 'method'
property :remote_ip, as: 'remoteIp'
property :referrer, as: 'referrer' property :referrer, as: 'referrer'
property :user_agent, as: 'userAgent' property :user_agent, as: 'userAgent'
property :url, as: 'url' property :url, as: 'url'
property :response_status_code, as: 'responseStatusCode'
property :method_prop, as: 'method'
property :remote_ip, as: 'remoteIp'
end end
end end
@ -209,35 +209,35 @@ module Google
class ErrorEvent class ErrorEvent
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :service_context, as: 'serviceContext', class: Google::Apis::ClouderrorreportingV1beta1::ServiceContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ServiceContext::Representation
property :event_time, as: 'eventTime'
property :context, as: 'context', class: Google::Apis::ClouderrorreportingV1beta1::ErrorContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ErrorContext::Representation property :context, as: 'context', class: Google::Apis::ClouderrorreportingV1beta1::ErrorContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ErrorContext::Representation
property :message, as: 'message' property :message, as: 'message'
property :service_context, as: 'serviceContext', class: Google::Apis::ClouderrorreportingV1beta1::ServiceContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ServiceContext::Representation
property :event_time, as: 'eventTime'
end end
end end
class ReportedErrorEvent class ReportedErrorEvent
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :event_time, as: 'eventTime'
property :context, as: 'context', class: Google::Apis::ClouderrorreportingV1beta1::ErrorContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ErrorContext::Representation property :context, as: 'context', class: Google::Apis::ClouderrorreportingV1beta1::ErrorContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ErrorContext::Representation
property :message, as: 'message' property :message, as: 'message'
property :service_context, as: 'serviceContext', class: Google::Apis::ClouderrorreportingV1beta1::ServiceContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ServiceContext::Representation property :service_context, as: 'serviceContext', class: Google::Apis::ClouderrorreportingV1beta1::ServiceContext, decorator: Google::Apis::ClouderrorreportingV1beta1::ServiceContext::Representation
property :event_time, as: 'eventTime'
end end
end end
class ErrorContext class ErrorContext
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :http_request, as: 'httpRequest', class: Google::Apis::ClouderrorreportingV1beta1::HttpRequestContext, decorator: Google::Apis::ClouderrorreportingV1beta1::HttpRequestContext::Representation
property :user, as: 'user' property :user, as: 'user'
property :report_location, as: 'reportLocation', class: Google::Apis::ClouderrorreportingV1beta1::SourceLocation, decorator: Google::Apis::ClouderrorreportingV1beta1::SourceLocation::Representation property :report_location, as: 'reportLocation', class: Google::Apis::ClouderrorreportingV1beta1::SourceLocation, decorator: Google::Apis::ClouderrorreportingV1beta1::SourceLocation::Representation
property :http_request, as: 'httpRequest', class: Google::Apis::ClouderrorreportingV1beta1::HttpRequestContext, decorator: Google::Apis::ClouderrorreportingV1beta1::HttpRequestContext::Representation
end end
end end

View File

@ -82,6 +82,111 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Lists the specified events.
# @param [String] project_name
# [Required] The resource name of the Google Cloud Platform project. Written
# as `projects/` plus the
# [Google Cloud Platform project
# ID](https://support.google.com/cloud/answer/6158840).
# Example: `projects/my-project-123`.
# @param [String] service_filter_service
# [Optional] The exact value to match against
# [`ServiceContext.service`](/error-reporting/reference/rest/v1beta1/
# ServiceContext#FIELDS.service).
# @param [String] page_token
# [Optional] A `next_page_token` provided by a previous response.
# @param [Fixnum] page_size
# [Optional] The maximum number of results to return per response.
# @param [String] service_filter_version
# [Optional] The exact value to match against
# [`ServiceContext.version`](/error-reporting/reference/rest/v1beta1/
# ServiceContext#FIELDS.version).
# @param [String] service_filter_resource_type
# [Optional] The exact value to match against
# [`ServiceContext.resource_type`](/error-reporting/reference/rest/v1beta1/
# ServiceContext#FIELDS.resource_type).
# @param [String] time_range_period
# Restricts the query to the specified time range.
# @param [String] group_id
# [Required] The group for which events shall be returned.
# @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::ClouderrorreportingV1beta1::ListEventsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ClouderrorreportingV1beta1::ListEventsResponse]
#
# @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 list_project_events(project_name, service_filter_service: nil, page_token: nil, page_size: nil, service_filter_version: nil, service_filter_resource_type: nil, time_range_period: nil, group_id: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1beta1/{+projectName}/events', options)
command.response_representation = Google::Apis::ClouderrorreportingV1beta1::ListEventsResponse::Representation
command.response_class = Google::Apis::ClouderrorreportingV1beta1::ListEventsResponse
command.params['projectName'] = project_name unless project_name.nil?
command.query['serviceFilter.service'] = service_filter_service unless service_filter_service.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['serviceFilter.version'] = service_filter_version unless service_filter_version.nil?
command.query['serviceFilter.resourceType'] = service_filter_resource_type unless service_filter_resource_type.nil?
command.query['timeRange.period'] = time_range_period unless time_range_period.nil?
command.query['groupId'] = group_id unless group_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Report an individual error event.
# This endpoint accepts <strong>either</strong> an OAuth token,
# <strong>or</strong> an
# <a href="https://support.google.com/cloud/answer/6158862">API key</a>
# for authentication. To use an API key, append it to the URL as the value of
# a `key` parameter. For example:
# <pre>POST https://clouderrorreporting.googleapis.com/v1beta1/projects/example-
# project/events:report?key=123ABC456</pre>
# @param [String] project_name
# [Required] The resource name of the Google Cloud Platform project. Written
# as `projects/` plus the
# [Google Cloud Platform project ID](https://support.google.com/cloud/answer/
# 6158840).
# Example: `projects/my-project-123`.
# @param [Google::Apis::ClouderrorreportingV1beta1::ReportedErrorEvent] reported_error_event_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::ClouderrorreportingV1beta1::ReportErrorEventResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ClouderrorreportingV1beta1::ReportErrorEventResponse]
#
# @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 report_project_event(project_name, reported_error_event_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1beta1/{+projectName}/events:report', options)
command.request_representation = Google::Apis::ClouderrorreportingV1beta1::ReportedErrorEvent::Representation
command.request_object = reported_error_event_object
command.response_representation = Google::Apis::ClouderrorreportingV1beta1::ReportErrorEventResponse::Representation
command.response_class = Google::Apis::ClouderrorreportingV1beta1::ReportErrorEventResponse
command.params['projectName'] = project_name unless project_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
# Get the specified group. # Get the specified group.
# @param [String] group_name # @param [String] group_name
# [Required] The group resource name. Written as # [Required] The group resource name. Written as
@ -160,13 +265,6 @@ module Google
# <a href="https://support.google.com/cloud/answer/6158840">Google Cloud # <a href="https://support.google.com/cloud/answer/6158840">Google Cloud
# Platform project ID</a>. # Platform project ID</a>.
# Example: <code>projects/my-project-123</code>. # Example: <code>projects/my-project-123</code>.
# @param [String] timed_count_duration
# [Optional] The preferred duration for a single returned `TimedCount`.
# If not set, no timed counts are returned.
# @param [String] page_token
# [Optional] A `next_page_token` provided by a previous response. To view
# additional results, pass this token along with the identical query
# parameters as the first request.
# @param [String] time_range_period # @param [String] time_range_period
# Restricts the query to the specified time range. # Restricts the query to the specified time range.
# @param [String] alignment # @param [String] alignment
@ -195,6 +293,13 @@ module Google
# @param [String] alignment_time # @param [String] alignment_time
# [Optional] Time where the timed counts shall be aligned if rounded # [Optional] Time where the timed counts shall be aligned if rounded
# alignment is chosen. Default is 00:00 UTC. # alignment is chosen. Default is 00:00 UTC.
# @param [String] timed_count_duration
# [Optional] The preferred duration for a single returned `TimedCount`.
# If not set, no timed counts are returned.
# @param [String] page_token
# [Optional] A `next_page_token` provided by a previous response. To view
# additional results, pass this token along with the identical query
# parameters as the first request.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -212,13 +317,11 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_project_group_stats(project_name, timed_count_duration: nil, page_token: nil, time_range_period: nil, alignment: nil, group_id: nil, service_filter_service: nil, page_size: nil, order: nil, service_filter_version: nil, service_filter_resource_type: nil, alignment_time: nil, fields: nil, quota_user: nil, options: nil, &block) def list_project_group_stats(project_name, time_range_period: nil, alignment: nil, group_id: nil, service_filter_service: nil, page_size: nil, order: nil, service_filter_version: nil, service_filter_resource_type: nil, alignment_time: nil, timed_count_duration: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1beta1/{+projectName}/groupStats', options) command = make_simple_command(:get, 'v1beta1/{+projectName}/groupStats', options)
command.response_representation = Google::Apis::ClouderrorreportingV1beta1::ListGroupStatsResponse::Representation command.response_representation = Google::Apis::ClouderrorreportingV1beta1::ListGroupStatsResponse::Representation
command.response_class = Google::Apis::ClouderrorreportingV1beta1::ListGroupStatsResponse command.response_class = Google::Apis::ClouderrorreportingV1beta1::ListGroupStatsResponse
command.params['projectName'] = project_name unless project_name.nil? command.params['projectName'] = project_name unless project_name.nil?
command.query['timedCountDuration'] = timed_count_duration unless timed_count_duration.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['timeRange.period'] = time_range_period unless time_range_period.nil? command.query['timeRange.period'] = time_range_period unless time_range_period.nil?
command.query['alignment'] = alignment unless alignment.nil? command.query['alignment'] = alignment unless alignment.nil?
command.query['groupId'] = group_id unless group_id.nil? command.query['groupId'] = group_id unless group_id.nil?
@ -228,111 +331,8 @@ module Google
command.query['serviceFilter.version'] = service_filter_version unless service_filter_version.nil? command.query['serviceFilter.version'] = service_filter_version unless service_filter_version.nil?
command.query['serviceFilter.resourceType'] = service_filter_resource_type unless service_filter_resource_type.nil? command.query['serviceFilter.resourceType'] = service_filter_resource_type unless service_filter_resource_type.nil?
command.query['alignmentTime'] = alignment_time unless alignment_time.nil? command.query['alignmentTime'] = alignment_time unless alignment_time.nil?
command.query['fields'] = fields unless fields.nil? command.query['timedCountDuration'] = timed_count_duration unless timed_count_duration.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists the specified events.
# @param [String] project_name
# [Required] The resource name of the Google Cloud Platform project. Written
# as `projects/` plus the
# [Google Cloud Platform project
# ID](https://support.google.com/cloud/answer/6158840).
# Example: `projects/my-project-123`.
# @param [String] group_id
# [Required] The group for which events shall be returned.
# @param [String] page_token
# [Optional] A `next_page_token` provided by a previous response.
# @param [String] service_filter_service
# [Optional] The exact value to match against
# [`ServiceContext.service`](/error-reporting/reference/rest/v1beta1/
# ServiceContext#FIELDS.service).
# @param [Fixnum] page_size
# [Optional] The maximum number of results to return per response.
# @param [String] service_filter_version
# [Optional] The exact value to match against
# [`ServiceContext.version`](/error-reporting/reference/rest/v1beta1/
# ServiceContext#FIELDS.version).
# @param [String] service_filter_resource_type
# [Optional] The exact value to match against
# [`ServiceContext.resource_type`](/error-reporting/reference/rest/v1beta1/
# ServiceContext#FIELDS.resource_type).
# @param [String] time_range_period
# Restricts the query to the specified time range.
# @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::ClouderrorreportingV1beta1::ListEventsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ClouderrorreportingV1beta1::ListEventsResponse]
#
# @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 list_project_events(project_name, group_id: nil, page_token: nil, service_filter_service: nil, page_size: nil, service_filter_version: nil, service_filter_resource_type: nil, time_range_period: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1beta1/{+projectName}/events', options)
command.response_representation = Google::Apis::ClouderrorreportingV1beta1::ListEventsResponse::Representation
command.response_class = Google::Apis::ClouderrorreportingV1beta1::ListEventsResponse
command.params['projectName'] = project_name unless project_name.nil?
command.query['groupId'] = group_id unless group_id.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['serviceFilter.service'] = service_filter_service unless service_filter_service.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['serviceFilter.version'] = service_filter_version unless service_filter_version.nil?
command.query['serviceFilter.resourceType'] = service_filter_resource_type unless service_filter_resource_type.nil?
command.query['timeRange.period'] = time_range_period unless time_range_period.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Report an individual error event.
# This endpoint accepts <strong>either</strong> an OAuth token,
# <strong>or</strong> an
# <a href="https://support.google.com/cloud/answer/6158862">API key</a>
# for authentication. To use an API key, append it to the URL as the value of
# a `key` parameter. For example:
# <pre>POST https://clouderrorreporting.googleapis.com/v1beta1/projects/example-
# project/events:report?key=123ABC456</pre>
# @param [String] project_name
# [Required] The resource name of the Google Cloud Platform project. Written
# as `projects/` plus the
# [Google Cloud Platform project ID](https://support.google.com/cloud/answer/
# 6158840).
# Example: `projects/my-project-123`.
# @param [Google::Apis::ClouderrorreportingV1beta1::ReportedErrorEvent] reported_error_event_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::ClouderrorreportingV1beta1::ReportErrorEventResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ClouderrorreportingV1beta1::ReportErrorEventResponse]
#
# @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 report_project_event(project_name, reported_error_event_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1beta1/{+projectName}/events:report', options)
command.request_representation = Google::Apis::ClouderrorreportingV1beta1::ReportedErrorEvent::Representation
command.request_object = reported_error_event_object
command.response_representation = Google::Apis::ClouderrorreportingV1beta1::ReportErrorEventResponse::Representation
command.response_class = Google::Apis::ClouderrorreportingV1beta1::ReportErrorEventResponse
command.params['projectName'] = project_name unless project_name.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)

View File

@ -26,11 +26,6 @@ module Google
class Location class Location
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The canonical id for this location. For example: `"us-east1"`.
# Corresponds to the JSON property `locationId`
# @return [String]
attr_accessor :location_id
# Service-specific metadata. For example the available capacity at the given # Service-specific metadata. For example the available capacity at the given
# location. # location.
# Corresponds to the JSON property `metadata` # Corresponds to the JSON property `metadata`
@ -49,16 +44,21 @@ module Google
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# The canonical id for this location. For example: `"us-east1"`.
# Corresponds to the JSON property `locationId`
# @return [String]
attr_accessor :location_id
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@location_id = args[:location_id] if args.key?(:location_id)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@labels = args[:labels] if args.key?(:labels) @labels = args[:labels] if args.key?(:labels)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@location_id = args[:location_id] if args.key?(:location_id)
end end
end end

View File

@ -37,10 +37,10 @@ module Google
class Location class Location
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :location_id, as: 'locationId'
hash :metadata, as: 'metadata' hash :metadata, as: 'metadata'
hash :labels, as: 'labels' hash :labels, as: 'labels'
property :name, as: 'name' property :name, as: 'name'
property :location_id, as: 'locationId'
end end
end end

View File

@ -22,82 +22,15 @@ module Google
module Apis module Apis
module CloudkmsV1 module CloudkmsV1
# A resource that represents Google Cloud Platform location.
class Location
include Google::Apis::Core::Hashable
# Cross-service attributes for the location. For example
# `"cloud.googleapis.com/region": "us-east1"`
# Corresponds to the JSON property `labels`
# @return [Hash<String,String>]
attr_accessor :labels
# Resource name for the location, which may vary between implementations.
# For example: `"projects/example-project/locations/us-east1"`
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The canonical id for this location. For example: `"us-east1"`.
# Corresponds to the JSON property `locationId`
# @return [String]
attr_accessor :location_id
# Service-specific metadata. For example the available capacity at the given
# location.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,Object>]
attr_accessor :metadata
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@labels = args[:labels] if args.key?(:labels)
@name = args[:name] if args.key?(:name)
@location_id = args[:location_id] if args.key?(:location_id)
@metadata = args[:metadata] if args.key?(:metadata)
end
end
# Response message for KeyManagementService.ListCryptoKeys.
class ListCryptoKeysResponse
include Google::Apis::Core::Hashable
# A token to retrieve next page of results. Pass this value in
# ListCryptoKeysRequest.page_token to retrieve the next page of results.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# The list of CryptoKeys.
# Corresponds to the JSON property `cryptoKeys`
# @return [Array<Google::Apis::CloudkmsV1::CryptoKey>]
attr_accessor :crypto_keys
# The total number of CryptoKeys that matched the query.
# Corresponds to the JSON property `totalSize`
# @return [Fixnum]
attr_accessor :total_size
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@crypto_keys = args[:crypto_keys] if args.key?(:crypto_keys)
@total_size = args[:total_size] if args.key?(:total_size)
end
end
# A condition to be met. # A condition to be met.
class Condition class Condition
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# An operator to apply the subject with.
# Corresponds to the JSON property `op`
# @return [String]
attr_accessor :op
# Trusted attributes discharged by the service. # Trusted attributes discharged by the service.
# Corresponds to the JSON property `svc` # Corresponds to the JSON property `svc`
# @return [String] # @return [String]
@ -124,23 +57,18 @@ module Google
# @return [String] # @return [String]
attr_accessor :iam attr_accessor :iam
# An operator to apply the subject with.
# Corresponds to the JSON property `op`
# @return [String]
attr_accessor :op
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@op = args[:op] if args.key?(:op)
@svc = args[:svc] if args.key?(:svc) @svc = args[:svc] if args.key?(:svc)
@sys = args[:sys] if args.key?(:sys) @sys = args[:sys] if args.key?(:sys)
@value = args[:value] if args.key?(:value) @value = args[:value] if args.key?(:value)
@values = args[:values] if args.key?(:values) @values = args[:values] if args.key?(:values)
@iam = args[:iam] if args.key?(:iam) @iam = args[:iam] if args.key?(:iam)
@op = args[:op] if args.key?(:op)
end end
end end
@ -218,6 +146,7 @@ module Google
# The decrypted data originally supplied in EncryptRequest.plaintext. # The decrypted data originally supplied in EncryptRequest.plaintext.
# Corresponds to the JSON property `plaintext` # Corresponds to the JSON property `plaintext`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :plaintext attr_accessor :plaintext
@ -257,25 +186,25 @@ module Google
class KeyRing class KeyRing
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Output only. The time at which this KeyRing was created.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# Output only. The resource name for the KeyRing in the format # Output only. The resource name for the KeyRing in the format
# `projects/*/locations/*/keyRings/*`. # `projects/*/locations/*/keyRings/*`.
# Corresponds to the JSON property `name` # Corresponds to the JSON property `name`
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# Output only. The time at which this KeyRing was created.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@create_time = args[:create_time] if args.key?(:create_time)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@create_time = args[:create_time] if args.key?(:create_time)
end end
end end
@ -283,24 +212,25 @@ module Google
class EncryptResponse class EncryptResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The encrypted data.
# Corresponds to the JSON property `ciphertext`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :ciphertext
# The resource name of the CryptoKeyVersion used in encryption. # The resource name of the CryptoKeyVersion used in encryption.
# Corresponds to the JSON property `name` # Corresponds to the JSON property `name`
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# The encrypted data.
# Corresponds to the JSON property `ciphertext`
# @return [String]
attr_accessor :ciphertext
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@name = args[:name] if args.key?(:name)
@ciphertext = args[:ciphertext] if args.key?(:ciphertext) @ciphertext = args[:ciphertext] if args.key?(:ciphertext)
@name = args[:name] if args.key?(:name)
end end
end end
@ -308,24 +238,24 @@ module Google
class ListLocationsResponse class ListLocationsResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The standard List next-page token.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# A list of locations that matches the specified filter in the request. # A list of locations that matches the specified filter in the request.
# Corresponds to the JSON property `locations` # Corresponds to the JSON property `locations`
# @return [Array<Google::Apis::CloudkmsV1::Location>] # @return [Array<Google::Apis::CloudkmsV1::Location>]
attr_accessor :locations attr_accessor :locations
# The standard List next-page token.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@locations = args[:locations] if args.key?(:locations) @locations = args[:locations] if args.key?(:locations)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
end end
end end
@ -358,19 +288,6 @@ module Google
class Policy class Policy
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# `etag` is used for optimistic concurrency control as a way to help
# prevent simultaneous updates of a policy from overwriting each other.
# It is strongly suggested that systems make use of the `etag` in the
# read-modify-write cycle to perform policy updates in order to avoid race
# conditions: An `etag` is returned in the response to `getIamPolicy`, and
# systems are expected to put that etag in the request to `setIamPolicy` to
# ensure that their change will be applied to the same version of the policy.
# If no `etag` is provided in the call to `setIamPolicy`, then the existing
# policy is overwritten blindly.
# Corresponds to the JSON property `etag`
# @return [String]
attr_accessor :etag
# #
# Corresponds to the JSON property `iamOwned` # Corresponds to the JSON property `iamOwned`
# @return [Boolean] # @return [Boolean]
@ -407,18 +324,32 @@ module Google
# @return [Array<Google::Apis::CloudkmsV1::Binding>] # @return [Array<Google::Apis::CloudkmsV1::Binding>]
attr_accessor :bindings attr_accessor :bindings
# `etag` is used for optimistic concurrency control as a way to help
# prevent simultaneous updates of a policy from overwriting each other.
# It is strongly suggested that systems make use of the `etag` in the
# read-modify-write cycle to perform policy updates in order to avoid race
# conditions: An `etag` is returned in the response to `getIamPolicy`, and
# systems are expected to put that etag in the request to `setIamPolicy` to
# ensure that their change will be applied to the same version of the policy.
# If no `etag` is provided in the call to `setIamPolicy`, then the existing
# policy is overwritten blindly.
# Corresponds to the JSON property `etag`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :etag
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@etag = args[:etag] if args.key?(:etag)
@iam_owned = args[:iam_owned] if args.key?(:iam_owned) @iam_owned = args[:iam_owned] if args.key?(:iam_owned)
@rules = args[:rules] if args.key?(:rules) @rules = args[:rules] if args.key?(:rules)
@version = args[:version] if args.key?(:version) @version = args[:version] if args.key?(:version)
@audit_configs = args[:audit_configs] if args.key?(:audit_configs) @audit_configs = args[:audit_configs] if args.key?(:audit_configs)
@bindings = args[:bindings] if args.key?(:bindings) @bindings = args[:bindings] if args.key?(:bindings)
@etag = args[:etag] if args.key?(:etag)
end end
end end
@ -454,19 +385,6 @@ module Google
end end
end end
# Write a Data Access (Gin) log
class DataAccessOptions
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# Response message for KeyManagementService.ListKeyRings. # Response message for KeyManagementService.ListKeyRings.
class ListKeyRingsResponse class ListKeyRingsResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -499,6 +417,19 @@ module Google
end end
end end
# Write a Data Access (Gin) log
class DataAccessOptions
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# Specifies the audit configuration for a service. # Specifies the audit configuration for a service.
# The configuration determines which permission types are logged, and what # The configuration determines which permission types are logged, and what
# identities, if any, are exempted from logging. # identities, if any, are exempted from logging.
@ -688,26 +619,28 @@ module Google
class EncryptRequest class EncryptRequest
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Required. The data to encrypt. Must be no larger than 64KiB.
# Corresponds to the JSON property `plaintext`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :plaintext
# Optional data that, if specified, must also be provided during decryption # Optional data that, if specified, must also be provided during decryption
# through DecryptRequest.additional_authenticated_data. Must be no # through DecryptRequest.additional_authenticated_data. Must be no
# larger than 64KiB. # larger than 64KiB.
# Corresponds to the JSON property `additionalAuthenticatedData` # Corresponds to the JSON property `additionalAuthenticatedData`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :additional_authenticated_data attr_accessor :additional_authenticated_data
# Required. The data to encrypt. Must be no larger than 64KiB.
# Corresponds to the JSON property `plaintext`
# @return [String]
attr_accessor :plaintext
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@additional_authenticated_data = args[:additional_authenticated_data] if args.key?(:additional_authenticated_data)
@plaintext = args[:plaintext] if args.key?(:plaintext) @plaintext = args[:plaintext] if args.key?(:plaintext)
@additional_authenticated_data = args[:additional_authenticated_data] if args.key?(:additional_authenticated_data)
end end
end end
@ -778,6 +711,68 @@ module Google
end end
end end
# A rule to be applied in a Policy.
class Rule
include Google::Apis::Core::Hashable
# If one or more 'not_in' clauses are specified, the rule matches
# if the PRINCIPAL/AUTHORITY_SELECTOR is in none of the entries.
# The format for in and not_in entries is the same as for members in a
# Binding (see google/iam/v1/policy.proto).
# Corresponds to the JSON property `notIn`
# @return [Array<String>]
attr_accessor :not_in
# Human-readable description of the rule.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
# Additional restrictions that must be met
# Corresponds to the JSON property `conditions`
# @return [Array<Google::Apis::CloudkmsV1::Condition>]
attr_accessor :conditions
# The config returned to callers of tech.iam.IAM.CheckPolicy for any entries
# that match the LOG action.
# Corresponds to the JSON property `logConfig`
# @return [Array<Google::Apis::CloudkmsV1::LogConfig>]
attr_accessor :log_config
# If one or more 'in' clauses are specified, the rule matches if
# the PRINCIPAL/AUTHORITY_SELECTOR is in at least one of these entries.
# Corresponds to the JSON property `in`
# @return [Array<String>]
attr_accessor :in
# A permission is a string of form '<service>.<resource type>.<verb>'
# (e.g., 'storage.buckets.list'). A value of '*' matches all permissions,
# and a verb part of '*' (e.g., 'storage.buckets.*') matches all verbs.
# Corresponds to the JSON property `permissions`
# @return [Array<String>]
attr_accessor :permissions
# Required
# Corresponds to the JSON property `action`
# @return [String]
attr_accessor :action
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@not_in = args[:not_in] if args.key?(:not_in)
@description = args[:description] if args.key?(:description)
@conditions = args[:conditions] if args.key?(:conditions)
@log_config = args[:log_config] if args.key?(:log_config)
@in = args[:in] if args.key?(:in)
@permissions = args[:permissions] if args.key?(:permissions)
@action = args[:action] if args.key?(:action)
end
end
# A CryptoKey represents a logical key that can be used for cryptographic # A CryptoKey represents a logical key that can be used for cryptographic
# operations. # operations.
# A CryptoKey is made up of one or more versions, which # A CryptoKey is made up of one or more versions, which
@ -844,72 +839,15 @@ module Google
end end
end end
# A rule to be applied in a Policy.
class Rule
include Google::Apis::Core::Hashable
# If one or more 'not_in' clauses are specified, the rule matches
# if the PRINCIPAL/AUTHORITY_SELECTOR is in none of the entries.
# The format for in and not_in entries is the same as for members in a
# Binding (see google/iam/v1/policy.proto).
# Corresponds to the JSON property `notIn`
# @return [Array<String>]
attr_accessor :not_in
# Human-readable description of the rule.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
# Additional restrictions that must be met
# Corresponds to the JSON property `conditions`
# @return [Array<Google::Apis::CloudkmsV1::Condition>]
attr_accessor :conditions
# The config returned to callers of tech.iam.IAM.CheckPolicy for any entries
# that match the LOG action.
# Corresponds to the JSON property `logConfig`
# @return [Array<Google::Apis::CloudkmsV1::LogConfig>]
attr_accessor :log_config
# If one or more 'in' clauses are specified, the rule matches if
# the PRINCIPAL/AUTHORITY_SELECTOR is in at least one of these entries.
# Corresponds to the JSON property `in`
# @return [Array<String>]
attr_accessor :in
# A permission is a string of form '<service>.<resource type>.<verb>'
# (e.g., 'storage.buckets.list'). A value of '*' matches all permissions,
# and a verb part of '*' (e.g., 'storage.buckets.*') matches all verbs.
# Corresponds to the JSON property `permissions`
# @return [Array<String>]
attr_accessor :permissions
# Required
# Corresponds to the JSON property `action`
# @return [String]
attr_accessor :action
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@not_in = args[:not_in] if args.key?(:not_in)
@description = args[:description] if args.key?(:description)
@conditions = args[:conditions] if args.key?(:conditions)
@log_config = args[:log_config] if args.key?(:log_config)
@in = args[:in] if args.key?(:in)
@permissions = args[:permissions] if args.key?(:permissions)
@action = args[:action] if args.key?(:action)
end
end
# Specifies what kind of log the caller must write # Specifies what kind of log the caller must write
class LogConfig class LogConfig
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Write a Cloud Audit log
# Corresponds to the JSON property `cloudAudit`
# @return [Google::Apis::CloudkmsV1::CloudAuditOptions]
attr_accessor :cloud_audit
# Options for counters # Options for counters
# Corresponds to the JSON property `counter` # Corresponds to the JSON property `counter`
# @return [Google::Apis::CloudkmsV1::CounterOptions] # @return [Google::Apis::CloudkmsV1::CounterOptions]
@ -920,20 +858,15 @@ module Google
# @return [Google::Apis::CloudkmsV1::DataAccessOptions] # @return [Google::Apis::CloudkmsV1::DataAccessOptions]
attr_accessor :data_access attr_accessor :data_access
# Write a Cloud Audit log
# Corresponds to the JSON property `cloudAudit`
# @return [Google::Apis::CloudkmsV1::CloudAuditOptions]
attr_accessor :cloud_audit
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@cloud_audit = args[:cloud_audit] if args.key?(:cloud_audit)
@counter = args[:counter] if args.key?(:counter) @counter = args[:counter] if args.key?(:counter)
@data_access = args[:data_access] if args.key?(:data_access) @data_access = args[:data_access] if args.key?(:data_access)
@cloud_audit = args[:cloud_audit] if args.key?(:cloud_audit)
end end
end end
@ -998,12 +931,14 @@ module Google
# Required. The encrypted data originally returned in # Required. The encrypted data originally returned in
# EncryptResponse.ciphertext. # EncryptResponse.ciphertext.
# Corresponds to the JSON property `ciphertext` # Corresponds to the JSON property `ciphertext`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :ciphertext attr_accessor :ciphertext
# Optional data that must match the data originally supplied in # Optional data that must match the data originally supplied in
# EncryptRequest.additional_authenticated_data. # EncryptRequest.additional_authenticated_data.
# Corresponds to the JSON property `additionalAuthenticatedData` # Corresponds to the JSON property `additionalAuthenticatedData`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :additional_authenticated_data attr_accessor :additional_authenticated_data
@ -1017,6 +952,78 @@ module Google
@additional_authenticated_data = args[:additional_authenticated_data] if args.key?(:additional_authenticated_data) @additional_authenticated_data = args[:additional_authenticated_data] if args.key?(:additional_authenticated_data)
end end
end end
# A resource that represents Google Cloud Platform location.
class Location
include Google::Apis::Core::Hashable
# Cross-service attributes for the location. For example
# `"cloud.googleapis.com/region": "us-east1"`
# Corresponds to the JSON property `labels`
# @return [Hash<String,String>]
attr_accessor :labels
# Resource name for the location, which may vary between implementations.
# For example: `"projects/example-project/locations/us-east1"`
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The canonical id for this location. For example: `"us-east1"`.
# Corresponds to the JSON property `locationId`
# @return [String]
attr_accessor :location_id
# Service-specific metadata. For example the available capacity at the given
# location.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,Object>]
attr_accessor :metadata
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@labels = args[:labels] if args.key?(:labels)
@name = args[:name] if args.key?(:name)
@location_id = args[:location_id] if args.key?(:location_id)
@metadata = args[:metadata] if args.key?(:metadata)
end
end
# Response message for KeyManagementService.ListCryptoKeys.
class ListCryptoKeysResponse
include Google::Apis::Core::Hashable
# A token to retrieve next page of results. Pass this value in
# ListCryptoKeysRequest.page_token to retrieve the next page of results.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# The list of CryptoKeys.
# Corresponds to the JSON property `cryptoKeys`
# @return [Array<Google::Apis::CloudkmsV1::CryptoKey>]
attr_accessor :crypto_keys
# The total number of CryptoKeys that matched the query.
# Corresponds to the JSON property `totalSize`
# @return [Fixnum]
attr_accessor :total_size
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@crypto_keys = args[:crypto_keys] if args.key?(:crypto_keys)
@total_size = args[:total_size] if args.key?(:total_size)
end
end
end end
end end
end end

View File

@ -22,18 +22,6 @@ module Google
module Apis module Apis
module CloudkmsV1 module CloudkmsV1
class Location
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListCryptoKeysResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Condition class Condition
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -100,13 +88,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class DataAccessOptions class ListKeyRingsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListKeyRingsResponse class DataAccessOptions
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -160,13 +148,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class CryptoKey class Rule
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Rule class CryptoKey
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -191,34 +179,26 @@ module Google
end end
class Location class Location
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels' include Google::Apis::Core::JsonObjectSupport
property :name, as: 'name'
property :location_id, as: 'locationId'
hash :metadata, as: 'metadata'
end
end end
class ListCryptoKeysResponse class ListCryptoKeysResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :crypto_keys, as: 'cryptoKeys', class: Google::Apis::CloudkmsV1::CryptoKey, decorator: Google::Apis::CloudkmsV1::CryptoKey::Representation
property :total_size, as: 'totalSize' include Google::Apis::Core::JsonObjectSupport
end
end end
class Condition class Condition
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :op, as: 'op'
property :svc, as: 'svc' property :svc, as: 'svc'
property :sys, as: 'sys' property :sys, as: 'sys'
property :value, as: 'value' property :value, as: 'value'
collection :values, as: 'values' collection :values, as: 'values'
property :iam, as: 'iam' property :iam, as: 'iam'
property :op, as: 'op'
end end
end end
@ -255,32 +235,31 @@ module Google
class KeyRing class KeyRing
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :create_time, as: 'createTime'
property :name, as: 'name' property :name, as: 'name'
property :create_time, as: 'createTime'
end end
end end
class EncryptResponse class EncryptResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :ciphertext, :base64 => true, as: 'ciphertext' property :ciphertext, :base64 => true, as: 'ciphertext'
property :name, as: 'name'
end end
end end
class ListLocationsResponse class ListLocationsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :locations, as: 'locations', class: Google::Apis::CloudkmsV1::Location, decorator: Google::Apis::CloudkmsV1::Location::Representation collection :locations, as: 'locations', class: Google::Apis::CloudkmsV1::Location, decorator: Google::Apis::CloudkmsV1::Location::Representation
property :next_page_token, as: 'nextPageToken'
end end
end end
class Policy class Policy
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :etag, :base64 => true, as: 'etag'
property :iam_owned, as: 'iamOwned' property :iam_owned, as: 'iamOwned'
collection :rules, as: 'rules', class: Google::Apis::CloudkmsV1::Rule, decorator: Google::Apis::CloudkmsV1::Rule::Representation collection :rules, as: 'rules', class: Google::Apis::CloudkmsV1::Rule, decorator: Google::Apis::CloudkmsV1::Rule::Representation
@ -289,6 +268,7 @@ module Google
collection :bindings, as: 'bindings', class: Google::Apis::CloudkmsV1::Binding, decorator: Google::Apis::CloudkmsV1::Binding::Representation collection :bindings, as: 'bindings', class: Google::Apis::CloudkmsV1::Binding, decorator: Google::Apis::CloudkmsV1::Binding::Representation
property :etag, :base64 => true, as: 'etag'
end end
end end
@ -305,12 +285,6 @@ module Google
end end
end end
class DataAccessOptions
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class ListKeyRingsResponse class ListKeyRingsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -321,6 +295,12 @@ module Google
end end
end end
class DataAccessOptions
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class AuditConfig class AuditConfig
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -359,8 +339,8 @@ module Google
class EncryptRequest class EncryptRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :additional_authenticated_data, :base64 => true, as: 'additionalAuthenticatedData'
property :plaintext, :base64 => true, as: 'plaintext' property :plaintext, :base64 => true, as: 'plaintext'
property :additional_authenticated_data, :base64 => true, as: 'additionalAuthenticatedData'
end end
end end
@ -387,19 +367,6 @@ module Google
end end
end end
class CryptoKey
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :purpose, as: 'purpose'
property :next_rotation_time, as: 'nextRotationTime'
property :create_time, as: 'createTime'
property :rotation_period, as: 'rotationPeriod'
property :primary, as: 'primary', class: Google::Apis::CloudkmsV1::CryptoKeyVersion, decorator: Google::Apis::CloudkmsV1::CryptoKeyVersion::Representation
property :name, as: 'name'
end
end
class Rule class Rule
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -415,15 +382,28 @@ module Google
end end
end end
class CryptoKey
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :purpose, as: 'purpose'
property :next_rotation_time, as: 'nextRotationTime'
property :create_time, as: 'createTime'
property :rotation_period, as: 'rotationPeriod'
property :primary, as: 'primary', class: Google::Apis::CloudkmsV1::CryptoKeyVersion, decorator: Google::Apis::CloudkmsV1::CryptoKeyVersion::Representation
property :name, as: 'name'
end
end
class LogConfig class LogConfig
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :cloud_audit, as: 'cloudAudit', class: Google::Apis::CloudkmsV1::CloudAuditOptions, decorator: Google::Apis::CloudkmsV1::CloudAuditOptions::Representation
property :counter, as: 'counter', class: Google::Apis::CloudkmsV1::CounterOptions, decorator: Google::Apis::CloudkmsV1::CounterOptions::Representation property :counter, as: 'counter', class: Google::Apis::CloudkmsV1::CounterOptions, decorator: Google::Apis::CloudkmsV1::CounterOptions::Representation
property :data_access, as: 'dataAccess', class: Google::Apis::CloudkmsV1::DataAccessOptions, decorator: Google::Apis::CloudkmsV1::DataAccessOptions::Representation property :data_access, as: 'dataAccess', class: Google::Apis::CloudkmsV1::DataAccessOptions, decorator: Google::Apis::CloudkmsV1::DataAccessOptions::Representation
property :cloud_audit, as: 'cloudAudit', class: Google::Apis::CloudkmsV1::CloudAuditOptions, decorator: Google::Apis::CloudkmsV1::CloudAuditOptions::Representation
end end
end end
@ -443,6 +423,26 @@ module Google
property :additional_authenticated_data, :base64 => true, as: 'additionalAuthenticatedData' property :additional_authenticated_data, :base64 => true, as: 'additionalAuthenticatedData'
end end
end end
class Location
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :name, as: 'name'
property :location_id, as: 'locationId'
hash :metadata, as: 'metadata'
end
end
class ListCryptoKeysResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :crypto_keys, as: 'cryptoKeys', class: Google::Apis::CloudkmsV1::CryptoKey, decorator: Google::Apis::CloudkmsV1::CryptoKey::Representation
property :total_size, as: 'totalSize'
end
end
end end
end end
end end

View File

@ -116,6 +116,47 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Lists KeyRings.
# @param [String] parent
# Required. The resource name of the location associated with the
# KeyRings, in the format `projects/*/locations/*`.
# @param [String] page_token
# Optional pagination token, returned earlier via
# ListKeyRingsResponse.next_page_token.
# @param [Fixnum] page_size
# Optional limit on the number of KeyRings to include in the
# response. Further KeyRings can subsequently be obtained by
# including the ListKeyRingsResponse.next_page_token in a subsequent
# request. If unspecified, the server will pick an appropriate default.
# @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::CloudkmsV1::ListKeyRingsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudkmsV1::ListKeyRingsResponse]
#
# @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 list_project_location_key_rings(parent, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+parent}/keyRings', options)
command.response_representation = Google::Apis::CloudkmsV1::ListKeyRingsResponse::Representation
command.response_class = Google::Apis::CloudkmsV1::ListKeyRingsResponse
command.params['parent'] = parent unless parent.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Create a new KeyRing in a given Project and Location. # Create a new KeyRing in a given Project and Location.
# @param [String] parent # @param [String] parent
# Required. The resource name of the location associated with the # Required. The resource name of the location associated with the
@ -291,47 +332,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Lists KeyRings.
# @param [String] parent
# Required. The resource name of the location associated with the
# KeyRings, in the format `projects/*/locations/*`.
# @param [String] page_token
# Optional pagination token, returned earlier via
# ListKeyRingsResponse.next_page_token.
# @param [Fixnum] page_size
# Optional limit on the number of KeyRings to include in the
# response. Further KeyRings can subsequently be obtained by
# including the ListKeyRingsResponse.next_page_token in a subsequent
# request. If unspecified, the server will pick an appropriate default.
# @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::CloudkmsV1::ListKeyRingsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudkmsV1::ListKeyRingsResponse]
#
# @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 list_project_location_key_rings(parent, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+parent}/keyRings', options)
command.response_representation = Google::Apis::CloudkmsV1::ListKeyRingsResponse::Representation
command.response_class = Google::Apis::CloudkmsV1::ListKeyRingsResponse
command.params['parent'] = parent unless parent.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists CryptoKeys. # Lists CryptoKeys.
# @param [String] parent # @param [String] parent
# Required. The resource name of the KeyRing to list, in the format # Required. The resource name of the KeyRing to list, in the format
@ -549,6 +549,37 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Returns metadata for a given CryptoKey, as well as its
# primary CryptoKeyVersion.
# @param [String] name
# The name of the CryptoKey to get.
# @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::CloudkmsV1::CryptoKey] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudkmsV1::CryptoKey]
#
# @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_location_key_ring_crypto_key(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::CloudkmsV1::CryptoKey::Representation
command.response_class = Google::Apis::CloudkmsV1::CryptoKey
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
# Update a CryptoKey. # Update a CryptoKey.
# @param [String] name # @param [String] name
# Output only. The resource name for this CryptoKey in the format # Output only. The resource name for this CryptoKey in the format
@ -586,37 +617,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Returns metadata for a given CryptoKey, as well as its
# primary CryptoKeyVersion.
# @param [String] name
# The name of the CryptoKey to get.
# @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::CloudkmsV1::CryptoKey] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudkmsV1::CryptoKey]
#
# @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_location_key_ring_crypto_key(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::CloudkmsV1::CryptoKey::Representation
command.response_class = Google::Apis::CloudkmsV1::CryptoKey
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
# Returns permissions that a caller has on the specified resource. # Returns permissions that a caller has on the specified resource.
# If the resource does not exist, this will return an empty set of # If the resource does not exist, this will return an empty set of
# permissions, not a NOT_FOUND error. # permissions, not a NOT_FOUND error.
@ -690,19 +690,14 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Lists CryptoKeyVersions. # Create a new CryptoKeyVersion in a CryptoKey.
# The server will assign the next sequential id. If unset,
# state will be set to
# ENABLED.
# @param [String] parent # @param [String] parent
# Required. The resource name of the CryptoKey to list, in the format # Required. The name of the CryptoKey associated with
# `projects/*/locations/*/keyRings/*/cryptoKeys/*`. # the CryptoKeyVersions.
# @param [String] page_token # @param [Google::Apis::CloudkmsV1::CryptoKeyVersion] crypto_key_version_object
# Optional pagination token, returned earlier via
# ListCryptoKeyVersionsResponse.next_page_token.
# @param [Fixnum] page_size
# Optional limit on the number of CryptoKeyVersions to
# include in the response. Further CryptoKeyVersions can
# subsequently be obtained by including the
# ListCryptoKeyVersionsResponse.next_page_token in a subsequent request.
# If unspecified, the server will pick an appropriate default.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -712,21 +707,21 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::CloudkmsV1::ListCryptoKeyVersionsResponse] parsed result object # @yieldparam result [Google::Apis::CloudkmsV1::CryptoKeyVersion] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::CloudkmsV1::ListCryptoKeyVersionsResponse] # @return [Google::Apis::CloudkmsV1::CryptoKeyVersion]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_project_location_key_ring_crypto_key_crypto_key_versions(parent, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block) def create_project_location_key_ring_crypto_key_crypto_key_version(parent, crypto_key_version_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+parent}/cryptoKeyVersions', options) command = make_simple_command(:post, 'v1/{+parent}/cryptoKeyVersions', options)
command.response_representation = Google::Apis::CloudkmsV1::ListCryptoKeyVersionsResponse::Representation command.request_representation = Google::Apis::CloudkmsV1::CryptoKeyVersion::Representation
command.response_class = Google::Apis::CloudkmsV1::ListCryptoKeyVersionsResponse command.request_object = crypto_key_version_object
command.response_representation = Google::Apis::CloudkmsV1::CryptoKeyVersion::Representation
command.response_class = Google::Apis::CloudkmsV1::CryptoKeyVersion
command.params['parent'] = parent unless parent.nil? command.params['parent'] = parent unless parent.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -774,43 +769,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Create a new CryptoKeyVersion in a CryptoKey.
# The server will assign the next sequential id. If unset,
# state will be set to
# ENABLED.
# @param [String] parent
# Required. The name of the CryptoKey associated with
# the CryptoKeyVersions.
# @param [Google::Apis::CloudkmsV1::CryptoKeyVersion] crypto_key_version_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::CloudkmsV1::CryptoKeyVersion] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudkmsV1::CryptoKeyVersion]
#
# @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 create_project_location_key_ring_crypto_key_crypto_key_version(parent, crypto_key_version_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+parent}/cryptoKeyVersions', options)
command.request_representation = Google::Apis::CloudkmsV1::CryptoKeyVersion::Representation
command.request_object = crypto_key_version_object
command.response_representation = Google::Apis::CloudkmsV1::CryptoKeyVersion::Representation
command.response_class = Google::Apis::CloudkmsV1::CryptoKeyVersion
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
# Restore a CryptoKeyVersion in the # Restore a CryptoKeyVersion in the
# DESTROY_SCHEDULED, # DESTROY_SCHEDULED,
# state. # state.
@ -920,6 +878,48 @@ module Google
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Lists CryptoKeyVersions.
# @param [String] parent
# Required. The resource name of the CryptoKey to list, in the format
# `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
# @param [String] page_token
# Optional pagination token, returned earlier via
# ListCryptoKeyVersionsResponse.next_page_token.
# @param [Fixnum] page_size
# Optional limit on the number of CryptoKeyVersions to
# include in the response. Further CryptoKeyVersions can
# subsequently be obtained by including the
# ListCryptoKeyVersionsResponse.next_page_token in a subsequent request.
# If unspecified, the server will pick an appropriate default.
# @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::CloudkmsV1::ListCryptoKeyVersionsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::CloudkmsV1::ListCryptoKeyVersionsResponse]
#
# @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 list_project_location_key_ring_crypto_key_crypto_key_versions(parent, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+parent}/cryptoKeyVersions', options)
command.response_representation = Google::Apis::CloudkmsV1::ListCryptoKeyVersionsResponse::Representation
command.response_class = Google::Apis::CloudkmsV1::ListCryptoKeyVersionsResponse
command.params['parent'] = parent unless parent.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
protected protected

View File

@ -26,7 +26,7 @@ module Google
# @see https://cloud.google.com/resource-manager # @see https://cloud.google.com/resource-manager
module CloudresourcemanagerV1 module CloudresourcemanagerV1
VERSION = 'V1' VERSION = 'V1'
REVISION = '20170327' REVISION = '20170329'
# View your data across Google Cloud Platform services # View your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM_READ_ONLY = 'https://www.googleapis.com/auth/cloud-platform.read-only' AUTH_CLOUD_PLATFORM_READ_ONLY = 'https://www.googleapis.com/auth/cloud-platform.read-only'

File diff suppressed because it is too large Load Diff

View File

@ -34,25 +34,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AuditConfig class AuditConfig
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Status class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLiensResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -64,19 +52,31 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListLiensResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Binding class Binding
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class GetOrgPolicyRequest class RestoreDefault
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class RestoreDefault class GetOrgPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -154,13 +154,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class OrgPolicy class BooleanPolicy
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class BooleanPolicy class OrgPolicy
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -250,7 +250,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class FolderOperation class ListAvailableOrgPolicyConstraintsRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -262,7 +262,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListAvailableOrgPolicyConstraintsRequest class FolderOperation
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -289,18 +289,6 @@ module Google
end end
end end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :done, as: 'done'
hash :response, as: 'response'
property :name, as: 'name'
property :error, as: 'error', class: Google::Apis::CloudresourcemanagerV1::Status, decorator: Google::Apis::CloudresourcemanagerV1::Status::Representation
hash :metadata, as: 'metadata'
end
end
class AuditConfig class AuditConfig
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -310,6 +298,42 @@ module Google
end end
end end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :response, as: 'response'
property :name, as: 'name'
property :error, as: 'error', class: Google::Apis::CloudresourcemanagerV1::Status, decorator: Google::Apis::CloudresourcemanagerV1::Status::Representation
hash :metadata, as: 'metadata'
property :done, as: 'done'
end
end
class Constraint
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :version, as: 'version'
property :list_constraint, as: 'listConstraint', class: Google::Apis::CloudresourcemanagerV1::ListConstraint, decorator: Google::Apis::CloudresourcemanagerV1::ListConstraint::Representation
property :display_name, as: 'displayName'
property :description, as: 'description'
property :boolean_constraint, as: 'booleanConstraint', class: Google::Apis::CloudresourcemanagerV1::BooleanConstraint, decorator: Google::Apis::CloudresourcemanagerV1::BooleanConstraint::Representation
property :constraint_default, as: 'constraintDefault'
property :name, as: 'name'
end
end
class ListLiensResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :liens, as: 'liens', class: Google::Apis::CloudresourcemanagerV1::Lien, decorator: Google::Apis::CloudresourcemanagerV1::Lien::Representation
end
end
class Status class Status
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -319,30 +343,6 @@ module Google
end end
end end
class ListLiensResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :liens, as: 'liens', class: Google::Apis::CloudresourcemanagerV1::Lien, decorator: Google::Apis::CloudresourcemanagerV1::Lien::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class Constraint
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :constraint_default, as: 'constraintDefault'
property :name, as: 'name'
property :list_constraint, as: 'listConstraint', class: Google::Apis::CloudresourcemanagerV1::ListConstraint, decorator: Google::Apis::CloudresourcemanagerV1::ListConstraint::Representation
property :version, as: 'version'
property :display_name, as: 'displayName'
property :description, as: 'description'
property :boolean_constraint, as: 'booleanConstraint', class: Google::Apis::CloudresourcemanagerV1::BooleanConstraint, decorator: Google::Apis::CloudresourcemanagerV1::BooleanConstraint::Representation
end
end
class Binding class Binding
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -351,6 +351,12 @@ module Google
end end
end end
class RestoreDefault
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class GetOrgPolicyRequest class GetOrgPolicyRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -358,12 +364,6 @@ module Google
end end
end end
class RestoreDefault
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class UndeleteProjectRequest class UndeleteProjectRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -425,14 +425,14 @@ module Google
class Project class Project
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :create_time, as: 'createTime'
property :name, as: 'name' property :name, as: 'name'
property :project_id, as: 'projectId' property :project_id, as: 'projectId'
property :lifecycle_state, as: 'lifecycleState' property :lifecycle_state, as: 'lifecycleState'
property :project_number, as: 'projectNumber' property :project_number, as: 'projectNumber'
property :parent, as: 'parent', class: Google::Apis::CloudresourcemanagerV1::ResourceId, decorator: Google::Apis::CloudresourcemanagerV1::ResourceId::Representation property :parent, as: 'parent', class: Google::Apis::CloudresourcemanagerV1::ResourceId, decorator: Google::Apis::CloudresourcemanagerV1::ResourceId::Representation
hash :labels, as: 'labels'
property :create_time, as: 'createTime'
end end
end end
@ -448,9 +448,9 @@ module Google
class ListOrgPoliciesResponse class ListOrgPoliciesResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :policies, as: 'policies', class: Google::Apis::CloudresourcemanagerV1::OrgPolicy, decorator: Google::Apis::CloudresourcemanagerV1::OrgPolicy::Representation collection :policies, as: 'policies', class: Google::Apis::CloudresourcemanagerV1::OrgPolicy, decorator: Google::Apis::CloudresourcemanagerV1::OrgPolicy::Representation
property :next_page_token, as: 'nextPageToken'
end end
end end
@ -461,22 +461,6 @@ module Google
end end
end end
class OrgPolicy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :version, as: 'version'
property :restore_default, as: 'restoreDefault', class: Google::Apis::CloudresourcemanagerV1::RestoreDefault, decorator: Google::Apis::CloudresourcemanagerV1::RestoreDefault::Representation
property :list_policy, as: 'listPolicy', class: Google::Apis::CloudresourcemanagerV1::ListPolicy, decorator: Google::Apis::CloudresourcemanagerV1::ListPolicy::Representation
property :etag, :base64 => true, as: 'etag'
property :constraint, as: 'constraint'
property :boolean_policy, as: 'booleanPolicy', class: Google::Apis::CloudresourcemanagerV1::BooleanPolicy, decorator: Google::Apis::CloudresourcemanagerV1::BooleanPolicy::Representation
property :update_time, as: 'updateTime'
end
end
class BooleanPolicy class BooleanPolicy
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -484,15 +468,31 @@ module Google
end end
end end
class OrgPolicy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :update_time, as: 'updateTime'
property :version, as: 'version'
property :restore_default, as: 'restoreDefault', class: Google::Apis::CloudresourcemanagerV1::RestoreDefault, decorator: Google::Apis::CloudresourcemanagerV1::RestoreDefault::Representation
property :list_policy, as: 'listPolicy', class: Google::Apis::CloudresourcemanagerV1::ListPolicy, decorator: Google::Apis::CloudresourcemanagerV1::ListPolicy::Representation
property :etag, :base64 => true, as: 'etag'
property :boolean_policy, as: 'booleanPolicy', class: Google::Apis::CloudresourcemanagerV1::BooleanPolicy, decorator: Google::Apis::CloudresourcemanagerV1::BooleanPolicy::Representation
property :constraint, as: 'constraint'
end
end
class Lien class Lien
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :parent, as: 'parent'
property :create_time, as: 'createTime'
property :origin, as: 'origin'
property :name, as: 'name' property :name, as: 'name'
property :reason, as: 'reason' property :reason, as: 'reason'
property :origin, as: 'origin'
collection :restrictions, as: 'restrictions' collection :restrictions, as: 'restrictions'
property :parent, as: 'parent'
property :create_time, as: 'createTime'
end end
end end
@ -604,6 +604,26 @@ module Google
end end
end end
class ListAvailableOrgPolicyConstraintsRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
end
end
class Policy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :etag, :base64 => true, as: 'etag'
property :version, as: 'version'
collection :audit_configs, as: 'auditConfigs', class: Google::Apis::CloudresourcemanagerV1::AuditConfig, decorator: Google::Apis::CloudresourcemanagerV1::AuditConfig::Representation
collection :bindings, as: 'bindings', class: Google::Apis::CloudresourcemanagerV1::Binding, decorator: Google::Apis::CloudresourcemanagerV1::Binding::Representation
end
end
class FolderOperation class FolderOperation
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -614,31 +634,11 @@ module Google
end end
end end
class Policy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :version, as: 'version'
collection :audit_configs, as: 'auditConfigs', class: Google::Apis::CloudresourcemanagerV1::AuditConfig, decorator: Google::Apis::CloudresourcemanagerV1::AuditConfig::Representation
collection :bindings, as: 'bindings', class: Google::Apis::CloudresourcemanagerV1::Binding, decorator: Google::Apis::CloudresourcemanagerV1::Binding::Representation
property :etag, :base64 => true, as: 'etag'
end
end
class ListAvailableOrgPolicyConstraintsRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
end
end
class ResourceId class ResourceId
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type'
property :id, as: 'id' property :id, as: 'id'
property :type, as: 'type'
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -26,13 +26,13 @@ module Google
# @see https://cloud.google.com/resource-manager # @see https://cloud.google.com/resource-manager
module CloudresourcemanagerV1beta1 module CloudresourcemanagerV1beta1
VERSION = 'V1beta1' VERSION = 'V1beta1'
REVISION = '20170327' REVISION = '20170329'
# View your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM_READ_ONLY = 'https://www.googleapis.com/auth/cloud-platform.read-only'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
# View your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM_READ_ONLY = 'https://www.googleapis.com/auth/cloud-platform.read-only'
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -22,7 +22,49 @@ module Google
module Apis module Apis
module CloudresourcemanagerV1beta1 module CloudresourcemanagerV1beta1
class ListPolicy class Binding
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class UndeleteProjectRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Organization
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ProjectCreationStatus
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GetIamPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TestIamPermissionsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class OrganizationOwner
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -40,145 +82,37 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class GetAncestryRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TestIamPermissionsRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FolderOperation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Policy
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListAvailableOrgPolicyConstraintsRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ResourceId
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GetEffectiveOrgPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListOrgPoliciesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AuditConfig
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListOrganizationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Constraint
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Binding
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RestoreDefault
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GetOrgPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ClearOrgPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class UndeleteProjectRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ProjectCreationStatus
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class BooleanConstraint
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TestIamPermissionsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class GetIamPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class OrganizationOwner
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListProjectsResponse class ListProjectsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class GetAncestryRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Project class Project
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListOrgPoliciesResponse class TestIamPermissionsRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Policy
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FolderOperation
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -190,13 +124,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class BooleanPolicy class ResourceId
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class OrgPolicy class AuditConfig
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -208,50 +142,77 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListConstraint
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SetOrgPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SetIamPolicyRequest class SetIamPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Empty class ListOrganizationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Binding
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :members, as: 'members'
property :role, as: 'role'
end
end
class Empty
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class UndeleteProjectRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class Organization class Organization
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListAvailableOrgPolicyConstraintsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListPolicy
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :all_values, as: 'allValues' property :creation_time, as: 'creationTime'
collection :allowed_values, as: 'allowedValues' property :owner, as: 'owner', class: Google::Apis::CloudresourcemanagerV1beta1::OrganizationOwner, decorator: Google::Apis::CloudresourcemanagerV1beta1::OrganizationOwner::Representation
property :suggested_value, as: 'suggestedValue'
property :inherit_from_parent, as: 'inheritFromParent' property :name, as: 'name'
collection :denied_values, as: 'deniedValues' property :organization_id, as: 'organizationId'
property :lifecycle_state, as: 'lifecycleState'
property :display_name, as: 'displayName'
end
end
class ProjectCreationStatus
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :ready, as: 'ready'
property :create_time, as: 'createTime'
property :gettable, as: 'gettable'
end
end
class GetIamPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class TestIamPermissionsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :permissions, as: 'permissions'
end
end
class OrganizationOwner
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :directory_customer_id, as: 'directoryCustomerId'
end end
end end
@ -271,12 +232,35 @@ module Google
end end
end end
class ListProjectsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :projects, as: 'projects', class: Google::Apis::CloudresourcemanagerV1beta1::Project, decorator: Google::Apis::CloudresourcemanagerV1beta1::Project::Representation
end
end
class GetAncestryRequest class GetAncestryRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
end end
end end
class Project
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :lifecycle_state, as: 'lifecycleState'
property :project_number, as: 'projectNumber'
property :parent, as: 'parent', class: Google::Apis::CloudresourcemanagerV1beta1::ResourceId, decorator: Google::Apis::CloudresourcemanagerV1beta1::ResourceId::Representation
hash :labels, as: 'labels'
property :create_time, as: 'createTime'
property :name, as: 'name'
property :project_id, as: 'projectId'
end
end
class TestIamPermissionsRequest class TestIamPermissionsRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -284,16 +268,6 @@ module Google
end end
end end
class FolderOperation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :destination_parent, as: 'destinationParent'
property :operation_type, as: 'operationType'
property :display_name, as: 'displayName'
property :source_parent, as: 'sourceParent'
end
end
class Policy class Policy
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -306,11 +280,20 @@ module Google
end end
end end
class ListAvailableOrgPolicyConstraintsRequest class FolderOperation
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :page_token, as: 'pageToken' property :operation_type, as: 'operationType'
property :page_size, as: 'pageSize' property :display_name, as: 'displayName'
property :source_parent, as: 'sourceParent'
property :destination_parent, as: 'destinationParent'
end
end
class FolderOperationError
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :error_message_id, as: 'errorMessageId'
end end
end end
@ -322,21 +305,6 @@ module Google
end end
end end
class GetEffectiveOrgPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :constraint, as: 'constraint'
end
end
class ListOrgPoliciesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
end
end
class AuditConfig class AuditConfig
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -346,162 +314,6 @@ module Google
end end
end end
class ListOrganizationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :organizations, as: 'organizations', class: Google::Apis::CloudresourcemanagerV1beta1::Organization, decorator: Google::Apis::CloudresourcemanagerV1beta1::Organization::Representation
end
end
class Constraint
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :list_constraint, as: 'listConstraint', class: Google::Apis::CloudresourcemanagerV1beta1::ListConstraint, decorator: Google::Apis::CloudresourcemanagerV1beta1::ListConstraint::Representation
property :version, as: 'version'
property :description, as: 'description'
property :display_name, as: 'displayName'
property :boolean_constraint, as: 'booleanConstraint', class: Google::Apis::CloudresourcemanagerV1beta1::BooleanConstraint, decorator: Google::Apis::CloudresourcemanagerV1beta1::BooleanConstraint::Representation
property :constraint_default, as: 'constraintDefault'
end
end
class Binding
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :members, as: 'members'
property :role, as: 'role'
end
end
class RestoreDefault
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class GetOrgPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :constraint, as: 'constraint'
end
end
class ClearOrgPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :etag, :base64 => true, as: 'etag'
property :constraint, as: 'constraint'
end
end
class UndeleteProjectRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class ProjectCreationStatus
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :ready, as: 'ready'
property :create_time, as: 'createTime'
property :gettable, as: 'gettable'
end
end
class BooleanConstraint
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class TestIamPermissionsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :permissions, as: 'permissions'
end
end
class GetIamPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class OrganizationOwner
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :directory_customer_id, as: 'directoryCustomerId'
end
end
class ListProjectsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :projects, as: 'projects', class: Google::Apis::CloudresourcemanagerV1beta1::Project, decorator: Google::Apis::CloudresourcemanagerV1beta1::Project::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class Project
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :project_id, as: 'projectId'
property :lifecycle_state, as: 'lifecycleState'
property :project_number, as: 'projectNumber'
property :parent, as: 'parent', class: Google::Apis::CloudresourcemanagerV1beta1::ResourceId, decorator: Google::Apis::CloudresourcemanagerV1beta1::ResourceId::Representation
property :create_time, as: 'createTime'
hash :labels, as: 'labels'
end
end
class ListOrgPoliciesResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :policies, as: 'policies', class: Google::Apis::CloudresourcemanagerV1beta1::OrgPolicy, decorator: Google::Apis::CloudresourcemanagerV1beta1::OrgPolicy::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class FolderOperationError
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :error_message_id, as: 'errorMessageId'
end
end
class BooleanPolicy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :enforced, as: 'enforced'
end
end
class OrgPolicy
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :version, as: 'version'
property :restore_default, as: 'restoreDefault', class: Google::Apis::CloudresourcemanagerV1beta1::RestoreDefault, decorator: Google::Apis::CloudresourcemanagerV1beta1::RestoreDefault::Representation
property :list_policy, as: 'listPolicy', class: Google::Apis::CloudresourcemanagerV1beta1::ListPolicy, decorator: Google::Apis::CloudresourcemanagerV1beta1::ListPolicy::Representation
property :etag, :base64 => true, as: 'etag'
property :boolean_policy, as: 'booleanPolicy', class: Google::Apis::CloudresourcemanagerV1beta1::BooleanPolicy, decorator: Google::Apis::CloudresourcemanagerV1beta1::BooleanPolicy::Representation
property :constraint, as: 'constraint'
property :update_time, as: 'updateTime'
end
end
class Ancestor class Ancestor
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -510,21 +322,6 @@ module Google
end end
end end
class ListConstraint
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :suggested_value, as: 'suggestedValue'
end
end
class SetOrgPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :policy, as: 'policy', class: Google::Apis::CloudresourcemanagerV1beta1::OrgPolicy, decorator: Google::Apis::CloudresourcemanagerV1beta1::OrgPolicy::Representation
end
end
class SetIamPolicyRequest class SetIamPolicyRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -534,30 +331,11 @@ module Google
end end
end end
class Empty class ListOrganizationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class Organization
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :owner, as: 'owner', class: Google::Apis::CloudresourcemanagerV1beta1::OrganizationOwner, decorator: Google::Apis::CloudresourcemanagerV1beta1::OrganizationOwner::Representation
property :name, as: 'name'
property :organization_id, as: 'organizationId'
property :lifecycle_state, as: 'lifecycleState'
property :display_name, as: 'displayName'
property :creation_time, as: 'creationTime'
end
end
class ListAvailableOrgPolicyConstraintsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken' property :next_page_token, as: 'nextPageToken'
collection :constraints, as: 'constraints', class: Google::Apis::CloudresourcemanagerV1beta1::Constraint, decorator: Google::Apis::CloudresourcemanagerV1beta1::Constraint::Representation collection :organizations, as: 'organizations', class: Google::Apis::CloudresourcemanagerV1beta1::Organization, decorator: Google::Apis::CloudresourcemanagerV1beta1::Organization::Representation
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -30,14 +30,14 @@ module Google
VERSION = 'V1' VERSION = 'V1'
REVISION = '20170320' REVISION = '20170320'
# Read Trace data for a project or application
AUTH_TRACE_READONLY = 'https://www.googleapis.com/auth/trace.readonly'
# Write Trace data for a project or application # Write Trace data for a project or application
AUTH_TRACE_APPEND = 'https://www.googleapis.com/auth/trace.append' AUTH_TRACE_APPEND = 'https://www.googleapis.com/auth/trace.append'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
# Read Trace data for a project or application
AUTH_TRACE_READONLY = 'https://www.googleapis.com/auth/trace.readonly'
end end
end end
end end

View File

@ -22,6 +22,25 @@ module Google
module Apis module Apis
module CloudtraceV1 module CloudtraceV1
# List of new or updated traces.
class Traces
include Google::Apis::Core::Hashable
# List of traces.
# Corresponds to the JSON property `traces`
# @return [Array<Google::Apis::CloudtraceV1::Trace>]
attr_accessor :traces
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@traces = args[:traces] if args.key?(:traces)
end
end
# A span represents a single timed event within a trace. Spans can be nested # A span represents a single timed event within a trace. Spans can be nested
# and form a trace tree. Often, a trace contains a root span that describes the # and form a trace tree. Often, a trace contains a root span that describes the
# end-to-end latency of an operation and, optionally, one or more subspans for # end-to-end latency of an operation and, optionally, one or more subspans for
@ -30,6 +49,18 @@ module Google
class TraceSpan class TraceSpan
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Start time of the span in nanoseconds from the UNIX epoch.
# Corresponds to the JSON property `startTime`
# @return [String]
attr_accessor :start_time
# Distinguishes between spans generated in a particular context. For example,
# two spans with the same name may be distinguished using `RPC_CLIENT`
# and `RPC_SERVER` to identify queueing latency associated with the span.
# Corresponds to the JSON property `kind`
# @return [String]
attr_accessor :kind
# Collection of labels associated with the span. Label keys must be less than # Collection of labels associated with the span. Label keys must be less than
# 128 bytes. Label values must be less than 16 kilobytes. # 128 bytes. Label values must be less than 16 kilobytes.
# Corresponds to the JSON property `labels` # Corresponds to the JSON property `labels`
@ -63,31 +94,19 @@ module Google
# @return [String] # @return [String]
attr_accessor :end_time attr_accessor :end_time
# Start time of the span in nanoseconds from the UNIX epoch.
# Corresponds to the JSON property `startTime`
# @return [String]
attr_accessor :start_time
# Distinguishes between spans generated in a particular context. For example,
# two spans with the same name may be distinguished using `RPC_CLIENT`
# and `RPC_SERVER` to identify queueing latency associated with the span.
# Corresponds to the JSON property `kind`
# @return [String]
attr_accessor :kind
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@start_time = args[:start_time] if args.key?(:start_time)
@kind = args[:kind] if args.key?(:kind)
@labels = args[:labels] if args.key?(:labels) @labels = args[:labels] if args.key?(:labels)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@span_id = args[:span_id] if args.key?(:span_id) @span_id = args[:span_id] if args.key?(:span_id)
@parent_span_id = args[:parent_span_id] if args.key?(:parent_span_id) @parent_span_id = args[:parent_span_id] if args.key?(:parent_span_id)
@end_time = args[:end_time] if args.key?(:end_time) @end_time = args[:end_time] if args.key?(:end_time)
@start_time = args[:start_time] if args.key?(:start_time)
@kind = args[:kind] if args.key?(:kind)
end end
end end
@ -170,25 +189,6 @@ module Google
@trace_id = args[:trace_id] if args.key?(:trace_id) @trace_id = args[:trace_id] if args.key?(:trace_id)
end end
end end
# List of new or updated traces.
class Traces
include Google::Apis::Core::Hashable
# List of traces.
# Corresponds to the JSON property `traces`
# @return [Array<Google::Apis::CloudtraceV1::Trace>]
attr_accessor :traces
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@traces = args[:traces] if args.key?(:traces)
end
end
end end
end end
end end

View File

@ -22,6 +22,12 @@ module Google
module Apis module Apis
module CloudtraceV1 module CloudtraceV1
class Traces
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TraceSpan class TraceSpan
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -47,21 +53,23 @@ module Google
end end
class Traces class Traces
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :traces, as: 'traces', class: Google::Apis::CloudtraceV1::Trace, decorator: Google::Apis::CloudtraceV1::Trace::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class TraceSpan class TraceSpan
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :start_time, as: 'startTime'
property :kind, as: 'kind'
hash :labels, as: 'labels' hash :labels, as: 'labels'
property :name, as: 'name' property :name, as: 'name'
property :span_id, as: 'spanId' property :span_id, as: 'spanId'
property :parent_span_id, as: 'parentSpanId' property :parent_span_id, as: 'parentSpanId'
property :end_time, as: 'endTime' property :end_time, as: 'endTime'
property :start_time, as: 'startTime'
property :kind, as: 'kind'
end end
end end
@ -89,14 +97,6 @@ module Google
property :trace_id, as: 'traceId' property :trace_id, as: 'traceId'
end end
end end
class Traces
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :traces, as: 'traces', class: Google::Apis::CloudtraceV1::Trace, decorator: Google::Apis::CloudtraceV1::Trace::Representation
end
end
end end
end end
end end

View File

@ -57,11 +57,11 @@ module Google
# @param [String] project_id # @param [String] project_id
# ID of the Cloud project where the trace data is stored. # ID of the Cloud project where the trace data is stored.
# @param [Google::Apis::CloudtraceV1::Traces] traces_object # @param [Google::Apis::CloudtraceV1::Traces] traces_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -74,34 +74,21 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def patch_project_traces(project_id, traces_object = nil, fields: nil, quota_user: nil, options: nil, &block) def patch_project_traces(project_id, traces_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:patch, 'v1/projects/{projectId}/traces', options) command = make_simple_command(:patch, 'v1/projects/{projectId}/traces', options)
command.request_representation = Google::Apis::CloudtraceV1::Traces::Representation command.request_representation = Google::Apis::CloudtraceV1::Traces::Representation
command.request_object = traces_object command.request_object = traces_object
command.response_representation = Google::Apis::CloudtraceV1::Empty::Representation command.response_representation = Google::Apis::CloudtraceV1::Empty::Representation
command.response_class = Google::Apis::CloudtraceV1::Empty command.response_class = Google::Apis::CloudtraceV1::Empty
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Returns of a list of traces that match the specified filter conditions. # Returns of a list of traces that match the specified filter conditions.
# @param [String] project_id # @param [String] project_id
# ID of the Cloud project where the trace data is stored. # ID of the Cloud project where the trace data is stored.
# @param [String] page_token
# Token identifying the page of results to return. If provided, use the
# value of the `next_page_token` field from a previous request. Optional.
# @param [String] start_time
# End of the time interval (inclusive) during which the trace data was
# collected from the application.
# @param [Fixnum] page_size
# Maximum number of traces to return. If not specified or <= 0, the
# implementation selects a reasonable value. The implementation may
# return fewer traces than the requested page size. Optional.
# @param [String] view
# Type of data returned for traces in the list. Optional. Default is
# `MINIMAL`.
# @param [String] order_by # @param [String] order_by
# Field used to sort the returned traces. Optional. # Field used to sort the returned traces. Optional.
# Can be one of the following: # Can be one of the following:
@ -118,11 +105,24 @@ module Google
# @param [String] end_time # @param [String] end_time
# Start of the time interval (inclusive) during which the trace data was # Start of the time interval (inclusive) during which the trace data was
# collected from the application. # collected from the application.
# @param [String] fields # @param [String] page_token
# Selector specifying which fields to include in a partial response. # Token identifying the page of results to return. If provided, use the
# value of the `next_page_token` field from a previous request. Optional.
# @param [String] start_time
# End of the time interval (inclusive) during which the trace data was
# collected from the application.
# @param [Fixnum] page_size
# Maximum number of traces to return. If not specified or <= 0, the
# implementation selects a reasonable value. The implementation may
# return fewer traces than the requested page size. Optional.
# @param [String] view
# Type of data returned for traces in the list. Optional. Default is
# `MINIMAL`.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -135,20 +135,20 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_project_traces(project_id, page_token: nil, start_time: nil, page_size: nil, view: nil, order_by: nil, filter: nil, end_time: nil, fields: nil, quota_user: nil, options: nil, &block) def list_project_traces(project_id, order_by: nil, filter: nil, end_time: nil, page_token: nil, start_time: nil, page_size: nil, view: nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/projects/{projectId}/traces', options) command = make_simple_command(:get, 'v1/projects/{projectId}/traces', options)
command.response_representation = Google::Apis::CloudtraceV1::ListTracesResponse::Representation command.response_representation = Google::Apis::CloudtraceV1::ListTracesResponse::Representation
command.response_class = Google::Apis::CloudtraceV1::ListTracesResponse command.response_class = Google::Apis::CloudtraceV1::ListTracesResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['orderBy'] = order_by unless order_by.nil?
command.query['filter'] = filter unless filter.nil?
command.query['endTime'] = end_time unless end_time.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['startTime'] = start_time unless start_time.nil? command.query['startTime'] = start_time unless start_time.nil?
command.query['pageSize'] = page_size unless page_size.nil? command.query['pageSize'] = page_size unless page_size.nil?
command.query['view'] = view unless view.nil? command.query['view'] = view unless view.nil?
command.query['orderBy'] = order_by unless order_by.nil?
command.query['filter'] = filter unless filter.nil?
command.query['endTime'] = end_time unless end_time.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
@ -157,11 +157,11 @@ module Google
# ID of the Cloud project where the trace data is stored. # ID of the Cloud project where the trace data is stored.
# @param [String] trace_id # @param [String] trace_id
# ID of the trace to return. # ID of the trace to return.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -174,14 +174,14 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_project_trace(project_id, trace_id, fields: nil, quota_user: nil, options: nil, &block) def get_project_trace(project_id, trace_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/projects/{projectId}/traces/{traceId}', options) command = make_simple_command(:get, 'v1/projects/{projectId}/traces/{traceId}', options)
command.response_representation = Google::Apis::CloudtraceV1::Trace::Representation command.response_representation = Google::Apis::CloudtraceV1::Trace::Representation
command.response_class = Google::Apis::CloudtraceV1::Trace command.response_class = Google::Apis::CloudtraceV1::Trace
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.params['traceId'] = trace_id unless trace_id.nil? command.params['traceId'] = trace_id unless trace_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end

View File

@ -1649,6 +1649,7 @@ module Google
# inserting a BackendService. An up-to-date fingerprint must be provided in # inserting a BackendService. An up-to-date fingerprint must be provided in
# order to update the BackendService. # order to update the BackendService.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -2684,6 +2685,7 @@ module Google
# hash in order to update or change labels. # hash in order to update or change labels.
# To see the latest fingerprint, make a get() request to retrieve a disk. # To see the latest fingerprint, make a get() request to retrieve a disk.
# Corresponds to the JSON property `labelFingerprint` # Corresponds to the JSON property `labelFingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :label_fingerprint attr_accessor :label_fingerprint
@ -3970,6 +3972,7 @@ module Google
# provide an up-to-date fingerprint hash when updating or changing labels. Make # provide an up-to-date fingerprint hash when updating or changing labels. Make
# a get() request to the resource to get the latest fingerprint. # a get() request to the resource to get the latest fingerprint.
# Corresponds to the JSON property `labelFingerprint` # Corresponds to the JSON property `labelFingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :label_fingerprint attr_accessor :label_fingerprint
@ -4762,6 +4765,7 @@ module Google
# to update or change labels. # to update or change labels.
# To see the latest fingerprint, make a get() request to retrieve an image. # To see the latest fingerprint, make a get() request to retrieve an image.
# Corresponds to the JSON property `labelFingerprint` # Corresponds to the JSON property `labelFingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :label_fingerprint attr_accessor :label_fingerprint
@ -5003,6 +5007,7 @@ module Google
# order to update or change metadata. # order to update or change metadata.
# To see the latest fingerprint, make get() request to the instance. # To see the latest fingerprint, make get() request to the instance.
# Corresponds to the JSON property `labelFingerprint` # Corresponds to the JSON property `labelFingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :label_fingerprint attr_accessor :label_fingerprint
@ -5191,6 +5196,7 @@ module Google
# fingerprint to detect conflicts when multiple users change the named ports # fingerprint to detect conflicts when multiple users change the named ports
# concurrently. # concurrently.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -5418,6 +5424,7 @@ module Google
# [Output Only] The fingerprint of the resource data. You can use this optional # [Output Only] The fingerprint of the resource data. You can use this optional
# field for optimistic locking when you update the resource. # field for optimistic locking when you update the resource.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -5995,6 +6002,7 @@ module Google
# Then, include the fingerprint in your request to ensure that you do not # Then, include the fingerprint in your request to ensure that you do not
# overwrite changes that were applied from another concurrent request. # overwrite changes that were applied from another concurrent request.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -6230,6 +6238,7 @@ module Google
# ensure that you do not overwrite changes that were applied from another # ensure that you do not overwrite changes that were applied from another
# concurrent request. # concurrent request.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -6678,6 +6687,7 @@ module Google
# conflicts. Provide the latest fingerprint value when making a request to add # conflicts. Provide the latest fingerprint value when making a request to add
# or change labels. # or change labels.
# Corresponds to the JSON property `labelFingerprint` # Corresponds to the JSON property `labelFingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :label_fingerprint attr_accessor :label_fingerprint
@ -7334,6 +7344,7 @@ module Google
# modify or update metadata. You must always provide an up-to-date fingerprint # modify or update metadata. You must always provide an up-to-date fingerprint
# hash in order to update or change metadata. # hash in order to update or change metadata.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -8346,6 +8357,7 @@ module Google
# If no `etag` is provided in the call to `setIamPolicy`, then the existing # If no `etag` is provided in the call to `setIamPolicy`, then the existing
# policy is overwritten blindly. # policy is overwritten blindly.
# Corresponds to the JSON property `etag` # Corresponds to the JSON property `etag`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :etag attr_accessor :etag
@ -8919,6 +8931,7 @@ module Google
# This field is used for optimistic locking when you update the target pool # This field is used for optimistic locking when you update the target pool
# entries. This field is optional. # entries. This field is optional.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -9046,6 +9059,7 @@ module Google
# ensure that you do not overwrite changes that were applied from another # ensure that you do not overwrite changes that were applied from another
# concurrent request. # concurrent request.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -10220,6 +10234,7 @@ module Google
# fingerprint hash in order to update or change labels. # fingerprint hash in order to update or change labels.
# To see the latest fingerprint, make a get() request to retrieve a snapshot. # To see the latest fingerprint, make a get() request to retrieve a snapshot.
# Corresponds to the JSON property `labelFingerprint` # Corresponds to the JSON property `labelFingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :label_fingerprint attr_accessor :label_fingerprint
@ -10914,6 +10929,7 @@ module Google
# hash in order to update or change metadata. # hash in order to update or change metadata.
# To see the latest fingerprint, make get() request to the instance. # To see the latest fingerprint, make get() request to the instance.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -12668,6 +12684,7 @@ module Google
# inserting a UrlMap. An up-to-date fingerprint must be provided in order to # inserting a UrlMap. An up-to-date fingerprint must be provided in order to
# update the UrlMap. # update the UrlMap.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -13467,6 +13484,7 @@ module Google
# provide an up-to-date fingerprint hash in order to update or change labels. # provide an up-to-date fingerprint hash in order to update or change labels.
# Make a get() request to the resource to get the latest fingerprint. # Make a get() request to the resource to get the latest fingerprint.
# Corresponds to the JSON property `labelFingerprint` # Corresponds to the JSON property `labelFingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :label_fingerprint attr_accessor :label_fingerprint

View File

@ -1215,6 +1215,7 @@ module Google
# inserting a BackendService. An up-to-date fingerprint must be provided in # inserting a BackendService. An up-to-date fingerprint must be provided in
# order to update the BackendService. # order to update the BackendService.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -4145,6 +4146,7 @@ module Google
# fingerprint to detect conflicts when multiple users change the named ports # fingerprint to detect conflicts when multiple users change the named ports
# concurrently. # concurrently.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -4360,6 +4362,7 @@ module Google
# [Output Only] The fingerprint of the resource data. You can use this optional # [Output Only] The fingerprint of the resource data. You can use this optional
# field for optimistic locking when you update the resource. # field for optimistic locking when you update the resource.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -4834,6 +4837,7 @@ module Google
# Then, include the fingerprint in your request to ensure that you do not # Then, include the fingerprint in your request to ensure that you do not
# overwrite changes that were applied from another concurrent request. # overwrite changes that were applied from another concurrent request.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -5069,6 +5073,7 @@ module Google
# ensure that you do not overwrite changes that were applied from another # ensure that you do not overwrite changes that were applied from another
# concurrent request. # concurrent request.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -6077,6 +6082,7 @@ module Google
# modify or update metadata. You must always provide an up-to-date fingerprint # modify or update metadata. You must always provide an up-to-date fingerprint
# hash in order to update or change metadata. # hash in order to update or change metadata.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -7339,6 +7345,7 @@ module Google
# This field is used for optimistic locking when you update the target pool # This field is used for optimistic locking when you update the target pool
# entries. This field is optional. # entries. This field is optional.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -7466,6 +7473,7 @@ module Google
# ensure that you do not overwrite changes that were applied from another # ensure that you do not overwrite changes that were applied from another
# concurrent request. # concurrent request.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -9150,6 +9158,7 @@ module Google
# hash in order to update or change metadata. # hash in order to update or change metadata.
# To see the latest fingerprint, make get() request to the instance. # To see the latest fingerprint, make get() request to the instance.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -10667,6 +10676,7 @@ module Google
# inserting a UrlMap. An up-to-date fingerprint must be provided in order to # inserting a UrlMap. An up-to-date fingerprint must be provided in order to
# update the UrlMap. # update the UrlMap.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -79,6 +79,46 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Request the job status.
# @param [String] project_id
# A project id.
# @param [String] location
# The location which contains the job specified by job_id.
# @param [String] job_id
# The job to get messages for.
# @param [String] start_time
# Return only metric data that has changed since this time.
# Default is to return all information about all metrics for the job.
# @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::DataflowV1b3::JobMetrics] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::DataflowV1b3::JobMetrics]
#
# @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_location_job_metrics(project_id, location, job_id, start_time: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}/metrics', options)
command.response_representation = Google::Apis::DataflowV1b3::JobMetrics::Representation
command.response_class = Google::Apis::DataflowV1b3::JobMetrics
command.params['projectId'] = project_id unless project_id.nil?
command.params['location'] = location unless location.nil?
command.params['jobId'] = job_id unless job_id.nil?
command.query['startTime'] = start_time unless start_time.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 state of the specified Cloud Dataflow job. # Gets the state of the specified Cloud Dataflow job.
# @param [String] project_id # @param [String] project_id
# The ID of the Cloud Platform project that the job belongs to. # The ID of the Cloud Platform project that the job belongs to.
@ -211,10 +251,10 @@ module Google
# @param [String] location # @param [String] location
# The location that contains this job. # The location that contains this job.
# @param [Google::Apis::DataflowV1b3::Job] job_object # @param [Google::Apis::DataflowV1b3::Job] job_object
# @param [String] view
# The level of information requested in response.
# @param [String] replace_job_id # @param [String] replace_job_id
# Deprecated. This field is now in the Job message. # Deprecated. This field is now in the Job message.
# @param [String] view
# The level of information requested in response.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -232,7 +272,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def create_project_location_job(project_id, location, job_object = nil, view: nil, replace_job_id: nil, fields: nil, quota_user: nil, options: nil, &block) def create_project_location_job(project_id, location, job_object = nil, replace_job_id: nil, view: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/jobs', options) command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/jobs', options)
command.request_representation = Google::Apis::DataflowV1b3::Job::Representation command.request_representation = Google::Apis::DataflowV1b3::Job::Representation
command.request_object = job_object command.request_object = job_object
@ -240,23 +280,21 @@ module Google
command.response_class = Google::Apis::DataflowV1b3::Job command.response_class = Google::Apis::DataflowV1b3::Job
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.params['location'] = location unless location.nil? command.params['location'] = location unless location.nil?
command.query['view'] = view unless view.nil?
command.query['replaceJobId'] = replace_job_id unless replace_job_id.nil? command.query['replaceJobId'] = replace_job_id unless replace_job_id.nil?
command.query['view'] = view unless view.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Request the job status. # Reports the status of dataflow WorkItems leased by a worker.
# @param [String] project_id # @param [String] project_id
# A project id. # The project which owns the WorkItem's job.
# @param [String] location # @param [String] location
# The location which contains the job specified by job_id. # The location which contains the WorkItem's job.
# @param [String] job_id # @param [String] job_id
# The job to get messages for. # The job which the WorkItem is part of.
# @param [String] start_time # @param [Google::Apis::DataflowV1b3::ReportWorkItemStatusRequest] report_work_item_status_request_object
# Return only metric data that has changed since this time.
# Default is to return all information about all metrics for the job.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -266,22 +304,62 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::DataflowV1b3::JobMetrics] parsed result object # @yieldparam result [Google::Apis::DataflowV1b3::ReportWorkItemStatusResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::DataflowV1b3::JobMetrics] # @return [Google::Apis::DataflowV1b3::ReportWorkItemStatusResponse]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_project_location_job_metrics(project_id, location, job_id, start_time: nil, fields: nil, quota_user: nil, options: nil, &block) def report_project_location_job_work_item_status(project_id, location, job_id, report_work_item_status_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}/metrics', options) command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}/workItems:reportStatus', options)
command.response_representation = Google::Apis::DataflowV1b3::JobMetrics::Representation command.request_representation = Google::Apis::DataflowV1b3::ReportWorkItemStatusRequest::Representation
command.response_class = Google::Apis::DataflowV1b3::JobMetrics command.request_object = report_work_item_status_request_object
command.response_representation = Google::Apis::DataflowV1b3::ReportWorkItemStatusResponse::Representation
command.response_class = Google::Apis::DataflowV1b3::ReportWorkItemStatusResponse
command.params['projectId'] = project_id unless project_id.nil?
command.params['location'] = location unless location.nil?
command.params['jobId'] = job_id unless job_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Leases a dataflow WorkItem to run.
# @param [String] project_id
# Identifies the project this worker belongs to.
# @param [String] location
# The location which contains the WorkItem's job.
# @param [String] job_id
# Identifies the workflow job this worker belongs to.
# @param [Google::Apis::DataflowV1b3::LeaseWorkItemRequest] lease_work_item_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::DataflowV1b3::LeaseWorkItemResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::DataflowV1b3::LeaseWorkItemResponse]
#
# @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 lease_project_location_work_item(project_id, location, job_id, lease_work_item_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}/workItems:lease', options)
command.request_representation = Google::Apis::DataflowV1b3::LeaseWorkItemRequest::Representation
command.request_object = lease_work_item_request_object
command.response_representation = Google::Apis::DataflowV1b3::LeaseWorkItemResponse::Representation
command.response_class = Google::Apis::DataflowV1b3::LeaseWorkItemResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.params['location'] = location unless location.nil? command.params['location'] = location unless location.nil?
command.params['jobId'] = job_id unless job_id.nil? command.params['jobId'] = job_id unless job_id.nil?
command.query['startTime'] = start_time unless start_time.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -344,84 +422,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Leases a dataflow WorkItem to run.
# @param [String] project_id
# Identifies the project this worker belongs to.
# @param [String] location
# The location which contains the WorkItem's job.
# @param [String] job_id
# Identifies the workflow job this worker belongs to.
# @param [Google::Apis::DataflowV1b3::LeaseWorkItemRequest] lease_work_item_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::DataflowV1b3::LeaseWorkItemResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::DataflowV1b3::LeaseWorkItemResponse]
#
# @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 lease_project_location_work_item(project_id, location, job_id, lease_work_item_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}/workItems:lease', options)
command.request_representation = Google::Apis::DataflowV1b3::LeaseWorkItemRequest::Representation
command.request_object = lease_work_item_request_object
command.response_representation = Google::Apis::DataflowV1b3::LeaseWorkItemResponse::Representation
command.response_class = Google::Apis::DataflowV1b3::LeaseWorkItemResponse
command.params['projectId'] = project_id unless project_id.nil?
command.params['location'] = location unless location.nil?
command.params['jobId'] = job_id unless job_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Reports the status of dataflow WorkItems leased by a worker.
# @param [String] project_id
# The project which owns the WorkItem's job.
# @param [String] location
# The location which contains the WorkItem's job.
# @param [String] job_id
# The job which the WorkItem is part of.
# @param [Google::Apis::DataflowV1b3::ReportWorkItemStatusRequest] report_work_item_status_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::DataflowV1b3::ReportWorkItemStatusResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::DataflowV1b3::ReportWorkItemStatusResponse]
#
# @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 report_project_location_job_work_item_status(project_id, location, job_id, report_work_item_status_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}/workItems:reportStatus', options)
command.request_representation = Google::Apis::DataflowV1b3::ReportWorkItemStatusRequest::Representation
command.request_object = report_work_item_status_request_object
command.response_representation = Google::Apis::DataflowV1b3::ReportWorkItemStatusResponse::Representation
command.response_class = Google::Apis::DataflowV1b3::ReportWorkItemStatusResponse
command.params['projectId'] = project_id unless project_id.nil?
command.params['location'] = location unless location.nil?
command.params['jobId'] = job_id unless job_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Launch a template. # Launch a template.
# @param [String] project_id # @param [String] project_id
# Required. The ID of the Cloud Platform project that the job belongs to. # Required. The ID of the Cloud Platform project that the job belongs to.
@ -579,12 +579,12 @@ module Google
# @param [String] project_id # @param [String] project_id
# The ID of the Cloud Platform project that the job belongs to. # The ID of the Cloud Platform project that the job belongs to.
# @param [Google::Apis::DataflowV1b3::Job] job_object # @param [Google::Apis::DataflowV1b3::Job] job_object
# @param [String] replace_job_id
# Deprecated. This field is now in the Job message.
# @param [String] view # @param [String] view
# The level of information requested in response. # The level of information requested in response.
# @param [String] location # @param [String] location
# The location that contains this job. # The location that contains this job.
# @param [String] replace_job_id
# Deprecated. This field is now in the Job message.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -602,16 +602,16 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def create_project_job(project_id, job_object = nil, view: nil, location: nil, replace_job_id: nil, fields: nil, quota_user: nil, options: nil, &block) def create_project_job(project_id, job_object = nil, replace_job_id: nil, view: nil, location: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1b3/projects/{projectId}/jobs', options) command = make_simple_command(:post, 'v1b3/projects/{projectId}/jobs', options)
command.request_representation = Google::Apis::DataflowV1b3::Job::Representation command.request_representation = Google::Apis::DataflowV1b3::Job::Representation
command.request_object = job_object command.request_object = job_object
command.response_representation = Google::Apis::DataflowV1b3::Job::Representation command.response_representation = Google::Apis::DataflowV1b3::Job::Representation
command.response_class = Google::Apis::DataflowV1b3::Job command.response_class = Google::Apis::DataflowV1b3::Job
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['replaceJobId'] = replace_job_id unless replace_job_id.nil?
command.query['view'] = view unless view.nil? command.query['view'] = view unless view.nil?
command.query['location'] = location unless location.nil? command.query['location'] = location unless location.nil?
command.query['replaceJobId'] = replace_job_id unless replace_job_id.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -662,10 +662,10 @@ module Google
# The ID of the Cloud Platform project that the job belongs to. # The ID of the Cloud Platform project that the job belongs to.
# @param [String] job_id # @param [String] job_id
# The job ID. # The job ID.
# @param [String] view
# The level of information requested in response.
# @param [String] location # @param [String] location
# The location that contains this job. # The location that contains this job.
# @param [String] view
# The level of information requested in response.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -683,14 +683,14 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_project_job(project_id, job_id, view: nil, location: nil, fields: nil, quota_user: nil, options: nil, &block) def get_project_job(project_id, job_id, location: nil, view: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1b3/projects/{projectId}/jobs/{jobId}', options) command = make_simple_command(:get, 'v1b3/projects/{projectId}/jobs/{jobId}', options)
command.response_representation = Google::Apis::DataflowV1b3::Job::Representation command.response_representation = Google::Apis::DataflowV1b3::Job::Representation
command.response_class = Google::Apis::DataflowV1b3::Job command.response_class = Google::Apis::DataflowV1b3::Job
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.params['jobId'] = job_id unless job_id.nil? command.params['jobId'] = job_id unless job_id.nil?
command.query['view'] = view unless view.nil?
command.query['location'] = location unless location.nil? command.query['location'] = location unless location.nil?
command.query['view'] = view unless view.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -893,11 +893,11 @@ module Google
# A project id. # A project id.
# @param [String] job_id # @param [String] job_id
# The job to get messages about. # The job to get messages about.
# @param [String] location
# The location which contains the job specified by job_id.
# @param [String] end_time # @param [String] end_time
# Return only messages with timestamps < end_time. The default is now # Return only messages with timestamps < end_time. The default is now
# (i.e. return up to the latest messages available). # (i.e. return up to the latest messages available).
# @param [String] location
# The location which contains the job specified by job_id.
# @param [String] start_time # @param [String] start_time
# If specified, return only messages with timestamps >= start_time. # If specified, return only messages with timestamps >= start_time.
# The default is the job creation time (i.e. beginning of messages). # The default is the job creation time (i.e. beginning of messages).
@ -928,14 +928,14 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_project_job_messages(project_id, job_id, location: nil, end_time: nil, start_time: nil, page_token: nil, page_size: nil, minimum_importance: nil, fields: nil, quota_user: nil, options: nil, &block) def list_project_job_messages(project_id, job_id, end_time: nil, location: nil, start_time: nil, page_token: nil, page_size: nil, minimum_importance: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1b3/projects/{projectId}/jobs/{jobId}/messages', options) command = make_simple_command(:get, 'v1b3/projects/{projectId}/jobs/{jobId}/messages', options)
command.response_representation = Google::Apis::DataflowV1b3::ListJobMessagesResponse::Representation command.response_representation = Google::Apis::DataflowV1b3::ListJobMessagesResponse::Representation
command.response_class = Google::Apis::DataflowV1b3::ListJobMessagesResponse command.response_class = Google::Apis::DataflowV1b3::ListJobMessagesResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.params['jobId'] = job_id unless job_id.nil? command.params['jobId'] = job_id unless job_id.nil?
command.query['location'] = location unless location.nil?
command.query['endTime'] = end_time unless end_time.nil? command.query['endTime'] = end_time unless end_time.nil?
command.query['location'] = location unless location.nil?
command.query['startTime'] = start_time unless start_time.nil? command.query['startTime'] = start_time unless start_time.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil? command.query['pageSize'] = page_size unless page_size.nil?

View File

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

File diff suppressed because it is too large Load Diff

View File

@ -22,19 +22,103 @@ module Google
module Apis module Apis
module DataprocV1 module DataprocV1
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class InstanceGroupConfig
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class JobScheduling
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListJobsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class NodeInitializationAction
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CancelJobRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SparkSqlJob
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Cluster
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListOperationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class OperationMetadata
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SoftwareConfig
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class JobPlacement
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PigJob
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ClusterStatus
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListClustersResponse class ListClustersResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Job class SparkJob
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class SparkJob class Job
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -58,13 +142,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class YarnApplication class QueryList
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class QueryList class YarnApplication
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -130,13 +214,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class AcceleratorConfig class ClusterMetrics
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ClusterMetrics class AcceleratorConfig
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -179,87 +263,162 @@ module Google
end end
class Status class Status
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport collection :details, as: 'details'
property :code, as: 'code'
property :message, as: 'message'
end
end end
class InstanceGroupConfig class InstanceGroupConfig
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :accelerators, as: 'accelerators', class: Google::Apis::DataprocV1::AcceleratorConfig, decorator: Google::Apis::DataprocV1::AcceleratorConfig::Representation
include Google::Apis::Core::JsonObjectSupport property :num_instances, as: 'numInstances'
property :disk_config, as: 'diskConfig', class: Google::Apis::DataprocV1::DiskConfig, decorator: Google::Apis::DataprocV1::DiskConfig::Representation
property :is_preemptible, as: 'isPreemptible'
property :managed_group_config, as: 'managedGroupConfig', class: Google::Apis::DataprocV1::ManagedGroupConfig, decorator: Google::Apis::DataprocV1::ManagedGroupConfig::Representation
property :machine_type_uri, as: 'machineTypeUri'
property :image_uri, as: 'imageUri'
collection :instance_names, as: 'instanceNames'
end
end end
class JobScheduling class JobScheduling
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :max_failures_per_hour, as: 'maxFailuresPerHour'
end end
class NodeInitializationAction
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class ListJobsResponse class ListJobsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :jobs, as: 'jobs', class: Google::Apis::DataprocV1::Job, decorator: Google::Apis::DataprocV1::Job::Representation
include Google::Apis::Core::JsonObjectSupport property :next_page_token, as: 'nextPageToken'
end
end
class NodeInitializationAction
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :execution_timeout, as: 'executionTimeout'
property :executable_file, as: 'executableFile'
end
end end
class CancelJobRequest class CancelJobRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport end
end end
class SparkSqlJob class SparkSqlJob
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :query_file_uri, as: 'queryFileUri'
property :query_list, as: 'queryList', class: Google::Apis::DataprocV1::QueryList, decorator: Google::Apis::DataprocV1::QueryList::Representation
include Google::Apis::Core::JsonObjectSupport hash :script_variables, as: 'scriptVariables'
collection :jar_file_uris, as: 'jarFileUris'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
hash :properties, as: 'properties'
end
end end
class Cluster class Cluster
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :metrics, as: 'metrics', class: Google::Apis::DataprocV1::ClusterMetrics, decorator: Google::Apis::DataprocV1::ClusterMetrics::Representation
include Google::Apis::Core::JsonObjectSupport property :status, as: 'status', class: Google::Apis::DataprocV1::ClusterStatus, decorator: Google::Apis::DataprocV1::ClusterStatus::Representation
collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::ClusterStatus, decorator: Google::Apis::DataprocV1::ClusterStatus::Representation
property :config, as: 'config', class: Google::Apis::DataprocV1::ClusterConfig, decorator: Google::Apis::DataprocV1::ClusterConfig::Representation
property :cluster_name, as: 'clusterName'
property :cluster_uuid, as: 'clusterUuid'
property :project_id, as: 'projectId'
end
end end
class ListOperationsResponse class ListOperationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :operations, as: 'operations', class: Google::Apis::DataprocV1::Operation, decorator: Google::Apis::DataprocV1::Operation::Representation
include Google::Apis::Core::JsonObjectSupport property :next_page_token, as: 'nextPageToken'
end
end end
class OperationMetadata class OperationMetadata
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :end_time, as: 'endTime'
property :start_time, as: 'startTime'
collection :warnings, as: 'warnings'
property :insert_time, as: 'insertTime'
collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::OperationStatus, decorator: Google::Apis::DataprocV1::OperationStatus::Representation
include Google::Apis::Core::JsonObjectSupport property :operation_type, as: 'operationType'
end property :description, as: 'description'
property :status, as: 'status', class: Google::Apis::DataprocV1::OperationStatus, decorator: Google::Apis::DataprocV1::OperationStatus::Representation
class JobPlacement property :details, as: 'details'
class Representation < Google::Apis::Core::JsonRepresentation; end property :state, as: 'state'
property :cluster_uuid, as: 'clusterUuid'
include Google::Apis::Core::JsonObjectSupport property :cluster_name, as: 'clusterName'
property :inner_state, as: 'innerState'
end
end end
class SoftwareConfig class SoftwareConfig
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :image_version, as: 'imageVersion'
hash :properties, as: 'properties'
end
end
include Google::Apis::Core::JsonObjectSupport class JobPlacement
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :cluster_name, as: 'clusterName'
property :cluster_uuid, as: 'clusterUuid'
end
end end
class PigJob class PigJob
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :continue_on_failure, as: 'continueOnFailure'
property :query_list, as: 'queryList', class: Google::Apis::DataprocV1::QueryList, decorator: Google::Apis::DataprocV1::QueryList::Representation
include Google::Apis::Core::JsonObjectSupport property :query_file_uri, as: 'queryFileUri'
collection :jar_file_uris, as: 'jarFileUris'
hash :script_variables, as: 'scriptVariables'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
hash :properties, as: 'properties'
end
end end
class ClusterStatus class ClusterStatus
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :state_start_time, as: 'stateStartTime'
property :substate, as: 'substate'
property :detail, as: 'detail'
property :state, as: 'state'
end
end end
class ListClustersResponse class ListClustersResponse
@ -271,17 +430,24 @@ module Google
end end
end end
class SparkJob
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :main_class, as: 'mainClass'
collection :archive_uris, as: 'archiveUris'
property :main_jar_file_uri, as: 'mainJarFileUri'
collection :jar_file_uris, as: 'jarFileUris'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
hash :properties, as: 'properties'
collection :args, as: 'args'
collection :file_uris, as: 'fileUris'
end
end
class Job class Job
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :driver_output_resource_uri, as: 'driverOutputResourceUri'
property :spark_job, as: 'sparkJob', class: Google::Apis::DataprocV1::SparkJob, decorator: Google::Apis::DataprocV1::SparkJob::Representation
property :spark_sql_job, as: 'sparkSqlJob', class: Google::Apis::DataprocV1::SparkSqlJob, decorator: Google::Apis::DataprocV1::SparkSqlJob::Representation
collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::JobStatus, decorator: Google::Apis::DataprocV1::JobStatus::Representation
collection :yarn_applications, as: 'yarnApplications', class: Google::Apis::DataprocV1::YarnApplication, decorator: Google::Apis::DataprocV1::YarnApplication::Representation collection :yarn_applications, as: 'yarnApplications', class: Google::Apis::DataprocV1::YarnApplication, decorator: Google::Apis::DataprocV1::YarnApplication::Representation
property :pyspark_job, as: 'pysparkJob', class: Google::Apis::DataprocV1::PySparkJob, decorator: Google::Apis::DataprocV1::PySparkJob::Representation property :pyspark_job, as: 'pysparkJob', class: Google::Apis::DataprocV1::PySparkJob, decorator: Google::Apis::DataprocV1::PySparkJob::Representation
@ -301,31 +467,24 @@ module Google
property :hive_job, as: 'hiveJob', class: Google::Apis::DataprocV1::HiveJob, decorator: Google::Apis::DataprocV1::HiveJob::Representation property :hive_job, as: 'hiveJob', class: Google::Apis::DataprocV1::HiveJob, decorator: Google::Apis::DataprocV1::HiveJob::Representation
end hash :labels, as: 'labels'
end property :driver_output_resource_uri, as: 'driverOutputResourceUri'
collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::JobStatus, decorator: Google::Apis::DataprocV1::JobStatus::Representation
class SparkJob property :spark_job, as: 'sparkJob', class: Google::Apis::DataprocV1::SparkJob, decorator: Google::Apis::DataprocV1::SparkJob::Representation
# @private
class Representation < Google::Apis::Core::JsonRepresentation property :spark_sql_job, as: 'sparkSqlJob', class: Google::Apis::DataprocV1::SparkSqlJob, decorator: Google::Apis::DataprocV1::SparkSqlJob::Representation
collection :jar_file_uris, as: 'jarFileUris'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
hash :properties, as: 'properties'
collection :args, as: 'args'
collection :file_uris, as: 'fileUris'
property :main_class, as: 'mainClass'
collection :archive_uris, as: 'archiveUris'
property :main_jar_file_uri, as: 'mainJarFileUri'
end end
end end
class JobStatus class JobStatus
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :state_start_time, as: 'stateStartTime'
property :substate, as: 'substate'
property :state, as: 'state' property :state, as: 'state'
property :details, as: 'details' property :details, as: 'details'
property :state_start_time, as: 'stateStartTime'
property :substate, as: 'substate'
end end
end end
@ -347,6 +506,13 @@ module Google
end end
end end
class QueryList
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :queries, as: 'queries'
end
end
class YarnApplication class YarnApplication
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -357,25 +523,18 @@ module Google
end end
end end
class QueryList
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :queries, as: 'queries'
end
end
class HadoopJob class HadoopJob
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :main_class, as: 'mainClass'
collection :archive_uris, as: 'archiveUris'
property :main_jar_file_uri, as: 'mainJarFileUri'
collection :jar_file_uris, as: 'jarFileUris' collection :jar_file_uris, as: 'jarFileUris'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
hash :properties, as: 'properties' hash :properties, as: 'properties'
collection :args, as: 'args' collection :args, as: 'args'
collection :file_uris, as: 'fileUris' collection :file_uris, as: 'fileUris'
property :main_class, as: 'mainClass'
collection :archive_uris, as: 'archiveUris'
property :main_jar_file_uri, as: 'mainJarFileUri'
end end
end end
@ -396,16 +555,16 @@ module Google
class ClusterOperationMetadata class ClusterOperationMetadata
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :operation_type, as: 'operationType'
property :description, as: 'description'
collection :warnings, as: 'warnings'
hash :labels, as: 'labels' hash :labels, as: 'labels'
property :status, as: 'status', class: Google::Apis::DataprocV1::ClusterOperationStatus, decorator: Google::Apis::DataprocV1::ClusterOperationStatus::Representation property :status, as: 'status', class: Google::Apis::DataprocV1::ClusterOperationStatus, decorator: Google::Apis::DataprocV1::ClusterOperationStatus::Representation
collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::ClusterOperationStatus, decorator: Google::Apis::DataprocV1::ClusterOperationStatus::Representation collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::ClusterOperationStatus, decorator: Google::Apis::DataprocV1::ClusterOperationStatus::Representation
property :cluster_uuid, as: 'clusterUuid'
property :cluster_name, as: 'clusterName' property :cluster_name, as: 'clusterName'
property :cluster_uuid, as: 'clusterUuid'
property :operation_type, as: 'operationType'
property :description, as: 'description'
collection :warnings, as: 'warnings'
end end
end end
@ -457,7 +616,6 @@ module Google
class PySparkJob class PySparkJob
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :archive_uris, as: 'archiveUris'
collection :jar_file_uris, as: 'jarFileUris' collection :jar_file_uris, as: 'jarFileUris'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
@ -466,14 +624,15 @@ module Google
collection :file_uris, as: 'fileUris' collection :file_uris, as: 'fileUris'
collection :python_file_uris, as: 'pythonFileUris' collection :python_file_uris, as: 'pythonFileUris'
property :main_python_file_uri, as: 'mainPythonFileUri' property :main_python_file_uri, as: 'mainPythonFileUri'
collection :archive_uris, as: 'archiveUris'
end end
end end
class GceClusterConfig class GceClusterConfig
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :internal_ip_only, as: 'internalIpOnly'
hash :metadata, as: 'metadata' hash :metadata, as: 'metadata'
property :internal_ip_only, as: 'internalIpOnly'
collection :service_account_scopes, as: 'serviceAccountScopes' collection :service_account_scopes, as: 'serviceAccountScopes'
collection :tags, as: 'tags' collection :tags, as: 'tags'
property :service_account, as: 'serviceAccount' property :service_account, as: 'serviceAccount'
@ -483,14 +642,6 @@ module Google
end end
end end
class AcceleratorConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :accelerator_count, as: 'acceleratorCount'
property :accelerator_type_uri, as: 'acceleratorTypeUri'
end
end
class ClusterMetrics class ClusterMetrics
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -499,6 +650,14 @@ module Google
end end
end end
class AcceleratorConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :accelerator_count, as: 'acceleratorCount'
property :accelerator_type_uri, as: 'acceleratorTypeUri'
end
end
class LoggingConfig class LoggingConfig
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -550,165 +709,6 @@ module Google
end end
end end
class Status
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :details, as: 'details'
property :code, as: 'code'
property :message, as: 'message'
end
end
class InstanceGroupConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :accelerators, as: 'accelerators', class: Google::Apis::DataprocV1::AcceleratorConfig, decorator: Google::Apis::DataprocV1::AcceleratorConfig::Representation
property :num_instances, as: 'numInstances'
property :disk_config, as: 'diskConfig', class: Google::Apis::DataprocV1::DiskConfig, decorator: Google::Apis::DataprocV1::DiskConfig::Representation
property :managed_group_config, as: 'managedGroupConfig', class: Google::Apis::DataprocV1::ManagedGroupConfig, decorator: Google::Apis::DataprocV1::ManagedGroupConfig::Representation
property :is_preemptible, as: 'isPreemptible'
property :image_uri, as: 'imageUri'
property :machine_type_uri, as: 'machineTypeUri'
collection :instance_names, as: 'instanceNames'
end
end
class JobScheduling
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :max_failures_per_hour, as: 'maxFailuresPerHour'
end
end
class NodeInitializationAction
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :executable_file, as: 'executableFile'
property :execution_timeout, as: 'executionTimeout'
end
end
class ListJobsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :jobs, as: 'jobs', class: Google::Apis::DataprocV1::Job, decorator: Google::Apis::DataprocV1::Job::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class CancelJobRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class SparkSqlJob
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :query_list, as: 'queryList', class: Google::Apis::DataprocV1::QueryList, decorator: Google::Apis::DataprocV1::QueryList::Representation
property :query_file_uri, as: 'queryFileUri'
hash :script_variables, as: 'scriptVariables'
collection :jar_file_uris, as: 'jarFileUris'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
hash :properties, as: 'properties'
end
end
class Cluster
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :project_id, as: 'projectId'
hash :labels, as: 'labels'
property :metrics, as: 'metrics', class: Google::Apis::DataprocV1::ClusterMetrics, decorator: Google::Apis::DataprocV1::ClusterMetrics::Representation
property :status, as: 'status', class: Google::Apis::DataprocV1::ClusterStatus, decorator: Google::Apis::DataprocV1::ClusterStatus::Representation
collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::ClusterStatus, decorator: Google::Apis::DataprocV1::ClusterStatus::Representation
property :config, as: 'config', class: Google::Apis::DataprocV1::ClusterConfig, decorator: Google::Apis::DataprocV1::ClusterConfig::Representation
property :cluster_name, as: 'clusterName'
property :cluster_uuid, as: 'clusterUuid'
end
end
class ListOperationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :operations, as: 'operations', class: Google::Apis::DataprocV1::Operation, decorator: Google::Apis::DataprocV1::Operation::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class OperationMetadata
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :end_time, as: 'endTime'
property :start_time, as: 'startTime'
collection :warnings, as: 'warnings'
property :insert_time, as: 'insertTime'
collection :status_history, as: 'statusHistory', class: Google::Apis::DataprocV1::OperationStatus, decorator: Google::Apis::DataprocV1::OperationStatus::Representation
property :operation_type, as: 'operationType'
property :description, as: 'description'
property :status, as: 'status', class: Google::Apis::DataprocV1::OperationStatus, decorator: Google::Apis::DataprocV1::OperationStatus::Representation
property :details, as: 'details'
property :state, as: 'state'
property :cluster_name, as: 'clusterName'
property :cluster_uuid, as: 'clusterUuid'
property :inner_state, as: 'innerState'
end
end
class JobPlacement
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :cluster_name, as: 'clusterName'
property :cluster_uuid, as: 'clusterUuid'
end
end
class SoftwareConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :image_version, as: 'imageVersion'
hash :properties, as: 'properties'
end
end
class PigJob
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :jar_file_uris, as: 'jarFileUris'
hash :script_variables, as: 'scriptVariables'
property :logging_config, as: 'loggingConfig', class: Google::Apis::DataprocV1::LoggingConfig, decorator: Google::Apis::DataprocV1::LoggingConfig::Representation
hash :properties, as: 'properties'
property :continue_on_failure, as: 'continueOnFailure'
property :query_file_uri, as: 'queryFileUri'
property :query_list, as: 'queryList', class: Google::Apis::DataprocV1::QueryList, decorator: Google::Apis::DataprocV1::QueryList::Representation
end
end
class ClusterStatus
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :detail, as: 'detail'
property :state, as: 'state'
property :state_start_time, as: 'stateStartTime'
property :substate, as: 'substate'
end
end
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -28,11 +28,11 @@ module Google
VERSION = 'V1' VERSION = 'V1'
REVISION = '20170314' REVISION = '20170314'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
# View and manage your Google Cloud Datastore data # View and manage your Google Cloud Datastore data
AUTH_DATASTORE = 'https://www.googleapis.com/auth/datastore' AUTH_DATASTORE = 'https://www.googleapis.com/auth/datastore'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
end end
end end
end end

View File

@ -22,16 +22,243 @@ module Google
module Apis module Apis
module DatastoreV1 module DatastoreV1
# The request for Datastore.RunQuery.
class RunQueryRequest
include Google::Apis::Core::Hashable
# The options shared by read requests.
# Corresponds to the JSON property `readOptions`
# @return [Google::Apis::DatastoreV1::ReadOptions]
attr_accessor :read_options
# A query for entities.
# Corresponds to the JSON property `query`
# @return [Google::Apis::DatastoreV1::Query]
attr_accessor :query
# A partition ID identifies a grouping of entities. The grouping is always
# by project and namespace, however the namespace ID may be empty.
# A partition ID contains several dimensions:
# project ID and namespace ID.
# Partition dimensions:
# - May be `""`.
# - Must be valid UTF-8 bytes.
# - Must have values that match regex `[A-Za-z\d\.\-_]`1,100``
# If the value of any dimension matches regex `__.*__`, the partition is
# reserved/read-only.
# A reserved/read-only partition ID is forbidden in certain documented
# contexts.
# Foreign partition IDs (in which the project ID does
# not match the context project ID ) are discouraged.
# Reads and writes of foreign partition IDs may fail if the project is not in an
# active state.
# Corresponds to the JSON property `partitionId`
# @return [Google::Apis::DatastoreV1::PartitionId]
attr_accessor :partition_id
# A [GQL query](https://cloud.google.com/datastore/docs/apis/gql/gql_reference).
# Corresponds to the JSON property `gqlQuery`
# @return [Google::Apis::DatastoreV1::GqlQuery]
attr_accessor :gql_query
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@read_options = args[:read_options] if args.key?(:read_options)
@query = args[:query] if args.key?(:query)
@partition_id = args[:partition_id] if args.key?(:partition_id)
@gql_query = args[:gql_query] if args.key?(:gql_query)
end
end
# The request for Datastore.Rollback.
class RollbackRequest
include Google::Apis::Core::Hashable
# The transaction identifier, returned by a call to
# Datastore.BeginTransaction.
# Corresponds to the JSON property `transaction`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :transaction
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@transaction = args[:transaction] if args.key?(:transaction)
end
end
# A filter that merges multiple other filters using the given operator.
class CompositeFilter
include Google::Apis::Core::Hashable
# The list of filters to combine.
# Must contain at least one filter.
# Corresponds to the JSON property `filters`
# @return [Array<Google::Apis::DatastoreV1::Filter>]
attr_accessor :filters
# The operator for combining multiple filters.
# Corresponds to the JSON property `op`
# @return [String]
attr_accessor :op
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@filters = args[:filters] if args.key?(:filters)
@op = args[:op] if args.key?(:op)
end
end
# The response for Datastore.AllocateIds.
class AllocateIdsResponse
include Google::Apis::Core::Hashable
# The keys specified in the request (in the same order), each with
# its key path completed with a newly allocated ID.
# Corresponds to the JSON property `keys`
# @return [Array<Google::Apis::DatastoreV1::Key>]
attr_accessor :keys
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@keys = args[:keys] if args.key?(:keys)
end
end
# A query for entities.
class Query
include Google::Apis::Core::Hashable
# The maximum number of results to return. Applies after all other
# constraints. Optional.
# Unspecified is interpreted as no limit.
# Must be >= 0 if specified.
# Corresponds to the JSON property `limit`
# @return [Fixnum]
attr_accessor :limit
# A holder for any type of filter.
# Corresponds to the JSON property `filter`
# @return [Google::Apis::DatastoreV1::Filter]
attr_accessor :filter
# A starting point for the query results. Query cursors are
# returned in query result batches and
# [can only be used to continue the same query](https://cloud.google.com/
# datastore/docs/concepts/queries#cursors_limits_and_offsets).
# Corresponds to the JSON property `startCursor`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :start_cursor
# The number of results to skip. Applies before limit, but after all other
# constraints. Optional. Must be >= 0 if specified.
# Corresponds to the JSON property `offset`
# @return [Fixnum]
attr_accessor :offset
# The kinds to query (if empty, returns entities of all kinds).
# Currently at most 1 kind may be specified.
# Corresponds to the JSON property `kind`
# @return [Array<Google::Apis::DatastoreV1::KindExpression>]
attr_accessor :kind
# The properties to make distinct. The query results will contain the first
# result for each distinct combination of values for the given properties
# (if empty, all results are returned).
# Corresponds to the JSON property `distinctOn`
# @return [Array<Google::Apis::DatastoreV1::PropertyReference>]
attr_accessor :distinct_on
# The order to apply to the query results (if empty, order is unspecified).
# Corresponds to the JSON property `order`
# @return [Array<Google::Apis::DatastoreV1::PropertyOrder>]
attr_accessor :order
# The projection to return. Defaults to returning all properties.
# Corresponds to the JSON property `projection`
# @return [Array<Google::Apis::DatastoreV1::Projection>]
attr_accessor :projection
# An ending point for the query results. Query cursors are
# returned in query result batches and
# [can only be used to limit the same query](https://cloud.google.com/datastore/
# docs/concepts/queries#cursors_limits_and_offsets).
# Corresponds to the JSON property `endCursor`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :end_cursor
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@limit = args[:limit] if args.key?(:limit)
@filter = args[:filter] if args.key?(:filter)
@start_cursor = args[:start_cursor] if args.key?(:start_cursor)
@offset = args[:offset] if args.key?(:offset)
@kind = args[:kind] if args.key?(:kind)
@distinct_on = args[:distinct_on] if args.key?(:distinct_on)
@order = args[:order] if args.key?(:order)
@projection = args[:projection] if args.key?(:projection)
@end_cursor = args[:end_cursor] if args.key?(:end_cursor)
end
end
# A filter on a specific property.
class PropertyFilter
include Google::Apis::Core::Hashable
# A message that can hold any of the supported value types and associated
# metadata.
# Corresponds to the JSON property `value`
# @return [Google::Apis::DatastoreV1::Value]
attr_accessor :value
# A reference to a property relative to the kind expressions.
# Corresponds to the JSON property `property`
# @return [Google::Apis::DatastoreV1::PropertyReference]
attr_accessor :property
# The operator to filter by.
# Corresponds to the JSON property `op`
# @return [String]
attr_accessor :op
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@value = args[:value] if args.key?(:value)
@property = args[:property] if args.key?(:property)
@op = args[:op] if args.key?(:op)
end
end
# The result of fetching an entity from Datastore. # The result of fetching an entity from Datastore.
class EntityResult class EntityResult
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A cursor that points to the position after the result entity.
# Set only when the `EntityResult` is part of a `QueryResultBatch` message.
# Corresponds to the JSON property `cursor`
# @return [String]
attr_accessor :cursor
# The version of the entity, a strictly positive number that monotonically # The version of the entity, a strictly positive number that monotonically
# increases with changes to the entity. # increases with changes to the entity.
# This field is set for `FULL` entity # This field is set for `FULL` entity
@ -51,42 +278,22 @@ module Google
# @return [Google::Apis::DatastoreV1::Entity] # @return [Google::Apis::DatastoreV1::Entity]
attr_accessor :entity attr_accessor :entity
# A cursor that points to the position after the result entity.
# Set only when the `EntityResult` is part of a `QueryResultBatch` message.
# Corresponds to the JSON property `cursor`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :cursor
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@cursor = args[:cursor] if args.key?(:cursor)
@version = args[:version] if args.key?(:version) @version = args[:version] if args.key?(:version)
@entity = args[:entity] if args.key?(:entity) @entity = args[:entity] if args.key?(:entity)
end @cursor = args[:cursor] if args.key?(:cursor)
end
# The response for Datastore.Commit.
class CommitResponse
include Google::Apis::Core::Hashable
# The result of performing the mutations.
# The i-th mutation result corresponds to the i-th mutation in the request.
# Corresponds to the JSON property `mutationResults`
# @return [Array<Google::Apis::DatastoreV1::MutationResult>]
attr_accessor :mutation_results
# The number of index entries updated during the commit, or zero if none were
# updated.
# Corresponds to the JSON property `indexUpdates`
# @return [Fixnum]
attr_accessor :index_updates
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@mutation_results = args[:mutation_results] if args.key?(:mutation_results)
@index_updates = args[:index_updates] if args.key?(:index_updates)
end end
end end
@ -200,6 +407,7 @@ module Google
# When `exclude_from_indexes` is false, may have at most 1500 bytes. # When `exclude_from_indexes` is false, may have at most 1500 bytes.
# In JSON requests, must be base64-encoded. # In JSON requests, must be base64-encoded.
# Corresponds to the JSON property `blobValue` # Corresponds to the JSON property `blobValue`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :blob_value attr_accessor :blob_value
@ -235,6 +443,33 @@ module Google
end end
end end
# The response for Datastore.Commit.
class CommitResponse
include Google::Apis::Core::Hashable
# The result of performing the mutations.
# The i-th mutation result corresponds to the i-th mutation in the request.
# Corresponds to the JSON property `mutationResults`
# @return [Array<Google::Apis::DatastoreV1::MutationResult>]
attr_accessor :mutation_results
# The number of index entries updated during the commit, or zero if none were
# updated.
# Corresponds to the JSON property `indexUpdates`
# @return [Fixnum]
attr_accessor :index_updates
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@mutation_results = args[:mutation_results] if args.key?(:mutation_results)
@index_updates = args[:index_updates] if args.key?(:index_updates)
end
end
# A partition ID identifies a grouping of entities. The grouping is always # A partition ID identifies a grouping of entities. The grouping is always
# by project and namespace, however the namespace ID may be empty. # by project and namespace, however the namespace ID may be empty.
# A partition ID contains several dimensions: # A partition ID contains several dimensions:
@ -282,6 +517,14 @@ module Google
class Entity class Entity
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A unique identifier for an entity.
# If a key's partition ID or any of its path kinds or names are
# reserved/read-only, the key is reserved/read-only.
# A reserved/read-only key is forbidden in certain documented contexts.
# Corresponds to the JSON property `key`
# @return [Google::Apis::DatastoreV1::Key]
attr_accessor :key
# The entity's properties. # The entity's properties.
# The map's keys are property names. # The map's keys are property names.
# A property name matching regex `__.*__` is reserved. # A property name matching regex `__.*__` is reserved.
@ -292,13 +535,30 @@ module Google
# @return [Hash<String,Google::Apis::DatastoreV1::Value>] # @return [Hash<String,Google::Apis::DatastoreV1::Value>]
attr_accessor :properties attr_accessor :properties
# A unique identifier for an entity. def initialize(**args)
# If a key's partition ID or any of its path kinds or names are update!(**args)
# reserved/read-only, the key is reserved/read-only. end
# A reserved/read-only key is forbidden in certain documented contexts.
# Corresponds to the JSON property `key` # Update properties of this object
# @return [Google::Apis::DatastoreV1::Key] def update!(**args)
attr_accessor :key @key = args[:key] if args.key?(:key)
@properties = args[:properties] if args.key?(:properties)
end
end
# The request for Datastore.Lookup.
class LookupRequest
include Google::Apis::Core::Hashable
# Keys of entities to look up.
# Corresponds to the JSON property `keys`
# @return [Array<Google::Apis::DatastoreV1::Key>]
attr_accessor :keys
# The options shared by read requests.
# Corresponds to the JSON property `readOptions`
# @return [Google::Apis::DatastoreV1::ReadOptions]
attr_accessor :read_options
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -306,8 +566,8 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@properties = args[:properties] if args.key?(:properties) @keys = args[:keys] if args.key?(:keys)
@key = args[:key] if args.key?(:key) @read_options = args[:read_options] if args.key?(:read_options)
end end
end end
@ -315,13 +575,9 @@ module Google
class QueryResultBatch class QueryResultBatch
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The results for this batch.
# Corresponds to the JSON property `entityResults`
# @return [Array<Google::Apis::DatastoreV1::EntityResult>]
attr_accessor :entity_results
# A cursor that points to the position after the last result in the batch. # A cursor that points to the position after the last result in the batch.
# Corresponds to the JSON property `endCursor` # Corresponds to the JSON property `endCursor`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :end_cursor attr_accessor :end_cursor
@ -345,6 +601,7 @@ module Google
# A cursor that points to the position after the last skipped result. # A cursor that points to the position after the last skipped result.
# Will be set when `skipped_results` != 0. # Will be set when `skipped_results` != 0.
# Corresponds to the JSON property `skippedCursor` # Corresponds to the JSON property `skippedCursor`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :skipped_cursor attr_accessor :skipped_cursor
@ -358,44 +615,24 @@ module Google
# @return [String] # @return [String]
attr_accessor :entity_result_type attr_accessor :entity_result_type
# The results for this batch.
# Corresponds to the JSON property `entityResults`
# @return [Array<Google::Apis::DatastoreV1::EntityResult>]
attr_accessor :entity_results
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@entity_results = args[:entity_results] if args.key?(:entity_results)
@end_cursor = args[:end_cursor] if args.key?(:end_cursor) @end_cursor = args[:end_cursor] if args.key?(:end_cursor)
@more_results = args[:more_results] if args.key?(:more_results) @more_results = args[:more_results] if args.key?(:more_results)
@snapshot_version = args[:snapshot_version] if args.key?(:snapshot_version) @snapshot_version = args[:snapshot_version] if args.key?(:snapshot_version)
@skipped_cursor = args[:skipped_cursor] if args.key?(:skipped_cursor) @skipped_cursor = args[:skipped_cursor] if args.key?(:skipped_cursor)
@skipped_results = args[:skipped_results] if args.key?(:skipped_results) @skipped_results = args[:skipped_results] if args.key?(:skipped_results)
@entity_result_type = args[:entity_result_type] if args.key?(:entity_result_type) @entity_result_type = args[:entity_result_type] if args.key?(:entity_result_type)
end @entity_results = args[:entity_results] if args.key?(:entity_results)
end
# The request for Datastore.Lookup.
class LookupRequest
include Google::Apis::Core::Hashable
# The options shared by read requests.
# Corresponds to the JSON property `readOptions`
# @return [Google::Apis::DatastoreV1::ReadOptions]
attr_accessor :read_options
# Keys of entities to look up.
# Corresponds to the JSON property `keys`
# @return [Array<Google::Apis::DatastoreV1::Key>]
attr_accessor :keys
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@read_options = args[:read_options] if args.key?(:read_options)
@keys = args[:keys] if args.key?(:keys)
end end
end end
@ -444,26 +681,27 @@ module Google
class GqlQueryParameter class GqlQueryParameter
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A query cursor. Query cursors are returned in query
# result batches.
# Corresponds to the JSON property `cursor`
# @return [String]
attr_accessor :cursor
# A message that can hold any of the supported value types and associated # A message that can hold any of the supported value types and associated
# metadata. # metadata.
# Corresponds to the JSON property `value` # Corresponds to the JSON property `value`
# @return [Google::Apis::DatastoreV1::Value] # @return [Google::Apis::DatastoreV1::Value]
attr_accessor :value attr_accessor :value
# A query cursor. Query cursors are returned in query
# result batches.
# Corresponds to the JSON property `cursor`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :cursor
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@cursor = args[:cursor] if args.key?(:cursor)
@value = args[:value] if args.key?(:value) @value = args[:value] if args.key?(:value)
@cursor = args[:cursor] if args.key?(:cursor)
end end
end end
@ -473,6 +711,7 @@ module Google
# The transaction identifier (always present). # The transaction identifier (always present).
# Corresponds to the JSON property `transaction` # Corresponds to the JSON property `transaction`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :transaction attr_accessor :transaction
@ -547,24 +786,24 @@ module Google
class RunQueryResponse class RunQueryResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A query for entities.
# Corresponds to the JSON property `query`
# @return [Google::Apis::DatastoreV1::Query]
attr_accessor :query
# A batch of results produced by a query. # A batch of results produced by a query.
# Corresponds to the JSON property `batch` # Corresponds to the JSON property `batch`
# @return [Google::Apis::DatastoreV1::QueryResultBatch] # @return [Google::Apis::DatastoreV1::QueryResultBatch]
attr_accessor :batch attr_accessor :batch
# A query for entities.
# Corresponds to the JSON property `query`
# @return [Google::Apis::DatastoreV1::Query]
attr_accessor :query
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@query = args[:query] if args.key?(:query)
@batch = args[:batch] if args.key?(:batch) @batch = args[:batch] if args.key?(:batch)
@query = args[:query] if args.key?(:query)
end end
end end
@ -572,6 +811,11 @@ module Google
class CommitRequest class CommitRequest
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The type of commit to perform. Defaults to `TRANSACTIONAL`.
# Corresponds to the JSON property `mode`
# @return [String]
attr_accessor :mode
# The mutations to perform. # The mutations to perform.
# When mode is `TRANSACTIONAL`, mutations affecting a single entity are # When mode is `TRANSACTIONAL`, mutations affecting a single entity are
# applied in order. The following sequences of mutations affecting a single # applied in order. The following sequences of mutations affecting a single
@ -590,36 +834,19 @@ module Google
# transaction identifier is returned by a call to # transaction identifier is returned by a call to
# Datastore.BeginTransaction. # Datastore.BeginTransaction.
# Corresponds to the JSON property `transaction` # Corresponds to the JSON property `transaction`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :transaction attr_accessor :transaction
# The type of commit to perform. Defaults to `TRANSACTIONAL`.
# Corresponds to the JSON property `mode`
# @return [String]
attr_accessor :mode
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@mode = args[:mode] if args.key?(:mode)
@mutations = args[:mutations] if args.key?(:mutations) @mutations = args[:mutations] if args.key?(:mutations)
@transaction = args[:transaction] if args.key?(:transaction) @transaction = args[:transaction] if args.key?(:transaction)
@mode = args[:mode] if args.key?(:mode)
end
end
# The request for Datastore.BeginTransaction.
class BeginTransactionRequest
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end end
end end
@ -648,6 +875,19 @@ module Google
end end
end end
# The request for Datastore.BeginTransaction.
class BeginTransactionRequest
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# A representation of a kind. # A representation of a kind.
class KindExpression class KindExpression
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -707,24 +947,24 @@ module Google
class LatLng class LatLng
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The longitude in degrees. It must be in the range [-180.0, +180.0].
# Corresponds to the JSON property `longitude`
# @return [Float]
attr_accessor :longitude
# The latitude in degrees. It must be in the range [-90.0, +90.0]. # The latitude in degrees. It must be in the range [-90.0, +90.0].
# Corresponds to the JSON property `latitude` # Corresponds to the JSON property `latitude`
# @return [Float] # @return [Float]
attr_accessor :latitude attr_accessor :latitude
# The longitude in degrees. It must be in the range [-180.0, +180.0].
# Corresponds to the JSON property `longitude`
# @return [Float]
attr_accessor :longitude
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@longitude = args[:longitude] if args.key?(:longitude)
@latitude = args[:latitude] if args.key?(:latitude) @latitude = args[:latitude] if args.key?(:latitude)
@longitude = args[:longitude] if args.key?(:longitude)
end end
end end
@ -804,6 +1044,25 @@ module Google
end end
end end
# A representation of a property in a projection.
class Projection
include Google::Apis::Core::Hashable
# A reference to a property relative to the kind expressions.
# Corresponds to the JSON property `property`
# @return [Google::Apis::DatastoreV1::PropertyReference]
attr_accessor :property
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@property = args[:property] if args.key?(:property)
end
end
# An array value. # An array value.
class ArrayValue class ArrayValue
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -825,29 +1084,18 @@ module Google
end end
end end
# A representation of a property in a projection.
class Projection
include Google::Apis::Core::Hashable
# A reference to a property relative to the kind expressions.
# Corresponds to the JSON property `property`
# @return [Google::Apis::DatastoreV1::PropertyReference]
attr_accessor :property
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@property = args[:property] if args.key?(:property)
end
end
# A mutation to apply to an entity. # A mutation to apply to an entity.
class Mutation class Mutation
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A Datastore data object.
# An entity is limited to 1 megabyte when stored. That _roughly_
# corresponds to a limit of 1 megabyte for the serialized form of this
# message.
# Corresponds to the JSON property `upsert`
# @return [Google::Apis::DatastoreV1::Entity]
attr_accessor :upsert
# A unique identifier for an entity. # A unique identifier for an entity.
# If a key's partition ID or any of its path kinds or names are # If a key's partition ID or any of its path kinds or names are
# reserved/read-only, the key is reserved/read-only. # reserved/read-only, the key is reserved/read-only.
@ -878,25 +1126,17 @@ module Google
# @return [Google::Apis::DatastoreV1::Entity] # @return [Google::Apis::DatastoreV1::Entity]
attr_accessor :update attr_accessor :update
# A Datastore data object.
# An entity is limited to 1 megabyte when stored. That _roughly_
# corresponds to a limit of 1 megabyte for the serialized form of this
# message.
# Corresponds to the JSON property `upsert`
# @return [Google::Apis::DatastoreV1::Entity]
attr_accessor :upsert
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@upsert = args[:upsert] if args.key?(:upsert)
@delete = args[:delete] if args.key?(:delete) @delete = args[:delete] if args.key?(:delete)
@insert = args[:insert] if args.key?(:insert) @insert = args[:insert] if args.key?(:insert)
@base_version = args[:base_version] if args.key?(:base_version) @base_version = args[:base_version] if args.key?(:base_version)
@update = args[:update] if args.key?(:update) @update = args[:update] if args.key?(:update)
@upsert = args[:upsert] if args.key?(:upsert)
end end
end end
@ -914,6 +1154,7 @@ module Google
# transaction identifier is returned by a call to # transaction identifier is returned by a call to
# Datastore.BeginTransaction. # Datastore.BeginTransaction.
# Corresponds to the JSON property `transaction` # Corresponds to the JSON property `transaction`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :transaction attr_accessor :transaction
@ -1034,254 +1275,24 @@ module Google
class Filter class Filter
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A filter on a specific property.
# Corresponds to the JSON property `propertyFilter`
# @return [Google::Apis::DatastoreV1::PropertyFilter]
attr_accessor :property_filter
# A filter that merges multiple other filters using the given operator. # A filter that merges multiple other filters using the given operator.
# Corresponds to the JSON property `compositeFilter` # Corresponds to the JSON property `compositeFilter`
# @return [Google::Apis::DatastoreV1::CompositeFilter] # @return [Google::Apis::DatastoreV1::CompositeFilter]
attr_accessor :composite_filter attr_accessor :composite_filter
# A filter on a specific property.
# Corresponds to the JSON property `propertyFilter`
# @return [Google::Apis::DatastoreV1::PropertyFilter]
attr_accessor :property_filter
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@property_filter = args[:property_filter] if args.key?(:property_filter)
@composite_filter = args[:composite_filter] if args.key?(:composite_filter) @composite_filter = args[:composite_filter] if args.key?(:composite_filter)
end @property_filter = args[:property_filter] if args.key?(:property_filter)
end
# The request for Datastore.Rollback.
class RollbackRequest
include Google::Apis::Core::Hashable
# The transaction identifier, returned by a call to
# Datastore.BeginTransaction.
# Corresponds to the JSON property `transaction`
# @return [String]
attr_accessor :transaction
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@transaction = args[:transaction] if args.key?(:transaction)
end
end
# The request for Datastore.RunQuery.
class RunQueryRequest
include Google::Apis::Core::Hashable
# The options shared by read requests.
# Corresponds to the JSON property `readOptions`
# @return [Google::Apis::DatastoreV1::ReadOptions]
attr_accessor :read_options
# A query for entities.
# Corresponds to the JSON property `query`
# @return [Google::Apis::DatastoreV1::Query]
attr_accessor :query
# A partition ID identifies a grouping of entities. The grouping is always
# by project and namespace, however the namespace ID may be empty.
# A partition ID contains several dimensions:
# project ID and namespace ID.
# Partition dimensions:
# - May be `""`.
# - Must be valid UTF-8 bytes.
# - Must have values that match regex `[A-Za-z\d\.\-_]`1,100``
# If the value of any dimension matches regex `__.*__`, the partition is
# reserved/read-only.
# A reserved/read-only partition ID is forbidden in certain documented
# contexts.
# Foreign partition IDs (in which the project ID does
# not match the context project ID ) are discouraged.
# Reads and writes of foreign partition IDs may fail if the project is not in an
# active state.
# Corresponds to the JSON property `partitionId`
# @return [Google::Apis::DatastoreV1::PartitionId]
attr_accessor :partition_id
# A [GQL query](https://cloud.google.com/datastore/docs/apis/gql/gql_reference).
# Corresponds to the JSON property `gqlQuery`
# @return [Google::Apis::DatastoreV1::GqlQuery]
attr_accessor :gql_query
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@read_options = args[:read_options] if args.key?(:read_options)
@query = args[:query] if args.key?(:query)
@partition_id = args[:partition_id] if args.key?(:partition_id)
@gql_query = args[:gql_query] if args.key?(:gql_query)
end
end
# A filter that merges multiple other filters using the given operator.
class CompositeFilter
include Google::Apis::Core::Hashable
# The list of filters to combine.
# Must contain at least one filter.
# Corresponds to the JSON property `filters`
# @return [Array<Google::Apis::DatastoreV1::Filter>]
attr_accessor :filters
# The operator for combining multiple filters.
# Corresponds to the JSON property `op`
# @return [String]
attr_accessor :op
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@filters = args[:filters] if args.key?(:filters)
@op = args[:op] if args.key?(:op)
end
end
# The response for Datastore.AllocateIds.
class AllocateIdsResponse
include Google::Apis::Core::Hashable
# The keys specified in the request (in the same order), each with
# its key path completed with a newly allocated ID.
# Corresponds to the JSON property `keys`
# @return [Array<Google::Apis::DatastoreV1::Key>]
attr_accessor :keys
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@keys = args[:keys] if args.key?(:keys)
end
end
# A query for entities.
class Query
include Google::Apis::Core::Hashable
# The kinds to query (if empty, returns entities of all kinds).
# Currently at most 1 kind may be specified.
# Corresponds to the JSON property `kind`
# @return [Array<Google::Apis::DatastoreV1::KindExpression>]
attr_accessor :kind
# The properties to make distinct. The query results will contain the first
# result for each distinct combination of values for the given properties
# (if empty, all results are returned).
# Corresponds to the JSON property `distinctOn`
# @return [Array<Google::Apis::DatastoreV1::PropertyReference>]
attr_accessor :distinct_on
# The order to apply to the query results (if empty, order is unspecified).
# Corresponds to the JSON property `order`
# @return [Array<Google::Apis::DatastoreV1::PropertyOrder>]
attr_accessor :order
# The projection to return. Defaults to returning all properties.
# Corresponds to the JSON property `projection`
# @return [Array<Google::Apis::DatastoreV1::Projection>]
attr_accessor :projection
# An ending point for the query results. Query cursors are
# returned in query result batches and
# [can only be used to limit the same query](https://cloud.google.com/datastore/
# docs/concepts/queries#cursors_limits_and_offsets).
# Corresponds to the JSON property `endCursor`
# @return [String]
attr_accessor :end_cursor
# A holder for any type of filter.
# Corresponds to the JSON property `filter`
# @return [Google::Apis::DatastoreV1::Filter]
attr_accessor :filter
# The maximum number of results to return. Applies after all other
# constraints. Optional.
# Unspecified is interpreted as no limit.
# Must be >= 0 if specified.
# Corresponds to the JSON property `limit`
# @return [Fixnum]
attr_accessor :limit
# A starting point for the query results. Query cursors are
# returned in query result batches and
# [can only be used to continue the same query](https://cloud.google.com/
# datastore/docs/concepts/queries#cursors_limits_and_offsets).
# Corresponds to the JSON property `startCursor`
# @return [String]
attr_accessor :start_cursor
# The number of results to skip. Applies before limit, but after all other
# constraints. Optional. Must be >= 0 if specified.
# Corresponds to the JSON property `offset`
# @return [Fixnum]
attr_accessor :offset
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@kind = args[:kind] if args.key?(:kind)
@distinct_on = args[:distinct_on] if args.key?(:distinct_on)
@order = args[:order] if args.key?(:order)
@projection = args[:projection] if args.key?(:projection)
@end_cursor = args[:end_cursor] if args.key?(:end_cursor)
@filter = args[:filter] if args.key?(:filter)
@limit = args[:limit] if args.key?(:limit)
@start_cursor = args[:start_cursor] if args.key?(:start_cursor)
@offset = args[:offset] if args.key?(:offset)
end
end
# A filter on a specific property.
class PropertyFilter
include Google::Apis::Core::Hashable
# A message that can hold any of the supported value types and associated
# metadata.
# Corresponds to the JSON property `value`
# @return [Google::Apis::DatastoreV1::Value]
attr_accessor :value
# A reference to a property relative to the kind expressions.
# Corresponds to the JSON property `property`
# @return [Google::Apis::DatastoreV1::PropertyReference]
attr_accessor :property
# The operator to filter by.
# Corresponds to the JSON property `op`
# @return [String]
attr_accessor :op
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@value = args[:value] if args.key?(:value)
@property = args[:property] if args.key?(:property)
@op = args[:op] if args.key?(:op)
end end
end end
end end

View File

@ -22,19 +22,55 @@ module Google
module Apis module Apis
module DatastoreV1 module DatastoreV1
class RunQueryRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RollbackRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CompositeFilter
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AllocateIdsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Query
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PropertyFilter
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class EntityResult class EntityResult
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class CommitResponse class Value
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Value class CommitResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -52,13 +88,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class QueryResultBatch class LookupRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class LookupRequest class QueryResultBatch
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -106,13 +142,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class BeginTransactionRequest class PropertyOrder
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class PropertyOrder class BeginTransactionRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -142,13 +178,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ArrayValue class Projection
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Projection class ArrayValue
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -190,58 +226,82 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class RollbackRequest class RunQueryRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :read_options, as: 'readOptions', class: Google::Apis::DatastoreV1::ReadOptions, decorator: Google::Apis::DatastoreV1::ReadOptions::Representation
include Google::Apis::Core::JsonObjectSupport property :query, as: 'query', class: Google::Apis::DatastoreV1::Query, decorator: Google::Apis::DatastoreV1::Query::Representation
property :partition_id, as: 'partitionId', class: Google::Apis::DatastoreV1::PartitionId, decorator: Google::Apis::DatastoreV1::PartitionId::Representation
property :gql_query, as: 'gqlQuery', class: Google::Apis::DatastoreV1::GqlQuery, decorator: Google::Apis::DatastoreV1::GqlQuery::Representation
end
end end
class RunQueryRequest class RollbackRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :transaction, :base64 => true, as: 'transaction'
end
end end
class CompositeFilter class CompositeFilter
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :filters, as: 'filters', class: Google::Apis::DatastoreV1::Filter, decorator: Google::Apis::DatastoreV1::Filter::Representation
include Google::Apis::Core::JsonObjectSupport property :op, as: 'op'
end
end end
class AllocateIdsResponse class AllocateIdsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :keys, as: 'keys', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class Query class Query
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :limit, as: 'limit'
property :filter, as: 'filter', class: Google::Apis::DatastoreV1::Filter, decorator: Google::Apis::DatastoreV1::Filter::Representation
include Google::Apis::Core::JsonObjectSupport property :start_cursor, :base64 => true, as: 'startCursor'
property :offset, as: 'offset'
collection :kind, as: 'kind', class: Google::Apis::DatastoreV1::KindExpression, decorator: Google::Apis::DatastoreV1::KindExpression::Representation
collection :distinct_on, as: 'distinctOn', class: Google::Apis::DatastoreV1::PropertyReference, decorator: Google::Apis::DatastoreV1::PropertyReference::Representation
collection :order, as: 'order', class: Google::Apis::DatastoreV1::PropertyOrder, decorator: Google::Apis::DatastoreV1::PropertyOrder::Representation
collection :projection, as: 'projection', class: Google::Apis::DatastoreV1::Projection, decorator: Google::Apis::DatastoreV1::Projection::Representation
property :end_cursor, :base64 => true, as: 'endCursor'
end
end end
class PropertyFilter class PropertyFilter
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :value, as: 'value', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation
include Google::Apis::Core::JsonObjectSupport property :property, as: 'property', class: Google::Apis::DatastoreV1::PropertyReference, decorator: Google::Apis::DatastoreV1::PropertyReference::Representation
property :op, as: 'op'
end
end end
class EntityResult class EntityResult
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :cursor, :base64 => true, as: 'cursor'
property :version, as: 'version' property :version, as: 'version'
property :entity, as: 'entity', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation property :entity, as: 'entity', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation
end property :cursor, :base64 => true, as: 'cursor'
end
class CommitResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :mutation_results, as: 'mutationResults', class: Google::Apis::DatastoreV1::MutationResult, decorator: Google::Apis::DatastoreV1::MutationResult::Representation
property :index_updates, as: 'indexUpdates'
end end
end end
@ -268,6 +328,15 @@ module Google
end end
end end
class CommitResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :mutation_results, as: 'mutationResults', class: Google::Apis::DatastoreV1::MutationResult, decorator: Google::Apis::DatastoreV1::MutationResult::Representation
property :index_updates, as: 'indexUpdates'
end
end
class PartitionId class PartitionId
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -279,9 +348,19 @@ module Google
class Entity class Entity
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :key, as: 'key', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation
hash :properties, as: 'properties', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation hash :properties, as: 'properties', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation
property :key, as: 'key', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation end
end
class LookupRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :keys, as: 'keys', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation
property :read_options, as: 'readOptions', class: Google::Apis::DatastoreV1::ReadOptions, decorator: Google::Apis::DatastoreV1::ReadOptions::Representation
end end
end end
@ -289,23 +368,13 @@ module Google
class QueryResultBatch class QueryResultBatch
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :entity_results, as: 'entityResults', class: Google::Apis::DatastoreV1::EntityResult, decorator: Google::Apis::DatastoreV1::EntityResult::Representation
property :end_cursor, :base64 => true, as: 'endCursor' property :end_cursor, :base64 => true, as: 'endCursor'
property :more_results, as: 'moreResults' property :more_results, as: 'moreResults'
property :snapshot_version, as: 'snapshotVersion' property :snapshot_version, as: 'snapshotVersion'
property :skipped_cursor, :base64 => true, as: 'skippedCursor' property :skipped_cursor, :base64 => true, as: 'skippedCursor'
property :skipped_results, as: 'skippedResults' property :skipped_results, as: 'skippedResults'
property :entity_result_type, as: 'entityResultType' property :entity_result_type, as: 'entityResultType'
end collection :entity_results, as: 'entityResults', class: Google::Apis::DatastoreV1::EntityResult, decorator: Google::Apis::DatastoreV1::EntityResult::Representation
end
class LookupRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :read_options, as: 'readOptions', class: Google::Apis::DatastoreV1::ReadOptions, decorator: Google::Apis::DatastoreV1::ReadOptions::Representation
collection :keys, as: 'keys', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation
end end
end end
@ -322,9 +391,9 @@ module Google
class GqlQueryParameter class GqlQueryParameter
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :cursor, :base64 => true, as: 'cursor'
property :value, as: 'value', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation property :value, as: 'value', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation
property :cursor, :base64 => true, as: 'cursor'
end end
end end
@ -358,26 +427,20 @@ module Google
class RunQueryResponse class RunQueryResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :query, as: 'query', class: Google::Apis::DatastoreV1::Query, decorator: Google::Apis::DatastoreV1::Query::Representation
property :batch, as: 'batch', class: Google::Apis::DatastoreV1::QueryResultBatch, decorator: Google::Apis::DatastoreV1::QueryResultBatch::Representation property :batch, as: 'batch', class: Google::Apis::DatastoreV1::QueryResultBatch, decorator: Google::Apis::DatastoreV1::QueryResultBatch::Representation
property :query, as: 'query', class: Google::Apis::DatastoreV1::Query, decorator: Google::Apis::DatastoreV1::Query::Representation
end end
end end
class CommitRequest class CommitRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :mode, as: 'mode'
collection :mutations, as: 'mutations', class: Google::Apis::DatastoreV1::Mutation, decorator: Google::Apis::DatastoreV1::Mutation::Representation collection :mutations, as: 'mutations', class: Google::Apis::DatastoreV1::Mutation, decorator: Google::Apis::DatastoreV1::Mutation::Representation
property :transaction, :base64 => true, as: 'transaction' property :transaction, :base64 => true, as: 'transaction'
property :mode, as: 'mode'
end
end
class BeginTransactionRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end end
end end
@ -390,6 +453,12 @@ module Google
end end
end end
class BeginTransactionRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class KindExpression class KindExpression
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -400,8 +469,8 @@ module Google
class LatLng class LatLng
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :longitude, as: 'longitude'
property :latitude, as: 'latitude' property :latitude, as: 'latitude'
property :longitude, as: 'longitude'
end end
end end
@ -422,14 +491,6 @@ module Google
end end
end end
class ArrayValue
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :values, as: 'values', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation
end
end
class Projection class Projection
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -438,9 +499,19 @@ module Google
end end
end end
class ArrayValue
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :values, as: 'values', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation
end
end
class Mutation class Mutation
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :upsert, as: 'upsert', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation
property :delete, as: 'delete', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation property :delete, as: 'delete', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation
property :insert, as: 'insert', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation property :insert, as: 'insert', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation
@ -448,8 +519,6 @@ module Google
property :base_version, as: 'baseVersion' property :base_version, as: 'baseVersion'
property :update, as: 'update', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation property :update, as: 'update', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation
property :upsert, as: 'upsert', class: Google::Apis::DatastoreV1::Entity, decorator: Google::Apis::DatastoreV1::Entity::Representation
end end
end end
@ -492,79 +561,10 @@ module Google
class Filter class Filter
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :property_filter, as: 'propertyFilter', class: Google::Apis::DatastoreV1::PropertyFilter, decorator: Google::Apis::DatastoreV1::PropertyFilter::Representation
property :composite_filter, as: 'compositeFilter', class: Google::Apis::DatastoreV1::CompositeFilter, decorator: Google::Apis::DatastoreV1::CompositeFilter::Representation property :composite_filter, as: 'compositeFilter', class: Google::Apis::DatastoreV1::CompositeFilter, decorator: Google::Apis::DatastoreV1::CompositeFilter::Representation
end property :property_filter, as: 'propertyFilter', class: Google::Apis::DatastoreV1::PropertyFilter, decorator: Google::Apis::DatastoreV1::PropertyFilter::Representation
end
class RollbackRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :transaction, :base64 => true, as: 'transaction'
end
end
class RunQueryRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :read_options, as: 'readOptions', class: Google::Apis::DatastoreV1::ReadOptions, decorator: Google::Apis::DatastoreV1::ReadOptions::Representation
property :query, as: 'query', class: Google::Apis::DatastoreV1::Query, decorator: Google::Apis::DatastoreV1::Query::Representation
property :partition_id, as: 'partitionId', class: Google::Apis::DatastoreV1::PartitionId, decorator: Google::Apis::DatastoreV1::PartitionId::Representation
property :gql_query, as: 'gqlQuery', class: Google::Apis::DatastoreV1::GqlQuery, decorator: Google::Apis::DatastoreV1::GqlQuery::Representation
end
end
class CompositeFilter
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :filters, as: 'filters', class: Google::Apis::DatastoreV1::Filter, decorator: Google::Apis::DatastoreV1::Filter::Representation
property :op, as: 'op'
end
end
class AllocateIdsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :keys, as: 'keys', class: Google::Apis::DatastoreV1::Key, decorator: Google::Apis::DatastoreV1::Key::Representation
end
end
class Query
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :kind, as: 'kind', class: Google::Apis::DatastoreV1::KindExpression, decorator: Google::Apis::DatastoreV1::KindExpression::Representation
collection :distinct_on, as: 'distinctOn', class: Google::Apis::DatastoreV1::PropertyReference, decorator: Google::Apis::DatastoreV1::PropertyReference::Representation
collection :order, as: 'order', class: Google::Apis::DatastoreV1::PropertyOrder, decorator: Google::Apis::DatastoreV1::PropertyOrder::Representation
collection :projection, as: 'projection', class: Google::Apis::DatastoreV1::Projection, decorator: Google::Apis::DatastoreV1::Projection::Representation
property :end_cursor, :base64 => true, as: 'endCursor'
property :filter, as: 'filter', class: Google::Apis::DatastoreV1::Filter, decorator: Google::Apis::DatastoreV1::Filter::Representation
property :limit, as: 'limit'
property :start_cursor, :base64 => true, as: 'startCursor'
property :offset, as: 'offset'
end
end
class PropertyFilter
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :value, as: 'value', class: Google::Apis::DatastoreV1::Value, decorator: Google::Apis::DatastoreV1::Value::Representation
property :property, as: 'property', class: Google::Apis::DatastoreV1::PropertyReference, decorator: Google::Apis::DatastoreV1::PropertyReference::Representation
property :op, as: 'op'
end end
end end
end end

View File

@ -52,11 +52,11 @@ module Google
# @param [String] project_id # @param [String] project_id
# The ID of the project against which to make the request. # The ID of the project against which to make the request.
# @param [Google::Apis::DatastoreV1::AllocateIdsRequest] allocate_ids_request_object # @param [Google::Apis::DatastoreV1::AllocateIdsRequest] allocate_ids_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -69,49 +69,15 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def allocate_project_ids(project_id, allocate_ids_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def allocate_project_ids(project_id, allocate_ids_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}:allocateIds', options) command = make_simple_command(:post, 'v1/projects/{projectId}:allocateIds', options)
command.request_representation = Google::Apis::DatastoreV1::AllocateIdsRequest::Representation command.request_representation = Google::Apis::DatastoreV1::AllocateIdsRequest::Representation
command.request_object = allocate_ids_request_object command.request_object = allocate_ids_request_object
command.response_representation = Google::Apis::DatastoreV1::AllocateIdsResponse::Representation command.response_representation = Google::Apis::DatastoreV1::AllocateIdsResponse::Representation
command.response_class = Google::Apis::DatastoreV1::AllocateIdsResponse command.response_class = Google::Apis::DatastoreV1::AllocateIdsResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Commits a transaction, optionally creating, deleting or modifying some
# entities.
# @param [String] project_id
# The ID of the project against which to make the request.
# @param [Google::Apis::DatastoreV1::CommitRequest] commit_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::DatastoreV1::CommitResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::DatastoreV1::CommitResponse]
#
# @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 commit_project(project_id, commit_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}:commit', options)
command.request_representation = Google::Apis::DatastoreV1::CommitRequest::Representation
command.request_object = commit_request_object
command.response_representation = Google::Apis::DatastoreV1::CommitResponse::Representation
command.response_class = Google::Apis::DatastoreV1::CommitResponse
command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
@ -119,11 +85,11 @@ module Google
# @param [String] project_id # @param [String] project_id
# The ID of the project against which to make the request. # The ID of the project against which to make the request.
# @param [Google::Apis::DatastoreV1::BeginTransactionRequest] begin_transaction_request_object # @param [Google::Apis::DatastoreV1::BeginTransactionRequest] begin_transaction_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -136,15 +102,49 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def begin_project_transaction(project_id, begin_transaction_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def begin_project_transaction(project_id, begin_transaction_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}:beginTransaction', options) command = make_simple_command(:post, 'v1/projects/{projectId}:beginTransaction', options)
command.request_representation = Google::Apis::DatastoreV1::BeginTransactionRequest::Representation command.request_representation = Google::Apis::DatastoreV1::BeginTransactionRequest::Representation
command.request_object = begin_transaction_request_object command.request_object = begin_transaction_request_object
command.response_representation = Google::Apis::DatastoreV1::BeginTransactionResponse::Representation command.response_representation = Google::Apis::DatastoreV1::BeginTransactionResponse::Representation
command.response_class = Google::Apis::DatastoreV1::BeginTransactionResponse command.response_class = Google::Apis::DatastoreV1::BeginTransactionResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Commits a transaction, optionally creating, deleting or modifying some
# entities.
# @param [String] project_id
# The ID of the project against which to make the request.
# @param [Google::Apis::DatastoreV1::CommitRequest] commit_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::DatastoreV1::CommitResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::DatastoreV1::CommitResponse]
#
# @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 commit_project(project_id, commit_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}:commit', options)
command.request_representation = Google::Apis::DatastoreV1::CommitRequest::Representation
command.request_object = commit_request_object
command.response_representation = Google::Apis::DatastoreV1::CommitResponse::Representation
command.response_class = Google::Apis::DatastoreV1::CommitResponse
command.params['projectId'] = project_id unless project_id.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
@ -152,11 +152,11 @@ module Google
# @param [String] project_id # @param [String] project_id
# The ID of the project against which to make the request. # The ID of the project against which to make the request.
# @param [Google::Apis::DatastoreV1::RunQueryRequest] run_query_request_object # @param [Google::Apis::DatastoreV1::RunQueryRequest] run_query_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -169,15 +169,15 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def run_project_query(project_id, run_query_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def run_project_query(project_id, run_query_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}:runQuery', options) command = make_simple_command(:post, 'v1/projects/{projectId}:runQuery', options)
command.request_representation = Google::Apis::DatastoreV1::RunQueryRequest::Representation command.request_representation = Google::Apis::DatastoreV1::RunQueryRequest::Representation
command.request_object = run_query_request_object command.request_object = run_query_request_object
command.response_representation = Google::Apis::DatastoreV1::RunQueryResponse::Representation command.response_representation = Google::Apis::DatastoreV1::RunQueryResponse::Representation
command.response_class = Google::Apis::DatastoreV1::RunQueryResponse command.response_class = Google::Apis::DatastoreV1::RunQueryResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
@ -185,11 +185,11 @@ module Google
# @param [String] project_id # @param [String] project_id
# The ID of the project against which to make the request. # The ID of the project against which to make the request.
# @param [Google::Apis::DatastoreV1::RollbackRequest] rollback_request_object # @param [Google::Apis::DatastoreV1::RollbackRequest] rollback_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -202,15 +202,15 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def rollback_project(project_id, rollback_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def rollback_project(project_id, rollback_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}:rollback', options) command = make_simple_command(:post, 'v1/projects/{projectId}:rollback', options)
command.request_representation = Google::Apis::DatastoreV1::RollbackRequest::Representation command.request_representation = Google::Apis::DatastoreV1::RollbackRequest::Representation
command.request_object = rollback_request_object command.request_object = rollback_request_object
command.response_representation = Google::Apis::DatastoreV1::RollbackResponse::Representation command.response_representation = Google::Apis::DatastoreV1::RollbackResponse::Representation
command.response_class = Google::Apis::DatastoreV1::RollbackResponse command.response_class = Google::Apis::DatastoreV1::RollbackResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
@ -218,11 +218,11 @@ module Google
# @param [String] project_id # @param [String] project_id
# The ID of the project against which to make the request. # The ID of the project against which to make the request.
# @param [Google::Apis::DatastoreV1::LookupRequest] lookup_request_object # @param [Google::Apis::DatastoreV1::LookupRequest] lookup_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -235,15 +235,15 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def lookup_project(project_id, lookup_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def lookup_project(project_id, lookup_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/projects/{projectId}:lookup', options) command = make_simple_command(:post, 'v1/projects/{projectId}:lookup', options)
command.request_representation = Google::Apis::DatastoreV1::LookupRequest::Representation command.request_representation = Google::Apis::DatastoreV1::LookupRequest::Representation
command.request_object = lookup_request_object command.request_object = lookup_request_object
command.response_representation = Google::Apis::DatastoreV1::LookupResponse::Representation command.response_representation = Google::Apis::DatastoreV1::LookupResponse::Representation
command.response_class = Google::Apis::DatastoreV1::LookupResponse command.response_class = Google::Apis::DatastoreV1::LookupResponse
command.params['projectId'] = project_id unless project_id.nil? command.params['projectId'] = project_id unless project_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end

View File

@ -225,6 +225,7 @@ module Google
# every request to modify data. To get the latest fingerprint value, perform a # every request to modify data. To get the latest fingerprint value, perform a
# get() request to a deployment. # get() request to a deployment.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -405,6 +406,7 @@ module Google
# every request to modify a deployment. To get the latest fingerprint value, # every request to modify a deployment. To get the latest fingerprint value,
# perform a get() request on the deployment. # perform a get() request on the deployment.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -458,6 +460,7 @@ module Google
# every request to modify a deployment. To get the latest fingerprint value, # every request to modify a deployment. To get the latest fingerprint value,
# perform a get() request on the deployment. # perform a get() request on the deployment.
# Corresponds to the JSON property `fingerprint` # Corresponds to the JSON property `fingerprint`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :fingerprint attr_accessor :fingerprint
@ -981,6 +984,7 @@ module Google
# If no `etag` is provided in the call to `setIamPolicy`, then the existing # If no `etag` is provided in the call to `setIamPolicy`, then the existing
# policy is overwritten blindly. # policy is overwritten blindly.
# Corresponds to the JSON property `etag` # Corresponds to the JSON property `etag`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :etag attr_accessor :etag

View File

@ -26,7 +26,7 @@ module Google
# @see https://developers.google.com/drive/ # @see https://developers.google.com/drive/
module DriveV2 module DriveV2
VERSION = 'V2' VERSION = 'V2'
REVISION = '20170320' REVISION = '20170323'
# View and manage the files in your Google Drive # View and manage the files in your Google Drive
AUTH_DRIVE = 'https://www.googleapis.com/auth/drive' AUTH_DRIVE = 'https://www.googleapis.com/auth/drive'

View File

@ -152,6 +152,11 @@ module Google
# @return [String] # @return [String]
attr_accessor :self_link attr_accessor :self_link
# A list of themes that are supported for Team Drives.
# Corresponds to the JSON property `teamDriveThemes`
# @return [Array<Google::Apis::DriveV2::About::TeamDriveTheme>]
attr_accessor :team_drive_themes
# Information about a Drive user. # Information about a Drive user.
# Corresponds to the JSON property `user` # Corresponds to the JSON property `user`
# @return [Google::Apis::DriveV2::User] # @return [Google::Apis::DriveV2::User]
@ -186,6 +191,7 @@ module Google
@remaining_change_ids = args[:remaining_change_ids] if args.key?(:remaining_change_ids) @remaining_change_ids = args[:remaining_change_ids] if args.key?(:remaining_change_ids)
@root_folder_id = args[:root_folder_id] if args.key?(:root_folder_id) @root_folder_id = args[:root_folder_id] if args.key?(:root_folder_id)
@self_link = args[:self_link] if args.key?(:self_link) @self_link = args[:self_link] if args.key?(:self_link)
@team_drive_themes = args[:team_drive_themes] if args.key?(:team_drive_themes)
@user = args[:user] if args.key?(:user) @user = args[:user] if args.key?(:user)
end end
@ -363,6 +369,37 @@ module Google
@service_name = args[:service_name] if args.key?(:service_name) @service_name = args[:service_name] if args.key?(:service_name)
end end
end end
#
class TeamDriveTheme
include Google::Apis::Core::Hashable
# A link to this Team Drive theme's background image.
# Corresponds to the JSON property `backgroundImageLink`
# @return [String]
attr_accessor :background_image_link
# The color of this Team Drive theme as an RGB hex string.
# Corresponds to the JSON property `colorRgb`
# @return [String]
attr_accessor :color_rgb
# The ID of the theme.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@background_image_link = args[:background_image_link] if args.key?(:background_image_link)
@color_rgb = args[:color_rgb] if args.key?(:color_rgb)
@id = args[:id] if args.key?(:id)
end
end
end end
# The apps resource provides a list of the apps that a user has installed, with # The apps resource provides a list of the apps that a user has installed, with
@ -1248,28 +1285,25 @@ module Google
attr_accessor :app_data_contents attr_accessor :app_data_contents
alias_method :app_data_contents?, :app_data_contents alias_method :app_data_contents?, :app_data_contents
# Whether the current user can comment on the file. Deprecated: use capabilities/ # Deprecated: use capabilities/canComment.
# canComment.
# Corresponds to the JSON property `canComment` # Corresponds to the JSON property `canComment`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_comment attr_accessor :can_comment
alias_method :can_comment?, :can_comment alias_method :can_comment?, :can_comment
# Whether the current user has read access to the Revisions resource of the file.
# Deprecated: use capabilities/canReadRevisions. # Deprecated: use capabilities/canReadRevisions.
# Corresponds to the JSON property `canReadRevisions` # Corresponds to the JSON property `canReadRevisions`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_read_revisions attr_accessor :can_read_revisions
alias_method :can_read_revisions?, :can_read_revisions alias_method :can_read_revisions?, :can_read_revisions
# Capabilities the current user has on the file. Each capability corresponds to # Capabilities the current user has on this file. Each capability corresponds to
# a fine-grained action that a user may take. # a fine-grained action that a user may take.
# Corresponds to the JSON property `capabilities` # Corresponds to the JSON property `capabilities`
# @return [Google::Apis::DriveV2::File::Capabilities] # @return [Google::Apis::DriveV2::File::Capabilities]
attr_accessor :capabilities attr_accessor :capabilities
# Whether the file can be copied by the current user. Deprecated: use # Deprecated: use capabilities/canCopy.
# capabilities/canCopy.
# Corresponds to the JSON property `copyable` # Corresponds to the JSON property `copyable`
# @return [Boolean] # @return [Boolean]
attr_accessor :copyable attr_accessor :copyable
@ -1296,8 +1330,7 @@ module Google
# @return [String] # @return [String]
attr_accessor :download_url attr_accessor :download_url
# Whether the file can be edited by the current user. Deprecated: use # Deprecated: use capabilities/canEdit.
# capabilities/canEdit.
# Corresponds to the JSON property `editable` # Corresponds to the JSON property `editable`
# @return [Boolean] # @return [Boolean]
attr_accessor :editable attr_accessor :editable
@ -1519,7 +1552,6 @@ module Google
# @return [String] # @return [String]
attr_accessor :self_link attr_accessor :self_link
# Whether the file's sharing settings can be modified by the current user.
# Deprecated: use capabilities/canShare. # Deprecated: use capabilities/canShare.
# Corresponds to the JSON property `shareable` # Corresponds to the JSON property `shareable`
# @return [Boolean] # @return [Boolean]
@ -1699,7 +1731,7 @@ module Google
@writers_can_share = args[:writers_can_share] if args.key?(:writers_can_share) @writers_can_share = args[:writers_can_share] if args.key?(:writers_can_share)
end end
# Capabilities the current user has on the file. Each capability corresponds to # Capabilities the current user has on this file. Each capability corresponds to
# a fine-grained action that a user may take. # a fine-grained action that a user may take.
class Capabilities class Capabilities
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -1711,33 +1743,33 @@ module Google
attr_accessor :can_add_children attr_accessor :can_add_children
alias_method :can_add_children?, :can_add_children alias_method :can_add_children?, :can_add_children
# Whether the current user can comment on the file. # Whether the current user can comment on this file.
# Corresponds to the JSON property `canComment` # Corresponds to the JSON property `canComment`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_comment attr_accessor :can_comment
alias_method :can_comment?, :can_comment alias_method :can_comment?, :can_comment
# Whether the file can be copied by the current user. For a Team Drive item, # Whether the current user can copy this file. For a Team Drive item, whether
# whether non-folder descendants of this item, or this item itself if it is not # the current user can copy non-folder descendants of this item, or this item
# a folder, can be copied. # itself if it is not a folder.
# Corresponds to the JSON property `canCopy` # Corresponds to the JSON property `canCopy`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_copy attr_accessor :can_copy
alias_method :can_copy?, :can_copy alias_method :can_copy?, :can_copy
# Whether the file can be deleted by the current user. # Whether the current user can delete this file.
# Corresponds to the JSON property `canDelete` # Corresponds to the JSON property `canDelete`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_delete attr_accessor :can_delete
alias_method :can_delete?, :can_delete alias_method :can_delete?, :can_delete
# Whether the file can be downloaded by the current user. # Whether the current user can download this file.
# Corresponds to the JSON property `canDownload` # Corresponds to the JSON property `canDownload`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_download attr_accessor :can_download
alias_method :can_download?, :can_download alias_method :can_download?, :can_download
# Whether the file can be edited by the current user. # Whether the current user can edit this file.
# Corresponds to the JSON property `canEdit` # Corresponds to the JSON property `canEdit`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_edit attr_accessor :can_edit
@ -1766,16 +1798,16 @@ module Google
attr_accessor :can_move_team_drive_item attr_accessor :can_move_team_drive_item
alias_method :can_move_team_drive_item?, :can_move_team_drive_item alias_method :can_move_team_drive_item?, :can_move_team_drive_item
# Whether the current user has read access to the Revisions resource of the file. # Whether the current user can read the revisions resource of this file. For a
# For a Team Drive item, whether revisions of non-folder descendants of this # Team Drive item, whether revisions of non-folder descendants of this item, or
# item, or this item itself if it is not a folder, can be read. # this item itself if it is not a folder, can be read.
# Corresponds to the JSON property `canReadRevisions` # Corresponds to the JSON property `canReadRevisions`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_read_revisions attr_accessor :can_read_revisions
alias_method :can_read_revisions?, :can_read_revisions alias_method :can_read_revisions?, :can_read_revisions
# Whether the current user has read access to the Team Drive to which this file # Whether the current user can read the Team Drive to which this file belongs.
# belongs. Only populated for Team Drive files. # Only populated for Team Drive files.
# Corresponds to the JSON property `canReadTeamDrive` # Corresponds to the JSON property `canReadTeamDrive`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_read_team_drive attr_accessor :can_read_team_drive
@ -1788,25 +1820,25 @@ module Google
attr_accessor :can_remove_children attr_accessor :can_remove_children
alias_method :can_remove_children?, :can_remove_children alias_method :can_remove_children?, :can_remove_children
# Whether the file can be renamed by the current user. # Whether the current user can rename this file.
# Corresponds to the JSON property `canRename` # Corresponds to the JSON property `canRename`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_rename attr_accessor :can_rename
alias_method :can_rename?, :can_rename alias_method :can_rename?, :can_rename
# Whether the file's sharing settings can be modified by the current user. # Whether the current user can modify the sharing settings for this file.
# Corresponds to the JSON property `canShare` # Corresponds to the JSON property `canShare`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_share attr_accessor :can_share
alias_method :can_share?, :can_share alias_method :can_share?, :can_share
# Whether the file can be trashed by the current user. # Whether the current user can move this file to trash.
# Corresponds to the JSON property `canTrash` # Corresponds to the JSON property `canTrash`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_trash attr_accessor :can_trash
alias_method :can_trash?, :can_trash alias_method :can_trash?, :can_trash
# Whether the file can be restored from the trash by the current user. # Whether the current user can restore this file from trash.
# Corresponds to the JSON property `canUntrash` # Corresponds to the JSON property `canUntrash`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_untrash attr_accessor :can_untrash
@ -2094,6 +2126,7 @@ module Google
# The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to
# RFC 4648 section 5. # RFC 4648 section 5.
# Corresponds to the JSON property `image` # Corresponds to the JSON property `image`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :image attr_accessor :image
@ -2402,7 +2435,7 @@ module Google
# @return [String] # @return [String]
attr_accessor :self_link attr_accessor :self_link
# Details of whether the Permissions on this Team Drive item are inherited or # Details of whether the permissions on this Team Drive item are inherited or
# directly on this item. This is an output-only field which is present only for # directly on this item. This is an output-only field which is present only for
# Team Drive items. # Team Drive items.
# Corresponds to the JSON property `teamDrivePermissionDetails` # Corresponds to the JSON property `teamDrivePermissionDetails`
@ -2888,11 +2921,30 @@ module Google
class TeamDrive class TeamDrive
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# An image file and cropping parameters from which a background image for this
# Team Drive is set. This is a write only field that can only be set on a drive.
# teamdrives.update request that does not set themeId. When specified, all
# fields of the backgroundImageFile must be set.
# Corresponds to the JSON property `backgroundImageFile`
# @return [Google::Apis::DriveV2::TeamDrive::BackgroundImageFile]
attr_accessor :background_image_file
# A short-lived link to this Team Drive's background image.
# Corresponds to the JSON property `backgroundImageLink`
# @return [String]
attr_accessor :background_image_link
# Capabilities the current user has on this Team Drive. # Capabilities the current user has on this Team Drive.
# Corresponds to the JSON property `capabilities` # Corresponds to the JSON property `capabilities`
# @return [Google::Apis::DriveV2::TeamDrive::Capabilities] # @return [Google::Apis::DriveV2::TeamDrive::Capabilities]
attr_accessor :capabilities attr_accessor :capabilities
# The color of this Team Drive as an RGB hex string. It can only be set on a
# drive.teamdrives.update request that does not set themeId.
# Corresponds to the JSON property `colorRgb`
# @return [String]
attr_accessor :color_rgb
# The ID of this Team Drive which is also the ID of the top level folder for # The ID of this Team Drive which is also the ID of the top level folder for
# this Team Drive. # this Team Drive.
# Corresponds to the JSON property `id` # Corresponds to the JSON property `id`
@ -2909,16 +2961,79 @@ module Google
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# The ID of the theme from which the background image and color will be set. The
# set of possible teamDriveThemes can be retrieved from a drive.about.get
# response. When not specified on a drive.teamdrives.insert request, a random
# theme is chosen from which the background image and color are set. This is a
# write only field that can only be set on a request that does not set colorRgb
# or backgroundImageFile.
# Corresponds to the JSON property `themeId`
# @return [String]
attr_accessor :theme_id
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@background_image_file = args[:background_image_file] if args.key?(:background_image_file)
@background_image_link = args[:background_image_link] if args.key?(:background_image_link)
@capabilities = args[:capabilities] if args.key?(:capabilities) @capabilities = args[:capabilities] if args.key?(:capabilities)
@color_rgb = args[:color_rgb] if args.key?(:color_rgb)
@id = args[:id] if args.key?(:id) @id = args[:id] if args.key?(:id)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@theme_id = args[:theme_id] if args.key?(:theme_id)
end
# An image file and cropping parameters from which a background image for this
# Team Drive is set. This is a write only field that can only be set on a drive.
# teamdrives.update request that does not set themeId. When specified, all
# fields of the backgroundImageFile must be set.
class BackgroundImageFile
include Google::Apis::Core::Hashable
# The ID of an image file in Drive to use for the background image.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# The width of the cropped image in the closed range of 0 to 1, which is the
# width of the cropped image divided by the width of the entire image. The
# height is computed by applying a width to height aspect ratio of 80 to 9. The
# resulting image must be at least 1280 pixels wide and 144 pixels high.
# Corresponds to the JSON property `width`
# @return [Float]
attr_accessor :width
# The X coordinate of the upper left corner of the cropping area in the
# background image. This is a value in the closed range of 0 to 1 which is the
# horizontal distance from the left side of the entire image to the left side of
# the cropping area divided by the width of the entire image.
# Corresponds to the JSON property `xCoordinate`
# @return [Float]
attr_accessor :x_coordinate
# The Y coordinate of the upper left corner of the cropping area in the
# background image. This is a value in the closed range of 0 to 1 which is the
# vertical distance from the top side of the entire image to the top side of the
# cropping area divided by the height of the entire image.
# Corresponds to the JSON property `yCoordinate`
# @return [Float]
attr_accessor :y_coordinate
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@id = args[:id] if args.key?(:id)
@width = args[:width] if args.key?(:width)
@x_coordinate = args[:x_coordinate] if args.key?(:x_coordinate)
@y_coordinate = args[:y_coordinate] if args.key?(:y_coordinate)
end
end end
# Capabilities the current user has on this Team Drive. # Capabilities the current user has on this Team Drive.
@ -2931,31 +3046,38 @@ module Google
attr_accessor :can_add_children attr_accessor :can_add_children
alias_method :can_add_children?, :can_add_children alias_method :can_add_children?, :can_add_children
# Whether the current user can change the background of this Team Drive.
# Corresponds to the JSON property `canChangeTeamDriveBackground`
# @return [Boolean]
attr_accessor :can_change_team_drive_background
alias_method :can_change_team_drive_background?, :can_change_team_drive_background
# Whether the current user can comment on files in this Team Drive. # Whether the current user can comment on files in this Team Drive.
# Corresponds to the JSON property `canComment` # Corresponds to the JSON property `canComment`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_comment attr_accessor :can_comment
alias_method :can_comment?, :can_comment alias_method :can_comment?, :can_comment
# Whether files in this Team Drive can be copied by the current user. # Whether the current user can copy files in this Team Drive.
# Corresponds to the JSON property `canCopy` # Corresponds to the JSON property `canCopy`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_copy attr_accessor :can_copy
alias_method :can_copy?, :can_copy alias_method :can_copy?, :can_copy
# Whether this Team Drive can be deleted by the current user. # Whether the current user can delete this Team Drive. Attempting to delete the
# Team Drive may still fail if there are untrashed items inside the Team Drive.
# Corresponds to the JSON property `canDeleteTeamDrive` # Corresponds to the JSON property `canDeleteTeamDrive`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_delete_team_drive attr_accessor :can_delete_team_drive
alias_method :can_delete_team_drive?, :can_delete_team_drive alias_method :can_delete_team_drive?, :can_delete_team_drive
# Whether files in this Team Drive can be downloaded by the current user. # Whether the current user can download files in this Team Drive.
# Corresponds to the JSON property `canDownload` # Corresponds to the JSON property `canDownload`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_download attr_accessor :can_download
alias_method :can_download?, :can_download alias_method :can_download?, :can_download
# Whether files in this Team Drive can be edited by the current user. # Whether the current user can edit files in this Team Drive
# Corresponds to the JSON property `canEdit` # Corresponds to the JSON property `canEdit`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_edit attr_accessor :can_edit
@ -2974,8 +3096,8 @@ module Google
attr_accessor :can_manage_members attr_accessor :can_manage_members
alias_method :can_manage_members?, :can_manage_members alias_method :can_manage_members?, :can_manage_members
# Whether the current user has read access to the Revisions resource of files in # Whether the current user can read the revisions resource of files in this Team
# this Team Drive. # Drive.
# Corresponds to the JSON property `canReadRevisions` # Corresponds to the JSON property `canReadRevisions`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_read_revisions attr_accessor :can_read_revisions
@ -2987,13 +3109,13 @@ module Google
attr_accessor :can_remove_children attr_accessor :can_remove_children
alias_method :can_remove_children?, :can_remove_children alias_method :can_remove_children?, :can_remove_children
# Whether files or folders in this Team Drive can be renamed by the current user. # Whether the current user can rename files or folders in this Team Drive.
# Corresponds to the JSON property `canRename` # Corresponds to the JSON property `canRename`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_rename attr_accessor :can_rename
alias_method :can_rename?, :can_rename alias_method :can_rename?, :can_rename
# Whether this Team Drive can be renamed by the current user. # Whether the current user can rename this Team Drive.
# Corresponds to the JSON property `canRenameTeamDrive` # Corresponds to the JSON property `canRenameTeamDrive`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_rename_team_drive attr_accessor :can_rename_team_drive
@ -3012,6 +3134,7 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@can_add_children = args[:can_add_children] if args.key?(:can_add_children) @can_add_children = args[:can_add_children] if args.key?(:can_add_children)
@can_change_team_drive_background = args[:can_change_team_drive_background] if args.key?(:can_change_team_drive_background)
@can_comment = args[:can_comment] if args.key?(:can_comment) @can_comment = args[:can_comment] if args.key?(:can_comment)
@can_copy = args[:can_copy] if args.key?(:can_copy) @can_copy = args[:can_copy] if args.key?(:can_copy)
@can_delete_team_drive = args[:can_delete_team_drive] if args.key?(:can_delete_team_drive) @can_delete_team_drive = args[:can_delete_team_drive] if args.key?(:can_delete_team_drive)

View File

@ -66,6 +66,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class TeamDriveTheme
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
@ -277,6 +283,12 @@ module Google
class TeamDrive class TeamDrive
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
class BackgroundImageFile
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Capabilities class Capabilities
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -336,6 +348,8 @@ module Google
property :remaining_change_ids, as: 'remainingChangeIds' property :remaining_change_ids, as: 'remainingChangeIds'
property :root_folder_id, as: 'rootFolderId' property :root_folder_id, as: 'rootFolderId'
property :self_link, as: 'selfLink' property :self_link, as: 'selfLink'
collection :team_drive_themes, as: 'teamDriveThemes', class: Google::Apis::DriveV2::About::TeamDriveTheme, decorator: Google::Apis::DriveV2::About::TeamDriveTheme::Representation
property :user, as: 'user', class: Google::Apis::DriveV2::User, decorator: Google::Apis::DriveV2::User::Representation property :user, as: 'user', class: Google::Apis::DriveV2::User, decorator: Google::Apis::DriveV2::User::Representation
end end
@ -396,6 +410,15 @@ module Google
property :service_name, as: 'serviceName' property :service_name, as: 'serviceName'
end end
end end
class TeamDriveTheme
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :background_image_link, as: 'backgroundImageLink'
property :color_rgb, as: 'colorRgb'
property :id, as: 'id'
end
end
end end
class App class App
@ -958,17 +981,33 @@ module Google
class TeamDrive class TeamDrive
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :background_image_file, as: 'backgroundImageFile', class: Google::Apis::DriveV2::TeamDrive::BackgroundImageFile, decorator: Google::Apis::DriveV2::TeamDrive::BackgroundImageFile::Representation
property :background_image_link, as: 'backgroundImageLink'
property :capabilities, as: 'capabilities', class: Google::Apis::DriveV2::TeamDrive::Capabilities, decorator: Google::Apis::DriveV2::TeamDrive::Capabilities::Representation property :capabilities, as: 'capabilities', class: Google::Apis::DriveV2::TeamDrive::Capabilities, decorator: Google::Apis::DriveV2::TeamDrive::Capabilities::Representation
property :color_rgb, as: 'colorRgb'
property :id, as: 'id' property :id, as: 'id'
property :kind, as: 'kind' property :kind, as: 'kind'
property :name, as: 'name' property :name, as: 'name'
property :theme_id, as: 'themeId'
end
class BackgroundImageFile
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
property :width, as: 'width'
property :x_coordinate, as: 'xCoordinate'
property :y_coordinate, as: 'yCoordinate'
end
end end
class Capabilities class Capabilities
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :can_add_children, as: 'canAddChildren' property :can_add_children, as: 'canAddChildren'
property :can_change_team_drive_background, as: 'canChangeTeamDriveBackground'
property :can_comment, as: 'canComment' property :can_comment, as: 'canComment'
property :can_copy, as: 'canCopy' property :can_copy, as: 'canCopy'
property :can_delete_team_drive, as: 'canDeleteTeamDrive' property :can_delete_team_drive, as: 'canDeleteTeamDrive'

View File

@ -2932,7 +2932,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_teamdrife(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def delete_teamdrive(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:delete, 'teamdrives/{teamDriveId}', options) command = make_simple_command(:delete, 'teamdrives/{teamDriveId}', options)
command.params['teamDriveId'] = team_drive_id unless team_drive_id.nil? command.params['teamDriveId'] = team_drive_id unless team_drive_id.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
@ -2965,7 +2965,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_teamdrife(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def get_teamdrive(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:get, 'teamdrives/{teamDriveId}', options) command = make_simple_command(:get, 'teamdrives/{teamDriveId}', options)
command.response_representation = Google::Apis::DriveV2::TeamDrive::Representation command.response_representation = Google::Apis::DriveV2::TeamDrive::Representation
command.response_class = Google::Apis::DriveV2::TeamDrive command.response_class = Google::Apis::DriveV2::TeamDrive
@ -3005,7 +3005,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def insert_teamdrife(request_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def insert_teamdrive(request_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:post, 'teamdrives', options) command = make_simple_command(:post, 'teamdrives', options)
command.request_representation = Google::Apis::DriveV2::TeamDrive::Representation command.request_representation = Google::Apis::DriveV2::TeamDrive::Representation
command.request_object = team_drive_object command.request_object = team_drive_object
@ -3081,7 +3081,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def update_teamdrife(team_drive_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def update_teamdrive(team_drive_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:put, 'teamdrives/{teamDriveId}', options) command = make_simple_command(:put, 'teamdrives/{teamDriveId}', options)
command.request_representation = Google::Apis::DriveV2::TeamDrive::Representation command.request_representation = Google::Apis::DriveV2::TeamDrive::Representation
command.request_object = team_drive_object command.request_object = team_drive_object

View File

@ -26,7 +26,7 @@ module Google
# @see https://developers.google.com/drive/ # @see https://developers.google.com/drive/
module DriveV3 module DriveV3
VERSION = 'V3' VERSION = 'V3'
REVISION = '20170320' REVISION = '20170323'
# View and manage the files in your Google Drive # View and manage the files in your Google Drive
AUTH_DRIVE = 'https://www.googleapis.com/auth/drive' AUTH_DRIVE = 'https://www.googleapis.com/auth/drive'

View File

@ -68,6 +68,11 @@ module Google
# @return [Google::Apis::DriveV3::About::StorageQuota] # @return [Google::Apis::DriveV3::About::StorageQuota]
attr_accessor :storage_quota attr_accessor :storage_quota
# A list of themes that are supported for Team Drives.
# Corresponds to the JSON property `teamDriveThemes`
# @return [Array<Google::Apis::DriveV3::About::TeamDriveTheme>]
attr_accessor :team_drive_themes
# Information about a Drive user. # Information about a Drive user.
# Corresponds to the JSON property `user` # Corresponds to the JSON property `user`
# @return [Google::Apis::DriveV3::User] # @return [Google::Apis::DriveV3::User]
@ -87,6 +92,7 @@ module Google
@max_import_sizes = args[:max_import_sizes] if args.key?(:max_import_sizes) @max_import_sizes = args[:max_import_sizes] if args.key?(:max_import_sizes)
@max_upload_size = args[:max_upload_size] if args.key?(:max_upload_size) @max_upload_size = args[:max_upload_size] if args.key?(:max_upload_size)
@storage_quota = args[:storage_quota] if args.key?(:storage_quota) @storage_quota = args[:storage_quota] if args.key?(:storage_quota)
@team_drive_themes = args[:team_drive_themes] if args.key?(:team_drive_themes)
@user = args[:user] if args.key?(:user) @user = args[:user] if args.key?(:user)
end end
@ -127,6 +133,37 @@ module Google
@usage_in_drive_trash = args[:usage_in_drive_trash] if args.key?(:usage_in_drive_trash) @usage_in_drive_trash = args[:usage_in_drive_trash] if args.key?(:usage_in_drive_trash)
end end
end end
#
class TeamDriveTheme
include Google::Apis::Core::Hashable
# A link to this Team Drive theme's background image.
# Corresponds to the JSON property `backgroundImageLink`
# @return [String]
attr_accessor :background_image_link
# The color of this Team Drive theme as an RGB hex string.
# Corresponds to the JSON property `colorRgb`
# @return [String]
attr_accessor :color_rgb
# The ID of the theme.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@background_image_link = args[:background_image_link] if args.key?(:background_image_link)
@color_rgb = args[:color_rgb] if args.key?(:color_rgb)
@id = args[:id] if args.key?(:id)
end
end
end end
# A change to a file or Team Drive. # A change to a file or Team Drive.
@ -482,7 +519,7 @@ module Google
# @return [Hash<String,String>] # @return [Hash<String,String>]
attr_accessor :app_properties attr_accessor :app_properties
# Capabilities the current user has on the file. Each capability corresponds to # Capabilities the current user has on this file. Each capability corresponds to
# a fine-grained action that a user may take. # a fine-grained action that a user may take.
# Corresponds to the JSON property `capabilities` # Corresponds to the JSON property `capabilities`
# @return [Google::Apis::DriveV3::File::Capabilities] # @return [Google::Apis::DriveV3::File::Capabilities]
@ -848,52 +885,52 @@ module Google
@writers_can_share = args[:writers_can_share] if args.key?(:writers_can_share) @writers_can_share = args[:writers_can_share] if args.key?(:writers_can_share)
end end
# Capabilities the current user has on the file. Each capability corresponds to # Capabilities the current user has on this file. Each capability corresponds to
# a fine-grained action that a user may take. # a fine-grained action that a user may take.
class Capabilities class Capabilities
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Whether the user can add children to this folder. This is always false when # Whether the current user can add children to this folder. This is always false
# the item is not a folder. # when the item is not a folder.
# Corresponds to the JSON property `canAddChildren` # Corresponds to the JSON property `canAddChildren`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_add_children attr_accessor :can_add_children
alias_method :can_add_children?, :can_add_children alias_method :can_add_children?, :can_add_children
# Whether the user can comment on the file. # Whether the current user can comment on this file.
# Corresponds to the JSON property `canComment` # Corresponds to the JSON property `canComment`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_comment attr_accessor :can_comment
alias_method :can_comment?, :can_comment alias_method :can_comment?, :can_comment
# Whether the user can copy the file. For a Team Drive item, whether non-folder # Whether the current user can copy this file. For a Team Drive item, whether
# descendants of this item, or this item itself if it is not a folder, can be # the current user can copy non-folder descendants of this item, or this item
# copied. # itself if it is not a folder.
# Corresponds to the JSON property `canCopy` # Corresponds to the JSON property `canCopy`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_copy attr_accessor :can_copy
alias_method :can_copy?, :can_copy alias_method :can_copy?, :can_copy
# Whether the file can be deleted by the user. # Whether the current user can delete this file.
# Corresponds to the JSON property `canDelete` # Corresponds to the JSON property `canDelete`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_delete attr_accessor :can_delete
alias_method :can_delete?, :can_delete alias_method :can_delete?, :can_delete
# Whether the file can be downloaded by the user. # Whether the current user can download this file.
# Corresponds to the JSON property `canDownload` # Corresponds to the JSON property `canDownload`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_download attr_accessor :can_download
alias_method :can_download?, :can_download alias_method :can_download?, :can_download
# Whether the user can edit the file's content. # Whether the current user can edit this file.
# Corresponds to the JSON property `canEdit` # Corresponds to the JSON property `canEdit`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_edit attr_accessor :can_edit
alias_method :can_edit?, :can_edit alias_method :can_edit?, :can_edit
# Whether the user can list the children of this folder. This is always false # Whether the current user can list the children of this folder. This is always
# when the item is not a folder. # false when the item is not a folder.
# Corresponds to the JSON property `canListChildren` # Corresponds to the JSON property `canListChildren`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_list_children attr_accessor :can_list_children
@ -906,15 +943,16 @@ module Google
attr_accessor :can_move_item_into_team_drive attr_accessor :can_move_item_into_team_drive
alias_method :can_move_item_into_team_drive?, :can_move_item_into_team_drive alias_method :can_move_item_into_team_drive?, :can_move_item_into_team_drive
# Whether the user can move this Team Drive item by changing its parent. Note # Whether the current user can move this Team Drive item by changing its parent.
# that a request to change the parent for this item may still fail depending on # Note that a request to change the parent for this item may still fail
# the new parent that is being added. Only populated for Team Drive files. # depending on the new parent that is being added. Only populated for Team Drive
# files.
# Corresponds to the JSON property `canMoveTeamDriveItem` # Corresponds to the JSON property `canMoveTeamDriveItem`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_move_team_drive_item attr_accessor :can_move_team_drive_item
alias_method :can_move_team_drive_item?, :can_move_team_drive_item alias_method :can_move_team_drive_item?, :can_move_team_drive_item
# Whether the user has read access to the Revisions resource of the file. For a # Whether the current user can read the revisions resource of this file. For a
# Team Drive item, whether revisions of non-folder descendants of this item, or # Team Drive item, whether revisions of non-folder descendants of this item, or
# this item itself if it is not a folder, can be read. # this item itself if it is not a folder, can be read.
# Corresponds to the JSON property `canReadRevisions` # Corresponds to the JSON property `canReadRevisions`
@ -922,39 +960,39 @@ module Google
attr_accessor :can_read_revisions attr_accessor :can_read_revisions
alias_method :can_read_revisions?, :can_read_revisions alias_method :can_read_revisions?, :can_read_revisions
# Whether the user has read access to the Team Drive to which this file belongs. # Whether the current user can read the Team Drive to which this file belongs.
# Only populated for Team Drive files. # Only populated for Team Drive files.
# Corresponds to the JSON property `canReadTeamDrive` # Corresponds to the JSON property `canReadTeamDrive`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_read_team_drive attr_accessor :can_read_team_drive
alias_method :can_read_team_drive?, :can_read_team_drive alias_method :can_read_team_drive?, :can_read_team_drive
# Whether the user can remove children from this folder. This is always false # Whether the current user can remove children from this folder. This is always
# when the item is not a folder. # false when the item is not a folder.
# Corresponds to the JSON property `canRemoveChildren` # Corresponds to the JSON property `canRemoveChildren`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_remove_children attr_accessor :can_remove_children
alias_method :can_remove_children?, :can_remove_children alias_method :can_remove_children?, :can_remove_children
# Whether the file can be renamed by the user. # Whether the current user can rename this file.
# Corresponds to the JSON property `canRename` # Corresponds to the JSON property `canRename`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_rename attr_accessor :can_rename
alias_method :can_rename?, :can_rename alias_method :can_rename?, :can_rename
# Whether the user can modify the file's permissions and sharing settings. # Whether the current user can modify the sharing settings for this file.
# Corresponds to the JSON property `canShare` # Corresponds to the JSON property `canShare`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_share attr_accessor :can_share
alias_method :can_share?, :can_share alias_method :can_share?, :can_share
# Whether the file can be trashed by the user. # Whether the current user can move this file to trash.
# Corresponds to the JSON property `canTrash` # Corresponds to the JSON property `canTrash`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_trash attr_accessor :can_trash
alias_method :can_trash?, :can_trash alias_method :can_trash?, :can_trash
# Whether the file can be restored from the trash by the current user. # Whether the current user can restore this file from trash.
# Corresponds to the JSON property `canUntrash` # Corresponds to the JSON property `canUntrash`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_untrash attr_accessor :can_untrash
@ -1019,6 +1057,7 @@ module Google
# The thumbnail data encoded with URL-safe Base64 (RFC 4648 section 5). # The thumbnail data encoded with URL-safe Base64 (RFC 4648 section 5).
# Corresponds to the JSON property `image` # Corresponds to the JSON property `image`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :image attr_accessor :image
@ -1388,7 +1427,7 @@ module Google
# @return [String] # @return [String]
attr_accessor :role attr_accessor :role
# Details of whether the Permissions on this Team Drive item are inherited or # Details of whether the permissions on this Team Drive item are inherited or
# directly on this item. This is an output-only field which is present only for # directly on this item. This is an output-only field which is present only for
# Team Drive items. # Team Drive items.
# Corresponds to the JSON property `teamDrivePermissionDetails` # Corresponds to the JSON property `teamDrivePermissionDetails`
@ -1783,11 +1822,30 @@ module Google
class TeamDrive class TeamDrive
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# An image file and cropping parameters from which a background image for this
# Team Drive is set. This is a write only field that can only be set on a drive.
# teamdrives.update request that does not set themeId. When specified, all
# fields of the backgroundImageFile must be set.
# Corresponds to the JSON property `backgroundImageFile`
# @return [Google::Apis::DriveV3::TeamDrive::BackgroundImageFile]
attr_accessor :background_image_file
# A short-lived link to this Team Drive's background image.
# Corresponds to the JSON property `backgroundImageLink`
# @return [String]
attr_accessor :background_image_link
# Capabilities the current user has on this Team Drive. # Capabilities the current user has on this Team Drive.
# Corresponds to the JSON property `capabilities` # Corresponds to the JSON property `capabilities`
# @return [Google::Apis::DriveV3::TeamDrive::Capabilities] # @return [Google::Apis::DriveV3::TeamDrive::Capabilities]
attr_accessor :capabilities attr_accessor :capabilities
# The color of this Team Drive as an RGB hex string. It can only be set on a
# drive.teamdrives.update request that does not set themeId.
# Corresponds to the JSON property `colorRgb`
# @return [String]
attr_accessor :color_rgb
# The ID of this Team Drive which is also the ID of the top level folder for # The ID of this Team Drive which is also the ID of the top level folder for
# this Team Drive. # this Team Drive.
# Corresponds to the JSON property `id` # Corresponds to the JSON property `id`
@ -1805,16 +1863,79 @@ module Google
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# The ID of the theme from which the background image and color will be set. The
# set of possible teamDriveThemes can be retrieved from a drive.about.get
# response. When not specified on a drive.teamdrives.create request, a random
# theme is chosen from which the background image and color are set. This is a
# write only field that can only be set on a request that does not set colorRgb
# or backgroundImageFile.
# Corresponds to the JSON property `themeId`
# @return [String]
attr_accessor :theme_id
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@background_image_file = args[:background_image_file] if args.key?(:background_image_file)
@background_image_link = args[:background_image_link] if args.key?(:background_image_link)
@capabilities = args[:capabilities] if args.key?(:capabilities) @capabilities = args[:capabilities] if args.key?(:capabilities)
@color_rgb = args[:color_rgb] if args.key?(:color_rgb)
@id = args[:id] if args.key?(:id) @id = args[:id] if args.key?(:id)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@theme_id = args[:theme_id] if args.key?(:theme_id)
end
# An image file and cropping parameters from which a background image for this
# Team Drive is set. This is a write only field that can only be set on a drive.
# teamdrives.update request that does not set themeId. When specified, all
# fields of the backgroundImageFile must be set.
class BackgroundImageFile
include Google::Apis::Core::Hashable
# The ID of an image file in Drive to use for the background image.
# Corresponds to the JSON property `id`
# @return [String]
attr_accessor :id
# The width of the cropped image in the closed range of 0 to 1, which is the
# width of the cropped image divided by the width of the entire image. The
# height is computed by applying a width to height aspect ratio of 80 to 9. The
# resulting image must be at least 1280 pixels wide and 144 pixels high.
# Corresponds to the JSON property `width`
# @return [Float]
attr_accessor :width
# The X coordinate of the upper left corner of the cropping area in the
# background image. This is a value in the closed range of 0 to 1 which is the
# horizontal distance from the left side of the entire image to the left side of
# the cropping area divided by the width of the entire image.
# Corresponds to the JSON property `xCoordinate`
# @return [Float]
attr_accessor :x_coordinate
# The Y coordinate of the upper left corner of the cropping area in the
# background image. This is a value in the closed range of 0 to 1 which is the
# vertical distance from the top side of the entire image to the top side of the
# cropping area divided by the height of the entire image.
# Corresponds to the JSON property `yCoordinate`
# @return [Float]
attr_accessor :y_coordinate
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@id = args[:id] if args.key?(:id)
@width = args[:width] if args.key?(:width)
@x_coordinate = args[:x_coordinate] if args.key?(:x_coordinate)
@y_coordinate = args[:y_coordinate] if args.key?(:y_coordinate)
end
end end
# Capabilities the current user has on this Team Drive. # Capabilities the current user has on this Team Drive.
@ -1827,31 +1948,38 @@ module Google
attr_accessor :can_add_children attr_accessor :can_add_children
alias_method :can_add_children?, :can_add_children alias_method :can_add_children?, :can_add_children
# Whether the current user can change the background of this Team Drive.
# Corresponds to the JSON property `canChangeTeamDriveBackground`
# @return [Boolean]
attr_accessor :can_change_team_drive_background
alias_method :can_change_team_drive_background?, :can_change_team_drive_background
# Whether the current user can comment on files in this Team Drive. # Whether the current user can comment on files in this Team Drive.
# Corresponds to the JSON property `canComment` # Corresponds to the JSON property `canComment`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_comment attr_accessor :can_comment
alias_method :can_comment?, :can_comment alias_method :can_comment?, :can_comment
# Whether files in this Team Drive can be copied by the current user. # Whether the current user can copy files in this Team Drive.
# Corresponds to the JSON property `canCopy` # Corresponds to the JSON property `canCopy`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_copy attr_accessor :can_copy
alias_method :can_copy?, :can_copy alias_method :can_copy?, :can_copy
# Whether this Team Drive can be deleted by the current user. # Whether the current user can delete this Team Drive. Attempting to delete the
# Team Drive may still fail if there are untrashed items inside the Team Drive.
# Corresponds to the JSON property `canDeleteTeamDrive` # Corresponds to the JSON property `canDeleteTeamDrive`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_delete_team_drive attr_accessor :can_delete_team_drive
alias_method :can_delete_team_drive?, :can_delete_team_drive alias_method :can_delete_team_drive?, :can_delete_team_drive
# Whether files in this Team Drive can be downloaded by the current user. # Whether the current user can download files in this Team Drive.
# Corresponds to the JSON property `canDownload` # Corresponds to the JSON property `canDownload`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_download attr_accessor :can_download
alias_method :can_download?, :can_download alias_method :can_download?, :can_download
# Whether files in this Team Drive can be edited by the current user. # Whether the current user can edit files in this Team Drive
# Corresponds to the JSON property `canEdit` # Corresponds to the JSON property `canEdit`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_edit attr_accessor :can_edit
@ -1870,8 +1998,8 @@ module Google
attr_accessor :can_manage_members attr_accessor :can_manage_members
alias_method :can_manage_members?, :can_manage_members alias_method :can_manage_members?, :can_manage_members
# Whether the current user has read access to the Revisions resource of files in # Whether the current user can read the revisions resource of files in this Team
# this Team Drive. # Drive.
# Corresponds to the JSON property `canReadRevisions` # Corresponds to the JSON property `canReadRevisions`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_read_revisions attr_accessor :can_read_revisions
@ -1883,13 +2011,13 @@ module Google
attr_accessor :can_remove_children attr_accessor :can_remove_children
alias_method :can_remove_children?, :can_remove_children alias_method :can_remove_children?, :can_remove_children
# Whether files or folders in this Team Drive can be renamed by the current user. # Whether the current user can rename files or folders in this Team Drive.
# Corresponds to the JSON property `canRename` # Corresponds to the JSON property `canRename`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_rename attr_accessor :can_rename
alias_method :can_rename?, :can_rename alias_method :can_rename?, :can_rename
# Whether this Team Drive can be renamed by the current user. # Whether the current user can rename this Team Drive.
# Corresponds to the JSON property `canRenameTeamDrive` # Corresponds to the JSON property `canRenameTeamDrive`
# @return [Boolean] # @return [Boolean]
attr_accessor :can_rename_team_drive attr_accessor :can_rename_team_drive
@ -1908,6 +2036,7 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@can_add_children = args[:can_add_children] if args.key?(:can_add_children) @can_add_children = args[:can_add_children] if args.key?(:can_add_children)
@can_change_team_drive_background = args[:can_change_team_drive_background] if args.key?(:can_change_team_drive_background)
@can_comment = args[:can_comment] if args.key?(:can_comment) @can_comment = args[:can_comment] if args.key?(:can_comment)
@can_copy = args[:can_copy] if args.key?(:can_copy) @can_copy = args[:can_copy] if args.key?(:can_copy)
@can_delete_team_drive = args[:can_delete_team_drive] if args.key?(:can_delete_team_drive) @can_delete_team_drive = args[:can_delete_team_drive] if args.key?(:can_delete_team_drive)

View File

@ -30,6 +30,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class TeamDriveTheme
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
@ -175,6 +181,12 @@ module Google
class TeamDrive class TeamDrive
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
class BackgroundImageFile
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Capabilities class Capabilities
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -216,6 +228,8 @@ module Google
property :max_upload_size, as: 'maxUploadSize' property :max_upload_size, as: 'maxUploadSize'
property :storage_quota, as: 'storageQuota', class: Google::Apis::DriveV3::About::StorageQuota, decorator: Google::Apis::DriveV3::About::StorageQuota::Representation property :storage_quota, as: 'storageQuota', class: Google::Apis::DriveV3::About::StorageQuota, decorator: Google::Apis::DriveV3::About::StorageQuota::Representation
collection :team_drive_themes, as: 'teamDriveThemes', class: Google::Apis::DriveV3::About::TeamDriveTheme, decorator: Google::Apis::DriveV3::About::TeamDriveTheme::Representation
property :user, as: 'user', class: Google::Apis::DriveV3::User, decorator: Google::Apis::DriveV3::User::Representation property :user, as: 'user', class: Google::Apis::DriveV3::User, decorator: Google::Apis::DriveV3::User::Representation
end end
@ -229,6 +243,15 @@ module Google
property :usage_in_drive_trash, as: 'usageInDriveTrash' property :usage_in_drive_trash, as: 'usageInDriveTrash'
end end
end end
class TeamDriveTheme
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :background_image_link, as: 'backgroundImageLink'
property :color_rgb, as: 'colorRgb'
property :id, as: 'id'
end
end
end end
class Change class Change
@ -601,17 +624,33 @@ module Google
class TeamDrive class TeamDrive
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :background_image_file, as: 'backgroundImageFile', class: Google::Apis::DriveV3::TeamDrive::BackgroundImageFile, decorator: Google::Apis::DriveV3::TeamDrive::BackgroundImageFile::Representation
property :background_image_link, as: 'backgroundImageLink'
property :capabilities, as: 'capabilities', class: Google::Apis::DriveV3::TeamDrive::Capabilities, decorator: Google::Apis::DriveV3::TeamDrive::Capabilities::Representation property :capabilities, as: 'capabilities', class: Google::Apis::DriveV3::TeamDrive::Capabilities, decorator: Google::Apis::DriveV3::TeamDrive::Capabilities::Representation
property :color_rgb, as: 'colorRgb'
property :id, as: 'id' property :id, as: 'id'
property :kind, as: 'kind' property :kind, as: 'kind'
property :name, as: 'name' property :name, as: 'name'
property :theme_id, as: 'themeId'
end
class BackgroundImageFile
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
property :width, as: 'width'
property :x_coordinate, as: 'xCoordinate'
property :y_coordinate, as: 'yCoordinate'
end
end end
class Capabilities class Capabilities
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :can_add_children, as: 'canAddChildren' property :can_add_children, as: 'canAddChildren'
property :can_change_team_drive_background, as: 'canChangeTeamDriveBackground'
property :can_comment, as: 'canComment' property :can_comment, as: 'canComment'
property :can_copy, as: 'canCopy' property :can_copy, as: 'canCopy'
property :can_delete_team_drive, as: 'canDeleteTeamDrive' property :can_delete_team_drive, as: 'canDeleteTeamDrive'

View File

@ -1669,7 +1669,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def create_teamdrife(request_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def create_teamdrive(request_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:post, 'teamdrives', options) command = make_simple_command(:post, 'teamdrives', options)
command.request_representation = Google::Apis::DriveV3::TeamDrive::Representation command.request_representation = Google::Apis::DriveV3::TeamDrive::Representation
command.request_object = team_drive_object command.request_object = team_drive_object
@ -1707,7 +1707,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_teamdrife(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def delete_teamdrive(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:delete, 'teamdrives/{teamDriveId}', options) command = make_simple_command(:delete, 'teamdrives/{teamDriveId}', options)
command.params['teamDriveId'] = team_drive_id unless team_drive_id.nil? command.params['teamDriveId'] = team_drive_id unless team_drive_id.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
@ -1740,7 +1740,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_teamdrife(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def get_teamdrive(team_drive_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:get, 'teamdrives/{teamDriveId}', options) command = make_simple_command(:get, 'teamdrives/{teamDriveId}', options)
command.response_representation = Google::Apis::DriveV3::TeamDrive::Representation command.response_representation = Google::Apis::DriveV3::TeamDrive::Representation
command.response_class = Google::Apis::DriveV3::TeamDrive command.response_class = Google::Apis::DriveV3::TeamDrive
@ -1814,7 +1814,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def update_teamdrife(team_drive_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) def update_teamdrive(team_drive_id, team_drive_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
command = make_simple_command(:patch, 'teamdrives/{teamDriveId}', options) command = make_simple_command(:patch, 'teamdrives/{teamDriveId}', options)
command.request_representation = Google::Apis::DriveV3::TeamDrive::Representation command.request_representation = Google::Apis::DriveV3::TeamDrive::Representation
command.request_object = team_drive_object command.request_object = team_drive_object

View File

@ -26,7 +26,7 @@ module Google
# @see https://firebase.google.com/docs/dynamic-links/ # @see https://firebase.google.com/docs/dynamic-links/
module FirebasedynamiclinksV1 module FirebasedynamiclinksV1
VERSION = 'V1' VERSION = 'V1'
REVISION = '20170323' REVISION = '20170330'
# View and administer all your Firebase data and settings # View and administer all your Firebase data and settings
AUTH_FIREBASE = 'https://www.googleapis.com/auth/firebase' AUTH_FIREBASE = 'https://www.googleapis.com/auth/firebase'

View File

@ -22,50 +22,16 @@ module Google
module Apis module Apis
module FirebasedynamiclinksV1 module FirebasedynamiclinksV1
# Parameters for iTunes Connect App Analytics.
class ITunesConnectAnalytics
include Google::Apis::Core::Hashable
# Affiliate token used to create affiliate-coded links.
# Corresponds to the JSON property `at`
# @return [String]
attr_accessor :at
# Campaign text that developers can optionally add to any link in order to
# track sales from a specific marketing campaign.
# Corresponds to the JSON property `ct`
# @return [String]
attr_accessor :ct
# iTune media types, including music, podcasts, audiobooks and so on.
# Corresponds to the JSON property `mt`
# @return [String]
attr_accessor :mt
# Provider token that enables analytics for Dynamic Links from within iTunes
# Connect.
# Corresponds to the JSON property `pt`
# @return [String]
attr_accessor :pt
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@at = args[:at] if args.key?(:at)
@ct = args[:ct] if args.key?(:ct)
@mt = args[:mt] if args.key?(:mt)
@pt = args[:pt] if args.key?(:pt)
end
end
# Parameters for social meta tag params. # Parameters for social meta tag params.
# Used to set meta tag data for link previews on social sites. # Used to set meta tag data for link previews on social sites.
class SocialMetaTagInfo class SocialMetaTagInfo
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A short description of the link. Optional.
# Corresponds to the JSON property `socialDescription`
# @return [String]
attr_accessor :social_description
# Title to be displayed. Optional. # Title to be displayed. Optional.
# Corresponds to the JSON property `socialTitle` # Corresponds to the JSON property `socialTitle`
# @return [String] # @return [String]
@ -76,10 +42,31 @@ module Google
# @return [String] # @return [String]
attr_accessor :social_image_link attr_accessor :social_image_link
# A short description of the link. Optional. def initialize(**args)
# Corresponds to the JSON property `socialDescription` update!(**args)
end
# Update properties of this object
def update!(**args)
@social_description = args[:social_description] if args.key?(:social_description)
@social_title = args[:social_title] if args.key?(:social_title)
@social_image_link = args[:social_image_link] if args.key?(:social_image_link)
end
end
# Dynamic Links warning messages.
class DynamicLinkWarning
include Google::Apis::Core::Hashable
# The warning code.
# Corresponds to the JSON property `warningCode`
# @return [String] # @return [String]
attr_accessor :social_description attr_accessor :warning_code
# The warning message to help developers improve their requests.
# Corresponds to the JSON property `warningMessage`
# @return [String]
attr_accessor :warning_message
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -87,9 +74,8 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@social_title = args[:social_title] if args.key?(:social_title) @warning_code = args[:warning_code] if args.key?(:warning_code)
@social_image_link = args[:social_image_link] if args.key?(:social_image_link) @warning_message = args[:warning_message] if args.key?(:warning_message)
@social_description = args[:social_description] if args.key?(:social_description)
end end
end end
@ -97,16 +83,6 @@ module Google
class AndroidInfo class AndroidInfo
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# If specified, this overrides the link parameter on Android.
# Corresponds to the JSON property `androidLink`
# @return [String]
attr_accessor :android_link
# Link to open on Android if the app is not installed.
# Corresponds to the JSON property `androidFallbackLink`
# @return [String]
attr_accessor :android_fallback_link
# Android package name of the app. # Android package name of the app.
# Corresponds to the JSON property `androidPackageName` # Corresponds to the JSON property `androidPackageName`
# @return [String] # @return [String]
@ -118,41 +94,26 @@ module Google
# @return [String] # @return [String]
attr_accessor :android_min_package_version_code attr_accessor :android_min_package_version_code
# If specified, this overrides the link parameter on Android.
# Corresponds to the JSON property `androidLink`
# @return [String]
attr_accessor :android_link
# Link to open on Android if the app is not installed.
# Corresponds to the JSON property `androidFallbackLink`
# @return [String]
attr_accessor :android_fallback_link
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@android_link = args[:android_link] if args.key?(:android_link)
@android_fallback_link = args[:android_fallback_link] if args.key?(:android_fallback_link)
@android_package_name = args[:android_package_name] if args.key?(:android_package_name) @android_package_name = args[:android_package_name] if args.key?(:android_package_name)
@android_min_package_version_code = args[:android_min_package_version_code] if args.key?(:android_min_package_version_code) @android_min_package_version_code = args[:android_min_package_version_code] if args.key?(:android_min_package_version_code)
end @android_link = args[:android_link] if args.key?(:android_link)
end @android_fallback_link = args[:android_fallback_link] if args.key?(:android_fallback_link)
# Dynamic Links warning messages.
class DynamicLinkWarning
include Google::Apis::Core::Hashable
# The warning message to help developers improve their requests.
# Corresponds to the JSON property `warningMessage`
# @return [String]
attr_accessor :warning_message
# The warning code.
# Corresponds to the JSON property `warningCode`
# @return [String]
attr_accessor :warning_code
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@warning_message = args[:warning_message] if args.key?(:warning_message)
@warning_code = args[:warning_code] if args.key?(:warning_code)
end end
end end
@ -181,16 +142,6 @@ module Google
class IosInfo class IosInfo
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Link to open on iOS if the app is not installed.
# Corresponds to the JSON property `iosFallbackLink`
# @return [String]
attr_accessor :ios_fallback_link
# iOS App Store ID.
# Corresponds to the JSON property `iosAppStoreId`
# @return [String]
attr_accessor :ios_app_store_id
# If specified, this overrides the ios_fallback_link value on iPads. # If specified, this overrides the ios_fallback_link value on iPads.
# Corresponds to the JSON property `iosIpadFallbackLink` # Corresponds to the JSON property `iosIpadFallbackLink`
# @return [String] # @return [String]
@ -213,18 +164,28 @@ module Google
# @return [String] # @return [String]
attr_accessor :ios_bundle_id attr_accessor :ios_bundle_id
# Link to open on iOS if the app is not installed.
# Corresponds to the JSON property `iosFallbackLink`
# @return [String]
attr_accessor :ios_fallback_link
# iOS App Store ID.
# Corresponds to the JSON property `iosAppStoreId`
# @return [String]
attr_accessor :ios_app_store_id
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@ios_fallback_link = args[:ios_fallback_link] if args.key?(:ios_fallback_link)
@ios_app_store_id = args[:ios_app_store_id] if args.key?(:ios_app_store_id)
@ios_ipad_fallback_link = args[:ios_ipad_fallback_link] if args.key?(:ios_ipad_fallback_link) @ios_ipad_fallback_link = args[:ios_ipad_fallback_link] if args.key?(:ios_ipad_fallback_link)
@ios_ipad_bundle_id = args[:ios_ipad_bundle_id] if args.key?(:ios_ipad_bundle_id) @ios_ipad_bundle_id = args[:ios_ipad_bundle_id] if args.key?(:ios_ipad_bundle_id)
@ios_custom_scheme = args[:ios_custom_scheme] if args.key?(:ios_custom_scheme) @ios_custom_scheme = args[:ios_custom_scheme] if args.key?(:ios_custom_scheme)
@ios_bundle_id = args[:ios_bundle_id] if args.key?(:ios_bundle_id) @ios_bundle_id = args[:ios_bundle_id] if args.key?(:ios_bundle_id)
@ios_fallback_link = args[:ios_fallback_link] if args.key?(:ios_fallback_link)
@ios_app_store_id = args[:ios_app_store_id] if args.key?(:ios_app_store_id)
end end
end end
@ -232,11 +193,6 @@ module Google
class AnalyticsInfo class AnalyticsInfo
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Parameters for iTunes Connect App Analytics.
# Corresponds to the JSON property `itunesConnectAnalytics`
# @return [Google::Apis::FirebasedynamiclinksV1::ITunesConnectAnalytics]
attr_accessor :itunes_connect_analytics
# Parameters for Google Play Campaign Measurements. # Parameters for Google Play Campaign Measurements.
# [Learn more](https://developers.google.com/analytics/devguides/collection/ # [Learn more](https://developers.google.com/analytics/devguides/collection/
# android/v4/campaigns#campaign-params) # android/v4/campaigns#campaign-params)
@ -244,14 +200,19 @@ module Google
# @return [Google::Apis::FirebasedynamiclinksV1::GooglePlayAnalytics] # @return [Google::Apis::FirebasedynamiclinksV1::GooglePlayAnalytics]
attr_accessor :google_play_analytics attr_accessor :google_play_analytics
# Parameters for iTunes Connect App Analytics.
# Corresponds to the JSON property `itunesConnectAnalytics`
# @return [Google::Apis::FirebasedynamiclinksV1::ITunesConnectAnalytics]
attr_accessor :itunes_connect_analytics
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@itunes_connect_analytics = args[:itunes_connect_analytics] if args.key?(:itunes_connect_analytics)
@google_play_analytics = args[:google_play_analytics] if args.key?(:google_play_analytics) @google_play_analytics = args[:google_play_analytics] if args.key?(:google_play_analytics)
@itunes_connect_analytics = args[:itunes_connect_analytics] if args.key?(:itunes_connect_analytics)
end end
end end
@ -346,6 +307,12 @@ module Google
class GooglePlayAnalytics class GooglePlayAnalytics
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Campaign content; used for A/B testing and content-targeted ads to
# differentiate ads or links that point to the same URL.
# Corresponds to the JSON property `utmContent`
# @return [String]
attr_accessor :utm_content
# Campaign medium; used to identify a medium such as email or cost-per-click. # Campaign medium; used to identify a medium such as email or cost-per-click.
# Corresponds to the JSON property `utmMedium` # Corresponds to the JSON property `utmMedium`
# @return [String] # @return [String]
@ -376,24 +343,18 @@ module Google
# @return [String] # @return [String]
attr_accessor :gclid attr_accessor :gclid
# Campaign content; used for A/B testing and content-targeted ads to
# differentiate ads or links that point to the same URL.
# Corresponds to the JSON property `utmContent`
# @return [String]
attr_accessor :utm_content
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@utm_content = args[:utm_content] if args.key?(:utm_content)
@utm_medium = args[:utm_medium] if args.key?(:utm_medium) @utm_medium = args[:utm_medium] if args.key?(:utm_medium)
@utm_term = args[:utm_term] if args.key?(:utm_term) @utm_term = args[:utm_term] if args.key?(:utm_term)
@utm_source = args[:utm_source] if args.key?(:utm_source) @utm_source = args[:utm_source] if args.key?(:utm_source)
@utm_campaign = args[:utm_campaign] if args.key?(:utm_campaign) @utm_campaign = args[:utm_campaign] if args.key?(:utm_campaign)
@gclid = args[:gclid] if args.key?(:gclid) @gclid = args[:gclid] if args.key?(:gclid)
@utm_content = args[:utm_content] if args.key?(:utm_content)
end end
end end
@ -401,6 +362,21 @@ module Google
class DynamicLinkInfo class DynamicLinkInfo
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Android related attributes to the Dynamic Link.
# Corresponds to the JSON property `androidInfo`
# @return [Google::Apis::FirebasedynamiclinksV1::AndroidInfo]
attr_accessor :android_info
# Information of navigation behavior.
# Corresponds to the JSON property `navigationInfo`
# @return [Google::Apis::FirebasedynamiclinksV1::NavigationInfo]
attr_accessor :navigation_info
# Tracking parameters supported by Dynamic Link.
# Corresponds to the JSON property `analyticsInfo`
# @return [Google::Apis::FirebasedynamiclinksV1::AnalyticsInfo]
attr_accessor :analytics_info
# Dynamic Links domain that the project owns, e.g. abcd.app.goo.gl # Dynamic Links domain that the project owns, e.g. abcd.app.goo.gl
# [Learn more](https://firebase.google.com/docs/dynamic-links/android#set-up- # [Learn more](https://firebase.google.com/docs/dynamic-links/android#set-up-
# firebase-and-the-dynamic-links-sdk) # firebase-and-the-dynamic-links-sdk)
@ -431,20 +407,47 @@ module Google
# @return [Google::Apis::FirebasedynamiclinksV1::SocialMetaTagInfo] # @return [Google::Apis::FirebasedynamiclinksV1::SocialMetaTagInfo]
attr_accessor :social_meta_tag_info attr_accessor :social_meta_tag_info
# Android related attributes to the Dynamic Link. def initialize(**args)
# Corresponds to the JSON property `androidInfo` update!(**args)
# @return [Google::Apis::FirebasedynamiclinksV1::AndroidInfo] end
attr_accessor :android_info
# Information of navigation behavior. # Update properties of this object
# Corresponds to the JSON property `navigationInfo` def update!(**args)
# @return [Google::Apis::FirebasedynamiclinksV1::NavigationInfo] @android_info = args[:android_info] if args.key?(:android_info)
attr_accessor :navigation_info @navigation_info = args[:navigation_info] if args.key?(:navigation_info)
@analytics_info = args[:analytics_info] if args.key?(:analytics_info)
@dynamic_link_domain = args[:dynamic_link_domain] if args.key?(:dynamic_link_domain)
@link = args[:link] if args.key?(:link)
@ios_info = args[:ios_info] if args.key?(:ios_info)
@social_meta_tag_info = args[:social_meta_tag_info] if args.key?(:social_meta_tag_info)
end
end
# Tracking parameters supported by Dynamic Link. # Parameters for iTunes Connect App Analytics.
# Corresponds to the JSON property `analyticsInfo` class ITunesConnectAnalytics
# @return [Google::Apis::FirebasedynamiclinksV1::AnalyticsInfo] include Google::Apis::Core::Hashable
attr_accessor :analytics_info
# Affiliate token used to create affiliate-coded links.
# Corresponds to the JSON property `at`
# @return [String]
attr_accessor :at
# Campaign text that developers can optionally add to any link in order to
# track sales from a specific marketing campaign.
# Corresponds to the JSON property `ct`
# @return [String]
attr_accessor :ct
# iTune media types, including music, podcasts, audiobooks and so on.
# Corresponds to the JSON property `mt`
# @return [String]
attr_accessor :mt
# Provider token that enables analytics for Dynamic Links from within iTunes
# Connect.
# Corresponds to the JSON property `pt`
# @return [String]
attr_accessor :pt
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -452,13 +455,10 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@dynamic_link_domain = args[:dynamic_link_domain] if args.key?(:dynamic_link_domain) @at = args[:at] if args.key?(:at)
@link = args[:link] if args.key?(:link) @ct = args[:ct] if args.key?(:ct)
@ios_info = args[:ios_info] if args.key?(:ios_info) @mt = args[:mt] if args.key?(:mt)
@social_meta_tag_info = args[:social_meta_tag_info] if args.key?(:social_meta_tag_info) @pt = args[:pt] if args.key?(:pt)
@android_info = args[:android_info] if args.key?(:android_info)
@navigation_info = args[:navigation_info] if args.key?(:navigation_info)
@analytics_info = args[:analytics_info] if args.key?(:analytics_info)
end end
end end
end end

View File

@ -22,25 +22,19 @@ module Google
module Apis module Apis
module FirebasedynamiclinksV1 module FirebasedynamiclinksV1
class ITunesConnectAnalytics
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SocialMetaTagInfo class SocialMetaTagInfo
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class AndroidInfo class DynamicLinkWarning
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class DynamicLinkWarning class AndroidInfo
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -95,39 +89,35 @@ module Google
end end
class ITunesConnectAnalytics class ITunesConnectAnalytics
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :at, as: 'at' include Google::Apis::Core::JsonObjectSupport
property :ct, as: 'ct'
property :mt, as: 'mt'
property :pt, as: 'pt'
end
end end
class SocialMetaTagInfo class SocialMetaTagInfo
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :social_description, as: 'socialDescription'
property :social_title, as: 'socialTitle' property :social_title, as: 'socialTitle'
property :social_image_link, as: 'socialImageLink' property :social_image_link, as: 'socialImageLink'
property :social_description, as: 'socialDescription'
end
end
class AndroidInfo
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :android_link, as: 'androidLink'
property :android_fallback_link, as: 'androidFallbackLink'
property :android_package_name, as: 'androidPackageName'
property :android_min_package_version_code, as: 'androidMinPackageVersionCode'
end end
end end
class DynamicLinkWarning class DynamicLinkWarning
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :warning_message, as: 'warningMessage'
property :warning_code, as: 'warningCode' property :warning_code, as: 'warningCode'
property :warning_message, as: 'warningMessage'
end
end
class AndroidInfo
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :android_package_name, as: 'androidPackageName'
property :android_min_package_version_code, as: 'androidMinPackageVersionCode'
property :android_link, as: 'androidLink'
property :android_fallback_link, as: 'androidFallbackLink'
end end
end end
@ -141,22 +131,22 @@ module Google
class IosInfo class IosInfo
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :ios_fallback_link, as: 'iosFallbackLink'
property :ios_app_store_id, as: 'iosAppStoreId'
property :ios_ipad_fallback_link, as: 'iosIpadFallbackLink' property :ios_ipad_fallback_link, as: 'iosIpadFallbackLink'
property :ios_ipad_bundle_id, as: 'iosIpadBundleId' property :ios_ipad_bundle_id, as: 'iosIpadBundleId'
property :ios_custom_scheme, as: 'iosCustomScheme' property :ios_custom_scheme, as: 'iosCustomScheme'
property :ios_bundle_id, as: 'iosBundleId' property :ios_bundle_id, as: 'iosBundleId'
property :ios_fallback_link, as: 'iosFallbackLink'
property :ios_app_store_id, as: 'iosAppStoreId'
end end
end end
class AnalyticsInfo class AnalyticsInfo
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :itunes_connect_analytics, as: 'itunesConnectAnalytics', class: Google::Apis::FirebasedynamiclinksV1::ITunesConnectAnalytics, decorator: Google::Apis::FirebasedynamiclinksV1::ITunesConnectAnalytics::Representation
property :google_play_analytics, as: 'googlePlayAnalytics', class: Google::Apis::FirebasedynamiclinksV1::GooglePlayAnalytics, decorator: Google::Apis::FirebasedynamiclinksV1::GooglePlayAnalytics::Representation property :google_play_analytics, as: 'googlePlayAnalytics', class: Google::Apis::FirebasedynamiclinksV1::GooglePlayAnalytics, decorator: Google::Apis::FirebasedynamiclinksV1::GooglePlayAnalytics::Representation
property :itunes_connect_analytics, as: 'itunesConnectAnalytics', class: Google::Apis::FirebasedynamiclinksV1::ITunesConnectAnalytics, decorator: Google::Apis::FirebasedynamiclinksV1::ITunesConnectAnalytics::Representation
end end
end end
@ -191,30 +181,40 @@ module Google
class GooglePlayAnalytics class GooglePlayAnalytics
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :utm_content, as: 'utmContent'
property :utm_medium, as: 'utmMedium' property :utm_medium, as: 'utmMedium'
property :utm_term, as: 'utmTerm' property :utm_term, as: 'utmTerm'
property :utm_source, as: 'utmSource' property :utm_source, as: 'utmSource'
property :utm_campaign, as: 'utmCampaign' property :utm_campaign, as: 'utmCampaign'
property :gclid, as: 'gclid' property :gclid, as: 'gclid'
property :utm_content, as: 'utmContent'
end end
end end
class DynamicLinkInfo class DynamicLinkInfo
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :dynamic_link_domain, as: 'dynamicLinkDomain'
property :link, as: 'link'
property :ios_info, as: 'iosInfo', class: Google::Apis::FirebasedynamiclinksV1::IosInfo, decorator: Google::Apis::FirebasedynamiclinksV1::IosInfo::Representation
property :social_meta_tag_info, as: 'socialMetaTagInfo', class: Google::Apis::FirebasedynamiclinksV1::SocialMetaTagInfo, decorator: Google::Apis::FirebasedynamiclinksV1::SocialMetaTagInfo::Representation
property :android_info, as: 'androidInfo', class: Google::Apis::FirebasedynamiclinksV1::AndroidInfo, decorator: Google::Apis::FirebasedynamiclinksV1::AndroidInfo::Representation property :android_info, as: 'androidInfo', class: Google::Apis::FirebasedynamiclinksV1::AndroidInfo, decorator: Google::Apis::FirebasedynamiclinksV1::AndroidInfo::Representation
property :navigation_info, as: 'navigationInfo', class: Google::Apis::FirebasedynamiclinksV1::NavigationInfo, decorator: Google::Apis::FirebasedynamiclinksV1::NavigationInfo::Representation property :navigation_info, as: 'navigationInfo', class: Google::Apis::FirebasedynamiclinksV1::NavigationInfo, decorator: Google::Apis::FirebasedynamiclinksV1::NavigationInfo::Representation
property :analytics_info, as: 'analyticsInfo', class: Google::Apis::FirebasedynamiclinksV1::AnalyticsInfo, decorator: Google::Apis::FirebasedynamiclinksV1::AnalyticsInfo::Representation property :analytics_info, as: 'analyticsInfo', class: Google::Apis::FirebasedynamiclinksV1::AnalyticsInfo, decorator: Google::Apis::FirebasedynamiclinksV1::AnalyticsInfo::Representation
property :dynamic_link_domain, as: 'dynamicLinkDomain'
property :link, as: 'link'
property :ios_info, as: 'iosInfo', class: Google::Apis::FirebasedynamiclinksV1::IosInfo, decorator: Google::Apis::FirebasedynamiclinksV1::IosInfo::Representation
property :social_meta_tag_info, as: 'socialMetaTagInfo', class: Google::Apis::FirebasedynamiclinksV1::SocialMetaTagInfo, decorator: Google::Apis::FirebasedynamiclinksV1::SocialMetaTagInfo::Representation
end
end
class ITunesConnectAnalytics
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :at, as: 'at'
property :ct, as: 'ct'
property :mt, as: 'mt'
property :pt, as: 'pt'
end end
end end
end end

View File

@ -22,14 +22,20 @@ module Google
module Apis module Apis
module FirebaserulesV1 module FirebaserulesV1
# `Source` is one or more `File` messages comprising a logical set of rules. # Represents a service-defined function call that was invoked during test
class Source # execution.
class FunctionCall
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# `File` set constituting the `Source` bundle. # Name of the function invoked.
# Corresponds to the JSON property `files` # Corresponds to the JSON property `function`
# @return [Array<Google::Apis::FirebaserulesV1::File>] # @return [String]
attr_accessor :files attr_accessor :function
# The arguments that were provided to the function.
# Corresponds to the JSON property `args`
# @return [Array<Object>]
attr_accessor :args
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -37,125 +43,40 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@files = args[:files] if args.key?(:files) @function = args[:function] if args.key?(:function)
@args = args[:args] if args.key?(:args)
end end
end end
# Position in the `Source` content including its line, column number, and an # `File` containing source content.
# index of the `File` in the `Source` message. Used for debug purposes. class File
class SourcePosition
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Line number of the source fragment. 1-based. # Fingerprint (e.g. github sha) associated with the `File`.
# Corresponds to the JSON property `line` # Corresponds to the JSON property `fingerprint`
# @return [Fixnum] # NOTE: Values are automatically base64 encoded/decoded in the client library.
attr_accessor :line
# First column on the source line associated with the source fragment.
# Corresponds to the JSON property `column`
# @return [Fixnum]
attr_accessor :column
# Name of the `File`.
# Corresponds to the JSON property `fileName`
# @return [String] # @return [String]
attr_accessor :file_name attr_accessor :fingerprint
def initialize(**args) # File name.
update!(**args)
end
# Update properties of this object
def update!(**args)
@line = args[:line] if args.key?(:line)
@column = args[:column] if args.key?(:column)
@file_name = args[:file_name] if args.key?(:file_name)
end
end
# Issues include warnings, errors, and deprecation notices.
class Issue
include Google::Apis::Core::Hashable
# The severity of the issue.
# Corresponds to the JSON property `severity`
# @return [String]
attr_accessor :severity
# Short error description.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
# Position in the `Source` content including its line, column number, and an
# index of the `File` in the `Source` message. Used for debug purposes.
# Corresponds to the JSON property `sourcePosition`
# @return [Google::Apis::FirebaserulesV1::SourcePosition]
attr_accessor :source_position
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@severity = args[:severity] if args.key?(:severity)
@description = args[:description] if args.key?(:description)
@source_position = args[:source_position] if args.key?(:source_position)
end
end
# The request for FirebaseRulesService.TestRuleset.
class TestRulesetRequest
include Google::Apis::Core::Hashable
# `Source` is one or more `File` messages comprising a logical set of rules.
# Corresponds to the JSON property `source`
# @return [Google::Apis::FirebaserulesV1::Source]
attr_accessor :source
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@source = args[:source] if args.key?(:source)
end
end
# `Ruleset` is an immutable copy of `Source` with a globally unique identifier
# and a creation time.
class Ruleset
include Google::Apis::Core::Hashable
# `Source` is one or more `File` messages comprising a logical set of rules.
# Corresponds to the JSON property `source`
# @return [Google::Apis::FirebaserulesV1::Source]
attr_accessor :source
# Time the `Ruleset` was created.
# Output only.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# Name of the `Ruleset`. The ruleset_id is auto generated by the service.
# Format: `projects/`project_id`/rulesets/`ruleset_id``
# Output only.
# Corresponds to the JSON property `name` # Corresponds to the JSON property `name`
# @return [String] # @return [String]
attr_accessor :name attr_accessor :name
# Textual Content.
# Corresponds to the JSON property `content`
# @return [String]
attr_accessor :content
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@source = args[:source] if args.key?(:source) @fingerprint = args[:fingerprint] if args.key?(:fingerprint)
@create_time = args[:create_time] if args.key?(:create_time)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@content = args[:content] if args.key?(:content)
end end
end end
@ -185,74 +106,11 @@ module Google
end end
end end
# Represents a service-defined function call that was invoked during test
# execution.
class FunctionCall
include Google::Apis::Core::Hashable
# The arguments that were provided to the function.
# Corresponds to the JSON property `args`
# @return [Array<Object>]
attr_accessor :args
# Name of the function invoked.
# Corresponds to the JSON property `function`
# @return [String]
attr_accessor :function
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@args = args[:args] if args.key?(:args)
@function = args[:function] if args.key?(:function)
end
end
# `File` containing source content.
class File
include Google::Apis::Core::Hashable
# File name.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Textual Content.
# Corresponds to the JSON property `content`
# @return [String]
attr_accessor :content
# Fingerprint (e.g. github sha) associated with the `File`.
# Corresponds to the JSON property `fingerprint`
# @return [String]
attr_accessor :fingerprint
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@name = args[:name] if args.key?(:name)
@content = args[:content] if args.key?(:content)
@fingerprint = args[:fingerprint] if args.key?(:fingerprint)
end
end
# `Release` is a named reference to a `Ruleset`. Once a `Release` refers to a # `Release` is a named reference to a `Ruleset`. Once a `Release` refers to a
# `Ruleset`, rules-enabled services will be able to enforce the `Ruleset`. # `Ruleset`, rules-enabled services will be able to enforce the `Ruleset`.
class Release class Release
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Time the release was created.
# Output only.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
# Time the release was updated. # Time the release was updated.
# Output only. # Output only.
# Corresponds to the JSON property `updateTime` # Corresponds to the JSON property `updateTime`
@ -288,16 +146,22 @@ module Google
# @return [String] # @return [String]
attr_accessor :ruleset_name attr_accessor :ruleset_name
# Time the release was created.
# Output only.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@create_time = args[:create_time] if args.key?(:create_time)
@update_time = args[:update_time] if args.key?(:update_time) @update_time = args[:update_time] if args.key?(:update_time)
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@ruleset_name = args[:ruleset_name] if args.key?(:ruleset_name) @ruleset_name = args[:ruleset_name] if args.key?(:ruleset_name)
@create_time = args[:create_time] if args.key?(:create_time)
end end
end end
@ -419,6 +283,143 @@ module Google
def update!(**args) def update!(**args)
end end
end end
# `Source` is one or more `File` messages comprising a logical set of rules.
class Source
include Google::Apis::Core::Hashable
# `File` set constituting the `Source` bundle.
# Corresponds to the JSON property `files`
# @return [Array<Google::Apis::FirebaserulesV1::File>]
attr_accessor :files
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@files = args[:files] if args.key?(:files)
end
end
# Position in the `Source` content including its line, column number, and an
# index of the `File` in the `Source` message. Used for debug purposes.
class SourcePosition
include Google::Apis::Core::Hashable
# First column on the source line associated with the source fragment.
# Corresponds to the JSON property `column`
# @return [Fixnum]
attr_accessor :column
# Name of the `File`.
# Corresponds to the JSON property `fileName`
# @return [String]
attr_accessor :file_name
# Line number of the source fragment. 1-based.
# Corresponds to the JSON property `line`
# @return [Fixnum]
attr_accessor :line
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@column = args[:column] if args.key?(:column)
@file_name = args[:file_name] if args.key?(:file_name)
@line = args[:line] if args.key?(:line)
end
end
# Issues include warnings, errors, and deprecation notices.
class Issue
include Google::Apis::Core::Hashable
# Position in the `Source` content including its line, column number, and an
# index of the `File` in the `Source` message. Used for debug purposes.
# Corresponds to the JSON property `sourcePosition`
# @return [Google::Apis::FirebaserulesV1::SourcePosition]
attr_accessor :source_position
# The severity of the issue.
# Corresponds to the JSON property `severity`
# @return [String]
attr_accessor :severity
# Short error description.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@source_position = args[:source_position] if args.key?(:source_position)
@severity = args[:severity] if args.key?(:severity)
@description = args[:description] if args.key?(:description)
end
end
# The request for FirebaseRulesService.TestRuleset.
class TestRulesetRequest
include Google::Apis::Core::Hashable
# `Source` is one or more `File` messages comprising a logical set of rules.
# Corresponds to the JSON property `source`
# @return [Google::Apis::FirebaserulesV1::Source]
attr_accessor :source
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@source = args[:source] if args.key?(:source)
end
end
# `Ruleset` is an immutable copy of `Source` with a globally unique identifier
# and a creation time.
class Ruleset
include Google::Apis::Core::Hashable
# Name of the `Ruleset`. The ruleset_id is auto generated by the service.
# Format: `projects/`project_id`/rulesets/`ruleset_id``
# Output only.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# `Source` is one or more `File` messages comprising a logical set of rules.
# Corresponds to the JSON property `source`
# @return [Google::Apis::FirebaserulesV1::Source]
attr_accessor :source
# Time the `Ruleset` was created.
# Output only.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@name = args[:name] if args.key?(:name)
@source = args[:source] if args.key?(:source)
@create_time = args[:create_time] if args.key?(:create_time)
end
end
end end
end end
end end

View File

@ -22,42 +22,6 @@ module Google
module Apis module Apis
module FirebaserulesV1 module FirebaserulesV1
class Source
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SourcePosition
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Issue
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TestRulesetRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Ruleset
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListReleasesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FunctionCall class FunctionCall
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -70,6 +34,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListReleasesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Release class Release
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -101,47 +71,49 @@ module Google
end end
class Source class Source
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :files, as: 'files', class: Google::Apis::FirebaserulesV1::File, decorator: Google::Apis::FirebaserulesV1::File::Representation
end include Google::Apis::Core::JsonObjectSupport
end end
class SourcePosition class SourcePosition
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :line, as: 'line' include Google::Apis::Core::JsonObjectSupport
property :column, as: 'column'
property :file_name, as: 'fileName'
end
end end
class Issue class Issue
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :severity, as: 'severity'
property :description, as: 'description'
property :source_position, as: 'sourcePosition', class: Google::Apis::FirebaserulesV1::SourcePosition, decorator: Google::Apis::FirebaserulesV1::SourcePosition::Representation
end include Google::Apis::Core::JsonObjectSupport
end end
class TestRulesetRequest class TestRulesetRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :source, as: 'source', class: Google::Apis::FirebaserulesV1::Source, decorator: Google::Apis::FirebaserulesV1::Source::Representation
end include Google::Apis::Core::JsonObjectSupport
end end
class Ruleset class Ruleset
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class FunctionCall
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :source, as: 'source', class: Google::Apis::FirebaserulesV1::Source, decorator: Google::Apis::FirebaserulesV1::Source::Representation property :function, as: 'function'
collection :args, as: 'args'
end
end
property :create_time, as: 'createTime' class File
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :fingerprint, :base64 => true, as: 'fingerprint'
property :name, as: 'name' property :name, as: 'name'
property :content, as: 'content'
end end
end end
@ -154,30 +126,13 @@ module Google
end end
end end
class FunctionCall
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :args, as: 'args'
property :function, as: 'function'
end
end
class File
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :content, as: 'content'
property :fingerprint, :base64 => true, as: 'fingerprint'
end
end
class Release class Release
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :create_time, as: 'createTime'
property :update_time, as: 'updateTime' property :update_time, as: 'updateTime'
property :name, as: 'name' property :name, as: 'name'
property :ruleset_name, as: 'rulesetName' property :ruleset_name, as: 'rulesetName'
property :create_time, as: 'createTime'
end end
end end
@ -217,6 +172,51 @@ module Google
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
end end
end end
class Source
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :files, as: 'files', class: Google::Apis::FirebaserulesV1::File, decorator: Google::Apis::FirebaserulesV1::File::Representation
end
end
class SourcePosition
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :column, as: 'column'
property :file_name, as: 'fileName'
property :line, as: 'line'
end
end
class Issue
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :source_position, as: 'sourcePosition', class: Google::Apis::FirebaserulesV1::SourcePosition, decorator: Google::Apis::FirebaserulesV1::SourcePosition::Representation
property :severity, as: 'severity'
property :description, as: 'description'
end
end
class TestRulesetRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :source, as: 'source', class: Google::Apis::FirebaserulesV1::Source, decorator: Google::Apis::FirebaserulesV1::Source::Representation
end
end
class Ruleset
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :source, as: 'source', class: Google::Apis::FirebaserulesV1::Source, decorator: Google::Apis::FirebaserulesV1::Source::Representation
property :create_time, as: 'createTime'
end
end
end end
end end
end end

View File

@ -101,10 +101,11 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Delete a `Release` by resource name. # Delete a `Ruleset` by resource name.
# If the `Ruleset` is referenced by a `Release` the operation will fail.
# @param [String] name # @param [String] name
# Resource name for the `Release` to delete. # Resource name for the ruleset to delete.
# Format: `projects/`project_id`/releases/`release_id`` # Format: `projects/`project_id`/rulesets/`ruleset_id``
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -122,7 +123,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_project_release(name, fields: nil, quota_user: nil, options: nil, &block) def delete_project_ruleset(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/{+name}', options) command = make_simple_command(:delete, 'v1/{+name}', options)
command.response_representation = Google::Apis::FirebaserulesV1::Empty::Representation command.response_representation = Google::Apis::FirebaserulesV1::Empty::Representation
command.response_class = Google::Apis::FirebaserulesV1::Empty command.response_class = Google::Apis::FirebaserulesV1::Empty
@ -132,10 +133,10 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Get a `Release` by name. # Get a `Ruleset` by name including the full `Source` contents.
# @param [String] name # @param [String] name
# Resource name of the `Release`. # Resource name for the ruleset to get.
# Format: `projects/`project_id`/releases/`release_id`` # Format: `projects/`project_id`/rulesets/`ruleset_id``
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -145,58 +146,44 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::FirebaserulesV1::Release] parsed result object # @yieldparam result [Google::Apis::FirebaserulesV1::Ruleset] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::FirebaserulesV1::Release] # @return [Google::Apis::FirebaserulesV1::Ruleset]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_project_release(name, fields: nil, quota_user: nil, options: nil, &block) def get_project_ruleset(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options) command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::FirebaserulesV1::Release::Representation command.response_representation = Google::Apis::FirebaserulesV1::Ruleset::Representation
command.response_class = Google::Apis::FirebaserulesV1::Release command.response_class = Google::Apis::FirebaserulesV1::Ruleset
command.params['name'] = name unless name.nil? command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# List the `Release` values for a project. This list may optionally be # List `Ruleset` metadata only and optionally filter the results by `Ruleset`
# filtered by `Release` name, `Ruleset` name, `TestSuite` name, or any # name.
# combination thereof. # The full `Source` contents of a `Ruleset` may be retrieved with
# GetRuleset.
# @param [String] name # @param [String] name
# Resource name for the project. # Resource name for the project.
# Format: `projects/`project_id`` # Format: `projects/`project_id``
# @param [String] filter
# `Release` filter. The list method supports filters with restrictions on the
# `Release.name`, `Release.ruleset_name`, and `Release.test_suite_name`.
# Example 1: A filter of 'name=prod*' might return `Release`s with names
# within 'projects/foo' prefixed with 'prod':
# Name | Ruleset Name
# ------------------------------|-------------
# projects/foo/releases/prod | projects/foo/rulesets/uuid1234
# projects/foo/releases/prod/v1 | projects/foo/rulesets/uuid1234
# projects/foo/releases/prod/v2 | projects/foo/rulesets/uuid8888
# Example 2: A filter of `name=prod* ruleset_name=uuid1234` would return only
# `Release` instances for 'projects/foo' with names prefixed with 'prod'
# referring to the same `Ruleset` name of 'uuid1234':
# Name | Ruleset Name
# ------------------------------|-------------
# projects/foo/releases/prod | projects/foo/rulesets/1234
# projects/foo/releases/prod/v1 | projects/foo/rulesets/1234
# In the examples, the filter parameters refer to the search filters are
# relative to the project. Fully qualified prefixed may also be used. e.g.
# `test_suite_name=projects/foo/testsuites/uuid1`
# @param [String] page_token # @param [String] page_token
# Next page token for the next batch of `Release` instances. # Next page token for loading the next batch of `Ruleset` instances.
# @param [Fixnum] page_size # @param [Fixnum] page_size
# Page size to load. Maximum of 100. Defaults to 10. # Page size to load. Maximum of 100. Defaults to 10.
# Note: `page_size` is just a hint and the service may choose to load fewer # Note: `page_size` is just a hint and the service may choose to load less
# than `page_size` results due to the size of the output. To traverse all of # than `page_size` due to the size of the output. To traverse all of the
# the releases, the caller should iterate until the `page_token` on the # releases, caller should iterate until the `page_token` is empty.
# response is empty. # @param [String] filter
# `Ruleset` filter. The list method supports filters with restrictions on
# `Ruleset.name`.
# Filters on `Ruleset.create_time` should use the `date` function which
# parses strings that conform to the RFC 3339 date/time specifications.
# Example: `create_time > date("2017-01-01") AND name=UUID-*`
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -206,22 +193,60 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::FirebaserulesV1::ListReleasesResponse] parsed result object # @yieldparam result [Google::Apis::FirebaserulesV1::ListRulesetsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::FirebaserulesV1::ListReleasesResponse] # @return [Google::Apis::FirebaserulesV1::ListRulesetsResponse]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_project_releases(name, filter: nil, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block) def list_project_rulesets(name, page_token: nil, page_size: nil, filter: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}/releases', options) command = make_simple_command(:get, 'v1/{+name}/rulesets', options)
command.response_representation = Google::Apis::FirebaserulesV1::ListReleasesResponse::Representation command.response_representation = Google::Apis::FirebaserulesV1::ListRulesetsResponse::Representation
command.response_class = Google::Apis::FirebaserulesV1::ListReleasesResponse command.response_class = Google::Apis::FirebaserulesV1::ListRulesetsResponse
command.params['name'] = name unless name.nil? command.params['name'] = name unless name.nil?
command.query['filter'] = filter unless filter.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil? command.query['pageSize'] = page_size unless page_size.nil?
command.query['filter'] = filter unless filter.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Create a `Ruleset` from `Source`.
# The `Ruleset` is given a unique generated name which is returned to the
# caller. `Source` containing syntactic or semantics errors will result in an
# error response indicating the first error encountered. For a detailed view
# of `Source` issues, use TestRuleset.
# @param [String] name
# Resource name for Project which owns this `Ruleset`.
# Format: `projects/`project_id``
# @param [Google::Apis::FirebaserulesV1::Ruleset] ruleset_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::FirebaserulesV1::Ruleset] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebaserulesV1::Ruleset]
#
# @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 create_project_ruleset(name, ruleset_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}/rulesets', options)
command.request_representation = Google::Apis::FirebaserulesV1::Ruleset::Representation
command.request_object = ruleset_object
command.response_representation = Google::Apis::FirebaserulesV1::Ruleset::Representation
command.response_class = Google::Apis::FirebaserulesV1::Ruleset
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -332,130 +357,10 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Get a `Ruleset` by name including the full `Source` contents. # Delete a `Release` by resource name.
# @param [String] name # @param [String] name
# Resource name for the ruleset to get. # Resource name for the `Release` to delete.
# Format: `projects/`project_id`/rulesets/`ruleset_id`` # Format: `projects/`project_id`/releases/`release_id``
# @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::FirebaserulesV1::Ruleset] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebaserulesV1::Ruleset]
#
# @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_ruleset(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::FirebaserulesV1::Ruleset::Representation
command.response_class = Google::Apis::FirebaserulesV1::Ruleset
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
# List `Ruleset` metadata only and optionally filter the results by `Ruleset`
# name.
# The full `Source` contents of a `Ruleset` may be retrieved with
# GetRuleset.
# @param [String] name
# Resource name for the project.
# Format: `projects/`project_id``
# @param [String] filter
# `Ruleset` filter. The list method supports filters with restrictions on
# `Ruleset.name`.
# Filters on `Ruleset.create_time` should use the `date` function which
# parses strings that conform to the RFC 3339 date/time specifications.
# Example: `create_time > date("2017-01-01") AND name=UUID-*`
# @param [String] page_token
# Next page token for loading the next batch of `Ruleset` instances.
# @param [Fixnum] page_size
# Page size to load. Maximum of 100. Defaults to 10.
# Note: `page_size` is just a hint and the service may choose to load less
# than `page_size` due to the size of the output. To traverse all of the
# releases, caller should iterate until the `page_token` is empty.
# @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::FirebaserulesV1::ListRulesetsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebaserulesV1::ListRulesetsResponse]
#
# @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 list_project_rulesets(name, filter: nil, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}/rulesets', options)
command.response_representation = Google::Apis::FirebaserulesV1::ListRulesetsResponse::Representation
command.response_class = Google::Apis::FirebaserulesV1::ListRulesetsResponse
command.params['name'] = name unless name.nil?
command.query['filter'] = filter unless filter.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Create a `Ruleset` from `Source`.
# The `Ruleset` is given a unique generated name which is returned to the
# caller. `Source` containing syntactic or semantics errors will result in an
# error response indicating the first error encountered. For a detailed view
# of `Source` issues, use TestRuleset.
# @param [String] name
# Resource name for Project which owns this `Ruleset`.
# Format: `projects/`project_id``
# @param [Google::Apis::FirebaserulesV1::Ruleset] ruleset_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::FirebaserulesV1::Ruleset] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebaserulesV1::Ruleset]
#
# @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 create_project_ruleset(name, ruleset_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}/rulesets', options)
command.request_representation = Google::Apis::FirebaserulesV1::Ruleset::Representation
command.request_object = ruleset_object
command.response_representation = Google::Apis::FirebaserulesV1::Ruleset::Representation
command.response_class = Google::Apis::FirebaserulesV1::Ruleset
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
# Delete a `Ruleset` by resource name.
# If the `Ruleset` is referenced by a `Release` the operation will fail.
# @param [String] name
# Resource name for the ruleset to delete.
# Format: `projects/`project_id`/rulesets/`ruleset_id``
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -473,7 +378,7 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_project_ruleset(name, fields: nil, quota_user: nil, options: nil, &block) def delete_project_release(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/{+name}', options) command = make_simple_command(:delete, 'v1/{+name}', options)
command.response_representation = Google::Apis::FirebaserulesV1::Empty::Representation command.response_representation = Google::Apis::FirebaserulesV1::Empty::Representation
command.response_class = Google::Apis::FirebaserulesV1::Empty command.response_class = Google::Apis::FirebaserulesV1::Empty
@ -482,6 +387,101 @@ module Google
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Get a `Release` by name.
# @param [String] name
# Resource name of the `Release`.
# Format: `projects/`project_id`/releases/`release_id``
# @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::FirebaserulesV1::Release] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebaserulesV1::Release]
#
# @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_release(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::FirebaserulesV1::Release::Representation
command.response_class = Google::Apis::FirebaserulesV1::Release
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
# List the `Release` values for a project. This list may optionally be
# filtered by `Release` name, `Ruleset` name, `TestSuite` name, or any
# combination thereof.
# @param [String] name
# Resource name for the project.
# Format: `projects/`project_id``
# @param [String] page_token
# Next page token for the next batch of `Release` instances.
# @param [Fixnum] page_size
# Page size to load. Maximum of 100. Defaults to 10.
# Note: `page_size` is just a hint and the service may choose to load fewer
# than `page_size` results due to the size of the output. To traverse all of
# the releases, the caller should iterate until the `page_token` on the
# response is empty.
# @param [String] filter
# `Release` filter. The list method supports filters with restrictions on the
# `Release.name`, `Release.ruleset_name`, and `Release.test_suite_name`.
# Example 1: A filter of 'name=prod*' might return `Release`s with names
# within 'projects/foo' prefixed with 'prod':
# Name | Ruleset Name
# ------------------------------|-------------
# projects/foo/releases/prod | projects/foo/rulesets/uuid1234
# projects/foo/releases/prod/v1 | projects/foo/rulesets/uuid1234
# projects/foo/releases/prod/v2 | projects/foo/rulesets/uuid8888
# Example 2: A filter of `name=prod* ruleset_name=uuid1234` would return only
# `Release` instances for 'projects/foo' with names prefixed with 'prod'
# referring to the same `Ruleset` name of 'uuid1234':
# Name | Ruleset Name
# ------------------------------|-------------
# projects/foo/releases/prod | projects/foo/rulesets/1234
# projects/foo/releases/prod/v1 | projects/foo/rulesets/1234
# In the examples, the filter parameters refer to the search filters are
# relative to the project. Fully qualified prefixed may also be used. e.g.
# `test_suite_name=projects/foo/testsuites/uuid1`
# @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::FirebaserulesV1::ListReleasesResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::FirebaserulesV1::ListReleasesResponse]
#
# @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 list_project_releases(name, page_token: nil, page_size: nil, filter: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}/releases', options)
command.response_representation = Google::Apis::FirebaserulesV1::ListReleasesResponse::Representation
command.response_class = Google::Apis::FirebaserulesV1::ListReleasesResponse
command.params['name'] = name unless name.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['filter'] = filter unless filter.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
protected protected

View File

@ -2754,6 +2754,7 @@ module Google
# Device token supplied by an iOS system call to register for remote # Device token supplied by an iOS system call to register for remote
# notifications. Encode this field as web-safe base64. # notifications. Encode this field as web-safe base64.
# Corresponds to the JSON property `apns_device_token` # Corresponds to the JSON property `apns_device_token`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :apns_device_token attr_accessor :apns_device_token
@ -3022,6 +3023,7 @@ module Google
# string. This is a developer-specified binary blob with size between 0 and 2 KB # string. This is a developer-specified binary blob with size between 0 and 2 KB
# before encoding. # before encoding.
# Corresponds to the JSON property `completionRewardData` # Corresponds to the JSON property `completionRewardData`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :completion_reward_data attr_accessor :completion_reward_data
@ -4318,6 +4320,7 @@ module Google
# The byte representation of the data (limited to 128 kB), as a Base64-encoded # The byte representation of the data (limited to 128 kB), as a Base64-encoded
# string with the URL_SAFE encoding option. # string with the URL_SAFE encoding option.
# Corresponds to the JSON property `data` # Corresponds to the JSON property `data`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :data attr_accessor :data
@ -4353,6 +4356,7 @@ module Google
# The byte representation of the data (limited to 128 kB), as a Base64-encoded # The byte representation of the data (limited to 128 kB), as a Base64-encoded
# string with the URL_SAFE encoding option. # string with the URL_SAFE encoding option.
# Corresponds to the JSON property `data` # Corresponds to the JSON property `data`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :data attr_accessor :data

View File

@ -27,6 +27,12 @@ module Google
VERSION = 'V1' VERSION = 'V1'
REVISION = '20170330' REVISION = '20170330'
# View and manage your data in Google BigQuery
AUTH_BIGQUERY = 'https://www.googleapis.com/auth/bigquery'
# Manage your data in Google Cloud Storage
AUTH_DEVSTORAGE_READ_WRITE = 'https://www.googleapis.com/auth/devstorage.read_write'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
@ -35,12 +41,6 @@ module Google
# View and manage Genomics data # View and manage Genomics data
AUTH_GENOMICS = 'https://www.googleapis.com/auth/genomics' AUTH_GENOMICS = 'https://www.googleapis.com/auth/genomics'
# View and manage your data in Google BigQuery
AUTH_BIGQUERY = 'https://www.googleapis.com/auth/bigquery'
# Manage your data in Google Cloud Storage
AUTH_DEVSTORAGE_READ_WRITE = 'https://www.googleapis.com/auth/devstorage.read_write'
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -22,54 +22,6 @@ module Google
module Apis module Apis
module GenomicsV1 module GenomicsV1
class AnnotationSet
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Transcript
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Experiment
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListDatasetsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TestIamPermissionsRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ExportReadGroupSetRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Exon
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CallSet
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SearchAnnotationSetsResponse class SearchAnnotationSetsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -118,7 +70,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class SearchReferencesResponse class TestIamPermissionsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -130,7 +82,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class TestIamPermissionsResponse class SearchReferencesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -148,13 +100,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class SearchReferencesRequest class LinearAlignment
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class LinearAlignment class SearchReferencesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -250,13 +202,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Operation class RuntimeMetadata
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class RuntimeMetadata class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -292,13 +244,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class UndeleteDatasetRequest class Binding
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Binding class UndeleteDatasetRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -370,13 +322,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ClinicalCondition class SearchReadsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class SearchReadsResponse class ClinicalCondition
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -388,13 +340,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ComputeEngine class CoverageBucket
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class CoverageBucket class ComputeEngine
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -454,104 +406,64 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class CigarUnit
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ReferenceSet class ReferenceSet
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class AnnotationSet class CigarUnit
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :reference_set_id, as: 'referenceSetId'
property :type, as: 'type'
hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection
items
end
property :id, as: 'id' include Google::Apis::Core::JsonObjectSupport
property :dataset_id, as: 'datasetId'
property :source_uri, as: 'sourceUri'
property :name, as: 'name'
end
end end
class Transcript class Transcript
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :gene_id, as: 'geneId'
collection :exons, as: 'exons', class: Google::Apis::GenomicsV1::Exon, decorator: Google::Apis::GenomicsV1::Exon::Representation
property :coding_sequence, as: 'codingSequence', class: Google::Apis::GenomicsV1::CodingSequence, decorator: Google::Apis::GenomicsV1::CodingSequence::Representation include Google::Apis::Core::JsonObjectSupport
end
end class AnnotationSet
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class Experiment class Experiment
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :sequencing_center, as: 'sequencingCenter' include Google::Apis::Core::JsonObjectSupport
property :platform_unit, as: 'platformUnit'
property :library_id, as: 'libraryId'
property :instrument_model, as: 'instrumentModel'
end
end end
class ListDatasetsResponse class ListDatasetsResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :datasets, as: 'datasets', class: Google::Apis::GenomicsV1::Dataset, decorator: Google::Apis::GenomicsV1::Dataset::Representation
property :next_page_token, as: 'nextPageToken' include Google::Apis::Core::JsonObjectSupport
end
end end
class TestIamPermissionsRequest class TestIamPermissionsRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :permissions, as: 'permissions' include Google::Apis::Core::JsonObjectSupport
end
end end
class ExportReadGroupSetRequest class ExportReadGroupSetRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :export_uri, as: 'exportUri' include Google::Apis::Core::JsonObjectSupport
collection :reference_names, as: 'referenceNames'
property :project_id, as: 'projectId'
end
end end
class Exon class Exon
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :end, as: 'end' include Google::Apis::Core::JsonObjectSupport
property :frame, as: 'frame'
property :start, as: 'start'
end
end end
class CallSet class CallSet
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :created, as: 'created'
property :sample_id, as: 'sampleId'
property :name, as: 'name'
hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection
items
end
collection :variant_set_ids, as: 'variantSetIds' include Google::Apis::Core::JsonObjectSupport
property :id, as: 'id'
end
end end
class SearchAnnotationSetsResponse class SearchAnnotationSetsResponse
@ -577,14 +489,14 @@ module Google
class VariantAnnotation class VariantAnnotation
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :clinical_significance, as: 'clinicalSignificance'
collection :conditions, as: 'conditions', class: Google::Apis::GenomicsV1::ClinicalCondition, decorator: Google::Apis::GenomicsV1::ClinicalCondition::Representation
property :effect, as: 'effect'
collection :transcript_ids, as: 'transcriptIds' collection :transcript_ids, as: 'transcriptIds'
property :type, as: 'type' property :type, as: 'type'
property :alternate_bases, as: 'alternateBases' property :alternate_bases, as: 'alternateBases'
property :gene_id, as: 'geneId' property :gene_id, as: 'geneId'
property :clinical_significance, as: 'clinicalSignificance'
collection :conditions, as: 'conditions', class: Google::Apis::GenomicsV1::ClinicalCondition, decorator: Google::Apis::GenomicsV1::ClinicalCondition::Representation
property :effect, as: 'effect'
end end
end end
@ -612,22 +524,22 @@ module Google
class SearchAnnotationsRequest class SearchAnnotationsRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :reference_id, as: 'referenceId'
property :end, as: 'end'
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize' property :page_size, as: 'pageSize'
property :start, as: 'start' property :start, as: 'start'
collection :annotation_set_ids, as: 'annotationSetIds' collection :annotation_set_ids, as: 'annotationSetIds'
property :reference_name, as: 'referenceName' property :reference_name, as: 'referenceName'
property :reference_id, as: 'referenceId'
property :end, as: 'end'
property :page_token, as: 'pageToken'
end end
end end
class OperationEvent class OperationEvent
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :start_time, as: 'startTime'
property :description, as: 'description' property :description, as: 'description'
property :end_time, as: 'endTime' property :end_time, as: 'endTime'
property :start_time, as: 'startTime'
end end
end end
@ -639,12 +551,10 @@ module Google
end end
end end
class SearchReferencesResponse class TestIamPermissionsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :references, as: 'references', class: Google::Apis::GenomicsV1::Reference, decorator: Google::Apis::GenomicsV1::Reference::Representation collection :permissions, as: 'permissions'
property :next_page_token, as: 'nextPageToken'
end end
end end
@ -654,10 +564,12 @@ module Google
end end
end end
class TestIamPermissionsResponse class SearchReferencesResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :permissions, as: 'permissions' property :next_page_token, as: 'nextPageToken'
collection :references, as: 'references', class: Google::Apis::GenomicsV1::Reference, decorator: Google::Apis::GenomicsV1::Reference::Representation
end end
end end
@ -676,41 +588,41 @@ module Google
class SearchReadGroupSetsResponse class SearchReadGroupSetsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :read_group_sets, as: 'readGroupSets', class: Google::Apis::GenomicsV1::ReadGroupSet, decorator: Google::Apis::GenomicsV1::ReadGroupSet::Representation collection :read_group_sets, as: 'readGroupSets', class: Google::Apis::GenomicsV1::ReadGroupSet, decorator: Google::Apis::GenomicsV1::ReadGroupSet::Representation
end property :next_page_token, as: 'nextPageToken'
end
class SearchReferencesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :md5checksums, as: 'md5checksums'
collection :accessions, as: 'accessions'
property :page_token, as: 'pageToken'
property :reference_set_id, as: 'referenceSetId'
property :page_size, as: 'pageSize'
end end
end end
class LinearAlignment class LinearAlignment
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :mapping_quality, as: 'mappingQuality'
property :position, as: 'position', class: Google::Apis::GenomicsV1::Position, decorator: Google::Apis::GenomicsV1::Position::Representation property :position, as: 'position', class: Google::Apis::GenomicsV1::Position, decorator: Google::Apis::GenomicsV1::Position::Representation
collection :cigar, as: 'cigar', class: Google::Apis::GenomicsV1::CigarUnit, decorator: Google::Apis::GenomicsV1::CigarUnit::Representation collection :cigar, as: 'cigar', class: Google::Apis::GenomicsV1::CigarUnit, decorator: Google::Apis::GenomicsV1::CigarUnit::Representation
property :mapping_quality, as: 'mappingQuality'
end
end
class SearchReferencesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :accessions, as: 'accessions'
property :page_token, as: 'pageToken'
property :reference_set_id, as: 'referenceSetId'
property :page_size, as: 'pageSize'
collection :md5checksums, as: 'md5checksums'
end end
end end
class Dataset class Dataset
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
property :create_time, as: 'createTime'
property :name, as: 'name' property :name, as: 'name'
property :project_id, as: 'projectId' property :project_id, as: 'projectId'
property :id, as: 'id'
property :create_time, as: 'createTime'
end end
end end
@ -724,6 +636,7 @@ module Google
class ReadGroup class ReadGroup
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
collection :programs, as: 'programs', class: Google::Apis::GenomicsV1::Program, decorator: Google::Apis::GenomicsV1::Program::Representation collection :programs, as: 'programs', class: Google::Apis::GenomicsV1::Program, decorator: Google::Apis::GenomicsV1::Program::Representation
property :predicted_insert_size, as: 'predictedInsertSize' property :predicted_insert_size, as: 'predictedInsertSize'
@ -739,34 +652,33 @@ module Google
items items
end end
property :id, as: 'id'
end end
end end
class ReadGroupSet class ReadGroupSet
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :dataset_id, as: 'datasetId'
property :filename, as: 'filename'
collection :read_groups, as: 'readGroups', class: Google::Apis::GenomicsV1::ReadGroup, decorator: Google::Apis::GenomicsV1::ReadGroup::Representation
property :name, as: 'name'
property :reference_set_id, as: 'referenceSetId'
hash :info, as: 'info', :class => Array do hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection include Representable::JSON::Collection
items items
end end
property :id, as: 'id' property :id, as: 'id'
property :dataset_id, as: 'datasetId'
collection :read_groups, as: 'readGroups', class: Google::Apis::GenomicsV1::ReadGroup, decorator: Google::Apis::GenomicsV1::ReadGroup::Representation
property :filename, as: 'filename'
property :name, as: 'name'
property :reference_set_id, as: 'referenceSetId'
end end
end end
class SearchVariantSetsResponse class SearchVariantSetsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :variant_sets, as: 'variantSets', class: Google::Apis::GenomicsV1::VariantSet, decorator: Google::Apis::GenomicsV1::VariantSet::Representation collection :variant_sets, as: 'variantSets', class: Google::Apis::GenomicsV1::VariantSet, decorator: Google::Apis::GenomicsV1::VariantSet::Representation
property :next_page_token, as: 'nextPageToken'
end end
end end
@ -807,10 +719,10 @@ module Google
class SearchCallSetsRequest class SearchCallSetsRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :page_size, as: 'pageSize'
collection :variant_set_ids, as: 'variantSetIds'
property :name, as: 'name' property :name, as: 'name'
property :page_token, as: 'pageToken' property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
collection :variant_set_ids, as: 'variantSetIds'
end end
end end
@ -827,23 +739,23 @@ module Google
class Policy class Policy
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :etag, :base64 => true, as: 'etag'
property :version, as: 'version'
collection :bindings, as: 'bindings', class: Google::Apis::GenomicsV1::Binding, decorator: Google::Apis::GenomicsV1::Binding::Representation collection :bindings, as: 'bindings', class: Google::Apis::GenomicsV1::Binding, decorator: Google::Apis::GenomicsV1::Binding::Representation
property :etag, :base64 => true, as: 'etag'
property :version, as: 'version'
end end
end end
class SearchReadsRequest class SearchReadsRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :start, as: 'start'
property :reference_name, as: 'referenceName' property :reference_name, as: 'referenceName'
collection :read_group_set_ids, as: 'readGroupSetIds' collection :read_group_set_ids, as: 'readGroupSetIds'
collection :read_group_ids, as: 'readGroupIds' collection :read_group_ids, as: 'readGroupIds'
property :end, as: 'end' property :end, as: 'end'
property :page_token, as: 'pageToken' property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize' property :page_size, as: 'pageSize'
property :start, as: 'start'
end end
end end
@ -856,8 +768,6 @@ module Google
class Annotation class Annotation
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :reverse_strand, as: 'reverseStrand'
property :reference_name, as: 'referenceName'
hash :info, as: 'info', :class => Array do hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection include Representable::JSON::Collection
items items
@ -874,6 +784,16 @@ module Google
property :reference_id, as: 'referenceId' property :reference_id, as: 'referenceId'
property :id, as: 'id' property :id, as: 'id'
property :reverse_strand, as: 'reverseStrand'
property :reference_name, as: 'referenceName'
end
end
class RuntimeMetadata
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :compute_engine, as: 'computeEngine', class: Google::Apis::GenomicsV1::ComputeEngine, decorator: Google::Apis::GenomicsV1::ComputeEngine::Representation
end end
end end
@ -889,14 +809,6 @@ module Google
end end
end end
class RuntimeMetadata
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :compute_engine, as: 'computeEngine', class: Google::Apis::GenomicsV1::ComputeEngine, decorator: Google::Apis::GenomicsV1::ComputeEngine::Representation
end
end
class ImportReadGroupSetsResponse class ImportReadGroupSetsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -907,43 +819,51 @@ module Google
class VariantCall class VariantCall
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :call_set_name, as: 'callSetName'
collection :genotype_likelihood, as: 'genotypeLikelihood'
property :call_set_id, as: 'callSetId'
collection :genotype, as: 'genotype'
property :phaseset, as: 'phaseset' property :phaseset, as: 'phaseset'
hash :info, as: 'info', :class => Array do hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection include Representable::JSON::Collection
items items
end end
property :call_set_name, as: 'callSetName'
collection :genotype_likelihood, as: 'genotypeLikelihood'
property :call_set_id, as: 'callSetId'
collection :genotype, as: 'genotype'
end end
end end
class SearchVariantsResponse class SearchVariantsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :variants, as: 'variants', class: Google::Apis::GenomicsV1::Variant, decorator: Google::Apis::GenomicsV1::Variant::Representation collection :variants, as: 'variants', class: Google::Apis::GenomicsV1::Variant, decorator: Google::Apis::GenomicsV1::Variant::Representation
property :next_page_token, as: 'nextPageToken'
end end
end end
class ListBasesResponse class ListBasesResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :sequence, as: 'sequence'
property :offset, as: 'offset' property :offset, as: 'offset'
property :next_page_token, as: 'nextPageToken' property :next_page_token, as: 'nextPageToken'
property :sequence, as: 'sequence'
end end
end end
class Status class Status
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :details, as: 'details'
property :code, as: 'code' property :code, as: 'code'
property :message, as: 'message' property :message, as: 'message'
collection :details, as: 'details'
end
end
class Binding
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :members, as: 'members'
property :role, as: 'role'
end end
end end
@ -953,35 +873,27 @@ module Google
end end
end end
class Binding
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :role, as: 'role'
collection :members, as: 'members'
end
end
class Range class Range
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :end, as: 'end'
property :reference_name, as: 'referenceName' property :reference_name, as: 'referenceName'
property :start, as: 'start' property :start, as: 'start'
property :end, as: 'end'
end end
end end
class VariantSet class VariantSet
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
property :description, as: 'description'
property :dataset_id, as: 'datasetId'
property :name, as: 'name' property :name, as: 'name'
property :reference_set_id, as: 'referenceSetId' property :reference_set_id, as: 'referenceSetId'
collection :metadata, as: 'metadata', class: Google::Apis::GenomicsV1::VariantSetMetadata, decorator: Google::Apis::GenomicsV1::VariantSetMetadata::Representation collection :metadata, as: 'metadata', class: Google::Apis::GenomicsV1::VariantSetMetadata, decorator: Google::Apis::GenomicsV1::VariantSetMetadata::Representation
collection :reference_bounds, as: 'referenceBounds', class: Google::Apis::GenomicsV1::ReferenceBound, decorator: Google::Apis::GenomicsV1::ReferenceBound::Representation collection :reference_bounds, as: 'referenceBounds', class: Google::Apis::GenomicsV1::ReferenceBound, decorator: Google::Apis::GenomicsV1::ReferenceBound::Representation
property :id, as: 'id'
property :description, as: 'description'
property :dataset_id, as: 'datasetId'
end end
end end
@ -996,41 +908,41 @@ module Google
class ReferenceBound class ReferenceBound
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :upper_bound, as: 'upperBound'
property :reference_name, as: 'referenceName' property :reference_name, as: 'referenceName'
property :upper_bound, as: 'upperBound'
end end
end end
class ListOperationsResponse class ListOperationsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :operations, as: 'operations', class: Google::Apis::GenomicsV1::Operation, decorator: Google::Apis::GenomicsV1::Operation::Representation collection :operations, as: 'operations', class: Google::Apis::GenomicsV1::Operation, decorator: Google::Apis::GenomicsV1::Operation::Representation
property :next_page_token, as: 'nextPageToken'
end end
end end
class Variant class Variant
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :variant_set_id, as: 'variantSetId'
property :reference_name, as: 'referenceName'
hash :info, as: 'info', :class => Array do hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection include Representable::JSON::Collection
items items
end end
property :reference_bases, as: 'referenceBases' property :reference_bases, as: 'referenceBases'
collection :names, as: 'names'
collection :alternate_bases, as: 'alternateBases' collection :alternate_bases, as: 'alternateBases'
property :end, as: 'end' collection :names, as: 'names'
collection :filter, as: 'filter' collection :filter, as: 'filter'
property :end, as: 'end'
collection :calls, as: 'calls', class: Google::Apis::GenomicsV1::VariantCall, decorator: Google::Apis::GenomicsV1::VariantCall::Representation collection :calls, as: 'calls', class: Google::Apis::GenomicsV1::VariantCall, decorator: Google::Apis::GenomicsV1::VariantCall::Representation
property :created, as: 'created' property :created, as: 'created'
property :start, as: 'start' property :start, as: 'start'
property :quality, as: 'quality' property :quality, as: 'quality'
property :id, as: 'id' property :id, as: 'id'
property :variant_set_id, as: 'variantSetId'
property :reference_name, as: 'referenceName'
end end
end end
@ -1046,15 +958,15 @@ module Google
class SearchVariantsRequest class SearchVariantsRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :start, as: 'start'
property :variant_name, as: 'variantName'
property :reference_name, as: 'referenceName'
collection :variant_set_ids, as: 'variantSetIds' collection :variant_set_ids, as: 'variantSetIds'
property :end, as: 'end' property :end, as: 'end'
property :max_calls, as: 'maxCalls' property :max_calls, as: 'maxCalls'
property :page_token, as: 'pageToken' property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize' property :page_size, as: 'pageSize'
collection :call_set_ids, as: 'callSetIds' collection :call_set_ids, as: 'callSetIds'
property :start, as: 'start'
property :variant_name, as: 'variantName'
property :reference_name, as: 'referenceName'
end end
end end
@ -1077,50 +989,59 @@ module Google
class SearchReadGroupSetsRequest class SearchReadGroupSetsRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :dataset_ids, as: 'datasetIds'
property :name, as: 'name' property :name, as: 'name'
property :page_token, as: 'pageToken' property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize' property :page_size, as: 'pageSize'
collection :dataset_ids, as: 'datasetIds'
end end
end end
class SearchAnnotationsResponse class SearchAnnotationsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :annotations, as: 'annotations', class: Google::Apis::GenomicsV1::Annotation, decorator: Google::Apis::GenomicsV1::Annotation::Representation collection :annotations, as: 'annotations', class: Google::Apis::GenomicsV1::Annotation, decorator: Google::Apis::GenomicsV1::Annotation::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class SearchReadsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :alignments, as: 'alignments', class: Google::Apis::GenomicsV1::Read, decorator: Google::Apis::GenomicsV1::Read::Representation
end end
end end
class ClinicalCondition class ClinicalCondition
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :omim_id, as: 'omimId'
collection :external_ids, as: 'externalIds', class: Google::Apis::GenomicsV1::ExternalId, decorator: Google::Apis::GenomicsV1::ExternalId::Representation collection :external_ids, as: 'externalIds', class: Google::Apis::GenomicsV1::ExternalId, decorator: Google::Apis::GenomicsV1::ExternalId::Representation
property :concept_id, as: 'conceptId' property :concept_id, as: 'conceptId'
collection :names, as: 'names' collection :names, as: 'names'
property :omim_id, as: 'omimId'
end
end
class SearchReadsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :alignments, as: 'alignments', class: Google::Apis::GenomicsV1::Read, decorator: Google::Apis::GenomicsV1::Read::Representation
property :next_page_token, as: 'nextPageToken'
end end
end end
class Program class Program
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :command_line, as: 'commandLine' property :command_line, as: 'commandLine'
property :prev_program_id, as: 'prevProgramId' property :prev_program_id, as: 'prevProgramId'
property :id, as: 'id' property :id, as: 'id'
property :version, as: 'version' property :version, as: 'version'
property :name, as: 'name' end
end
class CoverageBucket
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :range, as: 'range', class: Google::Apis::GenomicsV1::Range, decorator: Google::Apis::GenomicsV1::Range::Representation
property :mean_coverage, as: 'meanCoverage'
end end
end end
@ -1134,15 +1055,6 @@ module Google
end end
end end
class CoverageBucket
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :mean_coverage, as: 'meanCoverage'
property :range, as: 'range', class: Google::Apis::GenomicsV1::Range, decorator: Google::Apis::GenomicsV1::Range::Representation
end
end
class ExternalId class ExternalId
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -1154,30 +1066,30 @@ module Google
class Reference class Reference
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :ncbi_taxon_id, as: 'ncbiTaxonId'
property :source_uri, as: 'sourceUri'
property :name, as: 'name'
property :md5checksum, as: 'md5checksum'
property :id, as: 'id' property :id, as: 'id'
property :length, as: 'length' property :length, as: 'length'
collection :source_accessions, as: 'sourceAccessions' collection :source_accessions, as: 'sourceAccessions'
property :source_uri, as: 'sourceUri'
property :ncbi_taxon_id, as: 'ncbiTaxonId'
property :name, as: 'name'
property :md5checksum, as: 'md5checksum'
end end
end end
class VariantSetMetadata class VariantSetMetadata
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :number, as: 'number'
property :value, as: 'value' property :value, as: 'value'
property :id, as: 'id' property :id, as: 'id'
property :number, as: 'number'
property :key, as: 'key' property :key, as: 'key'
property :description, as: 'description' property :description, as: 'description'
property :type, as: 'type'
hash :info, as: 'info', :class => Array do hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection include Representable::JSON::Collection
items items
end end
property :type, as: 'type'
end end
end end
@ -1222,6 +1134,18 @@ module Google
class Read class Read
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :read_group_set_id, as: 'readGroupSetId'
property :duplicate_fragment, as: 'duplicateFragment'
property :read_number, as: 'readNumber'
property :aligned_sequence, as: 'alignedSequence'
property :read_group_id, as: 'readGroupId'
property :next_mate_position, as: 'nextMatePosition', class: Google::Apis::GenomicsV1::Position, decorator: Google::Apis::GenomicsV1::Position::Representation
hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection
items
end
property :proper_placement, as: 'properPlacement' property :proper_placement, as: 'properPlacement'
property :supplementary_alignment, as: 'supplementaryAlignment' property :supplementary_alignment, as: 'supplementaryAlignment'
property :fragment_length, as: 'fragmentLength' property :fragment_length, as: 'fragmentLength'
@ -1229,22 +1153,10 @@ module Google
collection :aligned_quality, as: 'alignedQuality' collection :aligned_quality, as: 'alignedQuality'
property :alignment, as: 'alignment', class: Google::Apis::GenomicsV1::LinearAlignment, decorator: Google::Apis::GenomicsV1::LinearAlignment::Representation property :alignment, as: 'alignment', class: Google::Apis::GenomicsV1::LinearAlignment, decorator: Google::Apis::GenomicsV1::LinearAlignment::Representation
property :id, as: 'id'
property :number_reads, as: 'numberReads' property :number_reads, as: 'numberReads'
property :id, as: 'id'
property :secondary_alignment, as: 'secondaryAlignment' property :secondary_alignment, as: 'secondaryAlignment'
property :fragment_name, as: 'fragmentName' property :fragment_name, as: 'fragmentName'
property :read_group_set_id, as: 'readGroupSetId'
property :duplicate_fragment, as: 'duplicateFragment'
property :read_number, as: 'readNumber'
property :read_group_id, as: 'readGroupId'
property :aligned_sequence, as: 'alignedSequence'
hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection
items
end
property :next_mate_position, as: 'nextMatePosition', class: Google::Apis::GenomicsV1::Position, decorator: Google::Apis::GenomicsV1::Position::Representation
end end
end end
@ -1257,15 +1169,6 @@ module Google
end end
end end
class CigarUnit
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :operation_length, as: 'operationLength'
property :operation, as: 'operation'
property :reference_sequence, as: 'referenceSequence'
end
end
class ReferenceSet class ReferenceSet
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -1279,6 +1182,103 @@ module Google
collection :source_accessions, as: 'sourceAccessions' collection :source_accessions, as: 'sourceAccessions'
end end
end end
class CigarUnit
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :reference_sequence, as: 'referenceSequence'
property :operation_length, as: 'operationLength'
property :operation, as: 'operation'
end
end
class Transcript
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :exons, as: 'exons', class: Google::Apis::GenomicsV1::Exon, decorator: Google::Apis::GenomicsV1::Exon::Representation
property :coding_sequence, as: 'codingSequence', class: Google::Apis::GenomicsV1::CodingSequence, decorator: Google::Apis::GenomicsV1::CodingSequence::Representation
property :gene_id, as: 'geneId'
end
end
class AnnotationSet
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :reference_set_id, as: 'referenceSetId'
property :type, as: 'type'
hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection
items
end
property :id, as: 'id'
property :dataset_id, as: 'datasetId'
property :source_uri, as: 'sourceUri'
end
end
class Experiment
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :sequencing_center, as: 'sequencingCenter'
property :platform_unit, as: 'platformUnit'
property :library_id, as: 'libraryId'
property :instrument_model, as: 'instrumentModel'
end
end
class ListDatasetsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :datasets, as: 'datasets', class: Google::Apis::GenomicsV1::Dataset, decorator: Google::Apis::GenomicsV1::Dataset::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class TestIamPermissionsRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :permissions, as: 'permissions'
end
end
class ExportReadGroupSetRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :export_uri, as: 'exportUri'
collection :reference_names, as: 'referenceNames'
property :project_id, as: 'projectId'
end
end
class Exon
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :start, as: 'start'
property :end, as: 'end'
property :frame, as: 'frame'
end
end
class CallSet
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
hash :info, as: 'info', :class => Array do
include Representable::JSON::Collection
items
end
collection :variant_set_ids, as: 'variantSetIds'
property :id, as: 'id'
property :created, as: 'created'
property :sample_id, as: 'sampleId'
end
end
end end
end end
end end

View File

@ -46,6 +46,83 @@ module Google
super('https://genomics.googleapis.com/', '') super('https://genomics.googleapis.com/', '')
end end
# Deletes a read group set.
# For the definitions of read group sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] read_group_set_id
# The ID of the read group set to be deleted. The caller must have WRITE
# permissions to the dataset associated with this read group set.
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::Empty]
#
# @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 delete_read_group_set(read_group_set_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/readgroupsets/{readGroupSetId}', options)
command.response_representation = Google::Apis::GenomicsV1::Empty::Representation
command.response_class = Google::Apis::GenomicsV1::Empty
command.params['readGroupSetId'] = read_group_set_id unless read_group_set_id.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Creates read group sets by asynchronously importing the provided
# information.
# For the definitions of read group sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# The caller must have WRITE permissions to the dataset.
# ## Notes on [BAM](https://samtools.github.io/hts-specs/SAMv1.pdf) import
# - Tags will be converted to strings - tag types are not preserved
# - Comments (`@CO`) in the input file header will not be preserved
# - Original header order of references (`@SQ`) will not be preserved
# - Any reverse stranded unmapped reads will be reverse complemented, and
# their qualities (also the "BQ" and "OQ" tags, if any) will be reversed
# - Unmapped reads will be stripped of positional information (reference name
# and position)
# @param [Google::Apis::GenomicsV1::ImportReadGroupSetsRequest] import_read_group_sets_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::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 import_read_group_sets(import_read_group_sets_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/readgroupsets:import', options)
command.request_representation = Google::Apis::GenomicsV1::ImportReadGroupSetsRequest::Representation
command.request_object = import_read_group_sets_request_object
command.response_representation = Google::Apis::GenomicsV1::Operation::Representation
command.response_class = Google::Apis::GenomicsV1::Operation
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Exports a read group set to a BAM file in Google Cloud Storage. # Exports a read group set to a BAM file in Google Cloud Storage.
# For the definitions of read group sets and other genomics resources, see # For the definitions of read group sets and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google
@ -123,39 +200,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Gets a read group set by ID.
# For the definitions of read group sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] read_group_set_id
# The ID of the read group set.
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::ReadGroupSet] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::ReadGroupSet]
#
# @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_read_group_set(read_group_set_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/readgroupsets/{readGroupSetId}', options)
command.response_representation = Google::Apis::GenomicsV1::ReadGroupSet::Representation
command.response_class = Google::Apis::GenomicsV1::ReadGroupSet
command.params['readGroupSetId'] = read_group_set_id unless read_group_set_id.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Updates a read group set. # Updates a read group set.
# For the definitions of read group sets and other genomics resources, see # For the definitions of read group sets and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google
@ -201,13 +245,12 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Deletes a read group set. # Gets a read group set by ID.
# For the definitions of read group sets and other genomics resources, see # For the definitions of read group sets and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics) # Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] read_group_set_id # @param [String] read_group_set_id
# The ID of the read group set to be deleted. The caller must have WRITE # The ID of the read group set.
# permissions to the dataset associated with this read group set.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -217,67 +260,24 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object # @yieldparam result [Google::Apis::GenomicsV1::ReadGroupSet] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::GenomicsV1::Empty] # @return [Google::Apis::GenomicsV1::ReadGroupSet]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_read_group_set(read_group_set_id, quota_user: nil, fields: nil, options: nil, &block) def get_read_group_set(read_group_set_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/readgroupsets/{readGroupSetId}', options) command = make_simple_command(:get, 'v1/readgroupsets/{readGroupSetId}', options)
command.response_representation = Google::Apis::GenomicsV1::Empty::Representation command.response_representation = Google::Apis::GenomicsV1::ReadGroupSet::Representation
command.response_class = Google::Apis::GenomicsV1::Empty command.response_class = Google::Apis::GenomicsV1::ReadGroupSet
command.params['readGroupSetId'] = read_group_set_id unless read_group_set_id.nil? command.params['readGroupSetId'] = read_group_set_id unless read_group_set_id.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Creates read group sets by asynchronously importing the provided
# information.
# For the definitions of read group sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# The caller must have WRITE permissions to the dataset.
# ## Notes on [BAM](https://samtools.github.io/hts-specs/SAMv1.pdf) import
# - Tags will be converted to strings - tag types are not preserved
# - Comments (`@CO`) in the input file header will not be preserved
# - Original header order of references (`@SQ`) will not be preserved
# - Any reverse stranded unmapped reads will be reverse complemented, and
# their qualities (also the "BQ" and "OQ" tags, if any) will be reversed
# - Unmapped reads will be stripped of positional information (reference name
# and position)
# @param [Google::Apis::GenomicsV1::ImportReadGroupSetsRequest] import_read_group_sets_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::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 import_read_group_sets(import_read_group_sets_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/readgroupsets:import', options)
command.request_representation = Google::Apis::GenomicsV1::ImportReadGroupSetsRequest::Representation
command.request_object = import_read_group_sets_request_object
command.response_representation = Google::Apis::GenomicsV1::Operation::Representation
command.response_class = Google::Apis::GenomicsV1::Operation
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Lists fixed width coverage buckets for a read group set, each of which # Lists fixed width coverage buckets for a read group set, each of which
# correspond to a range of a reference sequence. Each bucket summarizes # correspond to a range of a reference sequence. Each bucket summarizes
# coverage information across its corresponding genomic range. # coverage information across its corresponding genomic range.
@ -398,6 +398,75 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Deletes a call set.
# For the definitions of call sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] call_set_id
# The ID of the call set to be deleted.
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::Empty]
#
# @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 delete_call_set(call_set_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/callsets/{callSetId}', options)
command.response_representation = Google::Apis::GenomicsV1::Empty::Representation
command.response_class = Google::Apis::GenomicsV1::Empty
command.params['callSetId'] = call_set_id unless call_set_id.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Gets a list of call sets matching the criteria.
# For the definitions of call sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# Implements
# [GlobalAllianceApi.searchCallSets](https://github.com/ga4gh/schemas/blob/v0.5.
# 1/src/main/resources/avro/variantmethods.avdl#L178).
# @param [Google::Apis::GenomicsV1::SearchCallSetsRequest] search_call_sets_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::SearchCallSetsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::SearchCallSetsResponse]
#
# @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 search_call_sets(search_call_sets_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/callsets/search', options)
command.request_representation = Google::Apis::GenomicsV1::SearchCallSetsRequest::Representation
command.request_object = search_call_sets_request_object
command.response_representation = Google::Apis::GenomicsV1::SearchCallSetsResponse::Representation
command.response_class = Google::Apis::GenomicsV1::SearchCallSetsResponse
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Updates a call set. # Updates a call set.
# For the definitions of call sets and other genomics resources, see # For the definitions of call sets and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google
@ -507,12 +576,14 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Deletes a call set. # Creates a new annotation set. Caller must have WRITE permission for the
# For the definitions of call sets and other genomics resources, see # associated dataset.
# [Fundamentals of Google # The following fields are required:
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics) # * datasetId
# @param [String] call_set_id # * referenceSetId
# The ID of the call set to be deleted. # All other fields may be optionally specified, unless documented as being
# server-generated (for example, the `id` field).
# @param [Google::Apis::GenomicsV1::AnnotationSet] annotation_set_object
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -522,55 +593,20 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object # @yieldparam result [Google::Apis::GenomicsV1::AnnotationSet] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::GenomicsV1::Empty] # @return [Google::Apis::GenomicsV1::AnnotationSet]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_call_set(call_set_id, quota_user: nil, fields: nil, options: nil, &block) def create_annotation_set(annotation_set_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/callsets/{callSetId}', options) command = make_simple_command(:post, 'v1/annotationsets', options)
command.response_representation = Google::Apis::GenomicsV1::Empty::Representation command.request_representation = Google::Apis::GenomicsV1::AnnotationSet::Representation
command.response_class = Google::Apis::GenomicsV1::Empty command.request_object = annotation_set_object
command.params['callSetId'] = call_set_id unless call_set_id.nil? command.response_representation = Google::Apis::GenomicsV1::AnnotationSet::Representation
command.query['quotaUser'] = quota_user unless quota_user.nil? command.response_class = Google::Apis::GenomicsV1::AnnotationSet
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Gets a list of call sets matching the criteria.
# For the definitions of call sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# Implements
# [GlobalAllianceApi.searchCallSets](https://github.com/ga4gh/schemas/blob/v0.5.
# 1/src/main/resources/avro/variantmethods.avdl#L178).
# @param [Google::Apis::GenomicsV1::SearchCallSetsRequest] search_call_sets_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::SearchCallSetsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::SearchCallSetsResponse]
#
# @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 search_call_sets(search_call_sets_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/callsets/search', options)
command.request_representation = Google::Apis::GenomicsV1::SearchCallSetsRequest::Representation
command.request_object = search_call_sets_request_object
command.response_representation = Google::Apis::GenomicsV1::SearchCallSetsResponse::Representation
command.response_class = Google::Apis::GenomicsV1::SearchCallSetsResponse
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -714,14 +750,12 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Creates a new annotation set. Caller must have WRITE permission for the # Deletes a variant.
# associated dataset. # For the definitions of variants and other genomics resources, see
# The following fields are required: # [Fundamentals of Google
# * datasetId # Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# * referenceSetId # @param [String] variant_id
# All other fields may be optionally specified, unless documented as being # The ID of the variant to be deleted.
# server-generated (for example, the `id` field).
# @param [Google::Apis::GenomicsV1::AnnotationSet] annotation_set_object
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -731,20 +765,63 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::AnnotationSet] parsed result object # @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::GenomicsV1::AnnotationSet] # @return [Google::Apis::GenomicsV1::Empty]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def create_annotation_set(annotation_set_object = nil, quota_user: nil, fields: nil, options: nil, &block) def delete_variant(variant_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/annotationsets', options) command = make_simple_command(:delete, 'v1/variants/{variantId}', options)
command.request_representation = Google::Apis::GenomicsV1::AnnotationSet::Representation command.response_representation = Google::Apis::GenomicsV1::Empty::Representation
command.request_object = annotation_set_object command.response_class = Google::Apis::GenomicsV1::Empty
command.response_representation = Google::Apis::GenomicsV1::AnnotationSet::Representation command.params['variantId'] = variant_id unless variant_id.nil?
command.response_class = Google::Apis::GenomicsV1::AnnotationSet command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Creates variant data by asynchronously importing the provided information.
# For the definitions of variant sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# The variants for import will be merged with any existing variant that
# matches its reference sequence, start, end, reference bases, and
# alternative bases. If no such variant exists, a new one will be created.
# When variants are merged, the call information from the new variant
# is added to the existing variant, and Variant info fields are merged
# as specified in
# infoMergeConfig.
# As a special case, for single-sample VCF files, QUAL and FILTER fields will
# be moved to the call level; these are sometimes interpreted in a
# call-specific context.
# Imported VCF headers are appended to the metadata already in a variant set.
# @param [Google::Apis::GenomicsV1::ImportVariantsRequest] import_variants_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::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 import_variants(import_variants_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/variants:import', options)
command.request_representation = Google::Apis::GenomicsV1::ImportVariantsRequest::Representation
command.request_object = import_variants_request_object
command.response_representation = Google::Apis::GenomicsV1::Operation::Representation
command.response_class = Google::Apis::GenomicsV1::Operation
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -861,83 +938,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Deletes a variant.
# For the definitions of variants and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] variant_id
# The ID of the variant to be deleted.
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::Empty]
#
# @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 delete_variant(variant_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/variants/{variantId}', options)
command.response_representation = Google::Apis::GenomicsV1::Empty::Representation
command.response_class = Google::Apis::GenomicsV1::Empty
command.params['variantId'] = variant_id unless variant_id.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Creates variant data by asynchronously importing the provided information.
# For the definitions of variant sets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# The variants for import will be merged with any existing variant that
# matches its reference sequence, start, end, reference bases, and
# alternative bases. If no such variant exists, a new one will be created.
# When variants are merged, the call information from the new variant
# is added to the existing variant, and Variant info fields are merged
# as specified in
# infoMergeConfig.
# As a special case, for single-sample VCF files, QUAL and FILTER fields will
# be moved to the call level; these are sometimes interpreted in a
# call-specific context.
# Imported VCF headers are appended to the metadata already in a variant set.
# @param [Google::Apis::GenomicsV1::ImportVariantsRequest] import_variants_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::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 import_variants(import_variants_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/variants:import', options)
command.request_representation = Google::Apis::GenomicsV1::ImportVariantsRequest::Representation
command.request_object = import_variants_request_object
command.response_representation = Google::Apis::GenomicsV1::Operation::Representation
command.response_class = Google::Apis::GenomicsV1::Operation
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Creates a new variant. # Creates a new variant.
# For the definitions of variants and other genomics resources, see # For the definitions of variants and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google
@ -1165,8 +1165,6 @@ module Google
# 5.1/src/main/resources/avro/referencemethods.avdl#L221). # 5.1/src/main/resources/avro/referencemethods.avdl#L221).
# @param [String] reference_id # @param [String] reference_id
# The ID of the reference. # The ID of the reference.
# @param [String] start_position
# The start position (0-based) of this query. Defaults to 0.
# @param [String] end_position # @param [String] end_position
# The end position (0-based, exclusive) of this query. Defaults to the length # The end position (0-based, exclusive) of this query. Defaults to the length
# of this reference. # of this reference.
@ -1178,6 +1176,8 @@ module Google
# The maximum number of bases to return in a single page. If unspecified, # The maximum number of bases to return in a single page. If unspecified,
# defaults to 200Kbp (kilo base pairs). The maximum value is 10Mbp (mega base # defaults to 200Kbp (kilo base pairs). The maximum value is 10Mbp (mega base
# pairs). # pairs).
# @param [String] start_position
# The start position (0-based) of this query. Defaults to 0.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -1195,15 +1195,55 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_reference_bases(reference_id, start_position: nil, end_position: nil, page_token: nil, page_size: nil, quota_user: nil, fields: nil, options: nil, &block) def list_reference_bases(reference_id, end_position: nil, page_token: nil, page_size: nil, start_position: nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/references/{referenceId}/bases', options) command = make_simple_command(:get, 'v1/references/{referenceId}/bases', options)
command.response_representation = Google::Apis::GenomicsV1::ListBasesResponse::Representation command.response_representation = Google::Apis::GenomicsV1::ListBasesResponse::Representation
command.response_class = Google::Apis::GenomicsV1::ListBasesResponse command.response_class = Google::Apis::GenomicsV1::ListBasesResponse
command.params['referenceId'] = reference_id unless reference_id.nil? command.params['referenceId'] = reference_id unless reference_id.nil?
command.query['start'] = start_position unless start_position.nil?
command.query['end'] = end_position unless end_position.nil? command.query['end'] = end_position unless end_position.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil? command.query['pageSize'] = page_size unless page_size.nil?
command.query['start'] = start_position unless start_position.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Gets the access control policy for the dataset. This is empty if the
# policy or resource does not exist.
# See <a href="/iam/docs/managing-policies#getting_a_policy">Getting a
# Policy</a> for more information.
# For the definitions of datasets and other genomics resources, see
# [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] resource
# REQUIRED: The resource for which policy is being specified. Format is
# `datasets/<dataset ID>`.
# @param [Google::Apis::GenomicsV1::GetIamPolicyRequest] get_iam_policy_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Policy] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::Policy]
#
# @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_dataset_iam_policy(resource, get_iam_policy_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+resource}:getIamPolicy', options)
command.request_representation = Google::Apis::GenomicsV1::GetIamPolicyRequest::Representation
command.request_object = get_iam_policy_request_object
command.response_representation = Google::Apis::GenomicsV1::Policy::Representation
command.response_class = Google::Apis::GenomicsV1::Policy
command.params['resource'] = resource unless resource.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -1403,15 +1443,15 @@ module Google
# For the definitions of datasets and other genomics resources, see # For the definitions of datasets and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics) # Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] page_token
# The continuation token, which is used to page through large result sets.
# To get the next page of results, set this parameter to the value of
# `nextPageToken` from the previous response.
# @param [Fixnum] page_size # @param [Fixnum] page_size
# The maximum number of results to return in a single page. If unspecified, # The maximum number of results to return in a single page. If unspecified,
# defaults to 50. The maximum value is 1024. # defaults to 50. The maximum value is 1024.
# @param [String] project_id # @param [String] project_id
# Required. The Google Cloud project ID to list datasets for. # Required. The Google Cloud project ID to list datasets for.
# @param [String] page_token
# The continuation token, which is used to page through large result sets.
# To get the next page of results, set this parameter to the value of
# `nextPageToken` from the previous response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -1429,13 +1469,13 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_datasets(page_token: nil, page_size: nil, project_id: nil, quota_user: nil, fields: nil, options: nil, &block) def list_datasets(page_size: nil, project_id: nil, page_token: nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/datasets', options) command = make_simple_command(:get, 'v1/datasets', options)
command.response_representation = Google::Apis::GenomicsV1::ListDatasetsResponse::Representation command.response_representation = Google::Apis::GenomicsV1::ListDatasetsResponse::Representation
command.response_class = Google::Apis::GenomicsV1::ListDatasetsResponse command.response_class = Google::Apis::GenomicsV1::ListDatasetsResponse
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil? command.query['pageSize'] = page_size unless page_size.nil?
command.query['projectId'] = project_id unless project_id.nil? command.query['projectId'] = project_id unless project_id.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -1514,17 +1554,13 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Gets the access control policy for the dataset. This is empty if the # Deletes a variant set including all variants, call sets, and calls within.
# policy or resource does not exist. # This is not reversible.
# See <a href="/iam/docs/managing-policies#getting_a_policy">Getting a # For the definitions of variant sets and other genomics resources, see
# Policy</a> for more information.
# For the definitions of datasets and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics) # Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics)
# @param [String] resource # @param [String] variant_set_id
# REQUIRED: The resource for which policy is being specified. Format is # The ID of the variant set to be deleted.
# `datasets/<dataset ID>`.
# @param [Google::Apis::GenomicsV1::GetIamPolicyRequest] get_iam_policy_request_object
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -1534,21 +1570,19 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Policy] parsed result object # @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::GenomicsV1::Policy] # @return [Google::Apis::GenomicsV1::Empty]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def get_dataset_iam_policy(resource, get_iam_policy_request_object = nil, quota_user: nil, fields: nil, options: nil, &block) def delete_variantset(variant_set_id, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+resource}:getIamPolicy', options) command = make_simple_command(:delete, 'v1/variantsets/{variantSetId}', options)
command.request_representation = Google::Apis::GenomicsV1::GetIamPolicyRequest::Representation command.response_representation = Google::Apis::GenomicsV1::Empty::Representation
command.request_object = get_iam_policy_request_object command.response_class = Google::Apis::GenomicsV1::Empty
command.response_representation = Google::Apis::GenomicsV1::Policy::Representation command.params['variantSetId'] = variant_set_id unless variant_set_id.nil?
command.response_class = Google::Apis::GenomicsV1::Policy
command.params['resource'] = resource unless resource.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -1740,13 +1774,23 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Deletes a variant set including all variants, call sets, and calls within. # Creates a new annotation. Caller must have WRITE permission
# This is not reversible. # for the associated annotation set.
# For the definitions of variant sets and other genomics resources, see # The following fields are required:
# [Fundamentals of Google # * annotationSetId
# Genomics](https://cloud.google.com/genomics/fundamentals-of-google-genomics) # * referenceName or
# @param [String] variant_set_id # referenceId
# The ID of the variant set to be deleted. # ### Transcripts
# For annotations of type TRANSCRIPT, the following fields of
# transcript must be provided:
# * exons.start
# * exons.end
# All other fields may be optionally specified, unless documented as being
# server-generated (for example, the `id` field). The annotated
# range must be no longer than 100Mbp (mega base pairs). See the
# Annotation resource
# for additional restrictions on each field.
# @param [Google::Apis::GenomicsV1::Annotation] annotation_object
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -1756,19 +1800,61 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object # @yieldparam result [Google::Apis::GenomicsV1::Annotation] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::GenomicsV1::Empty] # @return [Google::Apis::GenomicsV1::Annotation]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def delete_variantset(variant_set_id, quota_user: nil, fields: nil, options: nil, &block) def create_annotation(annotation_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/variantsets/{variantSetId}', options) command = make_simple_command(:post, 'v1/annotations', options)
command.response_representation = Google::Apis::GenomicsV1::Empty::Representation command.request_representation = Google::Apis::GenomicsV1::Annotation::Representation
command.response_class = Google::Apis::GenomicsV1::Empty command.request_object = annotation_object
command.params['variantSetId'] = variant_set_id unless variant_set_id.nil? command.response_representation = Google::Apis::GenomicsV1::Annotation::Representation
command.response_class = Google::Apis::GenomicsV1::Annotation
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Creates one or more new annotations atomically. All annotations must
# belong to the same annotation set. Caller must have WRITE
# permission for this annotation set. For optimal performance, batch
# positionally adjacent annotations together.
# If the request has a systemic issue, such as an attempt to write to
# an inaccessible annotation set, the entire RPC will fail accordingly. For
# lesser data issues, when possible an error will be isolated to the
# corresponding batch entry in the response; the remaining well formed
# annotations will be created normally.
# For details on the requirements for each individual annotation resource,
# see
# CreateAnnotation.
# @param [Google::Apis::GenomicsV1::BatchCreateAnnotationsRequest] batch_create_annotations_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse]
#
# @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 batch_create_annotations(batch_create_annotations_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/annotations:batchCreate', options)
command.request_representation = Google::Apis::GenomicsV1::BatchCreateAnnotationsRequest::Representation
command.request_object = batch_create_annotations_request_object
command.response_representation = Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse::Representation
command.response_class = Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -1914,23 +2000,13 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Creates a new annotation. Caller must have WRITE permission # Starts asynchronous cancellation on a long-running operation. The server makes
# for the associated annotation set. # a best effort to cancel the operation, but success is not guaranteed. Clients
# The following fields are required: # may use Operations.GetOperation or Operations.ListOperations to check whether
# * annotationSetId # the cancellation succeeded or the operation completed despite cancellation.
# * referenceName or # @param [String] name
# referenceId # The name of the operation resource to be cancelled.
# ### Transcripts # @param [Google::Apis::GenomicsV1::CancelOperationRequest] cancel_operation_request_object
# For annotations of type TRANSCRIPT, the following fields of
# transcript must be provided:
# * exons.start
# * exons.end
# All other fields may be optionally specified, unless documented as being
# server-generated (for example, the `id` field). The annotated
# range must be no longer than 100Mbp (mega base pairs). See the
# Annotation resource
# for additional restrictions on each field.
# @param [Google::Apis::GenomicsV1::Annotation] annotation_object
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -1940,61 +2016,21 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Annotation] parsed result object # @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::GenomicsV1::Annotation] # @return [Google::Apis::GenomicsV1::Empty]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def create_annotation(annotation_object = nil, quota_user: nil, fields: nil, options: nil, &block) def cancel_operation(name, cancel_operation_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/annotations', options) command = make_simple_command(:post, 'v1/{+name}:cancel', options)
command.request_representation = Google::Apis::GenomicsV1::Annotation::Representation command.request_representation = Google::Apis::GenomicsV1::CancelOperationRequest::Representation
command.request_object = annotation_object command.request_object = cancel_operation_request_object
command.response_representation = Google::Apis::GenomicsV1::Annotation::Representation command.response_representation = Google::Apis::GenomicsV1::Empty::Representation
command.response_class = Google::Apis::GenomicsV1::Annotation command.response_class = Google::Apis::GenomicsV1::Empty
command.query['quotaUser'] = quota_user unless quota_user.nil? command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Creates one or more new annotations atomically. All annotations must
# belong to the same annotation set. Caller must have WRITE
# permission for this annotation set. For optimal performance, batch
# positionally adjacent annotations together.
# If the request has a systemic issue, such as an attempt to write to
# an inaccessible annotation set, the entire RPC will fail accordingly. For
# lesser data issues, when possible an error will be isolated to the
# corresponding batch entry in the response; the remaining well formed
# annotations will be created normally.
# For details on the requirements for each individual annotation resource,
# see
# CreateAnnotation.
# @param [Google::Apis::GenomicsV1::BatchCreateAnnotationsRequest] batch_create_annotations_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse]
#
# @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 batch_create_annotations(batch_create_annotations_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/annotations:batchCreate', options)
command.request_representation = Google::Apis::GenomicsV1::BatchCreateAnnotationsRequest::Representation
command.request_object = batch_create_annotations_request_object
command.response_representation = Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse::Representation
command.response_class = Google::Apis::GenomicsV1::BatchCreateAnnotationsResponse
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -2003,6 +2039,9 @@ module Google
# Lists operations that match the specified filter in the request. # Lists operations that match the specified filter in the request.
# @param [String] name # @param [String] name
# The name of the operation collection. # The name of the operation collection.
# @param [Fixnum] page_size
# The maximum number of results to return. If unspecified, defaults to
# 256. The maximum value is 2048.
# @param [String] filter # @param [String] filter
# A string for filtering Operations. # A string for filtering Operations.
# The following filter fields are supported&#58; # The following filter fields are supported&#58;
@ -2022,9 +2061,6 @@ module Google
# * `projectId = my-project AND labels.color = red` # * `projectId = my-project AND labels.color = red`
# @param [String] page_token # @param [String] page_token
# The standard list page token. # The standard list page token.
# @param [Fixnum] page_size
# The maximum number of results to return. If unspecified, defaults to
# 256. The maximum value is 2048.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -2042,14 +2078,14 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def list_operations(name, filter: nil, page_token: nil, page_size: nil, quota_user: nil, fields: nil, options: nil, &block) def list_operations(name, page_size: nil, filter: nil, page_token: nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options) command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::GenomicsV1::ListOperationsResponse::Representation command.response_representation = Google::Apis::GenomicsV1::ListOperationsResponse::Representation
command.response_class = Google::Apis::GenomicsV1::ListOperationsResponse command.response_class = Google::Apis::GenomicsV1::ListOperationsResponse
command.params['name'] = name unless name.nil? command.params['name'] = name unless name.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['filter'] = filter unless filter.nil? command.query['filter'] = filter unless filter.nil?
command.query['pageToken'] = page_token unless page_token.nil? command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -2087,42 +2123,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Starts asynchronous cancellation on a long-running operation. The server makes
# a best effort to cancel the operation, but success is not guaranteed. Clients
# may use Operations.GetOperation or Operations.ListOperations to check whether
# the cancellation succeeded or the operation completed despite cancellation.
# @param [String] name
# The name of the operation resource to be cancelled.
# @param [Google::Apis::GenomicsV1::CancelOperationRequest] cancel_operation_request_object
# @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 [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::GenomicsV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::GenomicsV1::Empty]
#
# @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 cancel_operation(name, cancel_operation_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}:cancel', options)
command.request_representation = Google::Apis::GenomicsV1::CancelOperationRequest::Representation
command.request_object = cancel_operation_request_object
command.response_representation = Google::Apis::GenomicsV1::Empty::Representation
command.response_class = Google::Apis::GenomicsV1::Empty
command.params['name'] = name unless name.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block)
end
# Searches for reference sets which match the given criteria. # Searches for reference sets which match the given criteria.
# For the definitions of references and other genomics resources, see # For the definitions of references and other genomics resources, see
# [Fundamentals of Google # [Fundamentals of Google

View File

@ -812,6 +812,7 @@ module Google
# Returned in messages.get and drafts.get responses when the format=RAW # Returned in messages.get and drafts.get responses when the format=RAW
# parameter is supplied. # parameter is supplied.
# Corresponds to the JSON property `raw` # Corresponds to the JSON property `raw`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :raw attr_accessor :raw
@ -925,6 +926,7 @@ module Google
# is sent as a separate attachment. An attachment ID is present if the body data # is sent as a separate attachment. An attachment ID is present if the body data
# is contained in a separate attachment. # is contained in a separate attachment.
# Corresponds to the JSON property `data` # Corresponds to the JSON property `data`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :data attr_accessor :data
@ -1215,6 +1217,7 @@ module Google
# PKCS#12 may be encrypted, in which case encryptedKeyPassword should be set # PKCS#12 may be encrypted, in which case encryptedKeyPassword should be set
# appropriately. # appropriately.
# Corresponds to the JSON property `pkcs12` # Corresponds to the JSON property `pkcs12`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :pkcs12 attr_accessor :pkcs12

View File

@ -22,6 +22,125 @@ module Google
module Apis module Apis
module IamV1 module IamV1
# The grantable role query response.
class QueryGrantableRolesResponse
include Google::Apis::Core::Hashable
# The list of matching roles.
# Corresponds to the JSON property `roles`
# @return [Array<Google::Apis::IamV1::Role>]
attr_accessor :roles
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@roles = args[:roles] if args.key?(:roles)
end
end
# The service account sign blob request.
class SignBlobRequest
include Google::Apis::Core::Hashable
# The bytes to sign.
# Corresponds to the JSON property `bytesToSign`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :bytes_to_sign
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@bytes_to_sign = args[:bytes_to_sign] if args.key?(:bytes_to_sign)
end
end
# A role in the Identity and Access Management API.
class Role
include Google::Apis::Core::Hashable
# Optional. A human-readable title for the role. Typically this
# is limited to 100 UTF-8 bytes.
# Corresponds to the JSON property `title`
# @return [String]
attr_accessor :title
# The name of the role.
# When Role is used in CreateRole, the role name must not be set.
# When Role is used in output and other input such as UpdateRole, the role
# name is the complete path, e.g., roles/logging.viewer for curated roles
# and organizations/`ORGANIZATION_ID`/roles/logging.viewer for custom roles.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Optional. A human-readable description for the role.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@title = args[:title] if args.key?(:title)
@name = args[:name] if args.key?(:name)
@description = args[:description] if args.key?(:description)
end
end
# Request message for `SetIamPolicy` method.
class SetIamPolicyRequest
include Google::Apis::Core::Hashable
# Defines an Identity and Access Management (IAM) policy. It is used to
# specify access control policies for Cloud Platform resources.
# A `Policy` consists of a list of `bindings`. A `Binding` binds a list of
# `members` to a `role`, where the members can be user accounts, Google groups,
# Google domains, and service accounts. A `role` is a named list of permissions
# defined by IAM.
# **Example**
# `
# "bindings": [
# `
# "role": "roles/owner",
# "members": [
# "user:mike@example.com",
# "group:admins@example.com",
# "domain:google.com",
# "serviceAccount:my-other-app@appspot.gserviceaccount.com",
# ]
# `,
# `
# "role": "roles/viewer",
# "members": ["user:sean@example.com"]
# `
# ]
# `
# For a description of IAM and its features, see the
# [IAM developer's guide](https://cloud.google.com/iam).
# Corresponds to the JSON property `policy`
# @return [Google::Apis::IamV1::Policy]
attr_accessor :policy
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@policy = args[:policy] if args.key?(:policy)
end
end
# Associates `members` with a `role`. # Associates `members` with a `role`.
class Binding class Binding
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -62,66 +181,17 @@ module Google
end end
end end
# A service account in the Identity and Access Management API. # The grantable role query request.
# To create a service account, specify the `project_id` and the `account_id` class QueryGrantableRolesRequest
# for the account. The `account_id` is unique within the project, and is used
# to generate the service account email address and a stable
# `unique_id`.
# If the account already exists, the account's resource name is returned
# in util::Status's ResourceInfo.resource_name in the format of
# projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL`. The caller can
# use the name in other methods to access the account.
# All other methods can identify the service account using the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Using `-` as a wildcard for the project will infer the project from
# the account. The `account` value can be the `email` address or the
# `unique_id` of the service account.
class ServiceAccount
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The resource name of the service account in the following format: # Required. The full resource name to query from the list of grantable roles.
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``. # The name follows the Google Cloud Platform resource format.
# Requests using `-` as a wildcard for the project will infer the project # For example, a Cloud Platform project with id `my-project` will be named
# from the `account` and the `account` value can be the `email` address or # `//cloudresourcemanager.googleapis.com/projects/my-project`.
# the `unique_id` of the service account. # Corresponds to the JSON property `fullResourceName`
# In responses the resource name will always be in the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Corresponds to the JSON property `name`
# @return [String] # @return [String]
attr_accessor :name attr_accessor :full_resource_name
# @OutputOnly The email address of the service account.
# Corresponds to the JSON property `email`
# @return [String]
attr_accessor :email
# @OutputOnly The id of the project that owns the service account.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
# @OutputOnly The unique and stable id of the service account.
# Corresponds to the JSON property `uniqueId`
# @return [String]
attr_accessor :unique_id
# @OutputOnly. The OAuth2 client id for the service account.
# This is used in conjunction with the OAuth2 clientconfig API to make
# three legged OAuth2 (3LO) flows to access the data of Google users.
# Corresponds to the JSON property `oauth2ClientId`
# @return [String]
attr_accessor :oauth2_client_id
# Optional. A user-specified description of the service account. Must be
# fewer than 100 UTF-8 bytes.
# Corresponds to the JSON property `displayName`
# @return [String]
attr_accessor :display_name
# Used to perform a consistent read-modify-write.
# Corresponds to the JSON property `etag`
# @return [String]
attr_accessor :etag
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -129,13 +199,7 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@name = args[:name] if args.key?(:name) @full_resource_name = args[:full_resource_name] if args.key?(:full_resource_name)
@email = args[:email] if args.key?(:email)
@project_id = args[:project_id] if args.key?(:project_id)
@unique_id = args[:unique_id] if args.key?(:unique_id)
@oauth2_client_id = args[:oauth2_client_id] if args.key?(:oauth2_client_id)
@display_name = args[:display_name] if args.key?(:display_name)
@etag = args[:etag] if args.key?(:etag)
end end
end end
@ -158,17 +222,67 @@ module Google
end end
end end
# The grantable role query request. # A service account in the Identity and Access Management API.
class QueryGrantableRolesRequest # To create a service account, specify the `project_id` and the `account_id`
# for the account. The `account_id` is unique within the project, and is used
# to generate the service account email address and a stable
# `unique_id`.
# If the account already exists, the account's resource name is returned
# in util::Status's ResourceInfo.resource_name in the format of
# projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL`. The caller can
# use the name in other methods to access the account.
# All other methods can identify the service account using the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Using `-` as a wildcard for the project will infer the project from
# the account. The `account` value can be the `email` address or the
# `unique_id` of the service account.
class ServiceAccount
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Required. The full resource name to query from the list of grantable roles. # @OutputOnly The id of the project that owns the service account.
# The name follows the Google Cloud Platform resource format. # Corresponds to the JSON property `projectId`
# For example, a Cloud Platform project with id `my-project` will be named
# `//cloudresourcemanager.googleapis.com/projects/my-project`.
# Corresponds to the JSON property `fullResourceName`
# @return [String] # @return [String]
attr_accessor :full_resource_name attr_accessor :project_id
# @OutputOnly. The OAuth2 client id for the service account.
# This is used in conjunction with the OAuth2 clientconfig API to make
# three legged OAuth2 (3LO) flows to access the data of Google users.
# Corresponds to the JSON property `oauth2ClientId`
# @return [String]
attr_accessor :oauth2_client_id
# @OutputOnly The unique and stable id of the service account.
# Corresponds to the JSON property `uniqueId`
# @return [String]
attr_accessor :unique_id
# Optional. A user-specified description of the service account. Must be
# fewer than 100 UTF-8 bytes.
# Corresponds to the JSON property `displayName`
# @return [String]
attr_accessor :display_name
# Used to perform a consistent read-modify-write.
# Corresponds to the JSON property `etag`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :etag
# @OutputOnly The email address of the service account.
# Corresponds to the JSON property `email`
# @return [String]
attr_accessor :email
# The resource name of the service account in the following format:
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Requests using `-` as a wildcard for the project will infer the project
# from the `account` and the `account` value can be the `email` address or
# the `unique_id` of the service account.
# In responses the resource name will always be in the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -176,7 +290,13 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@full_resource_name = args[:full_resource_name] if args.key?(:full_resource_name) @project_id = args[:project_id] if args.key?(:project_id)
@oauth2_client_id = args[:oauth2_client_id] if args.key?(:oauth2_client_id)
@unique_id = args[:unique_id] if args.key?(:unique_id)
@display_name = args[:display_name] if args.key?(:display_name)
@etag = args[:etag] if args.key?(:etag)
@email = args[:email] if args.key?(:email)
@name = args[:name] if args.key?(:name)
end end
end end
@ -237,11 +357,13 @@ module Google
# The private key data. Only provided in `CreateServiceAccountKey` # The private key data. Only provided in `CreateServiceAccountKey`
# responses. # responses.
# Corresponds to the JSON property `privateKeyData` # Corresponds to the JSON property `privateKeyData`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :private_key_data attr_accessor :private_key_data
# The public key data. Only provided in `GetServiceAccountKey` responses. # The public key data. Only provided in `GetServiceAccountKey` responses.
# Corresponds to the JSON property `publicKeyData` # Corresponds to the JSON property `publicKeyData`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :public_key_data attr_accessor :public_key_data
@ -261,6 +383,11 @@ module Google
# @return [String] # @return [String]
attr_accessor :key_algorithm attr_accessor :key_algorithm
# The key can be used after this timestamp.
# Corresponds to the JSON property `validAfterTime`
# @return [String]
attr_accessor :valid_after_time
# The output format for the private key. # The output format for the private key.
# Only provided in `CreateServiceAccountKey` responses, not # Only provided in `CreateServiceAccountKey` responses, not
# in `GetServiceAccountKey` or `ListServiceAccountKey` responses. # in `GetServiceAccountKey` or `ListServiceAccountKey` responses.
@ -270,11 +397,6 @@ module Google
# @return [String] # @return [String]
attr_accessor :private_key_type attr_accessor :private_key_type
# The key can be used after this timestamp.
# Corresponds to the JSON property `validAfterTime`
# @return [String]
attr_accessor :valid_after_time
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
@ -286,8 +408,8 @@ module Google
@name = args[:name] if args.key?(:name) @name = args[:name] if args.key?(:name)
@valid_before_time = args[:valid_before_time] if args.key?(:valid_before_time) @valid_before_time = args[:valid_before_time] if args.key?(:valid_before_time)
@key_algorithm = args[:key_algorithm] if args.key?(:key_algorithm) @key_algorithm = args[:key_algorithm] if args.key?(:key_algorithm)
@private_key_type = args[:private_key_type] if args.key?(:private_key_type)
@valid_after_time = args[:valid_after_time] if args.key?(:valid_after_time) @valid_after_time = args[:valid_after_time] if args.key?(:valid_after_time)
@private_key_type = args[:private_key_type] if args.key?(:private_key_type)
end end
end end
@ -319,6 +441,54 @@ module Google
end end
end end
# Request message for `TestIamPermissions` method.
class TestIamPermissionsRequest
include Google::Apis::Core::Hashable
# The set of permissions to check for the `resource`. Permissions with
# wildcards (such as '*' or 'storage.*') are not allowed. For more
# information see
# [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
# Corresponds to the JSON property `permissions`
# @return [Array<String>]
attr_accessor :permissions
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@permissions = args[:permissions] if args.key?(:permissions)
end
end
# The service account sign blob response.
class SignBlobResponse
include Google::Apis::Core::Hashable
# The signed blob.
# Corresponds to the JSON property `signature`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String]
attr_accessor :signature
# The id of the key used to sign the blob.
# Corresponds to the JSON property `keyId`
# @return [String]
attr_accessor :key_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@signature = args[:signature] if args.key?(:signature)
@key_id = args[:key_id] if args.key?(:key_id)
end
end
# The service account sign JWT response. # The service account sign JWT response.
class SignJwtResponse class SignJwtResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -344,53 +514,6 @@ module Google
end end
end end
# The service account sign blob response.
class SignBlobResponse
include Google::Apis::Core::Hashable
# The signed blob.
# Corresponds to the JSON property `signature`
# @return [String]
attr_accessor :signature
# The id of the key used to sign the blob.
# Corresponds to the JSON property `keyId`
# @return [String]
attr_accessor :key_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@signature = args[:signature] if args.key?(:signature)
@key_id = args[:key_id] if args.key?(:key_id)
end
end
# Request message for `TestIamPermissions` method.
class TestIamPermissionsRequest
include Google::Apis::Core::Hashable
# The set of permissions to check for the `resource`. Permissions with
# wildcards (such as '*' or 'storage.*') are not allowed. For more
# information see
# [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
# Corresponds to the JSON property `permissions`
# @return [Array<String>]
attr_accessor :permissions
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@permissions = args[:permissions] if args.key?(:permissions)
end
end
# Defines an Identity and Access Management (IAM) policy. It is used to # Defines an Identity and Access Management (IAM) policy. It is used to
# specify access control policies for Cloud Platform resources. # specify access control policies for Cloud Platform resources.
# A `Policy` consists of a list of `bindings`. A `Binding` binds a list of # A `Policy` consists of a list of `bindings`. A `Binding` binds a list of
@ -420,11 +543,6 @@ module Google
class Policy class Policy
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Version of the `Policy`. The default version is 0.
# Corresponds to the JSON property `version`
# @return [Fixnum]
attr_accessor :version
# Associates a list of `members` to a `role`. # Associates a list of `members` to a `role`.
# Multiple `bindings` must not be specified for the same `role`. # Multiple `bindings` must not be specified for the same `role`.
# `bindings` with no members will result in an error. # `bindings` with no members will result in an error.
@ -442,18 +560,24 @@ module Google
# If no `etag` is provided in the call to `setIamPolicy`, then the existing # If no `etag` is provided in the call to `setIamPolicy`, then the existing
# policy is overwritten blindly. # policy is overwritten blindly.
# Corresponds to the JSON property `etag` # Corresponds to the JSON property `etag`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :etag attr_accessor :etag
# Version of the `Policy`. The default version is 0.
# Corresponds to the JSON property `version`
# @return [Fixnum]
attr_accessor :version
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@version = args[:version] if args.key?(:version)
@bindings = args[:bindings] if args.key?(:bindings) @bindings = args[:bindings] if args.key?(:bindings)
@etag = args[:etag] if args.key?(:etag) @etag = args[:etag] if args.key?(:etag)
@version = args[:version] if args.key?(:version)
end end
end end
@ -502,13 +626,6 @@ module Google
class BindingDelta class BindingDelta
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A single identity requesting access for a Cloud Platform resource.
# Follows the same format of Binding.members.
# Required
# Corresponds to the JSON property `member`
# @return [String]
attr_accessor :member
# Role that is assigned to `members`. # Role that is assigned to `members`.
# For example, `roles/viewer`, `roles/editor`, or `roles/owner`. # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
# Required # Required
@ -522,15 +639,22 @@ module Google
# @return [String] # @return [String]
attr_accessor :action attr_accessor :action
# A single identity requesting access for a Cloud Platform resource.
# Follows the same format of Binding.members.
# Required
# Corresponds to the JSON property `member`
# @return [String]
attr_accessor :member
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@member = args[:member] if args.key?(:member)
@role = args[:role] if args.key?(:role) @role = args[:role] if args.key?(:role)
@action = args[:action] if args.key?(:action) @action = args[:action] if args.key?(:action)
@member = args[:member] if args.key?(:member)
end end
end end
@ -553,6 +677,47 @@ module Google
end end
end end
# The service account create request.
class CreateServiceAccountRequest
include Google::Apis::Core::Hashable
# A service account in the Identity and Access Management API.
# To create a service account, specify the `project_id` and the `account_id`
# for the account. The `account_id` is unique within the project, and is used
# to generate the service account email address and a stable
# `unique_id`.
# If the account already exists, the account's resource name is returned
# in util::Status's ResourceInfo.resource_name in the format of
# projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL`. The caller can
# use the name in other methods to access the account.
# All other methods can identify the service account using the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Using `-` as a wildcard for the project will infer the project from
# the account. The `account` value can be the `email` address or the
# `unique_id` of the service account.
# Corresponds to the JSON property `serviceAccount`
# @return [Google::Apis::IamV1::ServiceAccount]
attr_accessor :service_account
# Required. The account id that is used to generate the service account
# email address and a stable unique id. It is unique within a project,
# must be 6-30 characters long, and match the regular expression
# `[a-z]([-a-z0-9]*[a-z0-9])` to comply with RFC1035.
# Corresponds to the JSON property `accountId`
# @return [String]
attr_accessor :account_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@service_account = args[:service_account] if args.key?(:service_account)
@account_id = args[:account_id] if args.key?(:account_id)
end
end
# The service account list response. # The service account list response.
class ListServiceAccountsResponse class ListServiceAccountsResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -579,165 +744,6 @@ module Google
@accounts = args[:accounts] if args.key?(:accounts) @accounts = args[:accounts] if args.key?(:accounts)
end end
end end
# The service account create request.
class CreateServiceAccountRequest
include Google::Apis::Core::Hashable
# Required. The account id that is used to generate the service account
# email address and a stable unique id. It is unique within a project,
# must be 6-30 characters long, and match the regular expression
# `[a-z]([-a-z0-9]*[a-z0-9])` to comply with RFC1035.
# Corresponds to the JSON property `accountId`
# @return [String]
attr_accessor :account_id
# A service account in the Identity and Access Management API.
# To create a service account, specify the `project_id` and the `account_id`
# for the account. The `account_id` is unique within the project, and is used
# to generate the service account email address and a stable
# `unique_id`.
# If the account already exists, the account's resource name is returned
# in util::Status's ResourceInfo.resource_name in the format of
# projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL`. The caller can
# use the name in other methods to access the account.
# All other methods can identify the service account using the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Using `-` as a wildcard for the project will infer the project from
# the account. The `account` value can be the `email` address or the
# `unique_id` of the service account.
# Corresponds to the JSON property `serviceAccount`
# @return [Google::Apis::IamV1::ServiceAccount]
attr_accessor :service_account
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@account_id = args[:account_id] if args.key?(:account_id)
@service_account = args[:service_account] if args.key?(:service_account)
end
end
# The grantable role query response.
class QueryGrantableRolesResponse
include Google::Apis::Core::Hashable
# The list of matching roles.
# Corresponds to the JSON property `roles`
# @return [Array<Google::Apis::IamV1::Role>]
attr_accessor :roles
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@roles = args[:roles] if args.key?(:roles)
end
end
# A role in the Identity and Access Management API.
class Role
include Google::Apis::Core::Hashable
# Optional. A human-readable title for the role. Typically this
# is limited to 100 UTF-8 bytes.
# Corresponds to the JSON property `title`
# @return [String]
attr_accessor :title
# The name of the role.
# When Role is used in CreateRole, the role name must not be set.
# When Role is used in output and other input such as UpdateRole, the role
# name is the complete path, e.g., roles/logging.viewer for curated roles
# and organizations/`ORGANIZATION_ID`/roles/logging.viewer for custom roles.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Optional. A human-readable description for the role.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@title = args[:title] if args.key?(:title)
@name = args[:name] if args.key?(:name)
@description = args[:description] if args.key?(:description)
end
end
# The service account sign blob request.
class SignBlobRequest
include Google::Apis::Core::Hashable
# The bytes to sign.
# Corresponds to the JSON property `bytesToSign`
# @return [String]
attr_accessor :bytes_to_sign
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@bytes_to_sign = args[:bytes_to_sign] if args.key?(:bytes_to_sign)
end
end
# Request message for `SetIamPolicy` method.
class SetIamPolicyRequest
include Google::Apis::Core::Hashable
# Defines an Identity and Access Management (IAM) policy. It is used to
# specify access control policies for Cloud Platform resources.
# A `Policy` consists of a list of `bindings`. A `Binding` binds a list of
# `members` to a `role`, where the members can be user accounts, Google groups,
# Google domains, and service accounts. A `role` is a named list of permissions
# defined by IAM.
# **Example**
# `
# "bindings": [
# `
# "role": "roles/owner",
# "members": [
# "user:mike@example.com",
# "group:admins@example.com",
# "domain:google.com",
# "serviceAccount:my-other-app@appspot.gserviceaccount.com",
# ]
# `,
# `
# "role": "roles/viewer",
# "members": ["user:sean@example.com"]
# `
# ]
# `
# For a description of IAM and its features, see the
# [IAM developer's guide](https://cloud.google.com/iam).
# Corresponds to the JSON property `policy`
# @return [Google::Apis::IamV1::Policy]
attr_accessor :policy
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@policy = args[:policy] if args.key?(:policy)
end
end
end end
end end
end end

View File

@ -22,13 +22,37 @@ module Google
module Apis module Apis
module IamV1 module IamV1
class QueryGrantableRolesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SignBlobRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Role
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SetIamPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Binding class Binding
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ServiceAccount class QueryGrantableRolesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -40,7 +64,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class QueryGrantableRolesRequest class ServiceAccount
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -70,7 +94,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class SignJwtResponse class TestIamPermissionsRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -82,7 +106,7 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class TestIamPermissionsRequest class SignJwtResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -118,40 +142,48 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListServiceAccountsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CreateServiceAccountRequest class CreateServiceAccountRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class QueryGrantableRolesResponse class ListServiceAccountsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Role class QueryGrantableRolesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :roles, as: 'roles', class: Google::Apis::IamV1::Role, decorator: Google::Apis::IamV1::Role::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class SignBlobRequest class SignBlobRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :bytes_to_sign, :base64 => true, as: 'bytesToSign'
end
end
include Google::Apis::Core::JsonObjectSupport class Role
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :title, as: 'title'
property :name, as: 'name'
property :description, as: 'description'
end
end end
class SetIamPolicyRequest class SetIamPolicyRequest
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
property :policy, as: 'policy', class: Google::Apis::IamV1::Policy, decorator: Google::Apis::IamV1::Policy::Representation
include Google::Apis::Core::JsonObjectSupport end
end end
class Binding class Binding
@ -162,16 +194,10 @@ module Google
end end
end end
class ServiceAccount class QueryGrantableRolesRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name' property :full_resource_name, as: 'fullResourceName'
property :email, as: 'email'
property :project_id, as: 'projectId'
property :unique_id, as: 'uniqueId'
property :oauth2_client_id, as: 'oauth2ClientId'
property :display_name, as: 'displayName'
property :etag, :base64 => true, as: 'etag'
end end
end end
@ -181,10 +207,16 @@ module Google
end end
end end
class QueryGrantableRolesRequest class ServiceAccount
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :full_resource_name, as: 'fullResourceName' property :project_id, as: 'projectId'
property :oauth2_client_id, as: 'oauth2ClientId'
property :unique_id, as: 'uniqueId'
property :display_name, as: 'displayName'
property :etag, :base64 => true, as: 'etag'
property :email, as: 'email'
property :name, as: 'name'
end end
end end
@ -211,8 +243,8 @@ module Google
property :name, as: 'name' property :name, as: 'name'
property :valid_before_time, as: 'validBeforeTime' property :valid_before_time, as: 'validBeforeTime'
property :key_algorithm, as: 'keyAlgorithm' property :key_algorithm, as: 'keyAlgorithm'
property :private_key_type, as: 'privateKeyType'
property :valid_after_time, as: 'validAfterTime' property :valid_after_time, as: 'validAfterTime'
property :private_key_type, as: 'privateKeyType'
end end
end end
@ -224,11 +256,10 @@ module Google
end end
end end
class SignJwtResponse class TestIamPermissionsRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :key_id, as: 'keyId' collection :permissions, as: 'permissions'
property :signed_jwt, as: 'signedJwt'
end end
end end
@ -240,20 +271,21 @@ module Google
end end
end end
class TestIamPermissionsRequest class SignJwtResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :permissions, as: 'permissions' property :key_id, as: 'keyId'
property :signed_jwt, as: 'signedJwt'
end end
end end
class Policy class Policy
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :version, as: 'version'
collection :bindings, as: 'bindings', class: Google::Apis::IamV1::Binding, decorator: Google::Apis::IamV1::Binding::Representation collection :bindings, as: 'bindings', class: Google::Apis::IamV1::Binding, decorator: Google::Apis::IamV1::Binding::Representation
property :etag, :base64 => true, as: 'etag' property :etag, :base64 => true, as: 'etag'
property :version, as: 'version'
end end
end end
@ -275,9 +307,9 @@ module Google
class BindingDelta class BindingDelta
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :member, as: 'member'
property :role, as: 'role' property :role, as: 'role'
property :action, as: 'action' property :action, as: 'action'
property :member, as: 'member'
end end
end end
@ -289,6 +321,15 @@ module Google
end end
end end
class CreateServiceAccountRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :service_account, as: 'serviceAccount', class: Google::Apis::IamV1::ServiceAccount, decorator: Google::Apis::IamV1::ServiceAccount::Representation
property :account_id, as: 'accountId'
end
end
class ListServiceAccountsResponse class ListServiceAccountsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -297,47 +338,6 @@ module Google
end end
end end
class CreateServiceAccountRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :account_id, as: 'accountId'
property :service_account, as: 'serviceAccount', class: Google::Apis::IamV1::ServiceAccount, decorator: Google::Apis::IamV1::ServiceAccount::Representation
end
end
class QueryGrantableRolesResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :roles, as: 'roles', class: Google::Apis::IamV1::Role, decorator: Google::Apis::IamV1::Role::Representation
end
end
class Role
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :title, as: 'title'
property :name, as: 'name'
property :description, as: 'description'
end
end
class SignBlobRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :bytes_to_sign, :base64 => true, as: 'bytesToSign'
end
end
class SetIamPolicyRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :policy, as: 'policy', class: Google::Apis::IamV1::Policy, decorator: Google::Apis::IamV1::Policy::Representation
end
end
end end
end end
end end

View File

@ -48,82 +48,6 @@ module Google
super('https://iam.googleapis.com/', '') super('https://iam.googleapis.com/', '')
end end
# Gets a ServiceAccount.
# @param [String] name
# The resource name of the service account in the following format:
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Using `-` as a wildcard for the project will infer the project from
# the account. The `account` value can be the `email` address or the
# `unique_id` of the service account.
# @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::IamV1::ServiceAccount] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::IamV1::ServiceAccount]
#
# @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_service_account(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.response_class = Google::Apis::IamV1::ServiceAccount
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
# Updates a ServiceAccount.
# Currently, only the following fields are updatable:
# `display_name` .
# The `etag` is mandatory.
# @param [String] name
# The resource name of the service account in the following format:
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Requests using `-` as a wildcard for the project will infer the project
# from the `account` and the `account` value can be the `email` address or
# the `unique_id` of the service account.
# In responses the resource name will always be in the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# @param [Google::Apis::IamV1::ServiceAccount] service_account_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::IamV1::ServiceAccount] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::IamV1::ServiceAccount]
#
# @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 update_project_service_account(name, service_account_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:put, 'v1/{+name}', options)
command.request_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.request_object = service_account_object
command.response_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.response_class = Google::Apis::IamV1::ServiceAccount
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
# Tests the specified permissions against the IAM access control policy # Tests the specified permissions against the IAM access control policy
# for a ServiceAccount. # for a ServiceAccount.
# @param [String] resource # @param [String] resource
@ -193,47 +117,6 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Lists ServiceAccounts for a project.
# @param [String] name
# Required. The resource name of the project associated with the service
# accounts, such as `projects/my-project-123`.
# @param [String] page_token
# Optional pagination token returned in an earlier
# ListServiceAccountsResponse.next_page_token.
# @param [Fixnum] page_size
# Optional limit on the number of service accounts to include in the
# response. Further accounts can subsequently be obtained by including the
# ListServiceAccountsResponse.next_page_token
# in a subsequent request.
# @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::IamV1::ListServiceAccountsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::IamV1::ListServiceAccountsResponse]
#
# @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 list_project_service_accounts(name, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}/serviceAccounts', options)
command.response_representation = Google::Apis::IamV1::ListServiceAccountsResponse::Representation
command.response_class = Google::Apis::IamV1::ListServiceAccountsResponse
command.params['name'] = name unless name.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Signs a blob using a service account's system-managed private key. # Signs a blob using a service account's system-managed private key.
# @param [String] name # @param [String] name
# The resource name of the service account in the following format: # The resource name of the service account in the following format:
@ -271,12 +154,18 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Creates a ServiceAccount # Lists ServiceAccounts for a project.
# and returns it.
# @param [String] name # @param [String] name
# Required. The resource name of the project associated with the service # Required. The resource name of the project associated with the service
# accounts, such as `projects/my-project-123`. # accounts, such as `projects/my-project-123`.
# @param [Google::Apis::IamV1::CreateServiceAccountRequest] create_service_account_request_object # @param [Fixnum] page_size
# Optional limit on the number of service accounts to include in the
# response. Further accounts can subsequently be obtained by including the
# ListServiceAccountsResponse.next_page_token
# in a subsequent request.
# @param [String] page_token
# Optional pagination token returned in an earlier
# ListServiceAccountsResponse.next_page_token.
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
@ -286,21 +175,21 @@ module Google
# Request-specific options # Request-specific options
# #
# @yield [result, err] Result & error if block supplied # @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::IamV1::ServiceAccount] parsed result object # @yieldparam result [Google::Apis::IamV1::ListServiceAccountsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed # @yieldparam err [StandardError] error object if request failed
# #
# @return [Google::Apis::IamV1::ServiceAccount] # @return [Google::Apis::IamV1::ListServiceAccountsResponse]
# #
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def create_service_account(name, create_service_account_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) def list_project_service_accounts(name, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}/serviceAccounts', options) command = make_simple_command(:get, 'v1/{+name}/serviceAccounts', options)
command.request_representation = Google::Apis::IamV1::CreateServiceAccountRequest::Representation command.response_representation = Google::Apis::IamV1::ListServiceAccountsResponse::Representation
command.request_object = create_service_account_request_object command.response_class = Google::Apis::IamV1::ListServiceAccountsResponse
command.response_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.response_class = Google::Apis::IamV1::ServiceAccount
command.params['name'] = name unless name.nil? command.params['name'] = name unless name.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -381,6 +270,41 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Creates a ServiceAccount
# and returns it.
# @param [String] name
# Required. The resource name of the project associated with the service
# accounts, such as `projects/my-project-123`.
# @param [Google::Apis::IamV1::CreateServiceAccountRequest] create_service_account_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::IamV1::ServiceAccount] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::IamV1::ServiceAccount]
#
# @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 create_service_account(name, create_service_account_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}/serviceAccounts', options)
command.request_representation = Google::Apis::IamV1::CreateServiceAccountRequest::Representation
command.request_object = create_service_account_request_object
command.response_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.response_class = Google::Apis::IamV1::ServiceAccount
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
# Returns the IAM access control policy for a # Returns the IAM access control policy for a
# ServiceAccount. # ServiceAccount.
# @param [String] resource # @param [String] resource
@ -413,6 +337,82 @@ module Google
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Gets a ServiceAccount.
# @param [String] name
# The resource name of the service account in the following format:
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Using `-` as a wildcard for the project will infer the project from
# the account. The `account` value can be the `email` address or the
# `unique_id` of the service account.
# @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::IamV1::ServiceAccount] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::IamV1::ServiceAccount]
#
# @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_service_account(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.response_class = Google::Apis::IamV1::ServiceAccount
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
# Updates a ServiceAccount.
# Currently, only the following fields are updatable:
# `display_name` .
# The `etag` is mandatory.
# @param [String] name
# The resource name of the service account in the following format:
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# Requests using `-` as a wildcard for the project will infer the project
# from the `account` and the `account` value can be the `email` address or
# the `unique_id` of the service account.
# In responses the resource name will always be in the format
# `projects/`PROJECT_ID`/serviceAccounts/`SERVICE_ACCOUNT_EMAIL``.
# @param [Google::Apis::IamV1::ServiceAccount] service_account_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::IamV1::ServiceAccount] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::IamV1::ServiceAccount]
#
# @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 update_project_service_account(name, service_account_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:put, 'v1/{+name}', options)
command.request_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.request_object = service_account_object
command.response_representation = Google::Apis::IamV1::ServiceAccount::Representation
command.response_class = Google::Apis::IamV1::ServiceAccount
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
# Deletes a ServiceAccountKey. # Deletes a ServiceAccountKey.
# @param [String] name # @param [String] name
# The resource name of the service account key in the following format: # The resource name of the service account key in the following format:

View File

@ -1018,6 +1018,7 @@ module Google
# The salt separator. # The salt separator.
# Corresponds to the JSON property `saltSeparator` # Corresponds to the JSON property `saltSeparator`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :salt_separator attr_accessor :salt_separator
@ -1030,6 +1031,7 @@ module Google
# The key for to hash the password. # The key for to hash the password.
# Corresponds to the JSON property `signerKey` # Corresponds to the JSON property `signerKey`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :signer_key attr_accessor :signer_key
@ -1503,6 +1505,7 @@ module Google
# The user's hashed password. # The user's hashed password.
# Corresponds to the JSON property `passwordHash` # Corresponds to the JSON property `passwordHash`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :password_hash attr_accessor :password_hash
@ -1736,6 +1739,7 @@ module Google
# The user's hashed password. # The user's hashed password.
# Corresponds to the JSON property `passwordHash` # Corresponds to the JSON property `passwordHash`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :password_hash attr_accessor :password_hash
@ -1761,6 +1765,7 @@ module Google
# The user's password salt. # The user's password salt.
# Corresponds to the JSON property `salt` # Corresponds to the JSON property `salt`
# NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
attr_accessor :salt attr_accessor :salt

View File

@ -27,6 +27,11 @@ module Google
class SearchResponse class SearchResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The schema type of top-level JSON-LD object, e.g. ItemList.
# Corresponds to the JSON property `@type`
# @return [Object]
attr_accessor :_type
# The local context applicable for the response. See more details at # The local context applicable for the response. See more details at
# http://www.w3.org/TR/json-ld/#context-definitions. # http://www.w3.org/TR/json-ld/#context-definitions.
# Corresponds to the JSON property `@context` # Corresponds to the JSON property `@context`
@ -38,20 +43,15 @@ module Google
# @return [Array<Object>] # @return [Array<Object>]
attr_accessor :item_list_element attr_accessor :item_list_element
# The schema type of top-level JSON-LD object, e.g. ItemList.
# Corresponds to the JSON property `@type`
# @return [Object]
attr_accessor :_type
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@_type = args[:_type] if args.key?(:_type)
@_context = args[:_context] if args.key?(:_context) @_context = args[:_context] if args.key?(:_context)
@item_list_element = args[:item_list_element] if args.key?(:item_list_element) @item_list_element = args[:item_list_element] if args.key?(:item_list_element)
@_type = args[:_type] if args.key?(:_type)
end end
end end
end end

View File

@ -31,9 +31,9 @@ module Google
class SearchResponse class SearchResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :_type, as: '@type'
property :_context, as: '@context' property :_context, as: '@context'
collection :item_list_element, as: 'itemListElement' collection :item_list_element, as: 'itemListElement'
property :_type, as: '@type'
end end
end end
end end

View File

@ -32,16 +32,16 @@ module Google
# #
# @see https://developers.google.com/knowledge-graph/ # @see https://developers.google.com/knowledge-graph/
class KgsearchService < Google::Apis::Core::BaseService class KgsearchService < Google::Apis::Core::BaseService
# @return [String]
# 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] # @return [String]
# API key. Your API key identifies your project and provides you with API access, # 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. # quota, and reports. Required unless you provide an OAuth 2.0 token.
attr_accessor :key attr_accessor :key
# @return [String]
# 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
def initialize def initialize
super('https://kgsearch.googleapis.com/', '') super('https://kgsearch.googleapis.com/', '')
end end
@ -49,14 +49,6 @@ module Google
# Searches Knowledge Graph for entities that match the constraints. # Searches Knowledge Graph for entities that match the constraints.
# A list of matched entities will be returned in response, which will be in # A list of matched entities will be returned in response, which will be in
# JSON-LD format and compatible with http://schema.org # JSON-LD format and compatible with http://schema.org
# @param [Boolean] prefix
# Enables prefix match against names and aliases of entities
# @param [String] query
# The literal query string for search.
# @param [Array<String>, String] types
# Restricts returned entities with these types, e.g. Person
# (as defined in http://schema.org/Person). If multiple types are specified,
# returned entities will contain one or more of these types.
# @param [Boolean] indent # @param [Boolean] indent
# Enables indenting of json results. # Enables indenting of json results.
# @param [Array<String>, String] languages # @param [Array<String>, String] languages
@ -68,6 +60,14 @@ module Google
# URL as in ...?ids=A&ids=B # URL as in ...?ids=A&ids=B
# @param [Fixnum] limit # @param [Fixnum] limit
# Limits the number of entities to be returned. # Limits the number of entities to be returned.
# @param [Boolean] prefix
# Enables prefix match against names and aliases of entities
# @param [String] query
# The literal query string for search.
# @param [Array<String>, String] types
# Restricts returned entities with these types, e.g. Person
# (as defined in http://schema.org/Person). If multiple types are specified,
# returned entities will contain one or more of these types.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
@ -85,17 +85,17 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def search_entities(prefix: nil, query: nil, types: nil, indent: nil, languages: nil, ids: nil, limit: nil, quota_user: nil, fields: nil, options: nil, &block) def search_entities(indent: nil, languages: nil, ids: nil, limit: nil, prefix: nil, query: nil, types: nil, quota_user: nil, fields: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/entities:search', options) command = make_simple_command(:get, 'v1/entities:search', options)
command.response_representation = Google::Apis::KgsearchV1::SearchResponse::Representation command.response_representation = Google::Apis::KgsearchV1::SearchResponse::Representation
command.response_class = Google::Apis::KgsearchV1::SearchResponse command.response_class = Google::Apis::KgsearchV1::SearchResponse
command.query['prefix'] = prefix unless prefix.nil?
command.query['query'] = query unless query.nil?
command.query['types'] = types unless types.nil?
command.query['indent'] = indent unless indent.nil? command.query['indent'] = indent unless indent.nil?
command.query['languages'] = languages unless languages.nil? command.query['languages'] = languages unless languages.nil?
command.query['ids'] = ids unless ids.nil? command.query['ids'] = ids unless ids.nil?
command.query['limit'] = limit unless limit.nil? command.query['limit'] = limit unless limit.nil?
command.query['prefix'] = prefix unless prefix.nil?
command.query['query'] = query unless query.nil?
command.query['types'] = types unless types.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
@ -104,8 +104,8 @@ module Google
protected protected
def apply_command_defaults(command) def apply_command_defaults(command)
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['key'] = key unless key.nil? command.query['key'] = key unless key.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
end end
end end
end end

View File

@ -22,23 +22,99 @@ module Google
module Apis module Apis
module LanguageV1 module LanguageV1
# The syntax analysis request message.
class AnalyzeSyntaxRequest
include Google::Apis::Core::Hashable
# The encoding type used by the API to calculate offsets.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
# ################################################################ #
# Represents the input to API methods.
# Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1::Document]
attr_accessor :document
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@document = args[:document] if args.key?(:document)
end
end
# The sentiment analysis response message.
class AnalyzeSentimentResponse
include Google::Apis::Core::Hashable
# Represents the feeling associated with the entire text or entities in
# the text.
# Corresponds to the JSON property `documentSentiment`
# @return [Google::Apis::LanguageV1::Sentiment]
attr_accessor :document_sentiment
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See `Document.language` field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# The sentiment for all the sentences in the document.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1::Sentence>]
attr_accessor :sentences
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
@language = args[:language] if args.key?(:language)
@sentences = args[:sentences] if args.key?(:sentences)
end
end
# The entity analysis response message.
class AnalyzeEntitiesResponse
include Google::Apis::Core::Hashable
# The recognized entities in the input document.
# Corresponds to the JSON property `entities`
# @return [Array<Google::Apis::LanguageV1::Entity>]
attr_accessor :entities
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See `Document.language` field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@entities = args[:entities] if args.key?(:entities)
@language = args[:language] if args.key?(:language)
end
end
# Represents a phrase in the text that is a known entity, such as # Represents a phrase in the text that is a known entity, such as
# a person, an organization, or location. The API associates information, such # a person, an organization, or location. The API associates information, such
# as salience and mentions, with entities. # as salience and mentions, with entities.
class Entity class Entity
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The mentions of this entity in the input document. The API currently
# supports proper noun mentions.
# Corresponds to the JSON property `mentions`
# @return [Array<Google::Apis::LanguageV1::EntityMention>]
attr_accessor :mentions
# The representative name for the entity.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The entity type. # The entity type.
# Corresponds to the JSON property `type` # Corresponds to the JSON property `type`
# @return [String] # @return [String]
@ -60,17 +136,28 @@ module Google
# @return [Float] # @return [Float]
attr_accessor :salience attr_accessor :salience
# The mentions of this entity in the input document. The API currently
# supports proper noun mentions.
# Corresponds to the JSON property `mentions`
# @return [Array<Google::Apis::LanguageV1::EntityMention>]
attr_accessor :mentions
# The representative name for the entity.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@mentions = args[:mentions] if args.key?(:mentions)
@name = args[:name] if args.key?(:name)
@type = args[:type] if args.key?(:type) @type = args[:type] if args.key?(:type)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@salience = args[:salience] if args.key?(:salience) @salience = args[:salience] if args.key?(:salience)
@mentions = args[:mentions] if args.key?(:mentions)
@name = args[:name] if args.key?(:name)
end end
end end
@ -141,6 +228,57 @@ module Google
end end
end end
# The text annotations response message.
class AnnotateTextResponse
include Google::Apis::Core::Hashable
# Represents the feeling associated with the entire text or entities in
# the text.
# Corresponds to the JSON property `documentSentiment`
# @return [Google::Apis::LanguageV1::Sentiment]
attr_accessor :document_sentiment
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See `Document.language` field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# Sentences in the input document. Populated if the user enables
# AnnotateTextRequest.Features.extract_syntax.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1::Sentence>]
attr_accessor :sentences
# Tokens, along with their syntactic information, in the input document.
# Populated if the user enables
# AnnotateTextRequest.Features.extract_syntax.
# Corresponds to the JSON property `tokens`
# @return [Array<Google::Apis::LanguageV1::Token>]
attr_accessor :tokens
# Entities, along with their semantic information, in the input document.
# Populated if the user enables
# AnnotateTextRequest.Features.extract_entities.
# Corresponds to the JSON property `entities`
# @return [Array<Google::Apis::LanguageV1::Entity>]
attr_accessor :entities
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
@language = args[:language] if args.key?(:language)
@sentences = args[:sentences] if args.key?(:sentences)
@tokens = args[:tokens] if args.key?(:tokens)
@entities = args[:entities] if args.key?(:entities)
end
end
# The sentiment analysis request message. # The sentiment analysis request message.
class AnalyzeSentimentRequest class AnalyzeSentimentRequest
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -167,68 +305,12 @@ module Google
end end
end end
# The text annotations response message.
class AnnotateTextResponse
include Google::Apis::Core::Hashable
# Sentences in the input document. Populated if the user enables
# AnnotateTextRequest.Features.extract_syntax.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1::Sentence>]
attr_accessor :sentences
# Tokens, along with their syntactic information, in the input document.
# Populated if the user enables
# AnnotateTextRequest.Features.extract_syntax.
# Corresponds to the JSON property `tokens`
# @return [Array<Google::Apis::LanguageV1::Token>]
attr_accessor :tokens
# Entities, along with their semantic information, in the input document.
# Populated if the user enables
# AnnotateTextRequest.Features.extract_entities.
# Corresponds to the JSON property `entities`
# @return [Array<Google::Apis::LanguageV1::Entity>]
attr_accessor :entities
# Represents the feeling associated with the entire text or entities in
# the text.
# Corresponds to the JSON property `documentSentiment`
# @return [Google::Apis::LanguageV1::Sentiment]
attr_accessor :document_sentiment
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See `Document.language` field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@sentences = args[:sentences] if args.key?(:sentences)
@tokens = args[:tokens] if args.key?(:tokens)
@entities = args[:entities] if args.key?(:entities)
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
@language = args[:language] if args.key?(:language)
end
end
# Represents dependency parse tree information for a token. (For more # Represents dependency parse tree information for a token. (For more
# information on dependency labels, see # information on dependency labels, see
# http://www.aclweb.org/anthology/P13-2017 # http://www.aclweb.org/anthology/P13-2017
class DependencyEdge class DependencyEdge
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The parse label for the token.
# Corresponds to the JSON property `label`
# @return [String]
attr_accessor :label
# Represents the head of this token in the dependency tree. # Represents the head of this token in the dependency tree.
# This is the index of the token which has an arc going to this token. # This is the index of the token which has an arc going to this token.
# The index is the position of the token in the array of tokens returned # The index is the position of the token in the array of tokens returned
@ -238,14 +320,60 @@ module Google
# @return [Fixnum] # @return [Fixnum]
attr_accessor :head_token_index attr_accessor :head_token_index
# The parse label for the token.
# Corresponds to the JSON property `label`
# @return [String]
attr_accessor :label
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@label = args[:label] if args.key?(:label)
@head_token_index = args[:head_token_index] if args.key?(:head_token_index) @head_token_index = args[:head_token_index] if args.key?(:head_token_index)
@label = args[:label] if args.key?(:label)
end
end
# Represents the smallest syntactic building block of the text.
class Token
include Google::Apis::Core::Hashable
# Represents an output piece of text.
# Corresponds to the JSON property `text`
# @return [Google::Apis::LanguageV1::TextSpan]
attr_accessor :text
# Represents dependency parse tree information for a token. (For more
# information on dependency labels, see
# http://www.aclweb.org/anthology/P13-2017
# Corresponds to the JSON property `dependencyEdge`
# @return [Google::Apis::LanguageV1::DependencyEdge]
attr_accessor :dependency_edge
# [Lemma](https://en.wikipedia.org/wiki/Lemma_%28morphology%29) of the token.
# Corresponds to the JSON property `lemma`
# @return [String]
attr_accessor :lemma
# Represents part of speech information for a token. Parts of speech
# are as defined in
# http://www.lrec-conf.org/proceedings/lrec2012/pdf/274_Paper.pdf
# Corresponds to the JSON property `partOfSpeech`
# @return [Google::Apis::LanguageV1::PartOfSpeech]
attr_accessor :part_of_speech
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@text = args[:text] if args.key?(:text)
@dependency_edge = args[:dependency_edge] if args.key?(:dependency_edge)
@lemma = args[:lemma] if args.key?(:lemma)
@part_of_speech = args[:part_of_speech] if args.key?(:part_of_speech)
end end
end end
@ -275,47 +403,6 @@ module Google
end end
end end
# Represents the smallest syntactic building block of the text.
class Token
include Google::Apis::Core::Hashable
# Represents part of speech information for a token. Parts of speech
# are as defined in
# http://www.lrec-conf.org/proceedings/lrec2012/pdf/274_Paper.pdf
# Corresponds to the JSON property `partOfSpeech`
# @return [Google::Apis::LanguageV1::PartOfSpeech]
attr_accessor :part_of_speech
# Represents an output piece of text.
# Corresponds to the JSON property `text`
# @return [Google::Apis::LanguageV1::TextSpan]
attr_accessor :text
# Represents dependency parse tree information for a token. (For more
# information on dependency labels, see
# http://www.aclweb.org/anthology/P13-2017
# Corresponds to the JSON property `dependencyEdge`
# @return [Google::Apis::LanguageV1::DependencyEdge]
attr_accessor :dependency_edge
# [Lemma](https://en.wikipedia.org/wiki/Lemma_%28morphology%29) of the token.
# Corresponds to the JSON property `lemma`
# @return [String]
attr_accessor :lemma
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@part_of_speech = args[:part_of_speech] if args.key?(:part_of_speech)
@text = args[:text] if args.key?(:text)
@dependency_edge = args[:dependency_edge] if args.key?(:dependency_edge)
@lemma = args[:lemma] if args.key?(:lemma)
end
end
# The `Status` type defines a logical error model that is suitable for different # 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 # programming environments, including REST APIs and RPC APIs. It is used by
# [gRPC](https://github.com/grpc). The error model is designed to be: # [gRPC](https://github.com/grpc). The error model is designed to be:
@ -358,12 +445,6 @@ module Google
class Status class Status
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# A list of messages that carry the error details. There will be a
# common set of message types for APIs to use.
# Corresponds to the JSON property `details`
# @return [Array<Hash<String,Object>>]
attr_accessor :details
# The status code, which should be an enum value of google.rpc.Code. # The status code, which should be an enum value of google.rpc.Code.
# Corresponds to the JSON property `code` # Corresponds to the JSON property `code`
# @return [Fixnum] # @return [Fixnum]
@ -376,50 +457,21 @@ module Google
# @return [String] # @return [String]
attr_accessor :message attr_accessor :message
# A list of messages that carry the error details. There will be a
# common set of message types for APIs to use.
# Corresponds to the JSON property `details`
# @return [Array<Hash<String,Object>>]
attr_accessor :details
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@details = args[:details] if args.key?(:details)
@code = args[:code] if args.key?(:code) @code = args[:code] if args.key?(:code)
@message = args[:message] if args.key?(:message) @message = args[:message] if args.key?(:message)
end @details = args[:details] if args.key?(:details)
end
# All available features for sentiment, syntax, and semantic analysis.
# Setting each one to true will enable that specific analysis for the input.
class Features
include Google::Apis::Core::Hashable
# Extract entities.
# Corresponds to the JSON property `extractEntities`
# @return [Boolean]
attr_accessor :extract_entities
alias_method :extract_entities?, :extract_entities
# Extract syntax information.
# Corresponds to the JSON property `extractSyntax`
# @return [Boolean]
attr_accessor :extract_syntax
alias_method :extract_syntax?, :extract_syntax
# Extract document-level sentiment.
# Corresponds to the JSON property `extractDocumentSentiment`
# @return [Boolean]
attr_accessor :extract_document_sentiment
alias_method :extract_document_sentiment?, :extract_document_sentiment
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@extract_entities = args[:extract_entities] if args.key?(:extract_entities)
@extract_syntax = args[:extract_syntax] if args.key?(:extract_syntax)
@extract_document_sentiment = args[:extract_document_sentiment] if args.key?(:extract_document_sentiment)
end end
end end
@ -449,6 +501,90 @@ module Google
end end
end end
# All available features for sentiment, syntax, and semantic analysis.
# Setting each one to true will enable that specific analysis for the input.
class Features
include Google::Apis::Core::Hashable
# Extract syntax information.
# Corresponds to the JSON property `extractSyntax`
# @return [Boolean]
attr_accessor :extract_syntax
alias_method :extract_syntax?, :extract_syntax
# Extract document-level sentiment.
# Corresponds to the JSON property `extractDocumentSentiment`
# @return [Boolean]
attr_accessor :extract_document_sentiment
alias_method :extract_document_sentiment?, :extract_document_sentiment
# Extract entities.
# Corresponds to the JSON property `extractEntities`
# @return [Boolean]
attr_accessor :extract_entities
alias_method :extract_entities?, :extract_entities
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@extract_syntax = args[:extract_syntax] if args.key?(:extract_syntax)
@extract_document_sentiment = args[:extract_document_sentiment] if args.key?(:extract_document_sentiment)
@extract_entities = args[:extract_entities] if args.key?(:extract_entities)
end
end
# ################################################################ #
# Represents the input to API methods.
class Document
include Google::Apis::Core::Hashable
# Required. If the type is not set or is `TYPE_UNSPECIFIED`,
# returns an `INVALID_ARGUMENT` error.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
# The content of the input in string format.
# Corresponds to the JSON property `content`
# @return [String]
attr_accessor :content
# The Google Cloud Storage URI where the file content is located.
# This URI must be of the form: gs://bucket_name/object_name. For more
# details, see https://cloud.google.com/storage/docs/reference-uris.
# NOTE: Cloud Storage object versioning is not supported.
# Corresponds to the JSON property `gcsContentUri`
# @return [String]
attr_accessor :gcs_content_uri
# The language of the document (if not specified, the language is
# automatically detected). Both ISO and BCP-47 language codes are
# accepted.<br>
# **Current Language Restrictions:**
# * Only English, Spanish, and Japanese textual content are supported.
# If the language (either specified by the caller or automatically detected)
# is not supported by the called API method, an `INVALID_ARGUMENT` error
# is returned.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@type = args[:type] if args.key?(:type)
@content = args[:content] if args.key?(:content)
@gcs_content_uri = args[:gcs_content_uri] if args.key?(:gcs_content_uri)
@language = args[:language] if args.key?(:language)
end
end
# Represents a sentence in the input document. # Represents a sentence in the input document.
class Sentence class Sentence
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -475,41 +611,20 @@ module Google
end end
end end
# ################################################################ # # The entity analysis request message.
# Represents the input to API methods. class AnalyzeEntitiesRequest
class Document
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The language of the document (if not specified, the language is # ################################################################ #
# automatically detected). Both ISO and BCP-47 language codes are # Represents the input to API methods.
# accepted.<br> # Corresponds to the JSON property `document`
# **Current Language Restrictions:** # @return [Google::Apis::LanguageV1::Document]
# * Only English, Spanish, and Japanese textual content are supported. attr_accessor :document
# If the language (either specified by the caller or automatically detected)
# is not supported by the called API method, an `INVALID_ARGUMENT` error
# is returned.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# Required. If the type is not set or is `TYPE_UNSPECIFIED`, # The encoding type used by the API to calculate offsets.
# returns an `INVALID_ARGUMENT` error. # Corresponds to the JSON property `encodingType`
# Corresponds to the JSON property `type`
# @return [String] # @return [String]
attr_accessor :type attr_accessor :encoding_type
# The content of the input in string format.
# Corresponds to the JSON property `content`
# @return [String]
attr_accessor :content
# The Google Cloud Storage URI where the file content is located.
# This URI must be of the form: gs://bucket_name/object_name. For more
# details, see https://cloud.google.com/storage/docs/reference-uris.
# NOTE: Cloud Storage object versioning is not supported.
# Corresponds to the JSON property `gcsContentUri`
# @return [String]
attr_accessor :gcs_content_uri
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -517,10 +632,8 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@language = args[:language] if args.key?(:language) @document = args[:document] if args.key?(:document)
@type = args[:type] if args.key?(:type) @encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@content = args[:content] if args.key?(:content)
@gcs_content_uri = args[:gcs_content_uri] if args.key?(:gcs_content_uri)
end end
end end
@ -553,53 +666,12 @@ module Google
end end
end end
# The entity analysis request message.
class AnalyzeEntitiesRequest
include Google::Apis::Core::Hashable
# The encoding type used by the API to calculate offsets.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
# ################################################################ #
# Represents the input to API methods.
# Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1::Document]
attr_accessor :document
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@document = args[:document] if args.key?(:document)
end
end
# Represents part of speech information for a token. Parts of speech # Represents part of speech information for a token. Parts of speech
# are as defined in # are as defined in
# http://www.lrec-conf.org/proceedings/lrec2012/pdf/274_Paper.pdf # http://www.lrec-conf.org/proceedings/lrec2012/pdf/274_Paper.pdf
class PartOfSpeech class PartOfSpeech
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The grammatical case.
# Corresponds to the JSON property `case`
# @return [String]
attr_accessor :case
# The grammatical tense.
# Corresponds to the JSON property `tense`
# @return [String]
attr_accessor :tense
# The grammatical reciprocity.
# Corresponds to the JSON property `reciprocity`
# @return [String]
attr_accessor :reciprocity
# The grammatical form. # The grammatical form.
# Corresponds to the JSON property `form` # Corresponds to the JSON property `form`
# @return [String] # @return [String]
@ -645,15 +717,27 @@ module Google
# @return [String] # @return [String]
attr_accessor :proper attr_accessor :proper
# The grammatical case.
# Corresponds to the JSON property `case`
# @return [String]
attr_accessor :case
# The grammatical tense.
# Corresponds to the JSON property `tense`
# @return [String]
attr_accessor :tense
# The grammatical reciprocity.
# Corresponds to the JSON property `reciprocity`
# @return [String]
attr_accessor :reciprocity
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@case = args[:case] if args.key?(:case)
@tense = args[:tense] if args.key?(:tense)
@reciprocity = args[:reciprocity] if args.key?(:reciprocity)
@form = args[:form] if args.key?(:form) @form = args[:form] if args.key?(:form)
@number = args[:number] if args.key?(:number) @number = args[:number] if args.key?(:number)
@voice = args[:voice] if args.key?(:voice) @voice = args[:voice] if args.key?(:voice)
@ -663,93 +747,9 @@ module Google
@gender = args[:gender] if args.key?(:gender) @gender = args[:gender] if args.key?(:gender)
@person = args[:person] if args.key?(:person) @person = args[:person] if args.key?(:person)
@proper = args[:proper] if args.key?(:proper) @proper = args[:proper] if args.key?(:proper)
end @case = args[:case] if args.key?(:case)
end @tense = args[:tense] if args.key?(:tense)
@reciprocity = args[:reciprocity] if args.key?(:reciprocity)
# The syntax analysis request message.
class AnalyzeSyntaxRequest
include Google::Apis::Core::Hashable
# The encoding type used by the API to calculate offsets.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
# ################################################################ #
# Represents the input to API methods.
# Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1::Document]
attr_accessor :document
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@document = args[:document] if args.key?(:document)
end
end
# The sentiment analysis response message.
class AnalyzeSentimentResponse
include Google::Apis::Core::Hashable
# Represents the feeling associated with the entire text or entities in
# the text.
# Corresponds to the JSON property `documentSentiment`
# @return [Google::Apis::LanguageV1::Sentiment]
attr_accessor :document_sentiment
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See `Document.language` field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# The sentiment for all the sentences in the document.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1::Sentence>]
attr_accessor :sentences
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
@language = args[:language] if args.key?(:language)
@sentences = args[:sentences] if args.key?(:sentences)
end
end
# The entity analysis response message.
class AnalyzeEntitiesResponse
include Google::Apis::Core::Hashable
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See `Document.language` field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# The recognized entities in the input document.
# Corresponds to the JSON property `entities`
# @return [Array<Google::Apis::LanguageV1::Entity>]
attr_accessor :entities
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@language = args[:language] if args.key?(:language)
@entities = args[:entities] if args.key?(:entities)
end end
end end
end end

View File

@ -22,102 +22,6 @@ module Google
module Apis module Apis
module LanguageV1 module LanguageV1
class Entity
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeSyntaxResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnnotateTextRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeSentimentRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnnotateTextResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class DependencyEdge
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TextSpan
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Token
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Features
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class EntityMention
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Sentence
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Document
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Sentiment
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeEntitiesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PartOfSpeech
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeSyntaxRequest class AnalyzeSyntaxRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -137,14 +41,139 @@ module Google
end end
class Entity class Entity
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeSyntaxResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnnotateTextRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnnotateTextResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeSentimentRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class DependencyEdge
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Token
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TextSpan
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class EntityMention
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Features
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Document
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Sentence
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeEntitiesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Sentiment
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PartOfSpeech
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeSyntaxRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :mentions, as: 'mentions', class: Google::Apis::LanguageV1::EntityMention, decorator: Google::Apis::LanguageV1::EntityMention::Representation property :encoding_type, as: 'encodingType'
property :document, as: 'document', class: Google::Apis::LanguageV1::Document, decorator: Google::Apis::LanguageV1::Document::Representation
property :name, as: 'name' end
end
class AnalyzeSentimentResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1::Sentiment, decorator: Google::Apis::LanguageV1::Sentiment::Representation
property :language, as: 'language'
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1::Sentence, decorator: Google::Apis::LanguageV1::Sentence::Representation
end
end
class AnalyzeEntitiesResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :entities, as: 'entities', class: Google::Apis::LanguageV1::Entity, decorator: Google::Apis::LanguageV1::Entity::Representation
property :language, as: 'language'
end
end
class Entity
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type' property :type, as: 'type'
hash :metadata, as: 'metadata' hash :metadata, as: 'metadata'
property :salience, as: 'salience' property :salience, as: 'salience'
collection :mentions, as: 'mentions', class: Google::Apis::LanguageV1::EntityMention, decorator: Google::Apis::LanguageV1::EntityMention::Representation
property :name, as: 'name'
end end
end end
@ -170,6 +199,21 @@ module Google
end end
end end
class AnnotateTextResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1::Sentiment, decorator: Google::Apis::LanguageV1::Sentiment::Representation
property :language, as: 'language'
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1::Sentence, decorator: Google::Apis::LanguageV1::Sentence::Representation
collection :tokens, as: 'tokens', class: Google::Apis::LanguageV1::Token, decorator: Google::Apis::LanguageV1::Token::Representation
collection :entities, as: 'entities', class: Google::Apis::LanguageV1::Entity, decorator: Google::Apis::LanguageV1::Entity::Representation
end
end
class AnalyzeSentimentRequest class AnalyzeSentimentRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -179,26 +223,24 @@ module Google
end end
end end
class AnnotateTextResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1::Sentence, decorator: Google::Apis::LanguageV1::Sentence::Representation
collection :tokens, as: 'tokens', class: Google::Apis::LanguageV1::Token, decorator: Google::Apis::LanguageV1::Token::Representation
collection :entities, as: 'entities', class: Google::Apis::LanguageV1::Entity, decorator: Google::Apis::LanguageV1::Entity::Representation
property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1::Sentiment, decorator: Google::Apis::LanguageV1::Sentiment::Representation
property :language, as: 'language'
end
end
class DependencyEdge class DependencyEdge
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :label, as: 'label'
property :head_token_index, as: 'headTokenIndex' property :head_token_index, as: 'headTokenIndex'
property :label, as: 'label'
end
end
class Token
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :text, as: 'text', class: Google::Apis::LanguageV1::TextSpan, decorator: Google::Apis::LanguageV1::TextSpan::Representation
property :dependency_edge, as: 'dependencyEdge', class: Google::Apis::LanguageV1::DependencyEdge, decorator: Google::Apis::LanguageV1::DependencyEdge::Representation
property :lemma, as: 'lemma'
property :part_of_speech, as: 'partOfSpeech', class: Google::Apis::LanguageV1::PartOfSpeech, decorator: Google::Apis::LanguageV1::PartOfSpeech::Representation
end end
end end
@ -210,34 +252,12 @@ module Google
end end
end end
class Token
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :part_of_speech, as: 'partOfSpeech', class: Google::Apis::LanguageV1::PartOfSpeech, decorator: Google::Apis::LanguageV1::PartOfSpeech::Representation
property :text, as: 'text', class: Google::Apis::LanguageV1::TextSpan, decorator: Google::Apis::LanguageV1::TextSpan::Representation
property :dependency_edge, as: 'dependencyEdge', class: Google::Apis::LanguageV1::DependencyEdge, decorator: Google::Apis::LanguageV1::DependencyEdge::Representation
property :lemma, as: 'lemma'
end
end
class Status class Status
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :details, as: 'details'
property :code, as: 'code' property :code, as: 'code'
property :message, as: 'message' property :message, as: 'message'
end collection :details, as: 'details'
end
class Features
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :extract_entities, as: 'extractEntities'
property :extract_syntax, as: 'extractSyntax'
property :extract_document_sentiment, as: 'extractDocumentSentiment'
end end
end end
@ -250,6 +270,25 @@ module Google
end end
end end
class Features
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :extract_syntax, as: 'extractSyntax'
property :extract_document_sentiment, as: 'extractDocumentSentiment'
property :extract_entities, as: 'extractEntities'
end
end
class Document
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type'
property :content, as: 'content'
property :gcs_content_uri, as: 'gcsContentUri'
property :language, as: 'language'
end
end
class Sentence class Sentence
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -260,13 +299,12 @@ module Google
end end
end end
class Document class AnalyzeEntitiesRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :language, as: 'language' property :document, as: 'document', class: Google::Apis::LanguageV1::Document, decorator: Google::Apis::LanguageV1::Document::Representation
property :type, as: 'type'
property :content, as: 'content' property :encoding_type, as: 'encodingType'
property :gcs_content_uri, as: 'gcsContentUri'
end end
end end
@ -278,21 +316,9 @@ module Google
end end
end end
class AnalyzeEntitiesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :encoding_type, as: 'encodingType'
property :document, as: 'document', class: Google::Apis::LanguageV1::Document, decorator: Google::Apis::LanguageV1::Document::Representation
end
end
class PartOfSpeech class PartOfSpeech
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :case, as: 'case'
property :tense, as: 'tense'
property :reciprocity, as: 'reciprocity'
property :form, as: 'form' property :form, as: 'form'
property :number, as: 'number' property :number, as: 'number'
property :voice, as: 'voice' property :voice, as: 'voice'
@ -302,35 +328,9 @@ module Google
property :gender, as: 'gender' property :gender, as: 'gender'
property :person, as: 'person' property :person, as: 'person'
property :proper, as: 'proper' property :proper, as: 'proper'
end property :case, as: 'case'
end property :tense, as: 'tense'
property :reciprocity, as: 'reciprocity'
class AnalyzeSyntaxRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :encoding_type, as: 'encodingType'
property :document, as: 'document', class: Google::Apis::LanguageV1::Document, decorator: Google::Apis::LanguageV1::Document::Representation
end
end
class AnalyzeSentimentResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1::Sentiment, decorator: Google::Apis::LanguageV1::Sentiment::Representation
property :language, as: 'language'
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1::Sentence, decorator: Google::Apis::LanguageV1::Sentence::Representation
end
end
class AnalyzeEntitiesResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :language, as: 'language'
collection :entities, as: 'entities', class: Google::Apis::LanguageV1::Entity, decorator: Google::Apis::LanguageV1::Entity::Representation
end end
end end
end end

View File

@ -22,6 +22,325 @@ module Google
module Apis module Apis
module LanguageV1beta1 module LanguageV1beta1
# The entity analysis request message.
class AnalyzeEntitiesRequest
include Google::Apis::Core::Hashable
# The encoding type used by the API to calculate offsets.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
# ################################################################ #
# Represents the input to API methods.
# Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1beta1::Document]
attr_accessor :document
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@document = args[:document] if args.key?(:document)
end
end
# Represents the feeling associated with the entire text or entities in
# the text.
class Sentiment
include Google::Apis::Core::Hashable
# DEPRECATED FIELD - This field is being deprecated in
# favor of score. Please refer to our documentation at
# https://cloud.google.com/natural-language/docs for more information.
# Corresponds to the JSON property `polarity`
# @return [Float]
attr_accessor :polarity
# Sentiment score between -1.0 (negative sentiment) and 1.0
# (positive sentiment).
# Corresponds to the JSON property `score`
# @return [Float]
attr_accessor :score
# A non-negative number in the [0, +inf) range, which represents
# the absolute magnitude of sentiment regardless of score (positive or
# negative).
# Corresponds to the JSON property `magnitude`
# @return [Float]
attr_accessor :magnitude
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@polarity = args[:polarity] if args.key?(:polarity)
@score = args[:score] if args.key?(:score)
@magnitude = args[:magnitude] if args.key?(:magnitude)
end
end
# Represents part of speech information for a token.
class PartOfSpeech
include Google::Apis::Core::Hashable
# The grammatical form.
# Corresponds to the JSON property `form`
# @return [String]
attr_accessor :form
# The grammatical number.
# Corresponds to the JSON property `number`
# @return [String]
attr_accessor :number
# The grammatical voice.
# Corresponds to the JSON property `voice`
# @return [String]
attr_accessor :voice
# The grammatical aspect.
# Corresponds to the JSON property `aspect`
# @return [String]
attr_accessor :aspect
# The grammatical mood.
# Corresponds to the JSON property `mood`
# @return [String]
attr_accessor :mood
# The part of speech tag.
# Corresponds to the JSON property `tag`
# @return [String]
attr_accessor :tag
# The grammatical gender.
# Corresponds to the JSON property `gender`
# @return [String]
attr_accessor :gender
# The grammatical person.
# Corresponds to the JSON property `person`
# @return [String]
attr_accessor :person
# The grammatical properness.
# Corresponds to the JSON property `proper`
# @return [String]
attr_accessor :proper
# The grammatical case.
# Corresponds to the JSON property `case`
# @return [String]
attr_accessor :case
# The grammatical tense.
# Corresponds to the JSON property `tense`
# @return [String]
attr_accessor :tense
# The grammatical reciprocity.
# Corresponds to the JSON property `reciprocity`
# @return [String]
attr_accessor :reciprocity
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@form = args[:form] if args.key?(:form)
@number = args[:number] if args.key?(:number)
@voice = args[:voice] if args.key?(:voice)
@aspect = args[:aspect] if args.key?(:aspect)
@mood = args[:mood] if args.key?(:mood)
@tag = args[:tag] if args.key?(:tag)
@gender = args[:gender] if args.key?(:gender)
@person = args[:person] if args.key?(:person)
@proper = args[:proper] if args.key?(:proper)
@case = args[:case] if args.key?(:case)
@tense = args[:tense] if args.key?(:tense)
@reciprocity = args[:reciprocity] if args.key?(:reciprocity)
end
end
# The syntax analysis request message.
class AnalyzeSyntaxRequest
include Google::Apis::Core::Hashable
# ################################################################ #
# Represents the input to API methods.
# Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1beta1::Document]
attr_accessor :document
# The encoding type used by the API to calculate offsets.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@document = args[:document] if args.key?(:document)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
end
end
# The sentiment analysis response message.
class AnalyzeSentimentResponse
include Google::Apis::Core::Hashable
# The sentiment for all the sentences in the document.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1beta1::Sentence>]
attr_accessor :sentences
# Represents the feeling associated with the entire text or entities in
# the text.
# Corresponds to the JSON property `documentSentiment`
# @return [Google::Apis::LanguageV1beta1::Sentiment]
attr_accessor :document_sentiment
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@sentences = args[:sentences] if args.key?(:sentences)
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
@language = args[:language] if args.key?(:language)
end
end
# The entity analysis response message.
class AnalyzeEntitiesResponse
include Google::Apis::Core::Hashable
# The recognized entities in the input document.
# Corresponds to the JSON property `entities`
# @return [Array<Google::Apis::LanguageV1beta1::Entity>]
attr_accessor :entities
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See Document.language field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@entities = args[:entities] if args.key?(:entities)
@language = args[:language] if args.key?(:language)
end
end
# Represents a phrase in the text that is a known entity, such as
# a person, an organization, or location. The API associates information, such
# as salience and mentions, with entities.
class Entity
include Google::Apis::Core::Hashable
# The mentions of this entity in the input document. The API currently
# supports proper noun mentions.
# Corresponds to the JSON property `mentions`
# @return [Array<Google::Apis::LanguageV1beta1::EntityMention>]
attr_accessor :mentions
# The representative name for the entity.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The entity type.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
# Metadata associated with the entity.
# Currently, Wikipedia URLs and Knowledge Graph MIDs are provided, if
# available. The associated keys are "wikipedia_url" and "mid", respectively.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,String>]
attr_accessor :metadata
# The salience score associated with the entity in the [0, 1.0] range.
# The salience score for an entity provides information about the
# importance or centrality of that entity to the entire document text.
# Scores closer to 0 are less salient, while scores closer to 1.0 are highly
# salient.
# Corresponds to the JSON property `salience`
# @return [Float]
attr_accessor :salience
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@mentions = args[:mentions] if args.key?(:mentions)
@name = args[:name] if args.key?(:name)
@type = args[:type] if args.key?(:type)
@metadata = args[:metadata] if args.key?(:metadata)
@salience = args[:salience] if args.key?(:salience)
end
end
# The syntax analysis response message.
class AnalyzeSyntaxResponse
include Google::Apis::Core::Hashable
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See Document.language field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# Sentences in the input document.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1beta1::Sentence>]
attr_accessor :sentences
# Tokens, along with their syntactic information, in the input document.
# Corresponds to the JSON property `tokens`
# @return [Array<Google::Apis::LanguageV1beta1::Token>]
attr_accessor :tokens
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@language = args[:language] if args.key?(:language)
@sentences = args[:sentences] if args.key?(:sentences)
@tokens = args[:tokens] if args.key?(:tokens)
end
end
# The request message for the text annotation API, which can perform multiple # The request message for the text annotation API, which can perform multiple
# analysis types (sentiment, entities, and syntax) in one call. # analysis types (sentiment, entities, and syntax) in one call.
class AnnotateTextRequest class AnnotateTextRequest
@ -60,13 +379,6 @@ module Google
class AnnotateTextResponse class AnnotateTextResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See Document.language field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# Sentences in the input document. Populated if the user enables # Sentences in the input document. Populated if the user enables
# AnnotateTextRequest.Features.extract_syntax. # AnnotateTextRequest.Features.extract_syntax.
# Corresponds to the JSON property `sentences` # Corresponds to the JSON property `sentences`
@ -93,17 +405,24 @@ module Google
# @return [Google::Apis::LanguageV1beta1::Sentiment] # @return [Google::Apis::LanguageV1beta1::Sentiment]
attr_accessor :document_sentiment attr_accessor :document_sentiment
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See Document.language field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@language = args[:language] if args.key?(:language)
@sentences = args[:sentences] if args.key?(:sentences) @sentences = args[:sentences] if args.key?(:sentences)
@tokens = args[:tokens] if args.key?(:tokens) @tokens = args[:tokens] if args.key?(:tokens)
@entities = args[:entities] if args.key?(:entities) @entities = args[:entities] if args.key?(:entities)
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment) @document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
@language = args[:language] if args.key?(:language)
end end
end end
@ -111,26 +430,26 @@ module Google
class AnalyzeSentimentRequest class AnalyzeSentimentRequest
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The encoding type used by the API to calculate sentence offsets for the
# sentence sentiment.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
# ################################################################ # # ################################################################ #
# Represents the input to API methods. # Represents the input to API methods.
# Corresponds to the JSON property `document` # Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1beta1::Document] # @return [Google::Apis::LanguageV1beta1::Document]
attr_accessor :document attr_accessor :document
# The encoding type used by the API to calculate sentence offsets for the
# sentence sentiment.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@document = args[:document] if args.key?(:document) @document = args[:document] if args.key?(:document)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
end end
end end
@ -167,11 +486,6 @@ module Google
class Token class Token
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Represents part of speech information for a token.
# Corresponds to the JSON property `partOfSpeech`
# @return [Google::Apis::LanguageV1beta1::PartOfSpeech]
attr_accessor :part_of_speech
# Represents an output piece of text. # Represents an output piece of text.
# Corresponds to the JSON property `text` # Corresponds to the JSON property `text`
# @return [Google::Apis::LanguageV1beta1::TextSpan] # @return [Google::Apis::LanguageV1beta1::TextSpan]
@ -187,16 +501,21 @@ module Google
# @return [String] # @return [String]
attr_accessor :lemma attr_accessor :lemma
# Represents part of speech information for a token.
# Corresponds to the JSON property `partOfSpeech`
# @return [Google::Apis::LanguageV1beta1::PartOfSpeech]
attr_accessor :part_of_speech
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@part_of_speech = args[:part_of_speech] if args.key?(:part_of_speech)
@text = args[:text] if args.key?(:text) @text = args[:text] if args.key?(:text)
@dependency_edge = args[:dependency_edge] if args.key?(:dependency_edge) @dependency_edge = args[:dependency_edge] if args.key?(:dependency_edge)
@lemma = args[:lemma] if args.key?(:lemma) @lemma = args[:lemma] if args.key?(:lemma)
@part_of_speech = args[:part_of_speech] if args.key?(:part_of_speech)
end end
end end
@ -298,6 +617,32 @@ module Google
end end
end end
# Represents a mention for an entity in the text. Currently, proper noun
# mentions are supported.
class EntityMention
include Google::Apis::Core::Hashable
# Represents an output piece of text.
# Corresponds to the JSON property `text`
# @return [Google::Apis::LanguageV1beta1::TextSpan]
attr_accessor :text
# The type of the entity mention.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@text = args[:text] if args.key?(:text)
@type = args[:type] if args.key?(:type)
end
end
# All available features for sentiment, syntax, and semantic analysis. # All available features for sentiment, syntax, and semantic analysis.
# Setting each one to true will enable that specific analysis for the input. # Setting each one to true will enable that specific analysis for the input.
class Features class Features
@ -333,9 +678,8 @@ module Google
end end
end end
# Represents a mention for an entity in the text. Currently, proper noun # Represents a sentence in the input document.
# mentions are supported. class Sentence
class EntityMention
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Represents an output piece of text. # Represents an output piece of text.
@ -343,10 +687,11 @@ module Google
# @return [Google::Apis::LanguageV1beta1::TextSpan] # @return [Google::Apis::LanguageV1beta1::TextSpan]
attr_accessor :text attr_accessor :text
# The type of the entity mention. # Represents the feeling associated with the entire text or entities in
# Corresponds to the JSON property `type` # the text.
# @return [String] # Corresponds to the JSON property `sentiment`
attr_accessor :type # @return [Google::Apis::LanguageV1beta1::Sentiment]
attr_accessor :sentiment
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -355,7 +700,7 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@text = args[:text] if args.key?(:text) @text = args[:text] if args.key?(:text)
@type = args[:type] if args.key?(:type) @sentiment = args[:sentiment] if args.key?(:sentiment)
end end
end end
@ -407,351 +752,6 @@ module Google
@language = args[:language] if args.key?(:language) @language = args[:language] if args.key?(:language)
end end
end end
# Represents a sentence in the input document.
class Sentence
include Google::Apis::Core::Hashable
# Represents an output piece of text.
# Corresponds to the JSON property `text`
# @return [Google::Apis::LanguageV1beta1::TextSpan]
attr_accessor :text
# Represents the feeling associated with the entire text or entities in
# the text.
# Corresponds to the JSON property `sentiment`
# @return [Google::Apis::LanguageV1beta1::Sentiment]
attr_accessor :sentiment
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@text = args[:text] if args.key?(:text)
@sentiment = args[:sentiment] if args.key?(:sentiment)
end
end
# Represents the feeling associated with the entire text or entities in
# the text.
class Sentiment
include Google::Apis::Core::Hashable
# DEPRECATED FIELD - This field is being deprecated in
# favor of score. Please refer to our documentation at
# https://cloud.google.com/natural-language/docs for more information.
# Corresponds to the JSON property `polarity`
# @return [Float]
attr_accessor :polarity
# Sentiment score between -1.0 (negative sentiment) and 1.0
# (positive sentiment).
# Corresponds to the JSON property `score`
# @return [Float]
attr_accessor :score
# A non-negative number in the [0, +inf) range, which represents
# the absolute magnitude of sentiment regardless of score (positive or
# negative).
# Corresponds to the JSON property `magnitude`
# @return [Float]
attr_accessor :magnitude
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@polarity = args[:polarity] if args.key?(:polarity)
@score = args[:score] if args.key?(:score)
@magnitude = args[:magnitude] if args.key?(:magnitude)
end
end
# The entity analysis request message.
class AnalyzeEntitiesRequest
include Google::Apis::Core::Hashable
# The encoding type used by the API to calculate offsets.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
# ################################################################ #
# Represents the input to API methods.
# Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1beta1::Document]
attr_accessor :document
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@document = args[:document] if args.key?(:document)
end
end
# Represents part of speech information for a token.
class PartOfSpeech
include Google::Apis::Core::Hashable
# The grammatical form.
# Corresponds to the JSON property `form`
# @return [String]
attr_accessor :form
# The grammatical number.
# Corresponds to the JSON property `number`
# @return [String]
attr_accessor :number
# The grammatical voice.
# Corresponds to the JSON property `voice`
# @return [String]
attr_accessor :voice
# The grammatical aspect.
# Corresponds to the JSON property `aspect`
# @return [String]
attr_accessor :aspect
# The grammatical mood.
# Corresponds to the JSON property `mood`
# @return [String]
attr_accessor :mood
# The part of speech tag.
# Corresponds to the JSON property `tag`
# @return [String]
attr_accessor :tag
# The grammatical gender.
# Corresponds to the JSON property `gender`
# @return [String]
attr_accessor :gender
# The grammatical person.
# Corresponds to the JSON property `person`
# @return [String]
attr_accessor :person
# The grammatical properness.
# Corresponds to the JSON property `proper`
# @return [String]
attr_accessor :proper
# The grammatical case.
# Corresponds to the JSON property `case`
# @return [String]
attr_accessor :case
# The grammatical tense.
# Corresponds to the JSON property `tense`
# @return [String]
attr_accessor :tense
# The grammatical reciprocity.
# Corresponds to the JSON property `reciprocity`
# @return [String]
attr_accessor :reciprocity
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@form = args[:form] if args.key?(:form)
@number = args[:number] if args.key?(:number)
@voice = args[:voice] if args.key?(:voice)
@aspect = args[:aspect] if args.key?(:aspect)
@mood = args[:mood] if args.key?(:mood)
@tag = args[:tag] if args.key?(:tag)
@gender = args[:gender] if args.key?(:gender)
@person = args[:person] if args.key?(:person)
@proper = args[:proper] if args.key?(:proper)
@case = args[:case] if args.key?(:case)
@tense = args[:tense] if args.key?(:tense)
@reciprocity = args[:reciprocity] if args.key?(:reciprocity)
end
end
# The syntax analysis request message.
class AnalyzeSyntaxRequest
include Google::Apis::Core::Hashable
# The encoding type used by the API to calculate offsets.
# Corresponds to the JSON property `encodingType`
# @return [String]
attr_accessor :encoding_type
# ################################################################ #
# Represents the input to API methods.
# Corresponds to the JSON property `document`
# @return [Google::Apis::LanguageV1beta1::Document]
attr_accessor :document
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
@document = args[:document] if args.key?(:document)
end
end
# The sentiment analysis response message.
class AnalyzeSentimentResponse
include Google::Apis::Core::Hashable
# Represents the feeling associated with the entire text or entities in
# the text.
# Corresponds to the JSON property `documentSentiment`
# @return [Google::Apis::LanguageV1beta1::Sentiment]
attr_accessor :document_sentiment
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# The sentiment for all the sentences in the document.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1beta1::Sentence>]
attr_accessor :sentences
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
@language = args[:language] if args.key?(:language)
@sentences = args[:sentences] if args.key?(:sentences)
end
end
# The entity analysis response message.
class AnalyzeEntitiesResponse
include Google::Apis::Core::Hashable
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See Document.language field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# The recognized entities in the input document.
# Corresponds to the JSON property `entities`
# @return [Array<Google::Apis::LanguageV1beta1::Entity>]
attr_accessor :entities
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@language = args[:language] if args.key?(:language)
@entities = args[:entities] if args.key?(:entities)
end
end
# The syntax analysis response message.
class AnalyzeSyntaxResponse
include Google::Apis::Core::Hashable
# The language of the text, which will be the same as the language specified
# in the request or, if not specified, the automatically-detected language.
# See Document.language field for more details.
# Corresponds to the JSON property `language`
# @return [String]
attr_accessor :language
# Sentences in the input document.
# Corresponds to the JSON property `sentences`
# @return [Array<Google::Apis::LanguageV1beta1::Sentence>]
attr_accessor :sentences
# Tokens, along with their syntactic information, in the input document.
# Corresponds to the JSON property `tokens`
# @return [Array<Google::Apis::LanguageV1beta1::Token>]
attr_accessor :tokens
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@language = args[:language] if args.key?(:language)
@sentences = args[:sentences] if args.key?(:sentences)
@tokens = args[:tokens] if args.key?(:tokens)
end
end
# Represents a phrase in the text that is a known entity, such as
# a person, an organization, or location. The API associates information, such
# as salience and mentions, with entities.
class Entity
include Google::Apis::Core::Hashable
# The entity type.
# Corresponds to the JSON property `type`
# @return [String]
attr_accessor :type
# Metadata associated with the entity.
# Currently, Wikipedia URLs and Knowledge Graph MIDs are provided, if
# available. The associated keys are "wikipedia_url" and "mid", respectively.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,String>]
attr_accessor :metadata
# The salience score associated with the entity in the [0, 1.0] range.
# The salience score for an entity provides information about the
# importance or centrality of that entity to the entire document text.
# Scores closer to 0 are less salient, while scores closer to 1.0 are highly
# salient.
# Corresponds to the JSON property `salience`
# @return [Float]
attr_accessor :salience
# The mentions of this entity in the input document. The API currently
# supports proper noun mentions.
# Corresponds to the JSON property `mentions`
# @return [Array<Google::Apis::LanguageV1beta1::EntityMention>]
attr_accessor :mentions
# The representative name for the entity.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@type = args[:type] if args.key?(:type)
@metadata = args[:metadata] if args.key?(:metadata)
@salience = args[:salience] if args.key?(:salience)
@mentions = args[:mentions] if args.key?(:mentions)
@name = args[:name] if args.key?(:name)
end
end
end end
end end
end end

View File

@ -22,67 +22,7 @@ module Google
module Apis module Apis
module LanguageV1beta1 module LanguageV1beta1
class AnnotateTextRequest class AnalyzeEntitiesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnnotateTextResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeSentimentRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class DependencyEdge
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Token
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TextSpan
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Features
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class EntityMention
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Document
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Sentence
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -94,12 +34,6 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class AnalyzeEntitiesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class PartOfSpeech class PartOfSpeech
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -124,45 +58,85 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class AnalyzeSyntaxResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Entity class Entity
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class AnalyzeSyntaxResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnnotateTextRequest class AnnotateTextRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :encoding_type, as: 'encodingType'
property :document, as: 'document', class: Google::Apis::LanguageV1beta1::Document, decorator: Google::Apis::LanguageV1beta1::Document::Representation
property :features, as: 'features', class: Google::Apis::LanguageV1beta1::Features, decorator: Google::Apis::LanguageV1beta1::Features::Representation include Google::Apis::Core::JsonObjectSupport
end
end end
class AnnotateTextResponse class AnnotateTextResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :language, as: 'language'
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1beta1::Sentence, decorator: Google::Apis::LanguageV1beta1::Sentence::Representation
collection :tokens, as: 'tokens', class: Google::Apis::LanguageV1beta1::Token, decorator: Google::Apis::LanguageV1beta1::Token::Representation include Google::Apis::Core::JsonObjectSupport
collection :entities, as: 'entities', class: Google::Apis::LanguageV1beta1::Entity, decorator: Google::Apis::LanguageV1beta1::Entity::Representation
property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1beta1::Sentiment, decorator: Google::Apis::LanguageV1beta1::Sentiment::Representation
end
end end
class AnalyzeSentimentRequest class AnalyzeSentimentRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class DependencyEdge
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Token
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class TextSpan
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class EntityMention
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Features
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Sentence
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Document
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class AnalyzeEntitiesRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :encoding_type, as: 'encodingType' property :encoding_type, as: 'encodingType'
@ -171,82 +145,6 @@ module Google
end end
end end
class DependencyEdge
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :head_token_index, as: 'headTokenIndex'
property :label, as: 'label'
end
end
class Token
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :part_of_speech, as: 'partOfSpeech', class: Google::Apis::LanguageV1beta1::PartOfSpeech, decorator: Google::Apis::LanguageV1beta1::PartOfSpeech::Representation
property :text, as: 'text', class: Google::Apis::LanguageV1beta1::TextSpan, decorator: Google::Apis::LanguageV1beta1::TextSpan::Representation
property :dependency_edge, as: 'dependencyEdge', class: Google::Apis::LanguageV1beta1::DependencyEdge, decorator: Google::Apis::LanguageV1beta1::DependencyEdge::Representation
property :lemma, as: 'lemma'
end
end
class TextSpan
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :begin_offset, as: 'beginOffset'
property :content, as: 'content'
end
end
class Status
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :code, as: 'code'
property :message, as: 'message'
collection :details, as: 'details'
end
end
class Features
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :extract_entities, as: 'extractEntities'
property :extract_syntax, as: 'extractSyntax'
property :extract_document_sentiment, as: 'extractDocumentSentiment'
end
end
class EntityMention
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :text, as: 'text', class: Google::Apis::LanguageV1beta1::TextSpan, decorator: Google::Apis::LanguageV1beta1::TextSpan::Representation
property :type, as: 'type'
end
end
class Document
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type'
property :content, as: 'content'
property :gcs_content_uri, as: 'gcsContentUri'
property :language, as: 'language'
end
end
class Sentence
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :text, as: 'text', class: Google::Apis::LanguageV1beta1::TextSpan, decorator: Google::Apis::LanguageV1beta1::TextSpan::Representation
property :sentiment, as: 'sentiment', class: Google::Apis::LanguageV1beta1::Sentiment, decorator: Google::Apis::LanguageV1beta1::Sentiment::Representation
end
end
class Sentiment class Sentiment
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -256,15 +154,6 @@ module Google
end end
end end
class AnalyzeEntitiesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :encoding_type, as: 'encodingType'
property :document, as: 'document', class: Google::Apis::LanguageV1beta1::Document, decorator: Google::Apis::LanguageV1beta1::Document::Representation
end
end
class PartOfSpeech class PartOfSpeech
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -286,29 +175,41 @@ module Google
class AnalyzeSyntaxRequest class AnalyzeSyntaxRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :encoding_type, as: 'encodingType'
property :document, as: 'document', class: Google::Apis::LanguageV1beta1::Document, decorator: Google::Apis::LanguageV1beta1::Document::Representation property :document, as: 'document', class: Google::Apis::LanguageV1beta1::Document, decorator: Google::Apis::LanguageV1beta1::Document::Representation
property :encoding_type, as: 'encodingType'
end end
end end
class AnalyzeSentimentResponse class AnalyzeSentimentResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1beta1::Sentence, decorator: Google::Apis::LanguageV1beta1::Sentence::Representation
property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1beta1::Sentiment, decorator: Google::Apis::LanguageV1beta1::Sentiment::Representation property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1beta1::Sentiment, decorator: Google::Apis::LanguageV1beta1::Sentiment::Representation
property :language, as: 'language' property :language, as: 'language'
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1beta1::Sentence, decorator: Google::Apis::LanguageV1beta1::Sentence::Representation
end end
end end
class AnalyzeEntitiesResponse class AnalyzeEntitiesResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :language, as: 'language'
collection :entities, as: 'entities', class: Google::Apis::LanguageV1beta1::Entity, decorator: Google::Apis::LanguageV1beta1::Entity::Representation collection :entities, as: 'entities', class: Google::Apis::LanguageV1beta1::Entity, decorator: Google::Apis::LanguageV1beta1::Entity::Representation
property :language, as: 'language'
end
end
class Entity
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :mentions, as: 'mentions', class: Google::Apis::LanguageV1beta1::EntityMention, decorator: Google::Apis::LanguageV1beta1::EntityMention::Representation
property :name, as: 'name'
property :type, as: 'type'
hash :metadata, as: 'metadata'
property :salience, as: 'salience'
end end
end end
@ -323,15 +224,114 @@ module Google
end end
end end
class Entity class AnnotateTextRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :encoding_type, as: 'encodingType'
property :document, as: 'document', class: Google::Apis::LanguageV1beta1::Document, decorator: Google::Apis::LanguageV1beta1::Document::Representation
property :features, as: 'features', class: Google::Apis::LanguageV1beta1::Features, decorator: Google::Apis::LanguageV1beta1::Features::Representation
end
end
class AnnotateTextResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :sentences, as: 'sentences', class: Google::Apis::LanguageV1beta1::Sentence, decorator: Google::Apis::LanguageV1beta1::Sentence::Representation
collection :tokens, as: 'tokens', class: Google::Apis::LanguageV1beta1::Token, decorator: Google::Apis::LanguageV1beta1::Token::Representation
collection :entities, as: 'entities', class: Google::Apis::LanguageV1beta1::Entity, decorator: Google::Apis::LanguageV1beta1::Entity::Representation
property :document_sentiment, as: 'documentSentiment', class: Google::Apis::LanguageV1beta1::Sentiment, decorator: Google::Apis::LanguageV1beta1::Sentiment::Representation
property :language, as: 'language'
end
end
class AnalyzeSentimentRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :document, as: 'document', class: Google::Apis::LanguageV1beta1::Document, decorator: Google::Apis::LanguageV1beta1::Document::Representation
property :encoding_type, as: 'encodingType'
end
end
class DependencyEdge
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :head_token_index, as: 'headTokenIndex'
property :label, as: 'label'
end
end
class Token
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :text, as: 'text', class: Google::Apis::LanguageV1beta1::TextSpan, decorator: Google::Apis::LanguageV1beta1::TextSpan::Representation
property :dependency_edge, as: 'dependencyEdge', class: Google::Apis::LanguageV1beta1::DependencyEdge, decorator: Google::Apis::LanguageV1beta1::DependencyEdge::Representation
property :lemma, as: 'lemma'
property :part_of_speech, as: 'partOfSpeech', class: Google::Apis::LanguageV1beta1::PartOfSpeech, decorator: Google::Apis::LanguageV1beta1::PartOfSpeech::Representation
end
end
class TextSpan
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :begin_offset, as: 'beginOffset'
property :content, as: 'content'
end
end
class Status
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :code, as: 'code'
property :message, as: 'message'
collection :details, as: 'details'
end
end
class EntityMention
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :text, as: 'text', class: Google::Apis::LanguageV1beta1::TextSpan, decorator: Google::Apis::LanguageV1beta1::TextSpan::Representation
property :type, as: 'type'
end
end
class Features
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :extract_entities, as: 'extractEntities'
property :extract_syntax, as: 'extractSyntax'
property :extract_document_sentiment, as: 'extractDocumentSentiment'
end
end
class Sentence
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :text, as: 'text', class: Google::Apis::LanguageV1beta1::TextSpan, decorator: Google::Apis::LanguageV1beta1::TextSpan::Representation
property :sentiment, as: 'sentiment', class: Google::Apis::LanguageV1beta1::Sentiment, decorator: Google::Apis::LanguageV1beta1::Sentiment::Representation
end
end
class Document
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type' property :type, as: 'type'
hash :metadata, as: 'metadata' property :content, as: 'content'
property :salience, as: 'salience' property :gcs_content_uri, as: 'gcsContentUri'
collection :mentions, as: 'mentions', class: Google::Apis::LanguageV1beta1::EntityMention, decorator: Google::Apis::LanguageV1beta1::EntityMention::Representation property :language, as: 'language'
property :name, as: 'name'
end end
end end
end end

View File

@ -34,16 +34,16 @@ module Google
# #
# @see https://cloud.google.com/natural-language/ # @see https://cloud.google.com/natural-language/
class CloudNaturalLanguageService < Google::Apis::Core::BaseService class CloudNaturalLanguageService < Google::Apis::Core::BaseService
# @return [String]
# 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] # @return [String]
# API key. Your API key identifies your project and provides you with API access, # 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. # quota, and reports. Required unless you provide an OAuth 2.0 token.
attr_accessor :key attr_accessor :key
# @return [String]
# 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
def initialize def initialize
super('https://language.googleapis.com/', '') super('https://language.googleapis.com/', '')
end end
@ -51,11 +51,11 @@ module Google
# A convenience method that provides all the features that analyzeSentiment, # A convenience method that provides all the features that analyzeSentiment,
# analyzeEntities, and analyzeSyntax provide in one call. # analyzeEntities, and analyzeSyntax provide in one call.
# @param [Google::Apis::LanguageV1beta1::AnnotateTextRequest] annotate_text_request_object # @param [Google::Apis::LanguageV1beta1::AnnotateTextRequest] annotate_text_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -68,14 +68,14 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def annotate_document_text(annotate_text_request_object = nil, quota_user: nil, fields: nil, options: nil, &block) def annotate_document_text(annotate_text_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1beta1/documents:annotateText', options) command = make_simple_command(:post, 'v1beta1/documents:annotateText', options)
command.request_representation = Google::Apis::LanguageV1beta1::AnnotateTextRequest::Representation command.request_representation = Google::Apis::LanguageV1beta1::AnnotateTextRequest::Representation
command.request_object = annotate_text_request_object command.request_object = annotate_text_request_object
command.response_representation = Google::Apis::LanguageV1beta1::AnnotateTextResponse::Representation command.response_representation = Google::Apis::LanguageV1beta1::AnnotateTextResponse::Representation
command.response_class = Google::Apis::LanguageV1beta1::AnnotateTextResponse command.response_class = Google::Apis::LanguageV1beta1::AnnotateTextResponse
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
@ -83,11 +83,11 @@ module Google
# along with entity types, salience, mentions for each entity, and # along with entity types, salience, mentions for each entity, and
# other properties. # other properties.
# @param [Google::Apis::LanguageV1beta1::AnalyzeEntitiesRequest] analyze_entities_request_object # @param [Google::Apis::LanguageV1beta1::AnalyzeEntitiesRequest] analyze_entities_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -100,14 +100,14 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def analyze_document_entities(analyze_entities_request_object = nil, quota_user: nil, fields: nil, options: nil, &block) def analyze_document_entities(analyze_entities_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1beta1/documents:analyzeEntities', options) command = make_simple_command(:post, 'v1beta1/documents:analyzeEntities', options)
command.request_representation = Google::Apis::LanguageV1beta1::AnalyzeEntitiesRequest::Representation command.request_representation = Google::Apis::LanguageV1beta1::AnalyzeEntitiesRequest::Representation
command.request_object = analyze_entities_request_object command.request_object = analyze_entities_request_object
command.response_representation = Google::Apis::LanguageV1beta1::AnalyzeEntitiesResponse::Representation command.response_representation = Google::Apis::LanguageV1beta1::AnalyzeEntitiesResponse::Representation
command.response_class = Google::Apis::LanguageV1beta1::AnalyzeEntitiesResponse command.response_class = Google::Apis::LanguageV1beta1::AnalyzeEntitiesResponse
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
@ -115,11 +115,11 @@ module Google
# tokenization along with part of speech tags, dependency trees, and other # tokenization along with part of speech tags, dependency trees, and other
# properties. # properties.
# @param [Google::Apis::LanguageV1beta1::AnalyzeSyntaxRequest] analyze_syntax_request_object # @param [Google::Apis::LanguageV1beta1::AnalyzeSyntaxRequest] analyze_syntax_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -132,24 +132,24 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def analyze_document_syntax(analyze_syntax_request_object = nil, quota_user: nil, fields: nil, options: nil, &block) def analyze_document_syntax(analyze_syntax_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1beta1/documents:analyzeSyntax', options) command = make_simple_command(:post, 'v1beta1/documents:analyzeSyntax', options)
command.request_representation = Google::Apis::LanguageV1beta1::AnalyzeSyntaxRequest::Representation command.request_representation = Google::Apis::LanguageV1beta1::AnalyzeSyntaxRequest::Representation
command.request_object = analyze_syntax_request_object command.request_object = analyze_syntax_request_object
command.response_representation = Google::Apis::LanguageV1beta1::AnalyzeSyntaxResponse::Representation command.response_representation = Google::Apis::LanguageV1beta1::AnalyzeSyntaxResponse::Representation
command.response_class = Google::Apis::LanguageV1beta1::AnalyzeSyntaxResponse command.response_class = Google::Apis::LanguageV1beta1::AnalyzeSyntaxResponse
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
# Analyzes the sentiment of the provided text. # Analyzes the sentiment of the provided text.
# @param [Google::Apis::LanguageV1beta1::AnalyzeSentimentRequest] analyze_sentiment_request_object # @param [Google::Apis::LanguageV1beta1::AnalyzeSentimentRequest] analyze_sentiment_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user # @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any # 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. # arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [Google::Apis::RequestOptions] options # @param [Google::Apis::RequestOptions] options
# Request-specific options # Request-specific options
# #
@ -162,22 +162,22 @@ module Google
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @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::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required # @raise [Google::Apis::AuthorizationError] Authorization is required
def analyze_document_sentiment(analyze_sentiment_request_object = nil, quota_user: nil, fields: nil, options: nil, &block) def analyze_document_sentiment(analyze_sentiment_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1beta1/documents:analyzeSentiment', options) command = make_simple_command(:post, 'v1beta1/documents:analyzeSentiment', options)
command.request_representation = Google::Apis::LanguageV1beta1::AnalyzeSentimentRequest::Representation command.request_representation = Google::Apis::LanguageV1beta1::AnalyzeSentimentRequest::Representation
command.request_object = analyze_sentiment_request_object command.request_object = analyze_sentiment_request_object
command.response_representation = Google::Apis::LanguageV1beta1::AnalyzeSentimentResponse::Representation command.response_representation = Google::Apis::LanguageV1beta1::AnalyzeSentimentResponse::Representation
command.response_class = Google::Apis::LanguageV1beta1::AnalyzeSentimentResponse command.response_class = Google::Apis::LanguageV1beta1::AnalyzeSentimentResponse
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['fields'] = fields unless fields.nil? command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block) execute_or_queue_command(command, &block)
end end
protected protected
def apply_command_defaults(command) def apply_command_defaults(command)
command.query['quotaUser'] = quota_user unless quota_user.nil?
command.query['key'] = key unless key.nil? command.query['key'] = key unless key.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -22,109 +22,19 @@ module Google
module Apis module Apis
module LoggingV2 module LoggingV2
class LogLine
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLogMetricsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogEntry
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SourceLocation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLogEntriesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RequestLog
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListMonitoredResourceDescriptorsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SourceReference
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class WriteLogEntriesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogEntryOperation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogMetric
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class MonitoredResource
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class WriteLogEntriesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogSink
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLogsResponse class ListLogsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class HttpRequest class ListSinksResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class ListSinksResponse class HttpRequest
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -155,203 +65,118 @@ module Google
end end
class LogLine class LogLine
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :source_location, as: 'sourceLocation', class: Google::Apis::LoggingV2::SourceLocation, decorator: Google::Apis::LoggingV2::SourceLocation::Representation
property :time, as: 'time' include Google::Apis::Core::JsonObjectSupport
property :severity, as: 'severity'
property :log_message, as: 'logMessage'
end
end end
class ListLogMetricsResponse class ListLogMetricsResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :metrics, as: 'metrics', class: Google::Apis::LoggingV2::LogMetric, decorator: Google::Apis::LoggingV2::LogMetric::Representation
property :next_page_token, as: 'nextPageToken' include Google::Apis::Core::JsonObjectSupport
end
end
class LogEntry
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :trace, as: 'trace'
hash :labels, as: 'labels'
property :severity, as: 'severity'
property :source_location, as: 'sourceLocation', class: Google::Apis::LoggingV2::LogEntrySourceLocation, decorator: Google::Apis::LoggingV2::LogEntrySourceLocation::Representation
property :timestamp, as: 'timestamp'
property :log_name, as: 'logName'
property :http_request, as: 'httpRequest', class: Google::Apis::LoggingV2::HttpRequest, decorator: Google::Apis::LoggingV2::HttpRequest::Representation
property :resource, as: 'resource', class: Google::Apis::LoggingV2::MonitoredResource, decorator: Google::Apis::LoggingV2::MonitoredResource::Representation
hash :json_payload, as: 'jsonPayload'
property :operation, as: 'operation', class: Google::Apis::LoggingV2::LogEntryOperation, decorator: Google::Apis::LoggingV2::LogEntryOperation::Representation
property :insert_id, as: 'insertId'
property :text_payload, as: 'textPayload'
hash :proto_payload, as: 'protoPayload'
end
end end
class Empty class Empty
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
end include Google::Apis::Core::JsonObjectSupport
end
class LogEntry
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class SourceLocation class SourceLocation
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :file, as: 'file' include Google::Apis::Core::JsonObjectSupport
property :function_name, as: 'functionName'
property :line, as: 'line'
end
end end
class ListLogEntriesRequest class ListLogEntriesRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :project_ids, as: 'projectIds' include Google::Apis::Core::JsonObjectSupport
property :filter, as: 'filter'
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
property :order_by, as: 'orderBy'
collection :resource_names, as: 'resourceNames'
end
end end
class RequestLog class RequestLog
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :source_reference, as: 'sourceReference', class: Google::Apis::LoggingV2::SourceReference, decorator: Google::Apis::LoggingV2::SourceReference::Representation
property :response_size, as: 'responseSize' include Google::Apis::Core::JsonObjectSupport
property :trace_id, as: 'traceId'
collection :line, as: 'line', class: Google::Apis::LoggingV2::LogLine, decorator: Google::Apis::LoggingV2::LogLine::Representation
property :task_queue_name, as: 'taskQueueName'
property :referrer, as: 'referrer'
property :request_id, as: 'requestId'
property :nickname, as: 'nickname'
property :pending_time, as: 'pendingTime'
property :resource, as: 'resource'
property :status, as: 'status'
property :task_name, as: 'taskName'
property :url_map_entry, as: 'urlMapEntry'
property :instance_index, as: 'instanceIndex'
property :host, as: 'host'
property :finished, as: 'finished'
property :http_version, as: 'httpVersion'
property :start_time, as: 'startTime'
property :latency, as: 'latency'
property :ip, as: 'ip'
property :app_id, as: 'appId'
property :app_engine_release, as: 'appEngineRelease'
property :method_prop, as: 'method'
property :cost, as: 'cost'
property :instance_id, as: 'instanceId'
property :mega_cycles, as: 'megaCycles'
property :first, as: 'first'
property :version_id, as: 'versionId'
property :module_id, as: 'moduleId'
property :end_time, as: 'endTime'
property :user_agent, as: 'userAgent'
property :was_loading_request, as: 'wasLoadingRequest'
end
end end
class ListMonitoredResourceDescriptorsResponse class ListMonitoredResourceDescriptorsResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :resource_descriptors, as: 'resourceDescriptors', class: Google::Apis::LoggingV2::MonitoredResourceDescriptor, decorator: Google::Apis::LoggingV2::MonitoredResourceDescriptor::Representation
property :next_page_token, as: 'nextPageToken' include Google::Apis::Core::JsonObjectSupport
end
end end
class SourceReference class SourceReference
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :repository, as: 'repository'
property :revision_id, as: 'revisionId'
end
end
class WriteLogEntriesResponse include Google::Apis::Core::JsonObjectSupport
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class LogEntryOperation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :id, as: 'id'
property :producer, as: 'producer'
property :first, as: 'first'
property :last, as: 'last'
end
end end
class LogMetric class LogMetric
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name' include Google::Apis::Core::JsonObjectSupport
property :description, as: 'description' end
property :version, as: 'version'
property :filter, as: 'filter' class LogEntryOperation
end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class WriteLogEntriesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class MonitoredResource class MonitoredResource
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :type, as: 'type'
end
end
class WriteLogEntriesRequest include Google::Apis::Core::JsonObjectSupport
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :resource, as: 'resource', class: Google::Apis::LoggingV2::MonitoredResource, decorator: Google::Apis::LoggingV2::MonitoredResource::Representation
property :log_name, as: 'logName'
collection :entries, as: 'entries', class: Google::Apis::LoggingV2::LogEntry, decorator: Google::Apis::LoggingV2::LogEntry::Representation
property :partial_success, as: 'partialSuccess'
end
end end
class LogSink class LogSink
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :start_time, as: 'startTime' include Google::Apis::Core::JsonObjectSupport
property :writer_identity, as: 'writerIdentity' end
property :output_version_format, as: 'outputVersionFormat'
property :name, as: 'name' class WriteLogEntriesRequest
property :destination, as: 'destination' class Representation < Google::Apis::Core::JsonRepresentation; end
property :filter, as: 'filter'
property :end_time, as: 'endTime' include Google::Apis::Core::JsonObjectSupport
end
end end
class ListLogsResponse class ListLogsResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :log_names, as: 'logNames' collection :log_names, as: 'logNames'
property :next_page_token, as: 'nextPageToken'
end
end
class ListSinksResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :sinks, as: 'sinks', class: Google::Apis::LoggingV2::LogSink, decorator: Google::Apis::LoggingV2::LogSink::Representation
property :next_page_token, as: 'nextPageToken'
end end
end end
class HttpRequest class HttpRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :cache_validated_with_origin_server, as: 'cacheValidatedWithOriginServer'
property :status, as: 'status'
property :referer, as: 'referer'
property :user_agent, as: 'userAgent' property :user_agent, as: 'userAgent'
property :latency, as: 'latency' property :latency, as: 'latency'
property :cache_fill_bytes, as: 'cacheFillBytes' property :cache_fill_bytes, as: 'cacheFillBytes'
@ -359,22 +184,10 @@ module Google
property :response_size, as: 'responseSize' property :response_size, as: 'responseSize'
property :request_size, as: 'requestSize' property :request_size, as: 'requestSize'
property :request_url, as: 'requestUrl' property :request_url, as: 'requestUrl'
property :server_ip, as: 'serverIp'
property :remote_ip, as: 'remoteIp' property :remote_ip, as: 'remoteIp'
property :server_ip, as: 'serverIp'
property :cache_lookup, as: 'cacheLookup' property :cache_lookup, as: 'cacheLookup'
property :cache_hit, as: 'cacheHit' property :cache_hit, as: 'cacheHit'
property :cache_validated_with_origin_server, as: 'cacheValidatedWithOriginServer'
property :status, as: 'status'
property :referer, as: 'referer'
end
end
class ListSinksResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :sinks, as: 'sinks', class: Google::Apis::LoggingV2::LogSink, decorator: Google::Apis::LoggingV2::LogSink::Representation
end end
end end
@ -411,9 +224,196 @@ module Google
class ListLogEntriesResponse class ListLogEntriesResponse
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :entries, as: 'entries', class: Google::Apis::LoggingV2::LogEntry, decorator: Google::Apis::LoggingV2::LogEntry::Representation collection :entries, as: 'entries', class: Google::Apis::LoggingV2::LogEntry, decorator: Google::Apis::LoggingV2::LogEntry::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class LogLine
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :severity, as: 'severity'
property :log_message, as: 'logMessage'
property :source_location, as: 'sourceLocation', class: Google::Apis::LoggingV2::SourceLocation, decorator: Google::Apis::LoggingV2::SourceLocation::Representation
property :time, as: 'time'
end
end
class ListLogMetricsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :metrics, as: 'metrics', class: Google::Apis::LoggingV2::LogMetric, decorator: Google::Apis::LoggingV2::LogMetric::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class Empty
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class LogEntry
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :text_payload, as: 'textPayload'
hash :proto_payload, as: 'protoPayload'
property :trace, as: 'trace'
hash :labels, as: 'labels'
property :severity, as: 'severity'
property :source_location, as: 'sourceLocation', class: Google::Apis::LoggingV2::LogEntrySourceLocation, decorator: Google::Apis::LoggingV2::LogEntrySourceLocation::Representation
property :timestamp, as: 'timestamp'
property :log_name, as: 'logName'
property :http_request, as: 'httpRequest', class: Google::Apis::LoggingV2::HttpRequest, decorator: Google::Apis::LoggingV2::HttpRequest::Representation
property :resource, as: 'resource', class: Google::Apis::LoggingV2::MonitoredResource, decorator: Google::Apis::LoggingV2::MonitoredResource::Representation
hash :json_payload, as: 'jsonPayload'
property :insert_id, as: 'insertId'
property :operation, as: 'operation', class: Google::Apis::LoggingV2::LogEntryOperation, decorator: Google::Apis::LoggingV2::LogEntryOperation::Representation
end
end
class SourceLocation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :file, as: 'file'
property :function_name, as: 'functionName'
property :line, as: 'line'
end
end
class ListLogEntriesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :project_ids, as: 'projectIds'
property :filter, as: 'filter'
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
property :order_by, as: 'orderBy'
collection :resource_names, as: 'resourceNames'
end
end
class RequestLog
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :module_id, as: 'moduleId'
property :end_time, as: 'endTime'
property :user_agent, as: 'userAgent'
property :was_loading_request, as: 'wasLoadingRequest'
collection :source_reference, as: 'sourceReference', class: Google::Apis::LoggingV2::SourceReference, decorator: Google::Apis::LoggingV2::SourceReference::Representation
property :response_size, as: 'responseSize'
property :trace_id, as: 'traceId'
collection :line, as: 'line', class: Google::Apis::LoggingV2::LogLine, decorator: Google::Apis::LoggingV2::LogLine::Representation
property :task_queue_name, as: 'taskQueueName'
property :referrer, as: 'referrer'
property :request_id, as: 'requestId'
property :nickname, as: 'nickname'
property :pending_time, as: 'pendingTime'
property :resource, as: 'resource'
property :status, as: 'status'
property :task_name, as: 'taskName'
property :url_map_entry, as: 'urlMapEntry'
property :instance_index, as: 'instanceIndex'
property :host, as: 'host'
property :finished, as: 'finished'
property :http_version, as: 'httpVersion'
property :start_time, as: 'startTime'
property :latency, as: 'latency'
property :ip, as: 'ip'
property :app_id, as: 'appId'
property :app_engine_release, as: 'appEngineRelease'
property :method_prop, as: 'method'
property :cost, as: 'cost'
property :instance_id, as: 'instanceId'
property :mega_cycles, as: 'megaCycles'
property :first, as: 'first'
property :version_id, as: 'versionId'
end
end
class ListMonitoredResourceDescriptorsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :resource_descriptors, as: 'resourceDescriptors', class: Google::Apis::LoggingV2::MonitoredResourceDescriptor, decorator: Google::Apis::LoggingV2::MonitoredResourceDescriptor::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class SourceReference
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :repository, as: 'repository'
property :revision_id, as: 'revisionId'
end
end
class LogMetric
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :version, as: 'version'
property :filter, as: 'filter'
property :name, as: 'name'
property :description, as: 'description'
end
end
class LogEntryOperation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :last, as: 'last'
property :id, as: 'id'
property :producer, as: 'producer'
property :first, as: 'first'
end
end
class WriteLogEntriesResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class MonitoredResource
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :type, as: 'type'
hash :labels, as: 'labels'
end
end
class LogSink
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :filter, as: 'filter'
property :destination, as: 'destination'
property :end_time, as: 'endTime'
property :writer_identity, as: 'writerIdentity'
property :start_time, as: 'startTime'
property :output_version_format, as: 'outputVersionFormat'
end
end
class WriteLogEntriesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :log_name, as: 'logName'
collection :entries, as: 'entries', class: Google::Apis::LoggingV2::LogEntry, decorator: Google::Apis::LoggingV2::LogEntry::Representation
property :partial_success, as: 'partialSuccess'
hash :labels, as: 'labels'
property :resource, as: 'resource', class: Google::Apis::LoggingV2::MonitoredResource, decorator: Google::Apis::LoggingV2::MonitoredResource::Representation
end end
end end
end end

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -22,108 +22,6 @@ module Google
module Apis module Apis
module LoggingV2beta1 module LoggingV2beta1
class ListLogEntriesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class RequestLog
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListMonitoredResourceDescriptorsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SourceReference
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class WriteLogEntriesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogEntryOperation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogMetric
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class MonitoredResource
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogSink
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class WriteLogEntriesRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLogsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListSinksResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class HttpRequest
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LabelDescriptor
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class MonitoredResourceDescriptor
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogEntrySourceLocation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLogEntriesResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LogLine class LogLine
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -155,208 +53,105 @@ module Google
end end
class ListLogEntriesRequest class ListLogEntriesRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :order_by, as: 'orderBy' include Google::Apis::Core::JsonObjectSupport
collection :resource_names, as: 'resourceNames'
collection :project_ids, as: 'projectIds'
property :filter, as: 'filter'
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
end
end end
class RequestLog class RequestLog
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :version_id, as: 'versionId'
property :module_id, as: 'moduleId'
property :end_time, as: 'endTime'
property :user_agent, as: 'userAgent'
property :was_loading_request, as: 'wasLoadingRequest'
collection :source_reference, as: 'sourceReference', class: Google::Apis::LoggingV2beta1::SourceReference, decorator: Google::Apis::LoggingV2beta1::SourceReference::Representation
property :response_size, as: 'responseSize' include Google::Apis::Core::JsonObjectSupport
property :trace_id, as: 'traceId'
collection :line, as: 'line', class: Google::Apis::LoggingV2beta1::LogLine, decorator: Google::Apis::LoggingV2beta1::LogLine::Representation
property :referrer, as: 'referrer'
property :task_queue_name, as: 'taskQueueName'
property :request_id, as: 'requestId'
property :nickname, as: 'nickname'
property :status, as: 'status'
property :resource, as: 'resource'
property :pending_time, as: 'pendingTime'
property :task_name, as: 'taskName'
property :url_map_entry, as: 'urlMapEntry'
property :instance_index, as: 'instanceIndex'
property :finished, as: 'finished'
property :host, as: 'host'
property :http_version, as: 'httpVersion'
property :start_time, as: 'startTime'
property :latency, as: 'latency'
property :ip, as: 'ip'
property :app_id, as: 'appId'
property :app_engine_release, as: 'appEngineRelease'
property :method_prop, as: 'method'
property :cost, as: 'cost'
property :instance_id, as: 'instanceId'
property :mega_cycles, as: 'megaCycles'
property :first, as: 'first'
end
end end
class ListMonitoredResourceDescriptorsResponse class ListMonitoredResourceDescriptorsResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :resource_descriptors, as: 'resourceDescriptors', class: Google::Apis::LoggingV2beta1::MonitoredResourceDescriptor, decorator: Google::Apis::LoggingV2beta1::MonitoredResourceDescriptor::Representation
property :next_page_token, as: 'nextPageToken' include Google::Apis::Core::JsonObjectSupport
end
end end
class SourceReference class SourceReference
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :repository, as: 'repository'
property :revision_id, as: 'revisionId'
end
end
class WriteLogEntriesResponse include Google::Apis::Core::JsonObjectSupport
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end end
class LogEntryOperation class LogEntryOperation
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :last, as: 'last' include Google::Apis::Core::JsonObjectSupport
property :id, as: 'id'
property :producer, as: 'producer'
property :first, as: 'first'
end
end end
class LogMetric class LogMetric
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name' include Google::Apis::Core::JsonObjectSupport
property :description, as: 'description' end
property :version, as: 'version'
property :filter, as: 'filter' class WriteLogEntriesResponse
end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class MonitoredResource class MonitoredResource
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :type, as: 'type'
end
end
class LogSink include Google::Apis::Core::JsonObjectSupport
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :start_time, as: 'startTime'
property :writer_identity, as: 'writerIdentity'
property :output_version_format, as: 'outputVersionFormat'
property :name, as: 'name'
property :filter, as: 'filter'
property :destination, as: 'destination'
property :end_time, as: 'endTime'
end
end end
class WriteLogEntriesRequest class WriteLogEntriesRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :resource, as: 'resource', class: Google::Apis::LoggingV2beta1::MonitoredResource, decorator: Google::Apis::LoggingV2beta1::MonitoredResource::Representation
property :log_name, as: 'logName' include Google::Apis::Core::JsonObjectSupport
collection :entries, as: 'entries', class: Google::Apis::LoggingV2beta1::LogEntry, decorator: Google::Apis::LoggingV2beta1::LogEntry::Representation end
property :partial_success, as: 'partialSuccess' class LogSink
end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end end
class ListLogsResponse class ListLogsResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
collection :log_names, as: 'logNames'
property :next_page_token, as: 'nextPageToken'
end
end
class ListSinksResponse include Google::Apis::Core::JsonObjectSupport
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :sinks, as: 'sinks', class: Google::Apis::LoggingV2beta1::LogSink, decorator: Google::Apis::LoggingV2beta1::LogSink::Representation
end
end end
class HttpRequest class HttpRequest
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :cache_lookup, as: 'cacheLookup' include Google::Apis::Core::JsonObjectSupport
property :cache_hit, as: 'cacheHit' end
property :cache_validated_with_origin_server, as: 'cacheValidatedWithOriginServer'
property :status, as: 'status' class ListSinksResponse
property :referer, as: 'referer' class Representation < Google::Apis::Core::JsonRepresentation; end
property :latency, as: 'latency'
property :user_agent, as: 'userAgent' include Google::Apis::Core::JsonObjectSupport
property :cache_fill_bytes, as: 'cacheFillBytes'
property :request_method, as: 'requestMethod'
property :request_size, as: 'requestSize'
property :response_size, as: 'responseSize'
property :request_url, as: 'requestUrl'
property :remote_ip, as: 'remoteIp'
property :server_ip, as: 'serverIp'
end
end end
class LabelDescriptor class LabelDescriptor
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :key, as: 'key' include Google::Apis::Core::JsonObjectSupport
property :description, as: 'description'
property :value_type, as: 'valueType'
end
end end
class MonitoredResourceDescriptor class MonitoredResourceDescriptor
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :display_name, as: 'displayName'
property :description, as: 'description'
property :type, as: 'type'
collection :labels, as: 'labels', class: Google::Apis::LoggingV2beta1::LabelDescriptor, decorator: Google::Apis::LoggingV2beta1::LabelDescriptor::Representation
end include Google::Apis::Core::JsonObjectSupport
end end
class LogEntrySourceLocation class LogEntrySourceLocation
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :line, as: 'line' include Google::Apis::Core::JsonObjectSupport
property :file, as: 'file'
property :function, as: 'function'
end
end end
class ListLogEntriesResponse class ListLogEntriesResponse
# @private class Representation < Google::Apis::Core::JsonRepresentation; end
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :entries, as: 'entries', class: Google::Apis::LoggingV2beta1::LogEntry, decorator: Google::Apis::LoggingV2beta1::LogEntry::Representation
end include Google::Apis::Core::JsonObjectSupport
end end
class LogLine class LogLine
@ -382,23 +177,23 @@ module Google
class LogEntry class LogEntry
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :timestamp, as: 'timestamp'
property :log_name, as: 'logName' property :log_name, as: 'logName'
property :http_request, as: 'httpRequest', class: Google::Apis::LoggingV2beta1::HttpRequest, decorator: Google::Apis::LoggingV2beta1::HttpRequest::Representation
property :resource, as: 'resource', class: Google::Apis::LoggingV2beta1::MonitoredResource, decorator: Google::Apis::LoggingV2beta1::MonitoredResource::Representation property :resource, as: 'resource', class: Google::Apis::LoggingV2beta1::MonitoredResource, decorator: Google::Apis::LoggingV2beta1::MonitoredResource::Representation
property :http_request, as: 'httpRequest', class: Google::Apis::LoggingV2beta1::HttpRequest, decorator: Google::Apis::LoggingV2beta1::HttpRequest::Representation
hash :json_payload, as: 'jsonPayload' hash :json_payload, as: 'jsonPayload'
property :operation, as: 'operation', class: Google::Apis::LoggingV2beta1::LogEntryOperation, decorator: Google::Apis::LoggingV2beta1::LogEntryOperation::Representation property :operation, as: 'operation', class: Google::Apis::LoggingV2beta1::LogEntryOperation, decorator: Google::Apis::LoggingV2beta1::LogEntryOperation::Representation
property :insert_id, as: 'insertId' property :insert_id, as: 'insertId'
property :text_payload, as: 'textPayload' property :text_payload, as: 'textPayload'
hash :proto_payload, as: 'protoPayload' hash :proto_payload, as: 'protoPayload'
property :trace, as: 'trace'
hash :labels, as: 'labels' hash :labels, as: 'labels'
property :trace, as: 'trace'
property :severity, as: 'severity' property :severity, as: 'severity'
property :source_location, as: 'sourceLocation', class: Google::Apis::LoggingV2beta1::LogEntrySourceLocation, decorator: Google::Apis::LoggingV2beta1::LogEntrySourceLocation::Representation property :source_location, as: 'sourceLocation', class: Google::Apis::LoggingV2beta1::LogEntrySourceLocation, decorator: Google::Apis::LoggingV2beta1::LogEntrySourceLocation::Representation
property :timestamp, as: 'timestamp'
end end
end end
@ -411,11 +206,216 @@ module Google
class SourceLocation class SourceLocation
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :line, as: 'line'
property :file, as: 'file' property :file, as: 'file'
property :function_name, as: 'functionName' property :function_name, as: 'functionName'
end
end
class ListLogEntriesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :page_token, as: 'pageToken'
property :page_size, as: 'pageSize'
property :order_by, as: 'orderBy'
collection :resource_names, as: 'resourceNames'
property :filter, as: 'filter'
collection :project_ids, as: 'projectIds'
end
end
class RequestLog
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :line, as: 'line', class: Google::Apis::LoggingV2beta1::LogLine, decorator: Google::Apis::LoggingV2beta1::LogLine::Representation
property :referrer, as: 'referrer'
property :task_queue_name, as: 'taskQueueName'
property :request_id, as: 'requestId'
property :nickname, as: 'nickname'
property :status, as: 'status'
property :pending_time, as: 'pendingTime'
property :resource, as: 'resource'
property :task_name, as: 'taskName'
property :url_map_entry, as: 'urlMapEntry'
property :instance_index, as: 'instanceIndex'
property :host, as: 'host'
property :finished, as: 'finished'
property :http_version, as: 'httpVersion'
property :start_time, as: 'startTime'
property :latency, as: 'latency'
property :ip, as: 'ip'
property :app_id, as: 'appId'
property :app_engine_release, as: 'appEngineRelease'
property :method_prop, as: 'method'
property :cost, as: 'cost'
property :instance_id, as: 'instanceId'
property :mega_cycles, as: 'megaCycles'
property :first, as: 'first'
property :version_id, as: 'versionId'
property :module_id, as: 'moduleId'
property :end_time, as: 'endTime'
property :user_agent, as: 'userAgent'
property :was_loading_request, as: 'wasLoadingRequest'
collection :source_reference, as: 'sourceReference', class: Google::Apis::LoggingV2beta1::SourceReference, decorator: Google::Apis::LoggingV2beta1::SourceReference::Representation
property :response_size, as: 'responseSize'
property :trace_id, as: 'traceId'
end
end
class ListMonitoredResourceDescriptorsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :resource_descriptors, as: 'resourceDescriptors', class: Google::Apis::LoggingV2beta1::MonitoredResourceDescriptor, decorator: Google::Apis::LoggingV2beta1::MonitoredResourceDescriptor::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class SourceReference
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :repository, as: 'repository'
property :revision_id, as: 'revisionId'
end
end
class LogEntryOperation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :producer, as: 'producer'
property :first, as: 'first'
property :last, as: 'last'
property :id, as: 'id'
end
end
class LogMetric
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :description, as: 'description'
property :version, as: 'version'
property :filter, as: 'filter'
end
end
class WriteLogEntriesResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class MonitoredResource
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :type, as: 'type'
end
end
class WriteLogEntriesRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
hash :labels, as: 'labels'
property :resource, as: 'resource', class: Google::Apis::LoggingV2beta1::MonitoredResource, decorator: Google::Apis::LoggingV2beta1::MonitoredResource::Representation
property :log_name, as: 'logName'
collection :entries, as: 'entries', class: Google::Apis::LoggingV2beta1::LogEntry, decorator: Google::Apis::LoggingV2beta1::LogEntry::Representation
property :partial_success, as: 'partialSuccess'
end
end
class LogSink
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :writer_identity, as: 'writerIdentity'
property :start_time, as: 'startTime'
property :output_version_format, as: 'outputVersionFormat'
property :name, as: 'name'
property :filter, as: 'filter'
property :destination, as: 'destination'
property :end_time, as: 'endTime'
end
end
class ListLogsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :log_names, as: 'logNames'
property :next_page_token, as: 'nextPageToken'
end
end
class HttpRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :cache_hit, as: 'cacheHit'
property :cache_validated_with_origin_server, as: 'cacheValidatedWithOriginServer'
property :status, as: 'status'
property :referer, as: 'referer'
property :latency, as: 'latency'
property :user_agent, as: 'userAgent'
property :cache_fill_bytes, as: 'cacheFillBytes'
property :request_method, as: 'requestMethod'
property :request_size, as: 'requestSize'
property :response_size, as: 'responseSize'
property :request_url, as: 'requestUrl'
property :remote_ip, as: 'remoteIp'
property :server_ip, as: 'serverIp'
property :cache_lookup, as: 'cacheLookup'
end
end
class ListSinksResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :sinks, as: 'sinks', class: Google::Apis::LoggingV2beta1::LogSink, decorator: Google::Apis::LoggingV2beta1::LogSink::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class LabelDescriptor
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :description, as: 'description'
property :value_type, as: 'valueType'
property :key, as: 'key'
end
end
class MonitoredResourceDescriptor
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :display_name, as: 'displayName'
property :description, as: 'description'
property :type, as: 'type'
collection :labels, as: 'labels', class: Google::Apis::LoggingV2beta1::LabelDescriptor, decorator: Google::Apis::LoggingV2beta1::LabelDescriptor::Representation
property :name, as: 'name'
end
end
class LogEntrySourceLocation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :file, as: 'file'
property :function, as: 'function'
property :line, as: 'line' property :line, as: 'line'
end end
end end
class ListLogEntriesResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :entries, as: 'entries', class: Google::Apis::LoggingV2beta1::LogEntry, decorator: Google::Apis::LoggingV2beta1::LogEntry::Representation
property :next_page_token, as: 'nextPageToken'
end
end
end end
end end
end end

File diff suppressed because it is too large Load Diff

View File

@ -22,6 +22,153 @@ module Google
module Apis module Apis
module ManufacturersV1 module ManufacturersV1
# The number of products in a single package. For more information, see
# https://support.google.com/manufacturers/answer/6124116#count.
class Count
include Google::Apis::Core::Hashable
# The numeric value of the number of products in a package.
# Corresponds to the JSON property `value`
# @return [String]
attr_accessor :value
# The unit in which these products are counted.
# Corresponds to the JSON property `unit`
# @return [String]
attr_accessor :unit
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@value = args[:value] if args.key?(:value)
@unit = args[:unit] if args.key?(:unit)
end
end
# Product data.
class Product
include Google::Apis::Core::Hashable
# Names of the attributes of the product deleted manually via the
# Manufacturer Center UI.
# @OutputOnly
# Corresponds to the JSON property `manuallyDeletedAttributes`
# @return [Array<String>]
attr_accessor :manually_deleted_attributes
# A server-generated list of issues associated with the product.
# @OutputOnly
# Corresponds to the JSON property `issues`
# @return [Array<Google::Apis::ManufacturersV1::Issue>]
attr_accessor :issues
# Attributes of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116.
# Corresponds to the JSON property `finalAttributes`
# @return [Google::Apis::ManufacturersV1::Attributes]
attr_accessor :final_attributes
# The ID of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#id.
# @OutputOnly
# Corresponds to the JSON property `productId`
# @return [String]
attr_accessor :product_id
# Attributes of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116.
# Corresponds to the JSON property `uploadedAttributes`
# @return [Google::Apis::ManufacturersV1::Attributes]
attr_accessor :uploaded_attributes
# Parent ID in the format `accounts/`account_id``.
# `account_id` - The ID of the Manufacturer Center account.
# @OutputOnly
# Corresponds to the JSON property `parent`
# @return [String]
attr_accessor :parent
# Attributes of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116.
# Corresponds to the JSON property `manuallyProvidedAttributes`
# @return [Google::Apis::ManufacturersV1::Attributes]
attr_accessor :manually_provided_attributes
# The content language of the product as a two-letter ISO 639-1 language code
# (for example, en).
# @OutputOnly
# Corresponds to the JSON property `contentLanguage`
# @return [String]
attr_accessor :content_language
# The target country of the product as a CLDR territory code (for example,
# US).
# @OutputOnly
# Corresponds to the JSON property `targetCountry`
# @return [String]
attr_accessor :target_country
# Name in the format ``target_country`:`content_language`:`product_id``.
# `target_country` - The target country of the product as a CLDR territory
# code (for example, US).
# `content_language` - The content language of the product as a two-letter
# ISO 639-1 language code (for example, en).
# `product_id` - The ID of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#
# id.
# @OutputOnly
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@manually_deleted_attributes = args[:manually_deleted_attributes] if args.key?(:manually_deleted_attributes)
@issues = args[:issues] if args.key?(:issues)
@final_attributes = args[:final_attributes] if args.key?(:final_attributes)
@product_id = args[:product_id] if args.key?(:product_id)
@uploaded_attributes = args[:uploaded_attributes] if args.key?(:uploaded_attributes)
@parent = args[:parent] if args.key?(:parent)
@manually_provided_attributes = args[:manually_provided_attributes] if args.key?(:manually_provided_attributes)
@content_language = args[:content_language] if args.key?(:content_language)
@target_country = args[:target_country] if args.key?(:target_country)
@name = args[:name] if args.key?(:name)
end
end
# The capacity of a product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#capacity.
class Capacity
include Google::Apis::Core::Hashable
# The numeric value of the capacity.
# Corresponds to the JSON property `value`
# @return [String]
attr_accessor :value
# The unit of the capacity, i.e., MB, GB, or TB.
# Corresponds to the JSON property `unit`
# @return [String]
attr_accessor :unit
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@value = args[:value] if args.key?(:value)
@unit = args[:unit] if args.key?(:unit)
end
end
# #
class ListProductsResponse class ListProductsResponse
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -79,42 +226,15 @@ module Google
end end
end end
# A feature description of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#featuredesc.
class FeatureDescription
include Google::Apis::Core::Hashable
# An image.
# Corresponds to the JSON property `image`
# @return [Google::Apis::ManufacturersV1::Image]
attr_accessor :image
# A short description of the feature.
# Corresponds to the JSON property `headline`
# @return [String]
attr_accessor :headline
# A detailed description of the feature.
# Corresponds to the JSON property `text`
# @return [String]
attr_accessor :text
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@image = args[:image] if args.key?(:image)
@headline = args[:headline] if args.key?(:headline)
@text = args[:text] if args.key?(:text)
end
end
# Product issue. # Product issue.
class Issue class Issue
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The timestamp when this issue appeared.
# Corresponds to the JSON property `timestamp`
# @return [String]
attr_accessor :timestamp
# The severity of the issue. # The severity of the issue.
# Corresponds to the JSON property `severity` # Corresponds to the JSON property `severity`
# @return [String] # @return [String]
@ -138,10 +258,39 @@ module Google
# @return [String] # @return [String]
attr_accessor :attribute attr_accessor :attribute
# The timestamp when this issue appeared. def initialize(**args)
# Corresponds to the JSON property `timestamp` update!(**args)
end
# Update properties of this object
def update!(**args)
@timestamp = args[:timestamp] if args.key?(:timestamp)
@severity = args[:severity] if args.key?(:severity)
@description = args[:description] if args.key?(:description)
@type = args[:type] if args.key?(:type)
@attribute = args[:attribute] if args.key?(:attribute)
end
end
# A feature description of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#featuredesc.
class FeatureDescription
include Google::Apis::Core::Hashable
# A short description of the feature.
# Corresponds to the JSON property `headline`
# @return [String] # @return [String]
attr_accessor :timestamp attr_accessor :headline
# A detailed description of the feature.
# Corresponds to the JSON property `text`
# @return [String]
attr_accessor :text
# An image.
# Corresponds to the JSON property `image`
# @return [Google::Apis::ManufacturersV1::Image]
attr_accessor :image
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
@ -149,11 +298,9 @@ module Google
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@severity = args[:severity] if args.key?(:severity) @headline = args[:headline] if args.key?(:headline)
@description = args[:description] if args.key?(:description) @text = args[:text] if args.key?(:text)
@type = args[:type] if args.key?(:type) @image = args[:image] if args.key?(:image)
@attribute = args[:attribute] if args.key?(:attribute)
@timestamp = args[:timestamp] if args.key?(:timestamp)
end end
end end
@ -186,12 +333,6 @@ module Google
class Image class Image
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The status of the image.
# @OutputOnly
# Corresponds to the JSON property `status`
# @return [String]
attr_accessor :status
# The type of the image, i.e., crawled or uploaded. # The type of the image, i.e., crawled or uploaded.
# @OutputOnly # @OutputOnly
# Corresponds to the JSON property `type` # Corresponds to the JSON property `type`
@ -205,15 +346,21 @@ module Google
# @return [String] # @return [String]
attr_accessor :image_url attr_accessor :image_url
# The status of the image.
# @OutputOnly
# Corresponds to the JSON property `status`
# @return [String]
attr_accessor :status
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@status = args[:status] if args.key?(:status)
@type = args[:type] if args.key?(:type) @type = args[:type] if args.key?(:type)
@image_url = args[:image_url] if args.key?(:image_url) @image_url = args[:image_url] if args.key?(:image_url)
@status = args[:status] if args.key?(:status)
end end
end end
@ -222,70 +369,11 @@ module Google
class Attributes class Attributes
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The canonical name of the product. For more information, see # The flavor of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#productname. # https://support.google.com/manufacturers/answer/6124116#flavor.
# Corresponds to the JSON property `productName` # Corresponds to the JSON property `flavor`
# @return [String] # @return [String]
attr_accessor :product_name attr_accessor :flavor
# The size type of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#sizetype.
# Corresponds to the JSON property `sizeType`
# @return [String]
attr_accessor :size_type
# A price.
# Corresponds to the JSON property `suggestedRetailPrice`
# @return [Google::Apis::ManufacturersV1::Price]
attr_accessor :suggested_retail_price
# The rich format description of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#featuredesc.
# Corresponds to the JSON property `featureDescription`
# @return [Array<Google::Apis::ManufacturersV1::FeatureDescription>]
attr_accessor :feature_description
# The size of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#size.
# Corresponds to the JSON property `size`
# @return [String]
attr_accessor :size
# The title of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#title.
# Corresponds to the JSON property `title`
# @return [String]
attr_accessor :title
# The number of products in a single package. For more information, see
# https://support.google.com/manufacturers/answer/6124116#count.
# Corresponds to the JSON property `count`
# @return [Google::Apis::ManufacturersV1::Count]
attr_accessor :count
# The brand name of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#brand.
# Corresponds to the JSON property `brand`
# @return [String]
attr_accessor :brand
# The material of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#material.
# Corresponds to the JSON property `material`
# @return [String]
attr_accessor :material
# The disclosure date of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#disclosure.
# Corresponds to the JSON property `disclosureDate`
# @return [String]
attr_accessor :disclosure_date
# The scent of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#scent.
# Corresponds to the JSON property `scent`
# @return [String]
attr_accessor :scent
# The details of the product. For more information, see # The details of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#productdetail. # https://support.google.com/manufacturers/answer/6124116#productdetail.
@ -293,12 +381,6 @@ module Google
# @return [Array<Google::Apis::ManufacturersV1::ProductDetail>] # @return [Array<Google::Apis::ManufacturersV1::ProductDetail>]
attr_accessor :product_detail attr_accessor :product_detail
# The flavor of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#flavor.
# Corresponds to the JSON property `flavor`
# @return [String]
attr_accessor :flavor
# The target age group of the product. For more information, see # The target age group of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#agegroup. # https://support.google.com/manufacturers/answer/6124116#agegroup.
# Corresponds to the JSON property `ageGroup` # Corresponds to the JSON property `ageGroup`
@ -413,25 +495,79 @@ module Google
# @return [String] # @return [String]
attr_accessor :color attr_accessor :color
# The canonical name of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#productname.
# Corresponds to the JSON property `productName`
# @return [String]
attr_accessor :product_name
# The size type of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#sizetype.
# Corresponds to the JSON property `sizeType`
# @return [String]
attr_accessor :size_type
# A price.
# Corresponds to the JSON property `suggestedRetailPrice`
# @return [Google::Apis::ManufacturersV1::Price]
attr_accessor :suggested_retail_price
# The rich format description of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#featuredesc.
# Corresponds to the JSON property `featureDescription`
# @return [Array<Google::Apis::ManufacturersV1::FeatureDescription>]
attr_accessor :feature_description
# The size of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#size.
# Corresponds to the JSON property `size`
# @return [String]
attr_accessor :size
# The title of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#title.
# Corresponds to the JSON property `title`
# @return [String]
attr_accessor :title
# The number of products in a single package. For more information, see
# https://support.google.com/manufacturers/answer/6124116#count.
# Corresponds to the JSON property `count`
# @return [Google::Apis::ManufacturersV1::Count]
attr_accessor :count
# The brand name of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#brand.
# Corresponds to the JSON property `brand`
# @return [String]
attr_accessor :brand
# The disclosure date of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#disclosure.
# Corresponds to the JSON property `disclosureDate`
# @return [String]
attr_accessor :disclosure_date
# The material of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#material.
# Corresponds to the JSON property `material`
# @return [String]
attr_accessor :material
# The scent of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#scent.
# Corresponds to the JSON property `scent`
# @return [String]
attr_accessor :scent
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@product_name = args[:product_name] if args.key?(:product_name)
@size_type = args[:size_type] if args.key?(:size_type)
@suggested_retail_price = args[:suggested_retail_price] if args.key?(:suggested_retail_price)
@feature_description = args[:feature_description] if args.key?(:feature_description)
@size = args[:size] if args.key?(:size)
@title = args[:title] if args.key?(:title)
@count = args[:count] if args.key?(:count)
@brand = args[:brand] if args.key?(:brand)
@material = args[:material] if args.key?(:material)
@disclosure_date = args[:disclosure_date] if args.key?(:disclosure_date)
@scent = args[:scent] if args.key?(:scent)
@product_detail = args[:product_detail] if args.key?(:product_detail)
@flavor = args[:flavor] if args.key?(:flavor) @flavor = args[:flavor] if args.key?(:flavor)
@product_detail = args[:product_detail] if args.key?(:product_detail)
@age_group = args[:age_group] if args.key?(:age_group) @age_group = args[:age_group] if args.key?(:age_group)
@mpn = args[:mpn] if args.key?(:mpn) @mpn = args[:mpn] if args.key?(:mpn)
@product_page_url = args[:product_page_url] if args.key?(:product_page_url) @product_page_url = args[:product_page_url] if args.key?(:product_page_url)
@ -451,153 +587,17 @@ module Google
@additional_image_link = args[:additional_image_link] if args.key?(:additional_image_link) @additional_image_link = args[:additional_image_link] if args.key?(:additional_image_link)
@video_link = args[:video_link] if args.key?(:video_link) @video_link = args[:video_link] if args.key?(:video_link)
@color = args[:color] if args.key?(:color) @color = args[:color] if args.key?(:color)
end @product_name = args[:product_name] if args.key?(:product_name)
end @size_type = args[:size_type] if args.key?(:size_type)
@suggested_retail_price = args[:suggested_retail_price] if args.key?(:suggested_retail_price)
# The number of products in a single package. For more information, see @feature_description = args[:feature_description] if args.key?(:feature_description)
# https://support.google.com/manufacturers/answer/6124116#count. @size = args[:size] if args.key?(:size)
class Count @title = args[:title] if args.key?(:title)
include Google::Apis::Core::Hashable @count = args[:count] if args.key?(:count)
@brand = args[:brand] if args.key?(:brand)
# The numeric value of the number of products in a package. @disclosure_date = args[:disclosure_date] if args.key?(:disclosure_date)
# Corresponds to the JSON property `value` @material = args[:material] if args.key?(:material)
# @return [String] @scent = args[:scent] if args.key?(:scent)
attr_accessor :value
# The unit in which these products are counted.
# Corresponds to the JSON property `unit`
# @return [String]
attr_accessor :unit
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@value = args[:value] if args.key?(:value)
@unit = args[:unit] if args.key?(:unit)
end
end
# Product data.
class Product
include Google::Apis::Core::Hashable
# Attributes of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116.
# Corresponds to the JSON property `manuallyProvidedAttributes`
# @return [Google::Apis::ManufacturersV1::Attributes]
attr_accessor :manually_provided_attributes
# The target country of the product as a CLDR territory code (for example,
# US).
# @OutputOnly
# Corresponds to the JSON property `targetCountry`
# @return [String]
attr_accessor :target_country
# The content language of the product as a two-letter ISO 639-1 language code
# (for example, en).
# @OutputOnly
# Corresponds to the JSON property `contentLanguage`
# @return [String]
attr_accessor :content_language
# Name in the format ``target_country`:`content_language`:`product_id``.
# `target_country` - The target country of the product as a CLDR territory
# code (for example, US).
# `content_language` - The content language of the product as a two-letter
# ISO 639-1 language code (for example, en).
# `product_id` - The ID of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#
# id.
# @OutputOnly
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Names of the attributes of the product deleted manually via the
# Manufacturer Center UI.
# @OutputOnly
# Corresponds to the JSON property `manuallyDeletedAttributes`
# @return [Array<String>]
attr_accessor :manually_deleted_attributes
# A server-generated list of issues associated with the product.
# @OutputOnly
# Corresponds to the JSON property `issues`
# @return [Array<Google::Apis::ManufacturersV1::Issue>]
attr_accessor :issues
# Attributes of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116.
# Corresponds to the JSON property `finalAttributes`
# @return [Google::Apis::ManufacturersV1::Attributes]
attr_accessor :final_attributes
# The ID of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#id.
# @OutputOnly
# Corresponds to the JSON property `productId`
# @return [String]
attr_accessor :product_id
# Attributes of the product. For more information, see
# https://support.google.com/manufacturers/answer/6124116.
# Corresponds to the JSON property `uploadedAttributes`
# @return [Google::Apis::ManufacturersV1::Attributes]
attr_accessor :uploaded_attributes
# Parent ID in the format `accounts/`account_id``.
# `account_id` - The ID of the Manufacturer Center account.
# @OutputOnly
# Corresponds to the JSON property `parent`
# @return [String]
attr_accessor :parent
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@manually_provided_attributes = args[:manually_provided_attributes] if args.key?(:manually_provided_attributes)
@target_country = args[:target_country] if args.key?(:target_country)
@content_language = args[:content_language] if args.key?(:content_language)
@name = args[:name] if args.key?(:name)
@manually_deleted_attributes = args[:manually_deleted_attributes] if args.key?(:manually_deleted_attributes)
@issues = args[:issues] if args.key?(:issues)
@final_attributes = args[:final_attributes] if args.key?(:final_attributes)
@product_id = args[:product_id] if args.key?(:product_id)
@uploaded_attributes = args[:uploaded_attributes] if args.key?(:uploaded_attributes)
@parent = args[:parent] if args.key?(:parent)
end
end
# The capacity of a product. For more information, see
# https://support.google.com/manufacturers/answer/6124116#capacity.
class Capacity
include Google::Apis::Core::Hashable
# The numeric value of the capacity.
# Corresponds to the JSON property `value`
# @return [String]
attr_accessor :value
# The unit of the capacity, i.e., MB, GB, or TB.
# Corresponds to the JSON property `unit`
# @return [String]
attr_accessor :unit
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@value = args[:value] if args.key?(:value)
@unit = args[:unit] if args.key?(:unit)
end end
end end
end end

View File

@ -22,6 +22,24 @@ module Google
module Apis module Apis
module ManufacturersV1 module ManufacturersV1
class Count
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Product
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Capacity
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListProductsResponse class ListProductsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -34,13 +52,13 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class FeatureDescription class Issue
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class Issue class FeatureDescription
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
@ -65,21 +83,39 @@ module Google
end end
class Count class Count
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :value, as: 'value'
property :unit, as: 'unit'
end
end end
class Product class Product
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :manually_deleted_attributes, as: 'manuallyDeletedAttributes'
collection :issues, as: 'issues', class: Google::Apis::ManufacturersV1::Issue, decorator: Google::Apis::ManufacturersV1::Issue::Representation
include Google::Apis::Core::JsonObjectSupport property :final_attributes, as: 'finalAttributes', class: Google::Apis::ManufacturersV1::Attributes, decorator: Google::Apis::ManufacturersV1::Attributes::Representation
property :product_id, as: 'productId'
property :uploaded_attributes, as: 'uploadedAttributes', class: Google::Apis::ManufacturersV1::Attributes, decorator: Google::Apis::ManufacturersV1::Attributes::Representation
property :parent, as: 'parent'
property :manually_provided_attributes, as: 'manuallyProvidedAttributes', class: Google::Apis::ManufacturersV1::Attributes, decorator: Google::Apis::ManufacturersV1::Attributes::Representation
property :content_language, as: 'contentLanguage'
property :target_country, as: 'targetCountry'
property :name, as: 'name'
end
end end
class Capacity class Capacity
class Representation < Google::Apis::Core::JsonRepresentation; end # @private
class Representation < Google::Apis::Core::JsonRepresentation
include Google::Apis::Core::JsonObjectSupport property :value, as: 'value'
property :unit, as: 'unit'
end
end end
class ListProductsResponse class ListProductsResponse
@ -100,24 +136,24 @@ module Google
end end
end end
class FeatureDescription
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :image, as: 'image', class: Google::Apis::ManufacturersV1::Image, decorator: Google::Apis::ManufacturersV1::Image::Representation
property :headline, as: 'headline'
property :text, as: 'text'
end
end
class Issue class Issue
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :timestamp, as: 'timestamp'
property :severity, as: 'severity' property :severity, as: 'severity'
property :description, as: 'description' property :description, as: 'description'
property :type, as: 'type' property :type, as: 'type'
property :attribute, as: 'attribute' property :attribute, as: 'attribute'
property :timestamp, as: 'timestamp' end
end
class FeatureDescription
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :headline, as: 'headline'
property :text, as: 'text'
property :image, as: 'image', class: Google::Apis::ManufacturersV1::Image, decorator: Google::Apis::ManufacturersV1::Image::Representation
end end
end end
@ -132,32 +168,18 @@ module Google
class Image class Image
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :status, as: 'status'
property :type, as: 'type' property :type, as: 'type'
property :image_url, as: 'imageUrl' property :image_url, as: 'imageUrl'
property :status, as: 'status'
end end
end end
class Attributes class Attributes
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :product_name, as: 'productName' property :flavor, as: 'flavor'
property :size_type, as: 'sizeType'
property :suggested_retail_price, as: 'suggestedRetailPrice', class: Google::Apis::ManufacturersV1::Price, decorator: Google::Apis::ManufacturersV1::Price::Representation
collection :feature_description, as: 'featureDescription', class: Google::Apis::ManufacturersV1::FeatureDescription, decorator: Google::Apis::ManufacturersV1::FeatureDescription::Representation
property :size, as: 'size'
property :title, as: 'title'
property :count, as: 'count', class: Google::Apis::ManufacturersV1::Count, decorator: Google::Apis::ManufacturersV1::Count::Representation
property :brand, as: 'brand'
property :material, as: 'material'
property :disclosure_date, as: 'disclosureDate'
property :scent, as: 'scent'
collection :product_detail, as: 'productDetail', class: Google::Apis::ManufacturersV1::ProductDetail, decorator: Google::Apis::ManufacturersV1::ProductDetail::Representation collection :product_detail, as: 'productDetail', class: Google::Apis::ManufacturersV1::ProductDetail, decorator: Google::Apis::ManufacturersV1::ProductDetail::Representation
property :flavor, as: 'flavor'
property :age_group, as: 'ageGroup' property :age_group, as: 'ageGroup'
property :mpn, as: 'mpn' property :mpn, as: 'mpn'
property :product_page_url, as: 'productPageUrl' property :product_page_url, as: 'productPageUrl'
@ -180,42 +202,20 @@ module Google
collection :video_link, as: 'videoLink' collection :video_link, as: 'videoLink'
property :color, as: 'color' property :color, as: 'color'
end property :product_name, as: 'productName'
end property :size_type, as: 'sizeType'
property :suggested_retail_price, as: 'suggestedRetailPrice', class: Google::Apis::ManufacturersV1::Price, decorator: Google::Apis::ManufacturersV1::Price::Representation
class Count collection :feature_description, as: 'featureDescription', class: Google::Apis::ManufacturersV1::FeatureDescription, decorator: Google::Apis::ManufacturersV1::FeatureDescription::Representation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :value, as: 'value'
property :unit, as: 'unit'
end
end
class Product property :size, as: 'size'
# @private property :title, as: 'title'
class Representation < Google::Apis::Core::JsonRepresentation property :count, as: 'count', class: Google::Apis::ManufacturersV1::Count, decorator: Google::Apis::ManufacturersV1::Count::Representation
property :manually_provided_attributes, as: 'manuallyProvidedAttributes', class: Google::Apis::ManufacturersV1::Attributes, decorator: Google::Apis::ManufacturersV1::Attributes::Representation
property :target_country, as: 'targetCountry' property :brand, as: 'brand'
property :content_language, as: 'contentLanguage' property :disclosure_date, as: 'disclosureDate'
property :name, as: 'name' property :material, as: 'material'
collection :manually_deleted_attributes, as: 'manuallyDeletedAttributes' property :scent, as: 'scent'
collection :issues, as: 'issues', class: Google::Apis::ManufacturersV1::Issue, decorator: Google::Apis::ManufacturersV1::Issue::Representation
property :final_attributes, as: 'finalAttributes', class: Google::Apis::ManufacturersV1::Attributes, decorator: Google::Apis::ManufacturersV1::Attributes::Representation
property :product_id, as: 'productId'
property :uploaded_attributes, as: 'uploadedAttributes', class: Google::Apis::ManufacturersV1::Attributes, decorator: Google::Apis::ManufacturersV1::Attributes::Representation
property :parent, as: 'parent'
end
end
class Capacity
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :value, as: 'value'
property :unit, as: 'unit'
end end
end end
end end

View File

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

File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More