google-api-client 0.8.7 → 0.9.pre1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +20 -0
- data/.rspec +2 -0
- data/.rubocop.yml +7 -0
- data/.rubocop_todo.yml +63 -0
- data/.travis.yml +21 -0
- data/.yardopts +12 -0
- data/CHANGELOG.md +6 -3
- data/CONTRIBUTING.md +31 -0
- data/Gemfile +28 -2
- data/MIGRATING.md +171 -0
- data/README.md +158 -150
- data/Rakefile +1 -40
- data/api_names.yaml +872 -0
- data/api_names_out.yaml +20843 -0
- data/bin/generate-api +93 -0
- data/generated/google/apis/adexchangebuyer_v1_3.rb +35 -0
- data/generated/google/apis/adexchangebuyer_v1_3/classes.rb +1124 -0
- data/generated/google/apis/adexchangebuyer_v1_3/representations.rb +375 -0
- data/generated/google/apis/adexchangebuyer_v1_3/service.rb +893 -0
- data/generated/google/apis/adexchangeseller_v2_0.rb +38 -0
- data/generated/google/apis/adexchangeseller_v2_0/classes.rb +792 -0
- data/generated/google/apis/adexchangeseller_v2_0/representations.rb +309 -0
- data/generated/google/apis/adexchangeseller_v2_0/service.rb +682 -0
- data/generated/google/apis/admin_directory_v1.rb +89 -0
- data/generated/google/apis/admin_directory_v1/classes.rb +2389 -0
- data/generated/google/apis/admin_directory_v1/representations.rb +780 -0
- data/generated/google/apis/admin_directory_v1/service.rb +2805 -0
- data/generated/google/apis/admin_reports_v1.rb +38 -0
- data/generated/google/apis/admin_reports_v1/classes.rb +582 -0
- data/generated/google/apis/admin_reports_v1/representations.rb +231 -0
- data/generated/google/apis/admin_reports_v1/service.rb +341 -0
- data/generated/google/apis/adsense_v1_4.rb +38 -0
- data/generated/google/apis/adsense_v1_4/classes.rb +1279 -0
- data/generated/google/apis/adsense_v1_4/representations.rb +493 -0
- data/generated/google/apis/adsense_v1_4/service.rb +1752 -0
- data/generated/google/apis/adsensehost_v4_1.rb +35 -0
- data/generated/google/apis/adsensehost_v4_1/classes.rb +834 -0
- data/generated/google/apis/adsensehost_v4_1/representations.rb +327 -0
- data/generated/google/apis/adsensehost_v4_1/service.rb +1190 -0
- data/generated/google/apis/analytics_v3.rb +49 -0
- data/generated/google/apis/analytics_v3/classes.rb +5113 -0
- data/generated/google/apis/analytics_v3/representations.rb +1661 -0
- data/generated/google/apis/analytics_v3/service.rb +3600 -0
- data/generated/google/apis/androidenterprise_v1.rb +34 -0
- data/generated/google/apis/androidenterprise_v1/classes.rb +1162 -0
- data/generated/google/apis/androidenterprise_v1/representations.rb +431 -0
- data/generated/google/apis/androidenterprise_v1/service.rb +1979 -0
- data/generated/google/apis/androidpublisher_v2.rb +34 -0
- data/generated/google/apis/androidpublisher_v2/classes.rb +1374 -0
- data/generated/google/apis/androidpublisher_v2/representations.rb +630 -0
- data/generated/google/apis/androidpublisher_v2/service.rb +2390 -0
- data/generated/google/apis/appsactivity_v1.rb +46 -0
- data/generated/google/apis/appsactivity_v1/classes.rb +392 -0
- data/generated/google/apis/appsactivity_v1/representations.rb +184 -0
- data/generated/google/apis/appsactivity_v1/service.rb +129 -0
- data/generated/google/apis/appstate_v1.rb +34 -0
- data/generated/google/apis/appstate_v1/classes.rb +154 -0
- data/generated/google/apis/appstate_v1/representations.rb +79 -0
- data/generated/google/apis/appstate_v1/service.rb +265 -0
- data/generated/google/apis/autoscaler_v1beta2.rb +38 -0
- data/generated/google/apis/autoscaler_v1beta2/classes.rb +747 -0
- data/generated/google/apis/autoscaler_v1beta2/representations.rb +281 -0
- data/generated/google/apis/autoscaler_v1beta2/service.rb +488 -0
- data/generated/google/apis/bigquery_v2.rb +49 -0
- data/generated/google/apis/bigquery_v2/classes.rb +2255 -0
- data/generated/google/apis/bigquery_v2/representations.rb +754 -0
- data/generated/google/apis/bigquery_v2/service.rb +1003 -0
- data/generated/google/apis/blogger_v3.rb +37 -0
- data/generated/google/apis/blogger_v3/classes.rb +1354 -0
- data/generated/google/apis/blogger_v3/representations.rb +562 -0
- data/generated/google/apis/blogger_v3/service.rb +1620 -0
- data/generated/google/apis/books_v1.rb +34 -0
- data/generated/google/apis/books_v1/classes.rb +3515 -0
- data/generated/google/apis/books_v1/representations.rb +1361 -0
- data/generated/google/apis/books_v1/service.rb +2170 -0
- data/generated/google/apis/calendar_v3.rb +37 -0
- data/generated/google/apis/calendar_v3/classes.rb +1702 -0
- data/generated/google/apis/calendar_v3/representations.rb +566 -0
- data/generated/google/apis/calendar_v3/service.rb +1943 -0
- data/generated/google/apis/civicinfo_v2.rb +31 -0
- data/generated/google/apis/civicinfo_v2/classes.rb +1057 -0
- data/generated/google/apis/civicinfo_v2/representations.rb +374 -0
- data/generated/google/apis/civicinfo_v2/service.rb +284 -0
- data/generated/google/apis/cloudmonitoring_v2beta2.rb +34 -0
- data/generated/google/apis/cloudmonitoring_v2beta2/classes.rb +679 -0
- data/generated/google/apis/cloudmonitoring_v2beta2/representations.rb +311 -0
- data/generated/google/apis/cloudmonitoring_v2beta2/service.rb +458 -0
- data/generated/google/apis/cloudresourcemanager_v1beta1.rb +38 -0
- data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +139 -0
- data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +65 -0
- data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +301 -0
- data/generated/google/apis/compute_v1.rb +49 -0
- data/generated/google/apis/compute_v1/classes.rb +6391 -0
- data/generated/google/apis/compute_v1/representations.rb +2209 -0
- data/generated/google/apis/compute_v1/service.rb +6352 -0
- data/generated/google/apis/container_v1beta1.rb +35 -0
- data/generated/google/apis/container_v1beta1/classes.rb +466 -0
- data/generated/google/apis/container_v1beta1/representations.rb +177 -0
- data/generated/google/apis/container_v1beta1/service.rb +394 -0
- data/generated/google/apis/content_v2.rb +35 -0
- data/generated/google/apis/content_v2/classes.rb +3780 -0
- data/generated/google/apis/content_v2/representations.rb +1456 -0
- data/generated/google/apis/content_v2/service.rb +1706 -0
- data/generated/google/apis/coordinate_v1.rb +37 -0
- data/generated/google/apis/coordinate_v1/classes.rb +669 -0
- data/generated/google/apis/coordinate_v1/representations.rb +285 -0
- data/generated/google/apis/coordinate_v1/service.rb +687 -0
- data/{lib/google/api_client/auth/compute_service_account.rb → generated/google/apis/customsearch_v1.rb} +13 -10
- data/generated/google/apis/customsearch_v1/classes.rb +771 -0
- data/generated/google/apis/customsearch_v1/representations.rb +276 -0
- data/generated/google/apis/customsearch_v1/service.rb +208 -0
- data/generated/google/apis/datastore_v1beta2.rb +40 -0
- data/generated/google/apis/datastore_v1beta2/classes.rb +1186 -0
- data/generated/google/apis/datastore_v1beta2/representations.rb +526 -0
- data/generated/google/apis/datastore_v1beta2/service.rb +300 -0
- data/generated/google/apis/deploymentmanager_v2beta2.rb +41 -0
- data/generated/google/apis/deploymentmanager_v2beta2/classes.rb +820 -0
- data/generated/google/apis/deploymentmanager_v2beta2/representations.rb +303 -0
- data/generated/google/apis/deploymentmanager_v2beta2/service.rb +647 -0
- data/generated/google/apis/dfareporting_v2_1.rb +37 -0
- data/generated/google/apis/dfareporting_v2_1/classes.rb +10755 -0
- data/generated/google/apis/dfareporting_v2_1/representations.rb +3438 -0
- data/generated/google/apis/dfareporting_v2_1/service.rb +8775 -0
- data/generated/google/apis/discovery_v1.rb +32 -0
- data/generated/google/apis/discovery_v1/classes.rb +947 -0
- data/generated/google/apis/discovery_v1/representations.rb +355 -0
- data/generated/google/apis/discovery_v1/service.rb +144 -0
- data/generated/google/apis/dns_v1.rb +41 -0
- data/generated/google/apis/dns_v1/classes.rb +406 -0
- data/generated/google/apis/dns_v1/representations.rb +151 -0
- data/generated/google/apis/dns_v1/service.rb +460 -0
- data/{spec/google/api_client/request_spec.rb → generated/google/apis/doubleclickbidmanager_v1.rb} +15 -13
- data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +709 -0
- data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +297 -0
- data/generated/google/apis/doubleclickbidmanager_v1/service.rb +349 -0
- data/generated/google/apis/doubleclicksearch_v2.rb +35 -0
- data/generated/google/apis/doubleclicksearch_v2/classes.rb +947 -0
- data/generated/google/apis/doubleclicksearch_v2/representations.rb +315 -0
- data/generated/google/apis/doubleclicksearch_v2/service.rb +490 -0
- data/generated/google/apis/drive_v2.rb +55 -0
- data/generated/google/apis/drive_v2/classes.rb +2519 -0
- data/generated/google/apis/drive_v2/representations.rb +781 -0
- data/generated/google/apis/drive_v2/service.rb +2685 -0
- data/generated/google/apis/fitness_v1.rb +49 -0
- data/generated/google/apis/fitness_v1/classes.rb +809 -0
- data/generated/google/apis/fitness_v1/representations.rb +295 -0
- data/generated/google/apis/fitness_v1/service.rb +684 -0
- data/generated/google/apis/fusiontables_v2.rb +37 -0
- data/generated/google/apis/fusiontables_v2/classes.rb +1048 -0
- data/generated/google/apis/fusiontables_v2/representations.rb +409 -0
- data/generated/google/apis/fusiontables_v2/service.rb +1496 -0
- data/generated/google/apis/games_configuration_v1configuration.rb +34 -0
- data/generated/google/apis/games_configuration_v1configuration/classes.rb +506 -0
- data/generated/google/apis/games_configuration_v1configuration/representations.rb +206 -0
- data/generated/google/apis/games_configuration_v1configuration/service.rb +578 -0
- data/generated/google/apis/games_v1.rb +40 -0
- data/generated/google/apis/games_v1/classes.rb +4578 -0
- data/generated/google/apis/games_v1/representations.rb +1570 -0
- data/generated/google/apis/games_v1/service.rb +2306 -0
- data/generated/google/apis/gan_v1beta1.rb +31 -0
- data/generated/google/apis/gan_v1beta1/classes.rb +1428 -0
- data/generated/google/apis/gan_v1beta1/representations.rb +428 -0
- data/generated/google/apis/gan_v1beta1/service.rb +692 -0
- data/generated/google/apis/genomics_v1beta2.rb +46 -0
- data/generated/google/apis/genomics_v1beta2/classes.rb +3288 -0
- data/generated/google/apis/genomics_v1beta2/representations.rb +1194 -0
- data/generated/google/apis/genomics_v1beta2/service.rb +2356 -0
- data/generated/google/apis/gmail_v1.rb +49 -0
- data/generated/google/apis/gmail_v1/classes.rb +794 -0
- data/generated/google/apis/gmail_v1/representations.rb +339 -0
- data/generated/google/apis/gmail_v1/service.rb +1502 -0
- data/generated/google/apis/groupsmigration_v1.rb +34 -0
- data/generated/google/apis/groupsmigration_v1/classes.rb +51 -0
- data/generated/google/apis/groupsmigration_v1/representations.rb +38 -0
- data/generated/google/apis/groupsmigration_v1/service.rb +111 -0
- data/generated/google/apis/groupssettings_v1.rb +34 -0
- data/generated/google/apis/groupssettings_v1/classes.rb +221 -0
- data/generated/google/apis/groupssettings_v1/representations.rb +64 -0
- data/generated/google/apis/groupssettings_v1/service.rb +179 -0
- data/generated/google/apis/identitytoolkit_v3.rb +31 -0
- data/generated/google/apis/identitytoolkit_v3/classes.rb +1229 -0
- data/generated/google/apis/identitytoolkit_v3/representations.rb +422 -0
- data/generated/google/apis/identitytoolkit_v3/service.rb +491 -0
- data/generated/google/apis/licensing_v1.rb +34 -0
- data/generated/google/apis/licensing_v1/classes.rb +132 -0
- data/generated/google/apis/licensing_v1/representations.rb +68 -0
- data/generated/google/apis/licensing_v1/service.rb +376 -0
- data/generated/google/apis/logging_v1beta3.rb +35 -0
- data/generated/google/apis/logging_v1beta3/classes.rb +505 -0
- data/generated/google/apis/logging_v1beta3/representations.rb +222 -0
- data/generated/google/apis/logging_v1beta3/service.rb +670 -0
- data/generated/google/apis/manager_v1beta2.rb +50 -0
- data/generated/google/apis/manager_v1beta2/classes.rb +1287 -0
- data/generated/google/apis/manager_v1beta2/representations.rb +536 -0
- data/generated/google/apis/manager_v1beta2/service.rb +380 -0
- data/generated/google/apis/mapsengine_v1.rb +38 -0
- data/generated/google/apis/mapsengine_v1/classes.rb +2873 -0
- data/generated/google/apis/mapsengine_v1/representations.rb +1235 -0
- data/generated/google/apis/mapsengine_v1/service.rb +3465 -0
- data/generated/google/apis/mirror_v1.rb +37 -0
- data/generated/google/apis/mirror_v1/classes.rb +1072 -0
- data/generated/google/apis/mirror_v1/representations.rb +350 -0
- data/generated/google/apis/mirror_v1/service.rb +1001 -0
- data/generated/google/apis/oauth2_v2.rb +43 -0
- data/generated/google/apis/oauth2_v2/classes.rb +245 -0
- data/generated/google/apis/oauth2_v2/representations.rb +94 -0
- data/generated/google/apis/oauth2_v2/service.rb +203 -0
- data/generated/google/apis/pagespeedonline_v2.rb +32 -0
- data/generated/google/apis/pagespeedonline_v2/classes.rb +614 -0
- data/generated/google/apis/pagespeedonline_v2/representations.rb +244 -0
- data/generated/google/apis/pagespeedonline_v2/service.rb +120 -0
- data/generated/google/apis/plus_domains_v1.rb +61 -0
- data/generated/google/apis/plus_domains_v1/classes.rb +2402 -0
- data/generated/google/apis/plus_domains_v1/representations.rb +873 -0
- data/generated/google/apis/plus_domains_v1/service.rb +924 -0
- data/generated/google/apis/plus_v1.rb +43 -0
- data/generated/google/apis/plus_v1/classes.rb +2384 -0
- data/generated/google/apis/plus_v1/representations.rb +812 -0
- data/generated/google/apis/plus_v1/service.rb +616 -0
- data/generated/google/apis/prediction_v1_6.rb +44 -0
- data/generated/google/apis/prediction_v1_6/classes.rb +751 -0
- data/generated/google/apis/prediction_v1_6/representations.rb +327 -0
- data/generated/google/apis/prediction_v1_6/service.rb +388 -0
- data/generated/google/apis/pubsub_v1beta2.rb +37 -0
- data/generated/google/apis/pubsub_v1beta2/classes.rb +824 -0
- data/generated/google/apis/pubsub_v1beta2/representations.rb +366 -0
- data/generated/google/apis/pubsub_v1beta2/service.rb +778 -0
- data/generated/google/apis/qpx_express_v1.rb +31 -0
- data/generated/google/apis/qpx_express_v1/classes.rb +1268 -0
- data/generated/google/apis/qpx_express_v1/representations.rb +424 -0
- data/generated/google/apis/qpx_express_v1/service.rb +101 -0
- data/generated/google/apis/replicapool_v1beta2.rb +41 -0
- data/generated/google/apis/replicapool_v1beta2/classes.rb +621 -0
- data/generated/google/apis/replicapool_v1beta2/representations.rb +235 -0
- data/generated/google/apis/replicapool_v1beta2/service.rb +620 -0
- data/generated/google/apis/replicapoolupdater_v1beta1.rb +41 -0
- data/generated/google/apis/replicapoolupdater_v1beta1/classes.rb +682 -0
- data/generated/google/apis/replicapoolupdater_v1beta1/representations.rb +247 -0
- data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +472 -0
- data/generated/google/apis/reseller_v1.rb +37 -0
- data/generated/google/apis/reseller_v1/classes.rb +502 -0
- data/generated/google/apis/reseller_v1/representations.rb +199 -0
- data/generated/google/apis/reseller_v1/service.rb +637 -0
- data/generated/google/apis/resourceviews_v1beta2.rb +47 -0
- data/generated/google/apis/resourceviews_v1beta2/classes.rb +660 -0
- data/generated/google/apis/resourceviews_v1beta2/representations.rb +269 -0
- data/generated/google/apis/resourceviews_v1beta2/service.rb +574 -0
- data/generated/google/apis/site_verification_v1.rb +37 -0
- data/generated/google/apis/site_verification_v1/classes.rb +185 -0
- data/generated/google/apis/site_verification_v1/representations.rb +101 -0
- data/generated/google/apis/site_verification_v1/service.rb +322 -0
- data/generated/google/apis/sqladmin_v1beta4.rb +37 -0
- data/generated/google/apis/sqladmin_v1beta4/classes.rb +1817 -0
- data/generated/google/apis/sqladmin_v1beta4/representations.rb +688 -0
- data/generated/google/apis/sqladmin_v1beta4/service.rb +1534 -0
- data/generated/google/apis/storage_v1.rb +43 -0
- data/generated/google/apis/storage_v1/classes.rb +1177 -0
- data/generated/google/apis/storage_v1/representations.rb +427 -0
- data/generated/google/apis/storage_v1/service.rb +1920 -0
- data/generated/google/apis/tagmanager_v1.rb +52 -0
- data/generated/google/apis/tagmanager_v1/classes.rb +1226 -0
- data/generated/google/apis/tagmanager_v1/representations.rb +461 -0
- data/generated/google/apis/tagmanager_v1/service.rb +1978 -0
- data/generated/google/apis/taskqueue_v1beta2.rb +37 -0
- data/generated/google/apis/taskqueue_v1beta2/classes.rb +254 -0
- data/generated/google/apis/taskqueue_v1beta2/representations.rb +114 -0
- data/generated/google/apis/taskqueue_v1beta2/service.rb +416 -0
- data/generated/google/apis/tasks_v1.rb +37 -0
- data/generated/google/apis/tasks_v1/classes.rb +296 -0
- data/generated/google/apis/tasks_v1/representations.rb +115 -0
- data/generated/google/apis/tasks_v1/service.rb +657 -0
- data/generated/google/apis/translate_v2.rb +31 -0
- data/generated/google/apis/translate_v2/classes.rb +168 -0
- data/generated/google/apis/translate_v2/representations.rb +109 -0
- data/generated/google/apis/translate_v2/service.rb +185 -0
- data/generated/google/apis/urlshortener_v1.rb +34 -0
- data/generated/google/apis/urlshortener_v1/classes.rb +246 -0
- data/generated/google/apis/urlshortener_v1/representations.rb +111 -0
- data/generated/google/apis/urlshortener_v1/service.rb +179 -0
- data/generated/google/apis/webmasters_v3.rb +37 -0
- data/generated/google/apis/webmasters_v3/classes.rb +563 -0
- data/generated/google/apis/webmasters_v3/representations.rb +250 -0
- data/generated/google/apis/webmasters_v3/service.rb +587 -0
- data/generated/google/apis/youtube_analytics_v1.rb +46 -0
- data/generated/google/apis/youtube_analytics_v1/classes.rb +540 -0
- data/generated/google/apis/youtube_analytics_v1/representations.rb +242 -0
- data/generated/google/apis/youtube_analytics_v1/service.rb +567 -0
- data/generated/google/apis/youtube_v3.rb +49 -0
- data/generated/google/apis/youtube_v3/classes.rb +7225 -0
- data/generated/google/apis/youtube_v3/representations.rb +2529 -0
- data/generated/google/apis/youtube_v3/service.rb +4051 -0
- data/google-api-client.gemspec +27 -39
- data/lib/google/api_client/auth/storage.rb +3 -2
- data/lib/google/api_client/auth/storages/file_store.rb +1 -3
- data/lib/google/api_client/auth/storages/redis_store.rb +6 -2
- data/lib/google/apis.rb +48 -0
- data/lib/google/apis/core/api_command.rb +128 -0
- data/lib/google/apis/core/base_service.rb +314 -0
- data/lib/google/apis/core/batch.rb +222 -0
- data/lib/google/apis/core/download.rb +94 -0
- data/lib/google/apis/core/hashable.rb +44 -0
- data/lib/google/apis/core/http_command.rb +275 -0
- data/lib/google/apis/core/json_representation.rb +122 -0
- data/lib/google/{api_client/version.rb → apis/core/logging.rb} +12 -8
- data/lib/google/apis/core/multipart.rb +173 -0
- data/lib/google/apis/core/upload.rb +275 -0
- data/lib/google/{api_client → apis}/errors.rb +32 -28
- data/lib/google/apis/generator.rb +70 -0
- data/lib/google/apis/generator/annotator.rb +271 -0
- data/lib/google/apis/generator/helpers.rb +74 -0
- data/lib/google/apis/generator/model.rb +130 -0
- data/lib/google/apis/generator/template.rb +124 -0
- data/lib/google/apis/generator/templates/_class.tmpl +40 -0
- data/lib/google/apis/generator/templates/_method.tmpl +90 -0
- data/lib/google/apis/generator/templates/_representation.tmpl +51 -0
- data/lib/google/apis/generator/templates/_representation_stub.tmpl +15 -0
- data/lib/google/apis/generator/templates/_representation_type.tmpl +10 -0
- data/lib/google/{api_client/reference.rb → apis/generator/templates/classes.rb.tmpl} +11 -9
- data/lib/google/apis/generator/templates/module.rb.tmpl +40 -0
- data/lib/google/apis/generator/templates/representations.rb.tmpl +32 -0
- data/lib/google/apis/generator/templates/service.rb.tmpl +60 -0
- data/lib/google/apis/options.rb +79 -0
- data/lib/google/apis/version.rb +39 -0
- data/rakelib/metrics.rake +22 -0
- data/rakelib/rubocop.rake +10 -0
- data/rakelib/spec.rake +11 -0
- data/rakelib/yard.rake +11 -0
- data/samples/calendar/calendar.rb +43 -0
- data/samples/drive/drive.rb +40 -0
- data/samples/pubsub/pubsub.rb +52 -0
- data/{lib/google/api_client/discovery.rb → samples/translate/translate.rb} +14 -5
- data/script/generate +79 -0
- data/script/package +8 -0
- data/script/release +15 -0
- data/spec/fixtures/files/api_names.yaml +3 -0
- data/spec/fixtures/files/auth_stored_credentials.json +8 -0
- data/spec/fixtures/files/client_secrets.json +1 -0
- data/spec/fixtures/files/test.blah +1 -0
- data/spec/fixtures/files/test.txt +1 -0
- data/spec/fixtures/files/test_api.json +440 -0
- data/spec/google/api_client/auth/storage_spec.rb +1 -3
- data/spec/google/api_client/auth/storages/file_store_spec.rb +1 -2
- data/spec/google/api_client/auth/storages/redis_store_spec.rb +1 -3
- data/spec/google/apis/core/api_command_spec.rb +170 -0
- data/spec/google/apis/core/batch_spec.rb +128 -0
- data/spec/google/apis/core/download_spec.rb +90 -0
- data/spec/google/apis/core/hashable_spec.rb +60 -0
- data/spec/google/apis/core/http_command_spec.rb +238 -0
- data/spec/google/apis/core/json_representation_spec.rb +192 -0
- data/spec/google/apis/core/service_spec.rb +247 -0
- data/spec/google/apis/core/upload_spec.rb +238 -0
- data/{lib/google/api_client/service_account.rb → spec/google/apis/generated_spec.rb} +14 -8
- data/spec/google/apis/generator/generator_spec.rb +272 -0
- data/spec/google/apis/logging_spec.rb +45 -0
- data/spec/google/apis/options_spec.rb +40 -0
- data/spec/integration_tests/drive_spec.rb +35 -0
- data/spec/integration_tests/pubsub_spec.rb +48 -0
- data/spec/integration_tests/url_shortener_spec.rb +31 -0
- data/spec/spec_helper.rb +102 -46
- metadata +433 -178
- data/lib/compat/multi_json.rb +0 -19
- data/lib/google/api_client.rb +0 -750
- data/lib/google/api_client/auth/file_storage.rb +0 -59
- data/lib/google/api_client/auth/jwt_asserter.rb +0 -126
- data/lib/google/api_client/auth/key_utils.rb +0 -93
- data/lib/google/api_client/auth/pkcs12.rb +0 -41
- data/lib/google/api_client/batch.rb +0 -326
- data/lib/google/api_client/charset.rb +0 -33
- data/lib/google/api_client/discovery/api.rb +0 -310
- data/lib/google/api_client/discovery/media.rb +0 -77
- data/lib/google/api_client/discovery/method.rb +0 -363
- data/lib/google/api_client/discovery/resource.rb +0 -156
- data/lib/google/api_client/discovery/schema.rb +0 -117
- data/lib/google/api_client/environment.rb +0 -42
- data/lib/google/api_client/gzip.rb +0 -28
- data/lib/google/api_client/logging.rb +0 -32
- data/lib/google/api_client/media.rb +0 -259
- data/lib/google/api_client/railtie.rb +0 -18
- data/lib/google/api_client/request.rb +0 -350
- data/lib/google/api_client/result.rb +0 -255
- data/lib/google/api_client/service.rb +0 -233
- data/lib/google/api_client/service/batch.rb +0 -110
- data/lib/google/api_client/service/request.rb +0 -144
- data/lib/google/api_client/service/resource.rb +0 -40
- data/lib/google/api_client/service/result.rb +0 -162
- data/lib/google/api_client/service/simple_file_store.rb +0 -151
- data/lib/google/api_client/service/stub_generator.rb +0 -61
- data/spec/google/api_client/batch_spec.rb +0 -248
- data/spec/google/api_client/discovery_spec.rb +0 -708
- data/spec/google/api_client/gzip_spec.rb +0 -98
- data/spec/google/api_client/media_spec.rb +0 -178
- data/spec/google/api_client/result_spec.rb +0 -207
- data/spec/google/api_client/service_account_spec.rb +0 -169
- data/spec/google/api_client/service_spec.rb +0 -618
- data/spec/google/api_client/simple_file_store_spec.rb +0 -133
- data/spec/google/api_client_spec.rb +0 -352
@@ -0,0 +1,31 @@
|
|
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/qpx_express_v1/service.rb'
|
16
|
+
require 'google/apis/qpx_express_v1/classes.rb'
|
17
|
+
require 'google/apis/qpx_express_v1/representations.rb'
|
18
|
+
|
19
|
+
module Google
|
20
|
+
module Apis
|
21
|
+
# QPX Express API
|
22
|
+
#
|
23
|
+
# Lets you find the least expensive flights between an origin and a destination.
|
24
|
+
#
|
25
|
+
# @see http://developers.google.com/qpx-express
|
26
|
+
module QpxExpressV1
|
27
|
+
VERSION = 'V1'
|
28
|
+
REVISION = '20140321'
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
@@ -0,0 +1,1268 @@
|
|
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 QpxExpressV1
|
24
|
+
|
25
|
+
# The make, model, and type of an aircraft.
|
26
|
+
class AircraftData
|
27
|
+
include Google::Apis::Core::Hashable
|
28
|
+
|
29
|
+
# The aircraft code. For example, for a Boeing 777 the code would be 777.
|
30
|
+
# Corresponds to the JSON property `code`
|
31
|
+
# @return [String]
|
32
|
+
attr_accessor :code
|
33
|
+
|
34
|
+
# Identifies this as an aircraftData object. Value: the fixed string qpxexpress#
|
35
|
+
# aircraftData
|
36
|
+
# Corresponds to the JSON property `kind`
|
37
|
+
# @return [String]
|
38
|
+
attr_accessor :kind
|
39
|
+
|
40
|
+
# The name of an aircraft, for example Boeing 777.
|
41
|
+
# Corresponds to the JSON property `name`
|
42
|
+
# @return [String]
|
43
|
+
attr_accessor :name
|
44
|
+
|
45
|
+
def initialize(**args)
|
46
|
+
update!(**args)
|
47
|
+
end
|
48
|
+
|
49
|
+
# Update properties of this object
|
50
|
+
def update!(**args)
|
51
|
+
@code = args[:code] unless args[:code].nil?
|
52
|
+
@kind = args[:kind] unless args[:kind].nil?
|
53
|
+
@name = args[:name] unless args[:name].nil?
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
# An airport.
|
58
|
+
class AirportData
|
59
|
+
include Google::Apis::Core::Hashable
|
60
|
+
|
61
|
+
# The city code an airport is located in. For example, for JFK airport, this is
|
62
|
+
# NYC.
|
63
|
+
# Corresponds to the JSON property `city`
|
64
|
+
# @return [String]
|
65
|
+
attr_accessor :city
|
66
|
+
|
67
|
+
# An airport's code. For example, for Boston Logan airport, this is BOS.
|
68
|
+
# Corresponds to the JSON property `code`
|
69
|
+
# @return [String]
|
70
|
+
attr_accessor :code
|
71
|
+
|
72
|
+
# Identifies this as an airport object. Value: the fixed string qpxexpress#
|
73
|
+
# airportData.
|
74
|
+
# Corresponds to the JSON property `kind`
|
75
|
+
# @return [String]
|
76
|
+
attr_accessor :kind
|
77
|
+
|
78
|
+
# The name of an airport. For example, for airport BOS the name is "Boston Logan
|
79
|
+
# International".
|
80
|
+
# Corresponds to the JSON property `name`
|
81
|
+
# @return [String]
|
82
|
+
attr_accessor :name
|
83
|
+
|
84
|
+
def initialize(**args)
|
85
|
+
update!(**args)
|
86
|
+
end
|
87
|
+
|
88
|
+
# Update properties of this object
|
89
|
+
def update!(**args)
|
90
|
+
@city = args[:city] unless args[:city].nil?
|
91
|
+
@code = args[:code] unless args[:code].nil?
|
92
|
+
@kind = args[:kind] unless args[:kind].nil?
|
93
|
+
@name = args[:name] unless args[:name].nil?
|
94
|
+
end
|
95
|
+
end
|
96
|
+
|
97
|
+
# Information about an item of baggage.
|
98
|
+
class BagDescriptor
|
99
|
+
include Google::Apis::Core::Hashable
|
100
|
+
|
101
|
+
# Provides the commercial name for an optional service.
|
102
|
+
# Corresponds to the JSON property `commercialName`
|
103
|
+
# @return [String]
|
104
|
+
attr_accessor :commercial_name
|
105
|
+
|
106
|
+
# How many of this type of bag will be checked on this flight.
|
107
|
+
# Corresponds to the JSON property `count`
|
108
|
+
# @return [Fixnum]
|
109
|
+
attr_accessor :count
|
110
|
+
|
111
|
+
# A description of the baggage.
|
112
|
+
# Corresponds to the JSON property `description`
|
113
|
+
# @return [Array<String>]
|
114
|
+
attr_accessor :description
|
115
|
+
|
116
|
+
# Identifies this as a baggage object. Value: the fixed string qpxexpress#
|
117
|
+
# bagDescriptor.
|
118
|
+
# Corresponds to the JSON property `kind`
|
119
|
+
# @return [String]
|
120
|
+
attr_accessor :kind
|
121
|
+
|
122
|
+
# The standard IATA subcode used to identify this optional service.
|
123
|
+
# Corresponds to the JSON property `subcode`
|
124
|
+
# @return [String]
|
125
|
+
attr_accessor :subcode
|
126
|
+
|
127
|
+
def initialize(**args)
|
128
|
+
update!(**args)
|
129
|
+
end
|
130
|
+
|
131
|
+
# Update properties of this object
|
132
|
+
def update!(**args)
|
133
|
+
@commercial_name = args[:commercial_name] unless args[:commercial_name].nil?
|
134
|
+
@count = args[:count] unless args[:count].nil?
|
135
|
+
@description = args[:description] unless args[:description].nil?
|
136
|
+
@kind = args[:kind] unless args[:kind].nil?
|
137
|
+
@subcode = args[:subcode] unless args[:subcode].nil?
|
138
|
+
end
|
139
|
+
end
|
140
|
+
|
141
|
+
# Information about a carrier (ie. an airline, bus line, railroad, etc) that
|
142
|
+
# might be useful to display to an end-user.
|
143
|
+
class CarrierData
|
144
|
+
include Google::Apis::Core::Hashable
|
145
|
+
|
146
|
+
# The IATA designator of a carrier (airline, etc). For example, for American
|
147
|
+
# Airlines, the code is AA.
|
148
|
+
# Corresponds to the JSON property `code`
|
149
|
+
# @return [String]
|
150
|
+
attr_accessor :code
|
151
|
+
|
152
|
+
# Identifies this as a kind of carrier (ie. an airline, bus line, railroad, etc).
|
153
|
+
# Value: the fixed string qpxexpress#carrierData.
|
154
|
+
# Corresponds to the JSON property `kind`
|
155
|
+
# @return [String]
|
156
|
+
attr_accessor :kind
|
157
|
+
|
158
|
+
# The long, full name of a carrier. For example: American Airlines.
|
159
|
+
# Corresponds to the JSON property `name`
|
160
|
+
# @return [String]
|
161
|
+
attr_accessor :name
|
162
|
+
|
163
|
+
def initialize(**args)
|
164
|
+
update!(**args)
|
165
|
+
end
|
166
|
+
|
167
|
+
# Update properties of this object
|
168
|
+
def update!(**args)
|
169
|
+
@code = args[:code] unless args[:code].nil?
|
170
|
+
@kind = args[:kind] unless args[:kind].nil?
|
171
|
+
@name = args[:name] unless args[:name].nil?
|
172
|
+
end
|
173
|
+
end
|
174
|
+
|
175
|
+
# Information about a city that might be useful to an end-user; typically the
|
176
|
+
# city of an airport.
|
177
|
+
class CityData
|
178
|
+
include Google::Apis::Core::Hashable
|
179
|
+
|
180
|
+
# The IATA character ID of a city. For example, for Boston this is BOS.
|
181
|
+
# Corresponds to the JSON property `code`
|
182
|
+
# @return [String]
|
183
|
+
attr_accessor :code
|
184
|
+
|
185
|
+
# The two-character country code of the country the city is located in. For
|
186
|
+
# example, US for the United States of America.
|
187
|
+
# Corresponds to the JSON property `country`
|
188
|
+
# @return [String]
|
189
|
+
attr_accessor :country
|
190
|
+
|
191
|
+
# Identifies this as a city, typically with one or more airports. Value: the
|
192
|
+
# fixed string qpxexpress#cityData.
|
193
|
+
# Corresponds to the JSON property `kind`
|
194
|
+
# @return [String]
|
195
|
+
attr_accessor :kind
|
196
|
+
|
197
|
+
# The full name of a city. An example would be: New York.
|
198
|
+
# Corresponds to the JSON property `name`
|
199
|
+
# @return [String]
|
200
|
+
attr_accessor :name
|
201
|
+
|
202
|
+
def initialize(**args)
|
203
|
+
update!(**args)
|
204
|
+
end
|
205
|
+
|
206
|
+
# Update properties of this object
|
207
|
+
def update!(**args)
|
208
|
+
@code = args[:code] unless args[:code].nil?
|
209
|
+
@country = args[:country] unless args[:country].nil?
|
210
|
+
@kind = args[:kind] unless args[:kind].nil?
|
211
|
+
@name = args[:name] unless args[:name].nil?
|
212
|
+
end
|
213
|
+
end
|
214
|
+
|
215
|
+
# Detailed information about components found in the solutions of this response,
|
216
|
+
# including a trip's airport, city, taxes, airline, and aircraft.
|
217
|
+
class Data
|
218
|
+
include Google::Apis::Core::Hashable
|
219
|
+
|
220
|
+
# The aircraft that is flying between an origin and destination.
|
221
|
+
# Corresponds to the JSON property `aircraft`
|
222
|
+
# @return [Array<Google::Apis::QpxExpressV1::AircraftData>]
|
223
|
+
attr_accessor :aircraft
|
224
|
+
|
225
|
+
# The airport of an origin or destination.
|
226
|
+
# Corresponds to the JSON property `airport`
|
227
|
+
# @return [Array<Google::Apis::QpxExpressV1::AirportData>]
|
228
|
+
attr_accessor :airport
|
229
|
+
|
230
|
+
# The airline carrier of the aircraft flying between an origin and destination.
|
231
|
+
# Allowed values are IATA carrier codes.
|
232
|
+
# Corresponds to the JSON property `carrier`
|
233
|
+
# @return [Array<Google::Apis::QpxExpressV1::CarrierData>]
|
234
|
+
attr_accessor :carrier
|
235
|
+
|
236
|
+
# The city that is either the origin or destination of part of a trip.
|
237
|
+
# Corresponds to the JSON property `city`
|
238
|
+
# @return [Array<Google::Apis::QpxExpressV1::CityData>]
|
239
|
+
attr_accessor :city
|
240
|
+
|
241
|
+
# Identifies this as QPX Express response resource, including a trip's airport,
|
242
|
+
# city, taxes, airline, and aircraft. Value: the fixed string qpxexpress#data.
|
243
|
+
# Corresponds to the JSON property `kind`
|
244
|
+
# @return [String]
|
245
|
+
attr_accessor :kind
|
246
|
+
|
247
|
+
# The taxes due for flying between an origin and a destination.
|
248
|
+
# Corresponds to the JSON property `tax`
|
249
|
+
# @return [Array<Google::Apis::QpxExpressV1::TaxData>]
|
250
|
+
attr_accessor :tax
|
251
|
+
|
252
|
+
def initialize(**args)
|
253
|
+
update!(**args)
|
254
|
+
end
|
255
|
+
|
256
|
+
# Update properties of this object
|
257
|
+
def update!(**args)
|
258
|
+
@aircraft = args[:aircraft] unless args[:aircraft].nil?
|
259
|
+
@airport = args[:airport] unless args[:airport].nil?
|
260
|
+
@carrier = args[:carrier] unless args[:carrier].nil?
|
261
|
+
@city = args[:city] unless args[:city].nil?
|
262
|
+
@kind = args[:kind] unless args[:kind].nil?
|
263
|
+
@tax = args[:tax] unless args[:tax].nil?
|
264
|
+
end
|
265
|
+
end
|
266
|
+
|
267
|
+
# Complete information about a fare used in the solution to a low-fare search
|
268
|
+
# query. In the airline industry a fare is a price an airline charges for one-
|
269
|
+
# way travel between two points. A fare typically contains a carrier code, two
|
270
|
+
# city codes, a price, and a fare basis. (A fare basis is a one-to-eight
|
271
|
+
# character alphanumeric code used to identify a fare.)
|
272
|
+
class FareInfo
|
273
|
+
include Google::Apis::Core::Hashable
|
274
|
+
|
275
|
+
#
|
276
|
+
# Corresponds to the JSON property `basisCode`
|
277
|
+
# @return [String]
|
278
|
+
attr_accessor :basis_code
|
279
|
+
|
280
|
+
# The carrier of the aircraft or other vehicle commuting between two points.
|
281
|
+
# Corresponds to the JSON property `carrier`
|
282
|
+
# @return [String]
|
283
|
+
attr_accessor :carrier
|
284
|
+
|
285
|
+
# The city code of the city the trip ends at.
|
286
|
+
# Corresponds to the JSON property `destination`
|
287
|
+
# @return [String]
|
288
|
+
attr_accessor :destination
|
289
|
+
|
290
|
+
# A unique identifier of the fare.
|
291
|
+
# Corresponds to the JSON property `id`
|
292
|
+
# @return [String]
|
293
|
+
attr_accessor :id
|
294
|
+
|
295
|
+
# Identifies this as a fare object. Value: the fixed string qpxexpress#fareInfo.
|
296
|
+
# Corresponds to the JSON property `kind`
|
297
|
+
# @return [String]
|
298
|
+
attr_accessor :kind
|
299
|
+
|
300
|
+
# The city code of the city the trip begins at.
|
301
|
+
# Corresponds to the JSON property `origin`
|
302
|
+
# @return [String]
|
303
|
+
attr_accessor :origin
|
304
|
+
|
305
|
+
# Whether this is a private fare, for example one offered only to select
|
306
|
+
# customers rather than the general public.
|
307
|
+
# Corresponds to the JSON property `private`
|
308
|
+
# @return [Boolean]
|
309
|
+
attr_accessor :private
|
310
|
+
alias_method :private?, :private
|
311
|
+
|
312
|
+
def initialize(**args)
|
313
|
+
update!(**args)
|
314
|
+
end
|
315
|
+
|
316
|
+
# Update properties of this object
|
317
|
+
def update!(**args)
|
318
|
+
@basis_code = args[:basis_code] unless args[:basis_code].nil?
|
319
|
+
@carrier = args[:carrier] unless args[:carrier].nil?
|
320
|
+
@destination = args[:destination] unless args[:destination].nil?
|
321
|
+
@id = args[:id] unless args[:id].nil?
|
322
|
+
@kind = args[:kind] unless args[:kind].nil?
|
323
|
+
@origin = args[:origin] unless args[:origin].nil?
|
324
|
+
@private = args[:private] unless args[:private].nil?
|
325
|
+
end
|
326
|
+
end
|
327
|
+
|
328
|
+
# A flight is a sequence of legs with the same airline carrier and flight number.
|
329
|
+
# (A leg is the smallest unit of travel, in the case of a flight a takeoff
|
330
|
+
# immediately followed by a landing at two set points on a particular carrier
|
331
|
+
# with a particular flight number.) The naive view is that a flight is scheduled
|
332
|
+
# travel of an aircraft between two points, with possibly intermediate stops,
|
333
|
+
# but carriers will frequently list flights that require a change of aircraft
|
334
|
+
# between legs.
|
335
|
+
class FlightInfo
|
336
|
+
include Google::Apis::Core::Hashable
|
337
|
+
|
338
|
+
#
|
339
|
+
# Corresponds to the JSON property `carrier`
|
340
|
+
# @return [String]
|
341
|
+
attr_accessor :carrier
|
342
|
+
|
343
|
+
# The flight number.
|
344
|
+
# Corresponds to the JSON property `number`
|
345
|
+
# @return [String]
|
346
|
+
attr_accessor :number
|
347
|
+
|
348
|
+
def initialize(**args)
|
349
|
+
update!(**args)
|
350
|
+
end
|
351
|
+
|
352
|
+
# Update properties of this object
|
353
|
+
def update!(**args)
|
354
|
+
@carrier = args[:carrier] unless args[:carrier].nil?
|
355
|
+
@number = args[:number] unless args[:number].nil?
|
356
|
+
end
|
357
|
+
end
|
358
|
+
|
359
|
+
# Information about free baggage allowed on one segment of a trip.
|
360
|
+
class FreeBaggageAllowance
|
361
|
+
include Google::Apis::Core::Hashable
|
362
|
+
|
363
|
+
# A representation of a type of bag, such as an ATPCo subcode, Commercial Name,
|
364
|
+
# or other description.
|
365
|
+
# Corresponds to the JSON property `bagDescriptor`
|
366
|
+
# @return [Array<Google::Apis::QpxExpressV1::BagDescriptor>]
|
367
|
+
attr_accessor :bag_descriptor
|
368
|
+
|
369
|
+
# The maximum number of kilos all the free baggage together may weigh.
|
370
|
+
# Corresponds to the JSON property `kilos`
|
371
|
+
# @return [Fixnum]
|
372
|
+
attr_accessor :kilos
|
373
|
+
|
374
|
+
# The maximum number of kilos any one piece of baggage may weigh.
|
375
|
+
# Corresponds to the JSON property `kilosPerPiece`
|
376
|
+
# @return [Fixnum]
|
377
|
+
attr_accessor :kilos_per_piece
|
378
|
+
|
379
|
+
# Identifies this as free baggage object, allowed on one segment of a trip.
|
380
|
+
# Value: the fixed string qpxexpress#freeBaggageAllowance.
|
381
|
+
# Corresponds to the JSON property `kind`
|
382
|
+
# @return [String]
|
383
|
+
attr_accessor :kind
|
384
|
+
|
385
|
+
# The number of free pieces of baggage allowed.
|
386
|
+
# Corresponds to the JSON property `pieces`
|
387
|
+
# @return [Fixnum]
|
388
|
+
attr_accessor :pieces
|
389
|
+
|
390
|
+
# The number of pounds of free baggage allowed.
|
391
|
+
# Corresponds to the JSON property `pounds`
|
392
|
+
# @return [Fixnum]
|
393
|
+
attr_accessor :pounds
|
394
|
+
|
395
|
+
def initialize(**args)
|
396
|
+
update!(**args)
|
397
|
+
end
|
398
|
+
|
399
|
+
# Update properties of this object
|
400
|
+
def update!(**args)
|
401
|
+
@bag_descriptor = args[:bag_descriptor] unless args[:bag_descriptor].nil?
|
402
|
+
@kilos = args[:kilos] unless args[:kilos].nil?
|
403
|
+
@kilos_per_piece = args[:kilos_per_piece] unless args[:kilos_per_piece].nil?
|
404
|
+
@kind = args[:kind] unless args[:kind].nil?
|
405
|
+
@pieces = args[:pieces] unless args[:pieces].nil?
|
406
|
+
@pounds = args[:pounds] unless args[:pounds].nil?
|
407
|
+
end
|
408
|
+
end
|
409
|
+
|
410
|
+
# Information about a leg. (A leg is the smallest unit of travel, in the case of
|
411
|
+
# a flight a takeoff immediately followed by a landing at two set points on a
|
412
|
+
# particular carrier with a particular flight number.)
|
413
|
+
class LegInfo
|
414
|
+
include Google::Apis::Core::Hashable
|
415
|
+
|
416
|
+
# The aircraft (or bus, ferry, railcar, etc) travelling between the two points
|
417
|
+
# of this leg.
|
418
|
+
# Corresponds to the JSON property `aircraft`
|
419
|
+
# @return [String]
|
420
|
+
attr_accessor :aircraft
|
421
|
+
|
422
|
+
# The scheduled time of arrival at the destination of the leg, local to the
|
423
|
+
# point of arrival.
|
424
|
+
# Corresponds to the JSON property `arrivalTime`
|
425
|
+
# @return [String]
|
426
|
+
attr_accessor :arrival_time
|
427
|
+
|
428
|
+
# Whether you have to change planes following this leg. Only applies to the next
|
429
|
+
# leg.
|
430
|
+
# Corresponds to the JSON property `changePlane`
|
431
|
+
# @return [Boolean]
|
432
|
+
attr_accessor :change_plane
|
433
|
+
alias_method :change_plane?, :change_plane
|
434
|
+
|
435
|
+
# Duration of a connection following this leg, in minutes.
|
436
|
+
# Corresponds to the JSON property `connectionDuration`
|
437
|
+
# @return [Fixnum]
|
438
|
+
attr_accessor :connection_duration
|
439
|
+
|
440
|
+
# The scheduled departure time of the leg, local to the point of departure.
|
441
|
+
# Corresponds to the JSON property `departureTime`
|
442
|
+
# @return [String]
|
443
|
+
attr_accessor :departure_time
|
444
|
+
|
445
|
+
# The leg destination as a city and airport.
|
446
|
+
# Corresponds to the JSON property `destination`
|
447
|
+
# @return [String]
|
448
|
+
attr_accessor :destination
|
449
|
+
|
450
|
+
# The terminal the flight is scheduled to arrive at.
|
451
|
+
# Corresponds to the JSON property `destinationTerminal`
|
452
|
+
# @return [String]
|
453
|
+
attr_accessor :destination_terminal
|
454
|
+
|
455
|
+
# The scheduled travelling time from the origin to the destination.
|
456
|
+
# Corresponds to the JSON property `duration`
|
457
|
+
# @return [Fixnum]
|
458
|
+
attr_accessor :duration
|
459
|
+
|
460
|
+
# An identifier that uniquely identifies this leg in the solution.
|
461
|
+
# Corresponds to the JSON property `id`
|
462
|
+
# @return [String]
|
463
|
+
attr_accessor :id
|
464
|
+
|
465
|
+
# Identifies this as a leg object. A leg is the smallest unit of travel, in the
|
466
|
+
# case of a flight a takeoff immediately followed by a landing at two set points
|
467
|
+
# on a particular carrier with a particular flight number. Value: the fixed
|
468
|
+
# string qpxexpress#legInfo.
|
469
|
+
# Corresponds to the JSON property `kind`
|
470
|
+
# @return [String]
|
471
|
+
attr_accessor :kind
|
472
|
+
|
473
|
+
# A simple, general description of the meal(s) served on the flight, for example:
|
474
|
+
# "Hot meal".
|
475
|
+
# Corresponds to the JSON property `meal`
|
476
|
+
# @return [String]
|
477
|
+
attr_accessor :meal
|
478
|
+
|
479
|
+
# The number of miles in this leg.
|
480
|
+
# Corresponds to the JSON property `mileage`
|
481
|
+
# @return [Fixnum]
|
482
|
+
attr_accessor :mileage
|
483
|
+
|
484
|
+
# In percent, the published on time performance on this leg.
|
485
|
+
# Corresponds to the JSON property `onTimePerformance`
|
486
|
+
# @return [Fixnum]
|
487
|
+
attr_accessor :on_time_performance
|
488
|
+
|
489
|
+
# Department of Transportation disclosure information on the actual operator of
|
490
|
+
# a flight in a code share. (A code share refers to a marketing agreement
|
491
|
+
# between two carriers, where one carrier will list in its schedules (and take
|
492
|
+
# bookings for) flights that are actually operated by another carrier.)
|
493
|
+
# Corresponds to the JSON property `operatingDisclosure`
|
494
|
+
# @return [String]
|
495
|
+
attr_accessor :operating_disclosure
|
496
|
+
|
497
|
+
# The leg origin as a city and airport.
|
498
|
+
# Corresponds to the JSON property `origin`
|
499
|
+
# @return [String]
|
500
|
+
attr_accessor :origin
|
501
|
+
|
502
|
+
# The terminal the flight is scheduled to depart from.
|
503
|
+
# Corresponds to the JSON property `originTerminal`
|
504
|
+
# @return [String]
|
505
|
+
attr_accessor :origin_terminal
|
506
|
+
|
507
|
+
# Whether passenger information must be furnished to the United States
|
508
|
+
# Transportation Security Administration (TSA) prior to departure.
|
509
|
+
# Corresponds to the JSON property `secure`
|
510
|
+
# @return [Boolean]
|
511
|
+
attr_accessor :secure
|
512
|
+
alias_method :secure?, :secure
|
513
|
+
|
514
|
+
def initialize(**args)
|
515
|
+
update!(**args)
|
516
|
+
end
|
517
|
+
|
518
|
+
# Update properties of this object
|
519
|
+
def update!(**args)
|
520
|
+
@aircraft = args[:aircraft] unless args[:aircraft].nil?
|
521
|
+
@arrival_time = args[:arrival_time] unless args[:arrival_time].nil?
|
522
|
+
@change_plane = args[:change_plane] unless args[:change_plane].nil?
|
523
|
+
@connection_duration = args[:connection_duration] unless args[:connection_duration].nil?
|
524
|
+
@departure_time = args[:departure_time] unless args[:departure_time].nil?
|
525
|
+
@destination = args[:destination] unless args[:destination].nil?
|
526
|
+
@destination_terminal = args[:destination_terminal] unless args[:destination_terminal].nil?
|
527
|
+
@duration = args[:duration] unless args[:duration].nil?
|
528
|
+
@id = args[:id] unless args[:id].nil?
|
529
|
+
@kind = args[:kind] unless args[:kind].nil?
|
530
|
+
@meal = args[:meal] unless args[:meal].nil?
|
531
|
+
@mileage = args[:mileage] unless args[:mileage].nil?
|
532
|
+
@on_time_performance = args[:on_time_performance] unless args[:on_time_performance].nil?
|
533
|
+
@operating_disclosure = args[:operating_disclosure] unless args[:operating_disclosure].nil?
|
534
|
+
@origin = args[:origin] unless args[:origin].nil?
|
535
|
+
@origin_terminal = args[:origin_terminal] unless args[:origin_terminal].nil?
|
536
|
+
@secure = args[:secure] unless args[:secure].nil?
|
537
|
+
end
|
538
|
+
end
|
539
|
+
|
540
|
+
# The number and type of passengers. Unfortunately the definition of an infant,
|
541
|
+
# child, adult, and senior citizen varies across carriers and reservation
|
542
|
+
# systems.
|
543
|
+
class PassengerCounts
|
544
|
+
include Google::Apis::Core::Hashable
|
545
|
+
|
546
|
+
# The number of passengers that are adults.
|
547
|
+
# Corresponds to the JSON property `adultCount`
|
548
|
+
# @return [Fixnum]
|
549
|
+
attr_accessor :adult_count
|
550
|
+
|
551
|
+
# The number of passengers that are children.
|
552
|
+
# Corresponds to the JSON property `childCount`
|
553
|
+
# @return [Fixnum]
|
554
|
+
attr_accessor :child_count
|
555
|
+
|
556
|
+
# The number of passengers that are infants travelling in the lap of an adult.
|
557
|
+
# Corresponds to the JSON property `infantInLapCount`
|
558
|
+
# @return [Fixnum]
|
559
|
+
attr_accessor :infant_in_lap_count
|
560
|
+
|
561
|
+
# The number of passengers that are infants each assigned a seat.
|
562
|
+
# Corresponds to the JSON property `infantInSeatCount`
|
563
|
+
# @return [Fixnum]
|
564
|
+
attr_accessor :infant_in_seat_count
|
565
|
+
|
566
|
+
# Identifies this as a passenger count object, representing the number of
|
567
|
+
# passengers. Value: the fixed string qpxexpress#passengerCounts.
|
568
|
+
# Corresponds to the JSON property `kind`
|
569
|
+
# @return [String]
|
570
|
+
attr_accessor :kind
|
571
|
+
|
572
|
+
# The number of passengers that are senior citizens.
|
573
|
+
# Corresponds to the JSON property `seniorCount`
|
574
|
+
# @return [Fixnum]
|
575
|
+
attr_accessor :senior_count
|
576
|
+
|
577
|
+
def initialize(**args)
|
578
|
+
update!(**args)
|
579
|
+
end
|
580
|
+
|
581
|
+
# Update properties of this object
|
582
|
+
def update!(**args)
|
583
|
+
@adult_count = args[:adult_count] unless args[:adult_count].nil?
|
584
|
+
@child_count = args[:child_count] unless args[:child_count].nil?
|
585
|
+
@infant_in_lap_count = args[:infant_in_lap_count] unless args[:infant_in_lap_count].nil?
|
586
|
+
@infant_in_seat_count = args[:infant_in_seat_count] unless args[:infant_in_seat_count].nil?
|
587
|
+
@kind = args[:kind] unless args[:kind].nil?
|
588
|
+
@senior_count = args[:senior_count] unless args[:senior_count].nil?
|
589
|
+
end
|
590
|
+
end
|
591
|
+
|
592
|
+
# The price of one or more travel segments. The currency used to purchase
|
593
|
+
# tickets is usually determined by the sale/ticketing city or the sale/ticketing
|
594
|
+
# country, unless none are specified, in which case it defaults to that of the
|
595
|
+
# journey origin country.
|
596
|
+
class PricingInfo
|
597
|
+
include Google::Apis::Core::Hashable
|
598
|
+
|
599
|
+
# The total fare in the base fare currency (the currency of the country of
|
600
|
+
# origin). This element is only present when the sales currency and the currency
|
601
|
+
# of the country of commencement are different.
|
602
|
+
# Corresponds to the JSON property `baseFareTotal`
|
603
|
+
# @return [String]
|
604
|
+
attr_accessor :base_fare_total
|
605
|
+
|
606
|
+
# The fare used to price one or more segments.
|
607
|
+
# Corresponds to the JSON property `fare`
|
608
|
+
# @return [Array<Google::Apis::QpxExpressV1::FareInfo>]
|
609
|
+
attr_accessor :fare
|
610
|
+
|
611
|
+
# The horizontal fare calculation. This is a field on a ticket that displays all
|
612
|
+
# of the relevant items that go into the calculation of the fare.
|
613
|
+
# Corresponds to the JSON property `fareCalculation`
|
614
|
+
# @return [String]
|
615
|
+
attr_accessor :fare_calculation
|
616
|
+
|
617
|
+
# Identifies this as a pricing object, representing the price of one or more
|
618
|
+
# travel segments. Value: the fixed string qpxexpress#pricingInfo.
|
619
|
+
# Corresponds to the JSON property `kind`
|
620
|
+
# @return [String]
|
621
|
+
attr_accessor :kind
|
622
|
+
|
623
|
+
# The latest ticketing time for this pricing assuming the reservation occurs at
|
624
|
+
# ticketing time and there is no change in fares/rules. The time is local to the
|
625
|
+
# point of sale (POS).
|
626
|
+
# Corresponds to the JSON property `latestTicketingTime`
|
627
|
+
# @return [String]
|
628
|
+
attr_accessor :latest_ticketing_time
|
629
|
+
|
630
|
+
# The number and type of passengers. Unfortunately the definition of an infant,
|
631
|
+
# child, adult, and senior citizen varies across carriers and reservation
|
632
|
+
# systems.
|
633
|
+
# Corresponds to the JSON property `passengers`
|
634
|
+
# @return [Google::Apis::QpxExpressV1::PassengerCounts]
|
635
|
+
attr_accessor :passengers
|
636
|
+
|
637
|
+
# The passenger type code for this pricing. An alphanumeric code used by a
|
638
|
+
# carrier to restrict fares to certain categories of passenger. For instance, a
|
639
|
+
# fare might be valid only for senior citizens.
|
640
|
+
# Corresponds to the JSON property `ptc`
|
641
|
+
# @return [String]
|
642
|
+
attr_accessor :ptc
|
643
|
+
|
644
|
+
# Whether the fares on this pricing are refundable.
|
645
|
+
# Corresponds to the JSON property `refundable`
|
646
|
+
# @return [Boolean]
|
647
|
+
attr_accessor :refundable
|
648
|
+
alias_method :refundable?, :refundable
|
649
|
+
|
650
|
+
# The total fare in the sale or equivalent currency.
|
651
|
+
# Corresponds to the JSON property `saleFareTotal`
|
652
|
+
# @return [String]
|
653
|
+
attr_accessor :sale_fare_total
|
654
|
+
|
655
|
+
# The taxes in the sale or equivalent currency.
|
656
|
+
# Corresponds to the JSON property `saleTaxTotal`
|
657
|
+
# @return [String]
|
658
|
+
attr_accessor :sale_tax_total
|
659
|
+
|
660
|
+
# Total per-passenger price (fare and tax) in the sale or equivalent currency.
|
661
|
+
# Corresponds to the JSON property `saleTotal`
|
662
|
+
# @return [String]
|
663
|
+
attr_accessor :sale_total
|
664
|
+
|
665
|
+
# The per-segment price and baggage information.
|
666
|
+
# Corresponds to the JSON property `segmentPricing`
|
667
|
+
# @return [Array<Google::Apis::QpxExpressV1::SegmentPricing>]
|
668
|
+
attr_accessor :segment_pricing
|
669
|
+
|
670
|
+
# The taxes used to calculate the tax total per ticket.
|
671
|
+
# Corresponds to the JSON property `tax`
|
672
|
+
# @return [Array<Google::Apis::QpxExpressV1::TaxInfo>]
|
673
|
+
attr_accessor :tax
|
674
|
+
|
675
|
+
def initialize(**args)
|
676
|
+
update!(**args)
|
677
|
+
end
|
678
|
+
|
679
|
+
# Update properties of this object
|
680
|
+
def update!(**args)
|
681
|
+
@base_fare_total = args[:base_fare_total] unless args[:base_fare_total].nil?
|
682
|
+
@fare = args[:fare] unless args[:fare].nil?
|
683
|
+
@fare_calculation = args[:fare_calculation] unless args[:fare_calculation].nil?
|
684
|
+
@kind = args[:kind] unless args[:kind].nil?
|
685
|
+
@latest_ticketing_time = args[:latest_ticketing_time] unless args[:latest_ticketing_time].nil?
|
686
|
+
@passengers = args[:passengers] unless args[:passengers].nil?
|
687
|
+
@ptc = args[:ptc] unless args[:ptc].nil?
|
688
|
+
@refundable = args[:refundable] unless args[:refundable].nil?
|
689
|
+
@sale_fare_total = args[:sale_fare_total] unless args[:sale_fare_total].nil?
|
690
|
+
@sale_tax_total = args[:sale_tax_total] unless args[:sale_tax_total].nil?
|
691
|
+
@sale_total = args[:sale_total] unless args[:sale_total].nil?
|
692
|
+
@segment_pricing = args[:segment_pricing] unless args[:segment_pricing].nil?
|
693
|
+
@tax = args[:tax] unless args[:tax].nil?
|
694
|
+
end
|
695
|
+
end
|
696
|
+
|
697
|
+
# Details of a segment of a flight; a segment is one or more consecutive legs on
|
698
|
+
# the same flight. For example a hypothetical flight ZZ001, from DFW to OGG,
|
699
|
+
# would have one segment with two legs: DFW to HNL (leg 1), HNL to OGG (leg 2),
|
700
|
+
# and DFW to OGG (legs 1 and 2).
|
701
|
+
class SegmentInfo
|
702
|
+
include Google::Apis::Core::Hashable
|
703
|
+
|
704
|
+
# The booking code or class for this segment.
|
705
|
+
# Corresponds to the JSON property `bookingCode`
|
706
|
+
# @return [String]
|
707
|
+
attr_accessor :booking_code
|
708
|
+
|
709
|
+
# The number of seats available in this booking code on this segment.
|
710
|
+
# Corresponds to the JSON property `bookingCodeCount`
|
711
|
+
# @return [Fixnum]
|
712
|
+
attr_accessor :booking_code_count
|
713
|
+
|
714
|
+
# The cabin booked for this segment.
|
715
|
+
# Corresponds to the JSON property `cabin`
|
716
|
+
# @return [String]
|
717
|
+
attr_accessor :cabin
|
718
|
+
|
719
|
+
# In minutes, the duration of the connection following this segment.
|
720
|
+
# Corresponds to the JSON property `connectionDuration`
|
721
|
+
# @return [Fixnum]
|
722
|
+
attr_accessor :connection_duration
|
723
|
+
|
724
|
+
# The duration of the flight segment in minutes.
|
725
|
+
# Corresponds to the JSON property `duration`
|
726
|
+
# @return [Fixnum]
|
727
|
+
attr_accessor :duration
|
728
|
+
|
729
|
+
# A flight is a sequence of legs with the same airline carrier and flight number.
|
730
|
+
# (A leg is the smallest unit of travel, in the case of a flight a takeoff
|
731
|
+
# immediately followed by a landing at two set points on a particular carrier
|
732
|
+
# with a particular flight number.) The naive view is that a flight is scheduled
|
733
|
+
# travel of an aircraft between two points, with possibly intermediate stops,
|
734
|
+
# but carriers will frequently list flights that require a change of aircraft
|
735
|
+
# between legs.
|
736
|
+
# Corresponds to the JSON property `flight`
|
737
|
+
# @return [Google::Apis::QpxExpressV1::FlightInfo]
|
738
|
+
attr_accessor :flight
|
739
|
+
|
740
|
+
# An id uniquely identifying the segment in the solution.
|
741
|
+
# Corresponds to the JSON property `id`
|
742
|
+
# @return [String]
|
743
|
+
attr_accessor :id
|
744
|
+
|
745
|
+
# Identifies this as a segment object. A segment is one or more consecutive legs
|
746
|
+
# on the same flight. For example a hypothetical flight ZZ001, from DFW to OGG,
|
747
|
+
# could have one segment with two legs: DFW to HNL (leg 1), HNL to OGG (leg 2).
|
748
|
+
# Value: the fixed string qpxexpress#segmentInfo.
|
749
|
+
# Corresponds to the JSON property `kind`
|
750
|
+
# @return [String]
|
751
|
+
attr_accessor :kind
|
752
|
+
|
753
|
+
# The legs composing this segment.
|
754
|
+
# Corresponds to the JSON property `leg`
|
755
|
+
# @return [Array<Google::Apis::QpxExpressV1::LegInfo>]
|
756
|
+
attr_accessor :leg
|
757
|
+
|
758
|
+
# The solution-based index of a segment in a married segment group. Married
|
759
|
+
# segments can only be booked together. For example, an airline might report a
|
760
|
+
# certain booking code as sold out from Boston to Pittsburgh, but as available
|
761
|
+
# as part of two married segments Boston to Chicago connecting through
|
762
|
+
# Pittsburgh. For example content of this field, consider the round-trip flight
|
763
|
+
# ZZ1 PHX-PHL ZZ2 PHL-CLT ZZ3 CLT-PHX. This has three segments, with the two
|
764
|
+
# outbound ones (ZZ1 ZZ2) married. In this case, the two outbound segments
|
765
|
+
# belong to married segment group 0, and the return segment belongs to married
|
766
|
+
# segment group 1.
|
767
|
+
# Corresponds to the JSON property `marriedSegmentGroup`
|
768
|
+
# @return [String]
|
769
|
+
attr_accessor :married_segment_group
|
770
|
+
|
771
|
+
# Whether the operation of this segment remains subject to government approval.
|
772
|
+
# Corresponds to the JSON property `subjectToGovernmentApproval`
|
773
|
+
# @return [Boolean]
|
774
|
+
attr_accessor :subject_to_government_approval
|
775
|
+
alias_method :subject_to_government_approval?, :subject_to_government_approval
|
776
|
+
|
777
|
+
def initialize(**args)
|
778
|
+
update!(**args)
|
779
|
+
end
|
780
|
+
|
781
|
+
# Update properties of this object
|
782
|
+
def update!(**args)
|
783
|
+
@booking_code = args[:booking_code] unless args[:booking_code].nil?
|
784
|
+
@booking_code_count = args[:booking_code_count] unless args[:booking_code_count].nil?
|
785
|
+
@cabin = args[:cabin] unless args[:cabin].nil?
|
786
|
+
@connection_duration = args[:connection_duration] unless args[:connection_duration].nil?
|
787
|
+
@duration = args[:duration] unless args[:duration].nil?
|
788
|
+
@flight = args[:flight] unless args[:flight].nil?
|
789
|
+
@id = args[:id] unless args[:id].nil?
|
790
|
+
@kind = args[:kind] unless args[:kind].nil?
|
791
|
+
@leg = args[:leg] unless args[:leg].nil?
|
792
|
+
@married_segment_group = args[:married_segment_group] unless args[:married_segment_group].nil?
|
793
|
+
@subject_to_government_approval = args[:subject_to_government_approval] unless args[:subject_to_government_approval].nil?
|
794
|
+
end
|
795
|
+
end
|
796
|
+
|
797
|
+
# The price of this segment.
|
798
|
+
class SegmentPricing
|
799
|
+
include Google::Apis::Core::Hashable
|
800
|
+
|
801
|
+
# A segment identifier unique within a single solution. It is used to refer to
|
802
|
+
# different parts of the same solution.
|
803
|
+
# Corresponds to the JSON property `fareId`
|
804
|
+
# @return [String]
|
805
|
+
attr_accessor :fare_id
|
806
|
+
|
807
|
+
# Details of the free baggage allowance on this segment.
|
808
|
+
# Corresponds to the JSON property `freeBaggageOption`
|
809
|
+
# @return [Array<Google::Apis::QpxExpressV1::FreeBaggageAllowance>]
|
810
|
+
attr_accessor :free_baggage_option
|
811
|
+
|
812
|
+
# Identifies this as a segment pricing object, representing the price of this
|
813
|
+
# segment. Value: the fixed string qpxexpress#segmentPricing.
|
814
|
+
# Corresponds to the JSON property `kind`
|
815
|
+
# @return [String]
|
816
|
+
attr_accessor :kind
|
817
|
+
|
818
|
+
# Unique identifier in the response of this segment.
|
819
|
+
# Corresponds to the JSON property `segmentId`
|
820
|
+
# @return [String]
|
821
|
+
attr_accessor :segment_id
|
822
|
+
|
823
|
+
def initialize(**args)
|
824
|
+
update!(**args)
|
825
|
+
end
|
826
|
+
|
827
|
+
# Update properties of this object
|
828
|
+
def update!(**args)
|
829
|
+
@fare_id = args[:fare_id] unless args[:fare_id].nil?
|
830
|
+
@free_baggage_option = args[:free_baggage_option] unless args[:free_baggage_option].nil?
|
831
|
+
@kind = args[:kind] unless args[:kind].nil?
|
832
|
+
@segment_id = args[:segment_id] unless args[:segment_id].nil?
|
833
|
+
end
|
834
|
+
end
|
835
|
+
|
836
|
+
# Information about a slice. A slice represents a traveller's intent, the
|
837
|
+
# portion of a low-fare search corresponding to a traveler's request to get
|
838
|
+
# between two points. One-way journeys are generally expressed using 1 slice,
|
839
|
+
# round-trips using 2. For example, if a traveler specifies the following trip
|
840
|
+
# in a user interface:
|
841
|
+
# | Origin | Destination | Departure Date | | BOS | LAX | March 10, 2007 | | LAX
|
842
|
+
# | SYD | March 17, 2007 | | SYD | BOS | March 22, 2007 |
|
843
|
+
# then this is a three slice trip.
|
844
|
+
class SliceInfo
|
845
|
+
include Google::Apis::Core::Hashable
|
846
|
+
|
847
|
+
# The duration of the slice in minutes.
|
848
|
+
# Corresponds to the JSON property `duration`
|
849
|
+
# @return [Fixnum]
|
850
|
+
attr_accessor :duration
|
851
|
+
|
852
|
+
# Identifies this as a slice object. A slice represents a traveller's intent,
|
853
|
+
# the portion of a low-fare search corresponding to a traveler's request to get
|
854
|
+
# between two points. One-way journeys are generally expressed using 1 slice,
|
855
|
+
# round-trips using 2. Value: the fixed string qpxexpress#sliceInfo.
|
856
|
+
# Corresponds to the JSON property `kind`
|
857
|
+
# @return [String]
|
858
|
+
attr_accessor :kind
|
859
|
+
|
860
|
+
# The segment(s) constituting the slice.
|
861
|
+
# Corresponds to the JSON property `segment`
|
862
|
+
# @return [Array<Google::Apis::QpxExpressV1::SegmentInfo>]
|
863
|
+
attr_accessor :segment
|
864
|
+
|
865
|
+
def initialize(**args)
|
866
|
+
update!(**args)
|
867
|
+
end
|
868
|
+
|
869
|
+
# Update properties of this object
|
870
|
+
def update!(**args)
|
871
|
+
@duration = args[:duration] unless args[:duration].nil?
|
872
|
+
@kind = args[:kind] unless args[:kind].nil?
|
873
|
+
@segment = args[:segment] unless args[:segment].nil?
|
874
|
+
end
|
875
|
+
end
|
876
|
+
|
877
|
+
# Criteria a desired slice must satisfy.
|
878
|
+
class SliceInput
|
879
|
+
include Google::Apis::Core::Hashable
|
880
|
+
|
881
|
+
# Slices with only the carriers in this alliance should be returned; do not use
|
882
|
+
# this field with permittedCarrier. Allowed values are ONEWORLD, SKYTEAM, and
|
883
|
+
# STAR.
|
884
|
+
# Corresponds to the JSON property `alliance`
|
885
|
+
# @return [String]
|
886
|
+
attr_accessor :alliance
|
887
|
+
|
888
|
+
# Departure date in YYYY-MM-DD format.
|
889
|
+
# Corresponds to the JSON property `date`
|
890
|
+
# @return [String]
|
891
|
+
attr_accessor :date
|
892
|
+
|
893
|
+
# Airport or city IATA designator of the destination.
|
894
|
+
# Corresponds to the JSON property `destination`
|
895
|
+
# @return [String]
|
896
|
+
attr_accessor :destination
|
897
|
+
|
898
|
+
# Identifies this as a slice input object, representing the criteria a desired
|
899
|
+
# slice must satisfy. Value: the fixed string qpxexpress#sliceInput.
|
900
|
+
# Corresponds to the JSON property `kind`
|
901
|
+
# @return [String]
|
902
|
+
attr_accessor :kind
|
903
|
+
|
904
|
+
# The longest connection between two legs, in minutes, you are willing to accept.
|
905
|
+
# Corresponds to the JSON property `maxConnectionDuration`
|
906
|
+
# @return [Fixnum]
|
907
|
+
attr_accessor :max_connection_duration
|
908
|
+
|
909
|
+
# The maximum number of stops you are willing to accept in this slice.
|
910
|
+
# Corresponds to the JSON property `maxStops`
|
911
|
+
# @return [Fixnum]
|
912
|
+
attr_accessor :max_stops
|
913
|
+
|
914
|
+
# Airport or city IATA designator of the origin.
|
915
|
+
# Corresponds to the JSON property `origin`
|
916
|
+
# @return [String]
|
917
|
+
attr_accessor :origin
|
918
|
+
|
919
|
+
# A list of 2-letter IATA airline designators. Slices with only these carriers
|
920
|
+
# should be returned.
|
921
|
+
# Corresponds to the JSON property `permittedCarrier`
|
922
|
+
# @return [Array<String>]
|
923
|
+
attr_accessor :permitted_carrier
|
924
|
+
|
925
|
+
# Two times in a single day defining a time range.
|
926
|
+
# Corresponds to the JSON property `permittedDepartureTime`
|
927
|
+
# @return [Google::Apis::QpxExpressV1::TimeOfDayRange]
|
928
|
+
attr_accessor :permitted_departure_time
|
929
|
+
|
930
|
+
# Prefer solutions that book in this cabin for this slice. Allowed values are
|
931
|
+
# COACH, PREMIUM_COACH, BUSINESS, and FIRST.
|
932
|
+
# Corresponds to the JSON property `preferredCabin`
|
933
|
+
# @return [String]
|
934
|
+
attr_accessor :preferred_cabin
|
935
|
+
|
936
|
+
# A list of 2-letter IATA airline designators. Exclude slices that use these
|
937
|
+
# carriers.
|
938
|
+
# Corresponds to the JSON property `prohibitedCarrier`
|
939
|
+
# @return [Array<String>]
|
940
|
+
attr_accessor :prohibited_carrier
|
941
|
+
|
942
|
+
def initialize(**args)
|
943
|
+
update!(**args)
|
944
|
+
end
|
945
|
+
|
946
|
+
# Update properties of this object
|
947
|
+
def update!(**args)
|
948
|
+
@alliance = args[:alliance] unless args[:alliance].nil?
|
949
|
+
@date = args[:date] unless args[:date].nil?
|
950
|
+
@destination = args[:destination] unless args[:destination].nil?
|
951
|
+
@kind = args[:kind] unless args[:kind].nil?
|
952
|
+
@max_connection_duration = args[:max_connection_duration] unless args[:max_connection_duration].nil?
|
953
|
+
@max_stops = args[:max_stops] unless args[:max_stops].nil?
|
954
|
+
@origin = args[:origin] unless args[:origin].nil?
|
955
|
+
@permitted_carrier = args[:permitted_carrier] unless args[:permitted_carrier].nil?
|
956
|
+
@permitted_departure_time = args[:permitted_departure_time] unless args[:permitted_departure_time].nil?
|
957
|
+
@preferred_cabin = args[:preferred_cabin] unless args[:preferred_cabin].nil?
|
958
|
+
@prohibited_carrier = args[:prohibited_carrier] unless args[:prohibited_carrier].nil?
|
959
|
+
end
|
960
|
+
end
|
961
|
+
|
962
|
+
# Tax data.
|
963
|
+
class TaxData
|
964
|
+
include Google::Apis::Core::Hashable
|
965
|
+
|
966
|
+
# An identifier uniquely identifying a tax in a response.
|
967
|
+
# Corresponds to the JSON property `id`
|
968
|
+
# @return [String]
|
969
|
+
attr_accessor :id
|
970
|
+
|
971
|
+
# Identifies this as a tax data object, representing some tax. Value: the fixed
|
972
|
+
# string qpxexpress#taxData.
|
973
|
+
# Corresponds to the JSON property `kind`
|
974
|
+
# @return [String]
|
975
|
+
attr_accessor :kind
|
976
|
+
|
977
|
+
# The name of a tax.
|
978
|
+
# Corresponds to the JSON property `name`
|
979
|
+
# @return [String]
|
980
|
+
attr_accessor :name
|
981
|
+
|
982
|
+
def initialize(**args)
|
983
|
+
update!(**args)
|
984
|
+
end
|
985
|
+
|
986
|
+
# Update properties of this object
|
987
|
+
def update!(**args)
|
988
|
+
@id = args[:id] unless args[:id].nil?
|
989
|
+
@kind = args[:kind] unless args[:kind].nil?
|
990
|
+
@name = args[:name] unless args[:name].nil?
|
991
|
+
end
|
992
|
+
end
|
993
|
+
|
994
|
+
# Tax information.
|
995
|
+
class TaxInfo
|
996
|
+
include Google::Apis::Core::Hashable
|
997
|
+
|
998
|
+
# Whether this is a government charge or a carrier surcharge.
|
999
|
+
# Corresponds to the JSON property `chargeType`
|
1000
|
+
# @return [String]
|
1001
|
+
attr_accessor :charge_type
|
1002
|
+
|
1003
|
+
# The code to enter in the ticket's tax box.
|
1004
|
+
# Corresponds to the JSON property `code`
|
1005
|
+
# @return [String]
|
1006
|
+
attr_accessor :code
|
1007
|
+
|
1008
|
+
# For government charges, the country levying the charge.
|
1009
|
+
# Corresponds to the JSON property `country`
|
1010
|
+
# @return [String]
|
1011
|
+
attr_accessor :country
|
1012
|
+
|
1013
|
+
# Identifier uniquely identifying this tax in a response. Not present for
|
1014
|
+
# unnamed carrier surcharges.
|
1015
|
+
# Corresponds to the JSON property `id`
|
1016
|
+
# @return [String]
|
1017
|
+
attr_accessor :id
|
1018
|
+
|
1019
|
+
# Identifies this as a tax information object. Value: the fixed string
|
1020
|
+
# qpxexpress#taxInfo.
|
1021
|
+
# Corresponds to the JSON property `kind`
|
1022
|
+
# @return [String]
|
1023
|
+
attr_accessor :kind
|
1024
|
+
|
1025
|
+
# The price of the tax in the sales or equivalent currency.
|
1026
|
+
# Corresponds to the JSON property `salePrice`
|
1027
|
+
# @return [String]
|
1028
|
+
attr_accessor :sale_price
|
1029
|
+
|
1030
|
+
def initialize(**args)
|
1031
|
+
update!(**args)
|
1032
|
+
end
|
1033
|
+
|
1034
|
+
# Update properties of this object
|
1035
|
+
def update!(**args)
|
1036
|
+
@charge_type = args[:charge_type] unless args[:charge_type].nil?
|
1037
|
+
@code = args[:code] unless args[:code].nil?
|
1038
|
+
@country = args[:country] unless args[:country].nil?
|
1039
|
+
@id = args[:id] unless args[:id].nil?
|
1040
|
+
@kind = args[:kind] unless args[:kind].nil?
|
1041
|
+
@sale_price = args[:sale_price] unless args[:sale_price].nil?
|
1042
|
+
end
|
1043
|
+
end
|
1044
|
+
|
1045
|
+
# Two times in a single day defining a time range.
|
1046
|
+
class TimeOfDayRange
|
1047
|
+
include Google::Apis::Core::Hashable
|
1048
|
+
|
1049
|
+
# The earliest time of day in HH:MM format.
|
1050
|
+
# Corresponds to the JSON property `earliestTime`
|
1051
|
+
# @return [String]
|
1052
|
+
attr_accessor :earliest_time
|
1053
|
+
|
1054
|
+
# Identifies this as a time of day range object, representing two times in a
|
1055
|
+
# single day defining a time range. Value: the fixed string qpxexpress#
|
1056
|
+
# timeOfDayRange.
|
1057
|
+
# Corresponds to the JSON property `kind`
|
1058
|
+
# @return [String]
|
1059
|
+
attr_accessor :kind
|
1060
|
+
|
1061
|
+
# The latest time of day in HH:MM format.
|
1062
|
+
# Corresponds to the JSON property `latestTime`
|
1063
|
+
# @return [String]
|
1064
|
+
attr_accessor :latest_time
|
1065
|
+
|
1066
|
+
def initialize(**args)
|
1067
|
+
update!(**args)
|
1068
|
+
end
|
1069
|
+
|
1070
|
+
# Update properties of this object
|
1071
|
+
def update!(**args)
|
1072
|
+
@earliest_time = args[:earliest_time] unless args[:earliest_time].nil?
|
1073
|
+
@kind = args[:kind] unless args[:kind].nil?
|
1074
|
+
@latest_time = args[:latest_time] unless args[:latest_time].nil?
|
1075
|
+
end
|
1076
|
+
end
|
1077
|
+
|
1078
|
+
# Trip information.
|
1079
|
+
class TripOption
|
1080
|
+
include Google::Apis::Core::Hashable
|
1081
|
+
|
1082
|
+
# Identifier uniquely identifying this trip in a response.
|
1083
|
+
# Corresponds to the JSON property `id`
|
1084
|
+
# @return [String]
|
1085
|
+
attr_accessor :id
|
1086
|
+
|
1087
|
+
# Identifies this as a trip information object. Value: the fixed string
|
1088
|
+
# qpxexpress#tripOption.
|
1089
|
+
# Corresponds to the JSON property `kind`
|
1090
|
+
# @return [String]
|
1091
|
+
attr_accessor :kind
|
1092
|
+
|
1093
|
+
# Per passenger pricing information.
|
1094
|
+
# Corresponds to the JSON property `pricing`
|
1095
|
+
# @return [Array<Google::Apis::QpxExpressV1::PricingInfo>]
|
1096
|
+
attr_accessor :pricing
|
1097
|
+
|
1098
|
+
# The total price for all passengers on the trip, in the form of a currency
|
1099
|
+
# followed by an amount, e.g. USD253.35.
|
1100
|
+
# Corresponds to the JSON property `saleTotal`
|
1101
|
+
# @return [String]
|
1102
|
+
attr_accessor :sale_total
|
1103
|
+
|
1104
|
+
# The slices that make up this trip's itinerary.
|
1105
|
+
# Corresponds to the JSON property `slice`
|
1106
|
+
# @return [Array<Google::Apis::QpxExpressV1::SliceInfo>]
|
1107
|
+
attr_accessor :slice
|
1108
|
+
|
1109
|
+
def initialize(**args)
|
1110
|
+
update!(**args)
|
1111
|
+
end
|
1112
|
+
|
1113
|
+
# Update properties of this object
|
1114
|
+
def update!(**args)
|
1115
|
+
@id = args[:id] unless args[:id].nil?
|
1116
|
+
@kind = args[:kind] unless args[:kind].nil?
|
1117
|
+
@pricing = args[:pricing] unless args[:pricing].nil?
|
1118
|
+
@sale_total = args[:sale_total] unless args[:sale_total].nil?
|
1119
|
+
@slice = args[:slice] unless args[:slice].nil?
|
1120
|
+
end
|
1121
|
+
end
|
1122
|
+
|
1123
|
+
# A QPX Express search request, which will yield one or more solutions.
|
1124
|
+
class TripOptionsRequest
|
1125
|
+
include Google::Apis::Core::Hashable
|
1126
|
+
|
1127
|
+
# Do not return solutions that cost more than this price. The alphabetical part
|
1128
|
+
# of the price is in ISO 4217. The format, in regex, is [A-Z]`3`\d+(\.\d+)?
|
1129
|
+
# Example: $102.07
|
1130
|
+
# Corresponds to the JSON property `maxPrice`
|
1131
|
+
# @return [String]
|
1132
|
+
attr_accessor :max_price
|
1133
|
+
|
1134
|
+
# The number and type of passengers. Unfortunately the definition of an infant,
|
1135
|
+
# child, adult, and senior citizen varies across carriers and reservation
|
1136
|
+
# systems.
|
1137
|
+
# Corresponds to the JSON property `passengers`
|
1138
|
+
# @return [Google::Apis::QpxExpressV1::PassengerCounts]
|
1139
|
+
attr_accessor :passengers
|
1140
|
+
|
1141
|
+
# Return only solutions with refundable fares.
|
1142
|
+
# Corresponds to the JSON property `refundable`
|
1143
|
+
# @return [Boolean]
|
1144
|
+
attr_accessor :refundable
|
1145
|
+
alias_method :refundable?, :refundable
|
1146
|
+
|
1147
|
+
# IATA country code representing the point of sale. This determines the "
|
1148
|
+
# equivalent amount paid" currency for the ticket.
|
1149
|
+
# Corresponds to the JSON property `saleCountry`
|
1150
|
+
# @return [String]
|
1151
|
+
attr_accessor :sale_country
|
1152
|
+
|
1153
|
+
# The slices that make up the itinerary of this trip. A slice represents a
|
1154
|
+
# traveler's intent, the portion of a low-fare search corresponding to a
|
1155
|
+
# traveler's request to get between two points. One-way journeys are generally
|
1156
|
+
# expressed using one slice, round-trips using two. An example of a one slice
|
1157
|
+
# trip with three segments might be BOS-SYD, SYD-LAX, LAX-BOS if the traveler
|
1158
|
+
# only stopped in SYD and LAX just long enough to change planes.
|
1159
|
+
# Corresponds to the JSON property `slice`
|
1160
|
+
# @return [Array<Google::Apis::QpxExpressV1::SliceInput>]
|
1161
|
+
attr_accessor :slice
|
1162
|
+
|
1163
|
+
# The number of solutions to return, maximum 500.
|
1164
|
+
# Corresponds to the JSON property `solutions`
|
1165
|
+
# @return [Fixnum]
|
1166
|
+
attr_accessor :solutions
|
1167
|
+
|
1168
|
+
def initialize(**args)
|
1169
|
+
update!(**args)
|
1170
|
+
end
|
1171
|
+
|
1172
|
+
# Update properties of this object
|
1173
|
+
def update!(**args)
|
1174
|
+
@max_price = args[:max_price] unless args[:max_price].nil?
|
1175
|
+
@passengers = args[:passengers] unless args[:passengers].nil?
|
1176
|
+
@refundable = args[:refundable] unless args[:refundable].nil?
|
1177
|
+
@sale_country = args[:sale_country] unless args[:sale_country].nil?
|
1178
|
+
@slice = args[:slice] unless args[:slice].nil?
|
1179
|
+
@solutions = args[:solutions] unless args[:solutions].nil?
|
1180
|
+
end
|
1181
|
+
end
|
1182
|
+
|
1183
|
+
# A QPX Express search response.
|
1184
|
+
class TripOptionsResponse
|
1185
|
+
include Google::Apis::Core::Hashable
|
1186
|
+
|
1187
|
+
# Detailed information about components found in the solutions of this response,
|
1188
|
+
# including a trip's airport, city, taxes, airline, and aircraft.
|
1189
|
+
# Corresponds to the JSON property `data`
|
1190
|
+
# @return [Google::Apis::QpxExpressV1::Data]
|
1191
|
+
attr_accessor :data
|
1192
|
+
|
1193
|
+
# Identifies this as a QPX Express trip response object, which consists of zero
|
1194
|
+
# or more solutions. Value: the fixed string qpxexpress#tripOptions.
|
1195
|
+
# Corresponds to the JSON property `kind`
|
1196
|
+
# @return [String]
|
1197
|
+
attr_accessor :kind
|
1198
|
+
|
1199
|
+
# An identifier uniquely identifying this response.
|
1200
|
+
# Corresponds to the JSON property `requestId`
|
1201
|
+
# @return [String]
|
1202
|
+
attr_accessor :request_id
|
1203
|
+
|
1204
|
+
# A list of priced itinerary solutions to the QPX Express query.
|
1205
|
+
# Corresponds to the JSON property `tripOption`
|
1206
|
+
# @return [Array<Google::Apis::QpxExpressV1::TripOption>]
|
1207
|
+
attr_accessor :trip_option
|
1208
|
+
|
1209
|
+
def initialize(**args)
|
1210
|
+
update!(**args)
|
1211
|
+
end
|
1212
|
+
|
1213
|
+
# Update properties of this object
|
1214
|
+
def update!(**args)
|
1215
|
+
@data = args[:data] unless args[:data].nil?
|
1216
|
+
@kind = args[:kind] unless args[:kind].nil?
|
1217
|
+
@request_id = args[:request_id] unless args[:request_id].nil?
|
1218
|
+
@trip_option = args[:trip_option] unless args[:trip_option].nil?
|
1219
|
+
end
|
1220
|
+
end
|
1221
|
+
|
1222
|
+
# A QPX Express search request.
|
1223
|
+
class SearchTripsRequest
|
1224
|
+
include Google::Apis::Core::Hashable
|
1225
|
+
|
1226
|
+
# A QPX Express search request, which will yield one or more solutions.
|
1227
|
+
# Corresponds to the JSON property `request`
|
1228
|
+
# @return [Google::Apis::QpxExpressV1::TripOptionsRequest]
|
1229
|
+
attr_accessor :request
|
1230
|
+
|
1231
|
+
def initialize(**args)
|
1232
|
+
update!(**args)
|
1233
|
+
end
|
1234
|
+
|
1235
|
+
# Update properties of this object
|
1236
|
+
def update!(**args)
|
1237
|
+
@request = args[:request] unless args[:request].nil?
|
1238
|
+
end
|
1239
|
+
end
|
1240
|
+
|
1241
|
+
# A QPX Express search response.
|
1242
|
+
class SearchTripsResponse
|
1243
|
+
include Google::Apis::Core::Hashable
|
1244
|
+
|
1245
|
+
# Identifies this as a QPX Express API search response resource. Value: the
|
1246
|
+
# fixed string qpxExpress#tripsSearch.
|
1247
|
+
# Corresponds to the JSON property `kind`
|
1248
|
+
# @return [String]
|
1249
|
+
attr_accessor :kind
|
1250
|
+
|
1251
|
+
# A QPX Express search response.
|
1252
|
+
# Corresponds to the JSON property `trips`
|
1253
|
+
# @return [Google::Apis::QpxExpressV1::TripOptionsResponse]
|
1254
|
+
attr_accessor :trips
|
1255
|
+
|
1256
|
+
def initialize(**args)
|
1257
|
+
update!(**args)
|
1258
|
+
end
|
1259
|
+
|
1260
|
+
# Update properties of this object
|
1261
|
+
def update!(**args)
|
1262
|
+
@kind = args[:kind] unless args[:kind].nil?
|
1263
|
+
@trips = args[:trips] unless args[:trips].nil?
|
1264
|
+
end
|
1265
|
+
end
|
1266
|
+
end
|
1267
|
+
end
|
1268
|
+
end
|