google-api-client 0.9.8 → 0.9.20
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +37 -0
- data/Gemfile +9 -1
- data/README.md +10 -2
- data/api_names.yaml +63 -110
- data/generated/google/apis/adexchangebuyer2_v2beta1.rb +35 -0
- data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +298 -0
- data/generated/google/apis/adexchangebuyer2_v2beta1/representations.rb +122 -0
- data/generated/google/apis/adexchangebuyer2_v2beta1/service.rb +458 -0
- data/generated/google/apis/adexchangebuyer_v1_4.rb +1 -1
- data/generated/google/apis/adexchangebuyer_v1_4/classes.rb +260 -13
- data/generated/google/apis/adexchangebuyer_v1_4/representations.rb +81 -0
- data/generated/google/apis/adexchangebuyer_v1_4/service.rb +60 -8
- data/generated/google/apis/adexchangeseller_v2_0.rb +2 -3
- data/generated/google/apis/adexchangeseller_v2_0/service.rb +1 -2
- data/generated/google/apis/admin_directory_v1.rb +1 -1
- data/generated/google/apis/admin_directory_v1/classes.rb +86 -0
- data/generated/google/apis/admin_directory_v1/representations.rb +24 -0
- data/generated/google/apis/admin_directory_v1/service.rb +41 -2
- data/generated/google/apis/admin_reports_v1.rb +3 -3
- data/generated/google/apis/admin_reports_v1/service.rb +2 -2
- data/generated/google/apis/adsense_v1_4.rb +1 -1
- data/generated/google/apis/adsense_v1_4/classes.rb +1 -1
- data/generated/google/apis/adsensehost_v4_1.rb +1 -1
- data/generated/google/apis/adsensehost_v4_1/classes.rb +1 -2
- data/generated/google/apis/analytics_v3.rb +1 -1
- data/generated/google/apis/analytics_v3/classes.rb +379 -3
- data/generated/google/apis/analytics_v3/representations.rb +136 -0
- data/generated/google/apis/analytics_v3/service.rb +217 -0
- data/generated/google/apis/analyticsreporting_v4.rb +1 -1
- data/generated/google/apis/analyticsreporting_v4/classes.rb +50 -22
- data/generated/google/apis/androidenterprise_v1.rb +1 -1
- data/generated/google/apis/androidenterprise_v1/classes.rb +813 -49
- data/generated/google/apis/androidenterprise_v1/representations.rb +336 -0
- data/generated/google/apis/androidenterprise_v1/service.rb +1234 -145
- data/generated/google/apis/androidpublisher_v2.rb +1 -1
- data/generated/google/apis/androidpublisher_v2/classes.rb +47 -8
- data/generated/google/apis/androidpublisher_v2/representations.rb +27 -0
- data/generated/google/apis/androidpublisher_v2/service.rb +55 -0
- data/generated/google/apis/appengine_v1beta5.rb +7 -1
- data/generated/google/apis/appengine_v1beta5/classes.rb +516 -313
- data/generated/google/apis/appengine_v1beta5/representations.rb +115 -22
- data/generated/google/apis/appengine_v1beta5/service.rb +329 -33
- data/generated/google/apis/appsactivity_v1.rb +1 -1
- data/generated/google/apis/appsactivity_v1/classes.rb +7 -0
- data/generated/google/apis/appsactivity_v1/representations.rb +1 -0
- data/generated/google/apis/appstate_v1.rb +1 -1
- data/generated/google/apis/bigquery_v2.rb +1 -1
- data/generated/google/apis/bigquery_v2/classes.rb +277 -20
- data/generated/google/apis/bigquery_v2/representations.rb +86 -0
- data/generated/google/apis/bigquery_v2/service.rb +8 -2
- data/generated/google/apis/books_v1.rb +2 -2
- data/generated/google/apis/books_v1/classes.rb +79 -1
- data/generated/google/apis/books_v1/representations.rb +34 -0
- data/generated/google/apis/books_v1/service.rb +7 -3
- data/generated/google/apis/calendar_v3.rb +1 -1
- data/generated/google/apis/civicinfo_v2.rb +3 -2
- data/generated/google/apis/civicinfo_v2/classes.rb +377 -5
- data/generated/google/apis/civicinfo_v2/representations.rb +149 -0
- data/generated/google/apis/civicinfo_v2/service.rb +27 -6
- data/generated/google/apis/classroom_v1.rb +1 -1
- data/generated/google/apis/classroom_v1/classes.rb +183 -37
- data/generated/google/apis/classroom_v1/representations.rb +74 -9
- data/generated/google/apis/classroom_v1/service.rb +403 -38
- data/generated/google/apis/cloudbuild_v1.rb +1 -1
- data/generated/google/apis/cloudbuild_v1/classes.rb +381 -17
- data/generated/google/apis/cloudbuild_v1/representations.rb +137 -2
- data/generated/google/apis/cloudbuild_v1/service.rb +174 -1
- data/generated/google/apis/clouddebugger_v2.rb +3 -6
- data/generated/google/apis/clouddebugger_v2/service.rb +4 -4
- data/generated/google/apis/cloudmonitoring_v2beta2.rb +1 -1
- data/generated/google/apis/cloudresourcemanager_v1.rb +1 -1
- data/generated/google/apis/cloudresourcemanager_v1/classes.rb +502 -111
- data/generated/google/apis/cloudresourcemanager_v1/representations.rb +162 -24
- data/generated/google/apis/cloudresourcemanager_v1/service.rb +274 -30
- data/generated/google/apis/cloudresourcemanager_v1beta1.rb +1 -1
- data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +121 -9
- data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +46 -0
- data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +71 -58
- data/generated/google/apis/compute_beta.rb +1 -1
- data/generated/google/apis/compute_beta/classes.rb +2299 -434
- data/generated/google/apis/compute_beta/representations.rb +752 -33
- data/generated/google/apis/compute_beta/service.rb +6067 -3153
- data/generated/google/apis/compute_v1.rb +1 -1
- data/generated/google/apis/compute_v1/classes.rb +1681 -207
- data/generated/google/apis/compute_v1/representations.rb +552 -0
- data/generated/google/apis/compute_v1/service.rb +2797 -1171
- data/generated/google/apis/content_v2.rb +1 -1
- data/generated/google/apis/content_v2/classes.rb +757 -1
- data/generated/google/apis/content_v2/representations.rb +337 -0
- data/generated/google/apis/content_v2/service.rb +244 -0
- data/generated/google/apis/dataflow_v1b3.rb +38 -0
- data/generated/google/apis/dataflow_v1b3/classes.rb +4053 -0
- data/generated/google/apis/dataflow_v1b3/representations.rb +1736 -0
- data/generated/google/apis/dataflow_v1b3/service.rb +875 -0
- data/generated/google/apis/dataproc_v1.rb +2 -2
- data/generated/google/apis/dataproc_v1/classes.rb +213 -68
- data/generated/google/apis/dataproc_v1/representations.rb +38 -0
- data/generated/google/apis/dataproc_v1/service.rb +78 -48
- data/generated/google/apis/datastore_v1.rb +38 -0
- data/generated/google/apis/datastore_v1/classes.rb +1284 -0
- data/generated/google/apis/datastore_v1/representations.rb +572 -0
- data/generated/google/apis/datastore_v1/service.rb +259 -0
- data/generated/google/apis/datastore_v1beta3.rb +38 -0
- data/generated/google/apis/datastore_v1beta3/classes.rb +1284 -0
- data/generated/google/apis/datastore_v1beta3/representations.rb +572 -0
- data/generated/google/apis/datastore_v1beta3/service.rb +259 -0
- data/generated/google/apis/deploymentmanager_v2.rb +1 -1
- data/generated/google/apis/deploymentmanager_v2/classes.rb +384 -2
- data/generated/google/apis/deploymentmanager_v2/representations.rb +161 -0
- data/generated/google/apis/deploymentmanager_v2/service.rb +217 -55
- data/generated/google/apis/dfareporting_v2_5.rb +40 -0
- data/generated/google/apis/dfareporting_v2_5/classes.rb +11225 -0
- data/generated/google/apis/dfareporting_v2_5/representations.rb +3982 -0
- data/generated/google/apis/dfareporting_v2_5/service.rb +8755 -0
- data/generated/google/apis/dfareporting_v2_6.rb +40 -0
- data/generated/google/apis/dfareporting_v2_6/classes.rb +11586 -0
- data/generated/google/apis/dfareporting_v2_6/representations.rb +4119 -0
- data/generated/google/apis/dfareporting_v2_6/service.rb +9025 -0
- data/generated/google/apis/dns_v1.rb +1 -1
- data/generated/google/apis/dns_v1/classes.rb +1 -1
- data/generated/google/apis/doubleclickbidmanager_v1.rb +1 -1
- data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +79 -86
- data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +25 -28
- data/generated/google/apis/doubleclickbidmanager_v1/service.rb +10 -8
- data/generated/google/apis/doubleclicksearch_v2.rb +1 -1
- data/generated/google/apis/drive_v2.rb +1 -1
- data/generated/google/apis/drive_v2/classes.rb +27 -3
- data/generated/google/apis/drive_v2/representations.rb +4 -0
- data/generated/google/apis/drive_v2/service.rb +16 -3
- data/generated/google/apis/drive_v3.rb +1 -1
- data/generated/google/apis/drive_v3/classes.rb +50 -16
- data/generated/google/apis/drive_v3/representations.rb +4 -0
- data/generated/google/apis/drive_v3/service.rb +12 -2
- data/generated/google/apis/fitness_v1.rb +8 -2
- data/generated/google/apis/fitness_v1/classes.rb +64 -6
- data/generated/google/apis/fitness_v1/representations.rb +20 -0
- data/generated/google/apis/fitness_v1/service.rb +17 -18
- data/generated/google/apis/fusiontables_v2.rb +1 -1
- data/generated/google/apis/fusiontables_v2/classes.rb +4 -3
- data/generated/google/apis/games_configuration_v1configuration.rb +1 -1
- data/generated/google/apis/games_management_v1management.rb +1 -1
- data/generated/google/apis/games_v1.rb +1 -1
- data/generated/google/apis/genomics_v1.rb +2 -4
- data/generated/google/apis/genomics_v1/classes.rb +143 -34
- data/generated/google/apis/genomics_v1/representations.rb +48 -11
- data/generated/google/apis/genomics_v1/service.rb +35 -37
- data/generated/google/apis/gmail_v1.rb +10 -1
- data/generated/google/apis/gmail_v1/classes.rb +542 -4
- data/generated/google/apis/gmail_v1/representations.rb +213 -0
- data/generated/google/apis/gmail_v1/service.rb +898 -1
- data/generated/google/apis/groupssettings_v1.rb +1 -1
- data/generated/google/apis/groupssettings_v1/classes.rb +12 -0
- data/generated/google/apis/groupssettings_v1/representations.rb +2 -0
- data/generated/google/apis/iam_v1.rb +2 -2
- data/generated/google/apis/iam_v1/classes.rb +181 -206
- data/generated/google/apis/iam_v1/representations.rb +36 -45
- data/generated/google/apis/iam_v1/service.rb +101 -67
- data/generated/google/apis/identitytoolkit_v3.rb +4 -1
- data/generated/google/apis/identitytoolkit_v3/classes.rb +171 -1
- data/generated/google/apis/identitytoolkit_v3/representations.rb +26 -0
- data/generated/google/apis/language_v1beta1.rb +36 -0
- data/generated/google/apis/language_v1beta1/classes.rb +599 -0
- data/generated/google/apis/language_v1beta1/representations.rb +289 -0
- data/generated/google/apis/language_v1beta1/service.rb +152 -0
- data/generated/google/apis/logging_v2beta1.rb +6 -6
- data/generated/google/apis/logging_v2beta1/classes.rb +760 -731
- data/generated/google/apis/logging_v2beta1/representations.rb +136 -147
- data/generated/google/apis/logging_v2beta1/service.rb +290 -209
- data/generated/google/apis/mirror_v1.rb +2 -2
- data/generated/google/apis/mirror_v1/service.rb +1 -1
- data/generated/google/apis/monitoring_v3.rb +45 -0
- data/generated/google/apis/monitoring_v3/classes.rb +1337 -0
- data/generated/google/apis/monitoring_v3/representations.rb +516 -0
- data/generated/google/apis/monitoring_v3/service.rb +711 -0
- data/generated/google/apis/oauth2_v2.rb +1 -1
- data/generated/google/apis/pagespeedonline_v2.rb +1 -1
- data/generated/google/apis/plus_domains_v1.rb +1 -1
- data/generated/google/apis/plus_v1.rb +1 -1
- data/generated/google/apis/pubsub_v1.rb +1 -1
- data/generated/google/apis/pubsub_v1/classes.rb +10 -9
- data/generated/google/apis/pubsub_v1/service.rb +128 -27
- data/generated/google/apis/qpx_express_v1.rb +1 -1
- data/generated/google/apis/qpx_express_v1/classes.rb +6 -0
- data/generated/google/apis/qpx_express_v1/representations.rb +1 -0
- data/generated/google/apis/replicapool_v1beta2.rb +1 -1
- data/generated/google/apis/replicapoolupdater_v1beta1.rb +4 -2
- data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +3 -1
- data/generated/google/apis/script_v1.rb +1 -1
- data/generated/google/apis/script_v1/classes.rb +6 -0
- data/generated/google/apis/script_v1/representations.rb +1 -0
- data/generated/google/apis/sheets_v4.rb +1 -1
- data/generated/google/apis/sheets_v4/classes.rb +910 -89
- data/generated/google/apis/sheets_v4/representations.rb +194 -10
- data/generated/google/apis/sheets_v4/service.rb +216 -49
- data/generated/google/apis/slides_v1.rb +49 -0
- data/generated/google/apis/slides_v1/classes.rb +3926 -0
- data/generated/google/apis/slides_v1/representations.rb +1722 -0
- data/generated/google/apis/slides_v1/service.rb +202 -0
- data/generated/google/apis/speech_v1beta1.rb +34 -0
- data/generated/google/apis/speech_v1beta1/classes.rb +511 -0
- data/generated/google/apis/speech_v1beta1/representations.rb +218 -0
- data/generated/google/apis/speech_v1beta1/service.rb +271 -0
- data/generated/google/apis/sqladmin_v1beta4.rb +1 -1
- data/generated/google/apis/sqladmin_v1beta4/classes.rb +32 -8
- data/generated/google/apis/sqladmin_v1beta4/representations.rb +3 -0
- data/generated/google/apis/sqladmin_v1beta4/service.rb +42 -0
- data/generated/google/apis/storage_v1.rb +1 -1
- data/generated/google/apis/storage_v1/classes.rb +43 -18
- data/generated/google/apis/storage_v1/representations.rb +4 -1
- data/generated/google/apis/storage_v1/service.rb +5 -2
- data/generated/google/apis/translate_v2.rb +2 -2
- data/generated/google/apis/translate_v2/service.rb +1 -1
- data/generated/google/apis/vision_v1.rb +1 -1
- data/generated/google/apis/vision_v1/classes.rb +12 -11
- data/generated/google/apis/youtube_analytics_v1.rb +1 -1
- data/generated/google/apis/youtube_partner_v1.rb +1 -1
- data/generated/google/apis/youtube_partner_v1/classes.rb +6 -0
- data/generated/google/apis/youtube_partner_v1/representations.rb +2 -0
- data/generated/google/apis/youtube_partner_v1/service.rb +15 -3
- data/generated/google/apis/youtube_v3.rb +1 -1
- data/generated/google/apis/youtube_v3/classes.rb +183 -21
- data/generated/google/apis/youtube_v3/representations.rb +85 -4
- data/generated/google/apis/youtube_v3/service.rb +41 -5
- data/generated/google/apis/youtubereporting_v1.rb +1 -1
- data/google-api-client.gemspec +2 -1
- data/lib/google/apis/core/api_command.rb +4 -0
- data/lib/google/apis/core/base_service.rb +10 -4
- data/lib/google/apis/core/download.rb +7 -2
- data/lib/google/apis/core/http_command.rb +5 -1
- data/lib/google/apis/core/upload.rb +7 -1
- data/lib/google/apis/errors.rb +2 -2
- data/lib/google/apis/generator/annotator.rb +6 -0
- data/lib/google/apis/version.rb +1 -1
- data/samples/cli/lib/samples/bigquery.rb +101 -0
- data/samples/cli/lib/samples/sheets.rb +61 -0
- data/sync.rb +71 -0
- metadata +55 -13
@@ -312,15 +312,19 @@ module Google
|
|
312
312
|
# @private
|
313
313
|
class Representation < Google::Apis::Core::JsonRepresentation
|
314
314
|
property :app_id, as: 'appId'
|
315
|
+
property :auth_flow_type, as: 'authFlowType'
|
315
316
|
property :client_id, as: 'clientId'
|
316
317
|
property :context, as: 'context'
|
317
318
|
property :continue_uri, as: 'continueUri'
|
319
|
+
hash :custom_parameter, as: 'customParameter'
|
320
|
+
property :hosted_domain, as: 'hostedDomain'
|
318
321
|
property :identifier, as: 'identifier'
|
319
322
|
property :oauth_consumer_key, as: 'oauthConsumerKey'
|
320
323
|
property :oauth_scope, as: 'oauthScope'
|
321
324
|
property :openid_realm, as: 'openidRealm'
|
322
325
|
property :ota_app, as: 'otaApp'
|
323
326
|
property :provider_id, as: 'providerId'
|
327
|
+
property :session_id, as: 'sessionId'
|
324
328
|
end
|
325
329
|
end
|
326
330
|
|
@@ -360,6 +364,7 @@ module Google
|
|
360
364
|
collection :authorized_domains, as: 'authorizedDomains'
|
361
365
|
property :change_email_template, as: 'changeEmailTemplate', class: Google::Apis::IdentitytoolkitV3::EmailTemplate, decorator: Google::Apis::IdentitytoolkitV3::EmailTemplate::Representation
|
362
366
|
|
367
|
+
property :dynamic_links_domain, as: 'dynamicLinksDomain'
|
363
368
|
property :enable_anonymous_user, as: 'enableAnonymousUser'
|
364
369
|
collection :idp_config, as: 'idpConfig', class: Google::Apis::IdentitytoolkitV3::IdpConfig, decorator: Google::Apis::IdentitytoolkitV3::IdpConfig::Representation
|
365
370
|
|
@@ -389,6 +394,7 @@ module Google
|
|
389
394
|
class Representation < Google::Apis::Core::JsonRepresentation
|
390
395
|
property :captcha_challenge, as: 'captchaChallenge'
|
391
396
|
property :captcha_response, as: 'captchaResponse'
|
397
|
+
property :created_at, as: 'createdAt'
|
392
398
|
property :delegated_project_number, as: 'delegatedProjectNumber'
|
393
399
|
collection :delete_attribute, as: 'deleteAttribute'
|
394
400
|
collection :delete_provider, as: 'deleteProvider'
|
@@ -398,6 +404,7 @@ module Google
|
|
398
404
|
property :email_verified, as: 'emailVerified'
|
399
405
|
property :id_token, as: 'idToken'
|
400
406
|
property :instance_id, as: 'instanceId'
|
407
|
+
property :last_login_at, as: 'lastLoginAt'
|
401
408
|
property :local_id, as: 'localId'
|
402
409
|
property :oob_code, as: 'oobCode'
|
403
410
|
property :password, as: 'password'
|
@@ -458,23 +465,29 @@ module Google
|
|
458
465
|
class Representation < Google::Apis::Core::JsonRepresentation
|
459
466
|
property :captcha_challenge, as: 'captchaChallenge'
|
460
467
|
property :captcha_response, as: 'captchaResponse'
|
468
|
+
property :disabled, as: 'disabled'
|
461
469
|
property :display_name, as: 'displayName'
|
462
470
|
property :email, as: 'email'
|
471
|
+
property :email_verified, as: 'emailVerified'
|
463
472
|
property :id_token, as: 'idToken'
|
464
473
|
property :instance_id, as: 'instanceId'
|
465
474
|
property :password, as: 'password'
|
475
|
+
property :photo_url, as: 'photoUrl'
|
466
476
|
end
|
467
477
|
end
|
468
478
|
|
469
479
|
class UploadAccountRequest
|
470
480
|
# @private
|
471
481
|
class Representation < Google::Apis::Core::JsonRepresentation
|
482
|
+
property :allow_overwrite, as: 'allowOverwrite'
|
472
483
|
property :delegated_project_number, as: 'delegatedProjectNumber'
|
473
484
|
property :hash_algorithm, as: 'hashAlgorithm'
|
474
485
|
property :memory_cost, as: 'memoryCost'
|
475
486
|
property :rounds, as: 'rounds'
|
476
487
|
property :salt_separator, :base64 => true, as: 'saltSeparator'
|
488
|
+
property :sanity_check, as: 'sanityCheck'
|
477
489
|
property :signer_key, :base64 => true, as: 'signerKey'
|
490
|
+
property :target_project_id, as: 'targetProjectId'
|
478
491
|
collection :users, as: 'users', class: Google::Apis::IdentitytoolkitV3::UserInfo, decorator: Google::Apis::IdentitytoolkitV3::UserInfo::Representation
|
479
492
|
|
480
493
|
end
|
@@ -489,6 +502,7 @@ module Google
|
|
489
502
|
property :pending_id_token, as: 'pendingIdToken'
|
490
503
|
property :post_body, as: 'postBody'
|
491
504
|
property :request_uri, as: 'requestUri'
|
505
|
+
property :return_idp_credential, as: 'returnIdpCredential'
|
492
506
|
property :return_refresh_token, as: 'returnRefreshToken'
|
493
507
|
property :return_secure_token, as: 'returnSecureToken'
|
494
508
|
property :session_id, as: 'sessionId'
|
@@ -528,6 +542,7 @@ module Google
|
|
528
542
|
property :experiment_percent, as: 'experimentPercent'
|
529
543
|
property :provider, as: 'provider'
|
530
544
|
property :secret, as: 'secret'
|
545
|
+
collection :whitelisted_audiences, as: 'whitelistedAudiences'
|
531
546
|
end
|
532
547
|
end
|
533
548
|
|
@@ -550,6 +565,8 @@ module Google
|
|
550
565
|
class Representation < Google::Apis::Core::JsonRepresentation
|
551
566
|
property :email, as: 'email'
|
552
567
|
property :kind, as: 'kind'
|
568
|
+
property :new_email, as: 'newEmail'
|
569
|
+
property :request_type, as: 'requestType'
|
553
570
|
end
|
554
571
|
end
|
555
572
|
|
@@ -614,17 +631,22 @@ module Google
|
|
614
631
|
class UserInfo
|
615
632
|
# @private
|
616
633
|
class Representation < Google::Apis::Core::JsonRepresentation
|
634
|
+
property :created_at, as: 'createdAt'
|
635
|
+
property :custom_auth, as: 'customAuth'
|
617
636
|
property :disabled, as: 'disabled'
|
618
637
|
property :display_name, as: 'displayName'
|
619
638
|
property :email, as: 'email'
|
620
639
|
property :email_verified, as: 'emailVerified'
|
640
|
+
property :last_login_at, as: 'lastLoginAt'
|
621
641
|
property :local_id, as: 'localId'
|
622
642
|
property :password_hash, :base64 => true, as: 'passwordHash'
|
623
643
|
property :password_updated_at, as: 'passwordUpdatedAt'
|
624
644
|
property :photo_url, as: 'photoUrl'
|
625
645
|
collection :provider_user_info, as: 'providerUserInfo', class: Google::Apis::IdentitytoolkitV3::UserInfo::ProviderUserInfo, decorator: Google::Apis::IdentitytoolkitV3::UserInfo::ProviderUserInfo::Representation
|
626
646
|
|
647
|
+
property :raw_password, as: 'rawPassword'
|
627
648
|
property :salt, :base64 => true, as: 'salt'
|
649
|
+
property :screen_name, as: 'screenName'
|
628
650
|
property :valid_since, as: 'validSince'
|
629
651
|
property :version, as: 'version'
|
630
652
|
end
|
@@ -638,6 +660,7 @@ module Google
|
|
638
660
|
property :photo_url, as: 'photoUrl'
|
639
661
|
property :provider_id, as: 'providerId'
|
640
662
|
property :raw_id, as: 'rawId'
|
663
|
+
property :screen_name, as: 'screenName'
|
641
664
|
end
|
642
665
|
end
|
643
666
|
end
|
@@ -654,6 +677,7 @@ module Google
|
|
654
677
|
property :email, as: 'email'
|
655
678
|
property :email_recycled, as: 'emailRecycled'
|
656
679
|
property :email_verified, as: 'emailVerified'
|
680
|
+
property :error_message, as: 'errorMessage'
|
657
681
|
property :expires_in, as: 'expiresIn'
|
658
682
|
property :federated_id, as: 'federatedId'
|
659
683
|
property :first_name, as: 'firstName'
|
@@ -677,7 +701,9 @@ module Google
|
|
677
701
|
property :original_email, as: 'originalEmail'
|
678
702
|
property :photo_url, as: 'photoUrl'
|
679
703
|
property :provider_id, as: 'providerId'
|
704
|
+
property :raw_user_info, as: 'rawUserInfo'
|
680
705
|
property :refresh_token, as: 'refreshToken'
|
706
|
+
property :screen_name, as: 'screenName'
|
681
707
|
property :time_zone, as: 'timeZone'
|
682
708
|
collection :verified_provider, as: 'verifiedProvider'
|
683
709
|
end
|
@@ -0,0 +1,36 @@
|
|
1
|
+
# Copyright 2015 Google Inc.
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'google/apis/language_v1beta1/service.rb'
|
16
|
+
require 'google/apis/language_v1beta1/classes.rb'
|
17
|
+
require 'google/apis/language_v1beta1/representations.rb'
|
18
|
+
|
19
|
+
module Google
|
20
|
+
module Apis
|
21
|
+
# Google Cloud Natural Language API
|
22
|
+
#
|
23
|
+
# Google Cloud Natural Language API provides natural language understanding
|
24
|
+
# technologies to developers. Examples include sentiment analysis, entity
|
25
|
+
# recognition, and text annotations.
|
26
|
+
#
|
27
|
+
# @see https://cloud.google.com/natural-language/
|
28
|
+
module LanguageV1beta1
|
29
|
+
VERSION = 'V1beta1'
|
30
|
+
REVISION = '20161103'
|
31
|
+
|
32
|
+
# View and manage your data across Google Cloud Platform services
|
33
|
+
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
@@ -0,0 +1,599 @@
|
|
1
|
+
# Copyright 2015 Google Inc.
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'date'
|
16
|
+
require 'google/apis/core/base_service'
|
17
|
+
require 'google/apis/core/json_representation'
|
18
|
+
require 'google/apis/core/hashable'
|
19
|
+
require 'google/apis/errors'
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Apis
|
23
|
+
module LanguageV1beta1
|
24
|
+
|
25
|
+
# ################################################################ #
|
26
|
+
# Represents the input to API methods.
|
27
|
+
class Document
|
28
|
+
include Google::Apis::Core::Hashable
|
29
|
+
|
30
|
+
# The language of the document (if not specified, the language is
|
31
|
+
# automatically detected). Both ISO and BCP-47 language codes are
|
32
|
+
# accepted.<br>
|
33
|
+
# **Current Language Restrictions:**
|
34
|
+
# * Only English, Spanish, and Japanese textual content
|
35
|
+
# are supported, with the following additional restriction:
|
36
|
+
# * `analyzeSentiment` only supports English text.
|
37
|
+
# If the language (either specified by the caller or automatically detected)
|
38
|
+
# is not supported by the called API method, an `INVALID_ARGUMENT` error
|
39
|
+
# is returned.
|
40
|
+
# Corresponds to the JSON property `language`
|
41
|
+
# @return [String]
|
42
|
+
attr_accessor :language
|
43
|
+
|
44
|
+
# The Google Cloud Storage URI where the file content is located.
|
45
|
+
# Corresponds to the JSON property `gcsContentUri`
|
46
|
+
# @return [String]
|
47
|
+
attr_accessor :gcs_content_uri
|
48
|
+
|
49
|
+
# Required. If the type is not set or is `TYPE_UNSPECIFIED`,
|
50
|
+
# returns an `INVALID_ARGUMENT` error.
|
51
|
+
# Corresponds to the JSON property `type`
|
52
|
+
# @return [String]
|
53
|
+
attr_accessor :type
|
54
|
+
|
55
|
+
# The content of the input in string format.
|
56
|
+
# Corresponds to the JSON property `content`
|
57
|
+
# @return [String]
|
58
|
+
attr_accessor :content
|
59
|
+
|
60
|
+
def initialize(**args)
|
61
|
+
update!(**args)
|
62
|
+
end
|
63
|
+
|
64
|
+
# Update properties of this object
|
65
|
+
def update!(**args)
|
66
|
+
@language = args[:language] if args.key?(:language)
|
67
|
+
@gcs_content_uri = args[:gcs_content_uri] if args.key?(:gcs_content_uri)
|
68
|
+
@type = args[:type] if args.key?(:type)
|
69
|
+
@content = args[:content] if args.key?(:content)
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
# Represents an output piece of text.
|
74
|
+
class TextSpan
|
75
|
+
include Google::Apis::Core::Hashable
|
76
|
+
|
77
|
+
# The API calculates the beginning offset of the content in the original
|
78
|
+
# document according to the EncodingType specified in the API request.
|
79
|
+
# Corresponds to the JSON property `beginOffset`
|
80
|
+
# @return [Fixnum]
|
81
|
+
attr_accessor :begin_offset
|
82
|
+
|
83
|
+
# The content of the output text.
|
84
|
+
# Corresponds to the JSON property `content`
|
85
|
+
# @return [String]
|
86
|
+
attr_accessor :content
|
87
|
+
|
88
|
+
def initialize(**args)
|
89
|
+
update!(**args)
|
90
|
+
end
|
91
|
+
|
92
|
+
# Update properties of this object
|
93
|
+
def update!(**args)
|
94
|
+
@begin_offset = args[:begin_offset] if args.key?(:begin_offset)
|
95
|
+
@content = args[:content] if args.key?(:content)
|
96
|
+
end
|
97
|
+
end
|
98
|
+
|
99
|
+
# The `Status` type defines a logical error model that is suitable for different
|
100
|
+
# programming environments, including REST APIs and RPC APIs. It is used by
|
101
|
+
# [gRPC](https://github.com/grpc). The error model is designed to be:
|
102
|
+
# - Simple to use and understand for most users
|
103
|
+
# - Flexible enough to meet unexpected needs
|
104
|
+
# # Overview
|
105
|
+
# The `Status` message contains three pieces of data: error code, error message,
|
106
|
+
# and error details. The error code should be an enum value of
|
107
|
+
# google.rpc.Code, but it may accept additional error codes if needed. The
|
108
|
+
# error message should be a developer-facing English message that helps
|
109
|
+
# developers *understand* and *resolve* the error. If a localized user-facing
|
110
|
+
# error message is needed, put the localized message in the error details or
|
111
|
+
# localize it in the client. The optional error details may contain arbitrary
|
112
|
+
# information about the error. There is a predefined set of error detail types
|
113
|
+
# in the package `google.rpc` which can be used for common error conditions.
|
114
|
+
# # Language mapping
|
115
|
+
# The `Status` message is the logical representation of the error model, but it
|
116
|
+
# is not necessarily the actual wire format. When the `Status` message is
|
117
|
+
# exposed in different client libraries and different wire protocols, it can be
|
118
|
+
# mapped differently. For example, it will likely be mapped to some exceptions
|
119
|
+
# in Java, but more likely mapped to some error codes in C.
|
120
|
+
# # Other uses
|
121
|
+
# The error model and the `Status` message can be used in a variety of
|
122
|
+
# environments, either with or without APIs, to provide a
|
123
|
+
# consistent developer experience across different environments.
|
124
|
+
# Example uses of this error model include:
|
125
|
+
# - Partial errors. If a service needs to return partial errors to the client,
|
126
|
+
# it may embed the `Status` in the normal response to indicate the partial
|
127
|
+
# errors.
|
128
|
+
# - Workflow errors. A typical workflow has multiple steps. Each step may
|
129
|
+
# have a `Status` message for error reporting purpose.
|
130
|
+
# - Batch operations. If a client uses batch request and batch response, the
|
131
|
+
# `Status` message should be used directly inside batch response, one for
|
132
|
+
# each error sub-response.
|
133
|
+
# - Asynchronous operations. If an API call embeds asynchronous operation
|
134
|
+
# results in its response, the status of those operations should be
|
135
|
+
# represented directly using the `Status` message.
|
136
|
+
# - Logging. If some API errors are stored in logs, the message `Status` could
|
137
|
+
# be used directly after any stripping needed for security/privacy reasons.
|
138
|
+
class Status
|
139
|
+
include Google::Apis::Core::Hashable
|
140
|
+
|
141
|
+
# The status code, which should be an enum value of google.rpc.Code.
|
142
|
+
# Corresponds to the JSON property `code`
|
143
|
+
# @return [Fixnum]
|
144
|
+
attr_accessor :code
|
145
|
+
|
146
|
+
# A list of messages that carry the error details. There will be a
|
147
|
+
# common set of message types for APIs to use.
|
148
|
+
# Corresponds to the JSON property `details`
|
149
|
+
# @return [Array<Hash<String,Object>>]
|
150
|
+
attr_accessor :details
|
151
|
+
|
152
|
+
# A developer-facing error message, which should be in English. Any
|
153
|
+
# user-facing error message should be localized and sent in the
|
154
|
+
# google.rpc.Status.details field, or localized by the client.
|
155
|
+
# Corresponds to the JSON property `message`
|
156
|
+
# @return [String]
|
157
|
+
attr_accessor :message
|
158
|
+
|
159
|
+
def initialize(**args)
|
160
|
+
update!(**args)
|
161
|
+
end
|
162
|
+
|
163
|
+
# Update properties of this object
|
164
|
+
def update!(**args)
|
165
|
+
@code = args[:code] if args.key?(:code)
|
166
|
+
@details = args[:details] if args.key?(:details)
|
167
|
+
@message = args[:message] if args.key?(:message)
|
168
|
+
end
|
169
|
+
end
|
170
|
+
|
171
|
+
# The entity analysis request message.
|
172
|
+
class AnalyzeEntitiesRequest
|
173
|
+
include Google::Apis::Core::Hashable
|
174
|
+
|
175
|
+
# ################################################################ #
|
176
|
+
# Represents the input to API methods.
|
177
|
+
# Corresponds to the JSON property `document`
|
178
|
+
# @return [Google::Apis::LanguageV1beta1::Document]
|
179
|
+
attr_accessor :document
|
180
|
+
|
181
|
+
# The encoding type used by the API to calculate offsets.
|
182
|
+
# Corresponds to the JSON property `encodingType`
|
183
|
+
# @return [String]
|
184
|
+
attr_accessor :encoding_type
|
185
|
+
|
186
|
+
def initialize(**args)
|
187
|
+
update!(**args)
|
188
|
+
end
|
189
|
+
|
190
|
+
# Update properties of this object
|
191
|
+
def update!(**args)
|
192
|
+
@document = args[:document] if args.key?(:document)
|
193
|
+
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
|
194
|
+
end
|
195
|
+
end
|
196
|
+
|
197
|
+
# Represents a mention for an entity in the text. Currently, proper noun
|
198
|
+
# mentions are supported.
|
199
|
+
class EntityMention
|
200
|
+
include Google::Apis::Core::Hashable
|
201
|
+
|
202
|
+
# Represents an output piece of text.
|
203
|
+
# Corresponds to the JSON property `text`
|
204
|
+
# @return [Google::Apis::LanguageV1beta1::TextSpan]
|
205
|
+
attr_accessor :text
|
206
|
+
|
207
|
+
def initialize(**args)
|
208
|
+
update!(**args)
|
209
|
+
end
|
210
|
+
|
211
|
+
# Update properties of this object
|
212
|
+
def update!(**args)
|
213
|
+
@text = args[:text] if args.key?(:text)
|
214
|
+
end
|
215
|
+
end
|
216
|
+
|
217
|
+
# The sentiment analysis request message.
|
218
|
+
class AnalyzeSentimentRequest
|
219
|
+
include Google::Apis::Core::Hashable
|
220
|
+
|
221
|
+
# ################################################################ #
|
222
|
+
# Represents the input to API methods.
|
223
|
+
# Corresponds to the JSON property `document`
|
224
|
+
# @return [Google::Apis::LanguageV1beta1::Document]
|
225
|
+
attr_accessor :document
|
226
|
+
|
227
|
+
def initialize(**args)
|
228
|
+
update!(**args)
|
229
|
+
end
|
230
|
+
|
231
|
+
# Update properties of this object
|
232
|
+
def update!(**args)
|
233
|
+
@document = args[:document] if args.key?(:document)
|
234
|
+
end
|
235
|
+
end
|
236
|
+
|
237
|
+
# The sentiment analysis response message.
|
238
|
+
class AnalyzeSentimentResponse
|
239
|
+
include Google::Apis::Core::Hashable
|
240
|
+
|
241
|
+
# Represents the feeling associated with the entire text or entities in
|
242
|
+
# the text.
|
243
|
+
# Corresponds to the JSON property `documentSentiment`
|
244
|
+
# @return [Google::Apis::LanguageV1beta1::Sentiment]
|
245
|
+
attr_accessor :document_sentiment
|
246
|
+
|
247
|
+
# The language of the text, which will be the same as the language specified
|
248
|
+
# in the request or, if not specified, the automatically-detected language.
|
249
|
+
# Corresponds to the JSON property `language`
|
250
|
+
# @return [String]
|
251
|
+
attr_accessor :language
|
252
|
+
|
253
|
+
def initialize(**args)
|
254
|
+
update!(**args)
|
255
|
+
end
|
256
|
+
|
257
|
+
# Update properties of this object
|
258
|
+
def update!(**args)
|
259
|
+
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
|
260
|
+
@language = args[:language] if args.key?(:language)
|
261
|
+
end
|
262
|
+
end
|
263
|
+
|
264
|
+
# Represents dependency parse tree information for a token.
|
265
|
+
class DependencyEdge
|
266
|
+
include Google::Apis::Core::Hashable
|
267
|
+
|
268
|
+
# Represents the head of this token in the dependency tree.
|
269
|
+
# This is the index of the token which has an arc going to this token.
|
270
|
+
# The index is the position of the token in the array of tokens returned
|
271
|
+
# by the API method. If this token is a root token, then the
|
272
|
+
# `head_token_index` is its own index.
|
273
|
+
# Corresponds to the JSON property `headTokenIndex`
|
274
|
+
# @return [Fixnum]
|
275
|
+
attr_accessor :head_token_index
|
276
|
+
|
277
|
+
# The parse label for the token.
|
278
|
+
# Corresponds to the JSON property `label`
|
279
|
+
# @return [String]
|
280
|
+
attr_accessor :label
|
281
|
+
|
282
|
+
def initialize(**args)
|
283
|
+
update!(**args)
|
284
|
+
end
|
285
|
+
|
286
|
+
# Update properties of this object
|
287
|
+
def update!(**args)
|
288
|
+
@head_token_index = args[:head_token_index] if args.key?(:head_token_index)
|
289
|
+
@label = args[:label] if args.key?(:label)
|
290
|
+
end
|
291
|
+
end
|
292
|
+
|
293
|
+
# The request message for the text annotation API, which can perform multiple
|
294
|
+
# analysis types (sentiment, entities, and syntax) in one call.
|
295
|
+
class AnnotateTextRequest
|
296
|
+
include Google::Apis::Core::Hashable
|
297
|
+
|
298
|
+
# ################################################################ #
|
299
|
+
# Represents the input to API methods.
|
300
|
+
# Corresponds to the JSON property `document`
|
301
|
+
# @return [Google::Apis::LanguageV1beta1::Document]
|
302
|
+
attr_accessor :document
|
303
|
+
|
304
|
+
# The encoding type used by the API to calculate offsets.
|
305
|
+
# Corresponds to the JSON property `encodingType`
|
306
|
+
# @return [String]
|
307
|
+
attr_accessor :encoding_type
|
308
|
+
|
309
|
+
# All available features for sentiment, syntax, and semantic analysis.
|
310
|
+
# Setting each one to true will enable that specific analysis for the input.
|
311
|
+
# Corresponds to the JSON property `features`
|
312
|
+
# @return [Google::Apis::LanguageV1beta1::Features]
|
313
|
+
attr_accessor :features
|
314
|
+
|
315
|
+
def initialize(**args)
|
316
|
+
update!(**args)
|
317
|
+
end
|
318
|
+
|
319
|
+
# Update properties of this object
|
320
|
+
def update!(**args)
|
321
|
+
@document = args[:document] if args.key?(:document)
|
322
|
+
@encoding_type = args[:encoding_type] if args.key?(:encoding_type)
|
323
|
+
@features = args[:features] if args.key?(:features)
|
324
|
+
end
|
325
|
+
end
|
326
|
+
|
327
|
+
# Represents a sentence in the input document.
|
328
|
+
class Sentence
|
329
|
+
include Google::Apis::Core::Hashable
|
330
|
+
|
331
|
+
# Represents an output piece of text.
|
332
|
+
# Corresponds to the JSON property `text`
|
333
|
+
# @return [Google::Apis::LanguageV1beta1::TextSpan]
|
334
|
+
attr_accessor :text
|
335
|
+
|
336
|
+
def initialize(**args)
|
337
|
+
update!(**args)
|
338
|
+
end
|
339
|
+
|
340
|
+
# Update properties of this object
|
341
|
+
def update!(**args)
|
342
|
+
@text = args[:text] if args.key?(:text)
|
343
|
+
end
|
344
|
+
end
|
345
|
+
|
346
|
+
# All available features for sentiment, syntax, and semantic analysis.
|
347
|
+
# Setting each one to true will enable that specific analysis for the input.
|
348
|
+
class Features
|
349
|
+
include Google::Apis::Core::Hashable
|
350
|
+
|
351
|
+
# Extract document-level sentiment.
|
352
|
+
# Corresponds to the JSON property `extractDocumentSentiment`
|
353
|
+
# @return [Boolean]
|
354
|
+
attr_accessor :extract_document_sentiment
|
355
|
+
alias_method :extract_document_sentiment?, :extract_document_sentiment
|
356
|
+
|
357
|
+
# Extract entities.
|
358
|
+
# Corresponds to the JSON property `extractEntities`
|
359
|
+
# @return [Boolean]
|
360
|
+
attr_accessor :extract_entities
|
361
|
+
alias_method :extract_entities?, :extract_entities
|
362
|
+
|
363
|
+
# Extract syntax information.
|
364
|
+
# Corresponds to the JSON property `extractSyntax`
|
365
|
+
# @return [Boolean]
|
366
|
+
attr_accessor :extract_syntax
|
367
|
+
alias_method :extract_syntax?, :extract_syntax
|
368
|
+
|
369
|
+
def initialize(**args)
|
370
|
+
update!(**args)
|
371
|
+
end
|
372
|
+
|
373
|
+
# Update properties of this object
|
374
|
+
def update!(**args)
|
375
|
+
@extract_document_sentiment = args[:extract_document_sentiment] if args.key?(:extract_document_sentiment)
|
376
|
+
@extract_entities = args[:extract_entities] if args.key?(:extract_entities)
|
377
|
+
@extract_syntax = args[:extract_syntax] if args.key?(:extract_syntax)
|
378
|
+
end
|
379
|
+
end
|
380
|
+
|
381
|
+
# Represents part of speech information for a token.
|
382
|
+
class PartOfSpeech
|
383
|
+
include Google::Apis::Core::Hashable
|
384
|
+
|
385
|
+
# The part of speech tag.
|
386
|
+
# Corresponds to the JSON property `tag`
|
387
|
+
# @return [String]
|
388
|
+
attr_accessor :tag
|
389
|
+
|
390
|
+
def initialize(**args)
|
391
|
+
update!(**args)
|
392
|
+
end
|
393
|
+
|
394
|
+
# Update properties of this object
|
395
|
+
def update!(**args)
|
396
|
+
@tag = args[:tag] if args.key?(:tag)
|
397
|
+
end
|
398
|
+
end
|
399
|
+
|
400
|
+
# The text annotations response message.
|
401
|
+
class AnnotateTextResponse
|
402
|
+
include Google::Apis::Core::Hashable
|
403
|
+
|
404
|
+
# Entities, along with their semantic information, in the input document.
|
405
|
+
# Populated if the user enables
|
406
|
+
# AnnotateTextRequest.Features.extract_entities.
|
407
|
+
# Corresponds to the JSON property `entities`
|
408
|
+
# @return [Array<Google::Apis::LanguageV1beta1::Entity>]
|
409
|
+
attr_accessor :entities
|
410
|
+
|
411
|
+
# Represents the feeling associated with the entire text or entities in
|
412
|
+
# the text.
|
413
|
+
# Corresponds to the JSON property `documentSentiment`
|
414
|
+
# @return [Google::Apis::LanguageV1beta1::Sentiment]
|
415
|
+
attr_accessor :document_sentiment
|
416
|
+
|
417
|
+
# The language of the text, which will be the same as the language specified
|
418
|
+
# in the request or, if not specified, the automatically-detected language.
|
419
|
+
# See Document.language field for more details.
|
420
|
+
# Corresponds to the JSON property `language`
|
421
|
+
# @return [String]
|
422
|
+
attr_accessor :language
|
423
|
+
|
424
|
+
# Tokens, along with their syntactic information, in the input document.
|
425
|
+
# Populated if the user enables
|
426
|
+
# AnnotateTextRequest.Features.extract_syntax.
|
427
|
+
# Corresponds to the JSON property `tokens`
|
428
|
+
# @return [Array<Google::Apis::LanguageV1beta1::Token>]
|
429
|
+
attr_accessor :tokens
|
430
|
+
|
431
|
+
# Sentences in the input document. Populated if the user enables
|
432
|
+
# AnnotateTextRequest.Features.extract_syntax.
|
433
|
+
# Corresponds to the JSON property `sentences`
|
434
|
+
# @return [Array<Google::Apis::LanguageV1beta1::Sentence>]
|
435
|
+
attr_accessor :sentences
|
436
|
+
|
437
|
+
def initialize(**args)
|
438
|
+
update!(**args)
|
439
|
+
end
|
440
|
+
|
441
|
+
# Update properties of this object
|
442
|
+
def update!(**args)
|
443
|
+
@entities = args[:entities] if args.key?(:entities)
|
444
|
+
@document_sentiment = args[:document_sentiment] if args.key?(:document_sentiment)
|
445
|
+
@language = args[:language] if args.key?(:language)
|
446
|
+
@tokens = args[:tokens] if args.key?(:tokens)
|
447
|
+
@sentences = args[:sentences] if args.key?(:sentences)
|
448
|
+
end
|
449
|
+
end
|
450
|
+
|
451
|
+
# Represents a phrase in the text that is a known entity, such as
|
452
|
+
# a person, an organization, or location. The API associates information, such
|
453
|
+
# as salience and mentions, with entities.
|
454
|
+
class Entity
|
455
|
+
include Google::Apis::Core::Hashable
|
456
|
+
|
457
|
+
# Metadata associated with the entity.
|
458
|
+
# Currently, only Wikipedia URLs are provided, if available.
|
459
|
+
# The associated key is "wikipedia_url".
|
460
|
+
# Corresponds to the JSON property `metadata`
|
461
|
+
# @return [Hash<String,String>]
|
462
|
+
attr_accessor :metadata
|
463
|
+
|
464
|
+
# The salience score associated with the entity in the [0, 1.0] range.
|
465
|
+
# The salience score for an entity provides information about the
|
466
|
+
# importance or centrality of that entity to the entire document text.
|
467
|
+
# Scores closer to 0 are less salient, while scores closer to 1.0 are highly
|
468
|
+
# salient.
|
469
|
+
# Corresponds to the JSON property `salience`
|
470
|
+
# @return [Float]
|
471
|
+
attr_accessor :salience
|
472
|
+
|
473
|
+
# The entity type.
|
474
|
+
# Corresponds to the JSON property `type`
|
475
|
+
# @return [String]
|
476
|
+
attr_accessor :type
|
477
|
+
|
478
|
+
# The mentions of this entity in the input document. The API currently
|
479
|
+
# supports proper noun mentions.
|
480
|
+
# Corresponds to the JSON property `mentions`
|
481
|
+
# @return [Array<Google::Apis::LanguageV1beta1::EntityMention>]
|
482
|
+
attr_accessor :mentions
|
483
|
+
|
484
|
+
# The representative name for the entity.
|
485
|
+
# Corresponds to the JSON property `name`
|
486
|
+
# @return [String]
|
487
|
+
attr_accessor :name
|
488
|
+
|
489
|
+
def initialize(**args)
|
490
|
+
update!(**args)
|
491
|
+
end
|
492
|
+
|
493
|
+
# Update properties of this object
|
494
|
+
def update!(**args)
|
495
|
+
@metadata = args[:metadata] if args.key?(:metadata)
|
496
|
+
@salience = args[:salience] if args.key?(:salience)
|
497
|
+
@type = args[:type] if args.key?(:type)
|
498
|
+
@mentions = args[:mentions] if args.key?(:mentions)
|
499
|
+
@name = args[:name] if args.key?(:name)
|
500
|
+
end
|
501
|
+
end
|
502
|
+
|
503
|
+
# Represents the feeling associated with the entire text or entities in
|
504
|
+
# the text.
|
505
|
+
class Sentiment
|
506
|
+
include Google::Apis::Core::Hashable
|
507
|
+
|
508
|
+
# DEPRECATED FIELD - This field is being deprecated in
|
509
|
+
# favor of score. Please refer to our documentation at
|
510
|
+
# https://cloud.google.com/natural-language/docs for more information.
|
511
|
+
# Corresponds to the JSON property `polarity`
|
512
|
+
# @return [Float]
|
513
|
+
attr_accessor :polarity
|
514
|
+
|
515
|
+
# A non-negative number in the [0, +inf) range, which represents
|
516
|
+
# the absolute magnitude of sentiment regardless of polarity (positive or
|
517
|
+
# negative).
|
518
|
+
# Corresponds to the JSON property `magnitude`
|
519
|
+
# @return [Float]
|
520
|
+
attr_accessor :magnitude
|
521
|
+
|
522
|
+
def initialize(**args)
|
523
|
+
update!(**args)
|
524
|
+
end
|
525
|
+
|
526
|
+
# Update properties of this object
|
527
|
+
def update!(**args)
|
528
|
+
@polarity = args[:polarity] if args.key?(:polarity)
|
529
|
+
@magnitude = args[:magnitude] if args.key?(:magnitude)
|
530
|
+
end
|
531
|
+
end
|
532
|
+
|
533
|
+
# Represents the smallest syntactic building block of the text.
|
534
|
+
class Token
|
535
|
+
include Google::Apis::Core::Hashable
|
536
|
+
|
537
|
+
# Represents an output piece of text.
|
538
|
+
# Corresponds to the JSON property `text`
|
539
|
+
# @return [Google::Apis::LanguageV1beta1::TextSpan]
|
540
|
+
attr_accessor :text
|
541
|
+
|
542
|
+
# Represents part of speech information for a token.
|
543
|
+
# Corresponds to the JSON property `partOfSpeech`
|
544
|
+
# @return [Google::Apis::LanguageV1beta1::PartOfSpeech]
|
545
|
+
attr_accessor :part_of_speech
|
546
|
+
|
547
|
+
# Represents dependency parse tree information for a token.
|
548
|
+
# Corresponds to the JSON property `dependencyEdge`
|
549
|
+
# @return [Google::Apis::LanguageV1beta1::DependencyEdge]
|
550
|
+
attr_accessor :dependency_edge
|
551
|
+
|
552
|
+
# [Lemma](https://en.wikipedia.org/wiki/Lemma_(morphology))
|
553
|
+
# of the token.
|
554
|
+
# Corresponds to the JSON property `lemma`
|
555
|
+
# @return [String]
|
556
|
+
attr_accessor :lemma
|
557
|
+
|
558
|
+
def initialize(**args)
|
559
|
+
update!(**args)
|
560
|
+
end
|
561
|
+
|
562
|
+
# Update properties of this object
|
563
|
+
def update!(**args)
|
564
|
+
@text = args[:text] if args.key?(:text)
|
565
|
+
@part_of_speech = args[:part_of_speech] if args.key?(:part_of_speech)
|
566
|
+
@dependency_edge = args[:dependency_edge] if args.key?(:dependency_edge)
|
567
|
+
@lemma = args[:lemma] if args.key?(:lemma)
|
568
|
+
end
|
569
|
+
end
|
570
|
+
|
571
|
+
# The entity analysis response message.
|
572
|
+
class AnalyzeEntitiesResponse
|
573
|
+
include Google::Apis::Core::Hashable
|
574
|
+
|
575
|
+
# The recognized entities in the input document.
|
576
|
+
# Corresponds to the JSON property `entities`
|
577
|
+
# @return [Array<Google::Apis::LanguageV1beta1::Entity>]
|
578
|
+
attr_accessor :entities
|
579
|
+
|
580
|
+
# The language of the text, which will be the same as the language specified
|
581
|
+
# in the request or, if not specified, the automatically-detected language.
|
582
|
+
# See Document.language field for more details.
|
583
|
+
# Corresponds to the JSON property `language`
|
584
|
+
# @return [String]
|
585
|
+
attr_accessor :language
|
586
|
+
|
587
|
+
def initialize(**args)
|
588
|
+
update!(**args)
|
589
|
+
end
|
590
|
+
|
591
|
+
# Update properties of this object
|
592
|
+
def update!(**args)
|
593
|
+
@entities = args[:entities] if args.key?(:entities)
|
594
|
+
@language = args[:language] if args.key?(:language)
|
595
|
+
end
|
596
|
+
end
|
597
|
+
end
|
598
|
+
end
|
599
|
+
end
|