From 1b79f1d15d691fc24604bf51e1b8f6822561368b Mon Sep 17 00:00:00 2001 From: yoshi-code-bot <70984784+yoshi-code-bot@users.noreply.github.com> Date: Tue, 12 Mar 2024 20:14:16 -0700 Subject: [PATCH] feat: Automated regeneration of WalletObjects client (#11043) Auto-created at 2024-03-13 03:10:49 +0000 using the toys pull request generator. --- clients/wallet_objects/.gitignore | 37 ++ clients/wallet_objects/LICENSE | 201 +++++++ clients/wallet_objects/README.md | 23 + clients/wallet_objects/config/config.exs | 20 + .../wallet_objects/v1/api/eventticketclass.ex | 429 +++++++++++++++ .../v1/api/eventticketobject.ex | 509 ++++++++++++++++++ .../wallet_objects/v1/api/flightclass.ex | 404 ++++++++++++++ .../wallet_objects/v1/api/flightobject.ex | 414 ++++++++++++++ .../wallet_objects/v1/api/genericclass.ex | 414 ++++++++++++++ .../wallet_objects/v1/api/genericobject.ex | 419 ++++++++++++++ .../wallet_objects/v1/api/giftcardclass.ex | 419 ++++++++++++++ .../wallet_objects/v1/api/giftcardobject.ex | 419 ++++++++++++++ .../wallet_objects/v1/api/issuer.ex | 327 +++++++++++ .../google_api/wallet_objects/v1/api/jwt.ex | 86 +++ .../wallet_objects/v1/api/loyaltyclass.ex | 414 ++++++++++++++ .../wallet_objects/v1/api/loyaltyobject.ex | 491 +++++++++++++++++ .../google_api/wallet_objects/v1/api/media.ex | 351 ++++++++++++ .../wallet_objects/v1/api/offerclass.ex | 404 ++++++++++++++ .../wallet_objects/v1/api/offerobject.ex | 404 ++++++++++++++ .../wallet_objects/v1/api/permissions.ex | 149 +++++ .../wallet_objects/v1/api/smarttap.ex | 86 +++ .../wallet_objects/v1/api/transitclass.ex | 414 ++++++++++++++ .../wallet_objects/v1/api/transitobject.ex | 419 ++++++++++++++ .../wallet_objects/v1/connection.ex | 32 ++ .../google_api/wallet_objects/v1/metadata.ex | 26 + .../v1/model/activation_options.ex | 49 ++ .../v1/model/activation_status.ex | 46 ++ .../v1/model/add_message_request.ex | 46 ++ .../wallet_objects/v1/model/airport_info.ex | 58 ++ .../wallet_objects/v1/model/app_link_data.ex | 53 ++ .../v1/model/app_link_data_app_link_info.ex | 56 ++ .../app_link_data_app_link_info_app_target.ex | 49 ++ .../v1/model/authentication_key.ex | 49 ++ .../wallet_objects/v1/model/barcode.ex | 61 +++ .../v1/model/barcode_section_detail.ex | 46 ++ .../v1/model/blobstore2_info.ex | 58 ++ .../v1/model/boarding_and_seating_info.ex | 70 +++ .../v1/model/boarding_and_seating_policy.ex | 52 ++ .../v1/model/callback_options.ex | 49 ++ .../v1/model/card_barcode_section_details.ex | 52 ++ .../v1/model/card_row_one_item.ex | 46 ++ .../v1/model/card_row_template_info.ex | 52 ++ .../v1/model/card_row_three_items.ex | 52 ++ .../v1/model/card_row_two_items.ex | 49 ++ .../v1/model/card_template_override.ex | 50 ++ .../v1/model/class_template_info.ex | 59 ++ .../v1/model/composite_media.ex | 76 +++ .../v1/model/content_type_info.ex | 58 ++ .../wallet_objects/v1/model/date_time.ex | 46 ++ .../v1/model/details_item_info.ex | 46 ++ .../v1/model/details_template_override.ex | 46 ++ .../wallet_objects/v1/model/device_context.ex | 46 ++ .../v1/model/diff_checksums_response.ex | 58 ++ .../v1/model/diff_download_response.ex | 46 ++ .../v1/model/diff_upload_request.ex | 52 ++ .../v1/model/diff_upload_response.ex | 49 ++ .../v1/model/diff_version_response.ex | 49 ++ .../v1/model/discoverable_program.ex | 60 +++ ...scoverable_program_merchant_signin_info.ex | 48 ++ ...scoverable_program_merchant_signup_info.ex | 51 ++ .../v1/model/download_parameters.ex | 49 ++ .../v1/model/event_date_time.ex | 61 +++ .../v1/model/event_reservation_info.ex | 49 ++ .../wallet_objects/v1/model/event_seat.ex | 58 ++ .../v1/model/event_ticket_class.ex | 173 ++++++ ...event_ticket_class_add_message_response.ex | 46 ++ .../model/event_ticket_class_list_response.ex | 49 ++ .../v1/model/event_ticket_object.ex | 136 +++++ ...vent_ticket_object_add_message_response.ex | 46 ++ .../event_ticket_object_list_response.ex | 49 ++ .../wallet_objects/v1/model/event_venue.ex | 52 ++ .../v1/model/expiry_notification.ex | 46 ++ .../v1/model/field_reference.ex | 49 ++ .../wallet_objects/v1/model/field_selector.ex | 46 ++ .../v1/model/first_row_option.ex | 49 ++ .../wallet_objects/v1/model/flight_carrier.ex | 64 +++ .../wallet_objects/v1/model/flight_class.ex | 158 ++++++ .../flight_class_add_message_response.ex | 46 ++ .../v1/model/flight_class_list_response.ex | 49 ++ .../wallet_objects/v1/model/flight_header.ex | 61 +++ .../wallet_objects/v1/model/flight_object.ex | 128 +++++ .../flight_object_add_message_response.ex | 46 ++ .../v1/model/flight_object_list_response.ex | 49 ++ .../v1/model/frequent_flyer_info.ex | 52 ++ .../wallet_objects/v1/model/generic_class.ex | 79 +++ .../generic_class_add_message_response.ex | 46 ++ .../v1/model/generic_class_list_response.ex | 49 ++ .../wallet_objects/v1/model/generic_object.ex | 112 ++++ .../generic_object_add_message_response.ex | 46 ++ .../v1/model/generic_object_list_response.ex | 49 ++ .../v1/model/gift_card_class.ex | 155 ++++++ .../gift_card_class_add_message_response.ex | 46 ++ .../v1/model/gift_card_class_list_response.ex | 49 ++ .../v1/model/gift_card_object.ex | 127 +++++ .../gift_card_object_add_message_response.ex | 46 ++ .../model/gift_card_object_list_response.ex | 49 ++ .../wallet_objects/v1/model/grouping_info.ex | 49 ++ .../wallet_objects/v1/model/image.ex | 52 ++ .../v1/model/image_module_data.ex | 49 ++ .../wallet_objects/v1/model/image_uri.ex | 52 ++ .../v1/model/info_module_data.ex | 49 ++ .../wallet_objects/v1/model/issuer.ex | 61 +++ .../v1/model/issuer_contact_info.ex | 55 ++ .../v1/model/issuer_list_response.ex | 46 ++ .../v1/model/issuer_to_user_info.ex | 55 ++ .../v1/model/jwt_insert_response.ex | 49 ++ .../wallet_objects/v1/model/jwt_resource.ex | 46 ++ .../wallet_objects/v1/model/label_value.ex | 55 ++ .../v1/model/label_value_row.ex | 46 ++ .../wallet_objects/v1/model/lat_long_point.ex | 52 ++ .../v1/model/links_module_data.ex | 46 ++ .../v1/model/list_template_override.ex | 52 ++ .../v1/model/localized_string.ex | 52 ++ .../wallet_objects/v1/model/loyalty_class.ex | 176 ++++++ .../loyalty_class_add_message_response.ex | 46 ++ .../v1/model/loyalty_class_list_response.ex | 49 ++ .../wallet_objects/v1/model/loyalty_object.ex | 127 +++++ .../loyalty_object_add_message_response.ex | 46 ++ .../v1/model/loyalty_object_list_response.ex | 49 ++ .../wallet_objects/v1/model/loyalty_points.ex | 52 ++ .../v1/model/loyalty_points_balance.ex | 55 ++ .../wallet_objects/v1/model/media.ex | 135 +++++ .../v1/model/media_request_info.ex | 70 +++ .../wallet_objects/v1/model/message.ex | 67 +++ .../v1/model/modify_linked_offer_objects.ex | 49 ++ .../modify_linked_offer_objects_request.ex | 47 ++ .../wallet_objects/v1/model/money.ex | 52 ++ .../wallet_objects/v1/model/notifications.ex | 49 ++ .../wallet_objects/v1/model/object_id.ex | 52 ++ .../wallet_objects/v1/model/offer_class.ex | 163 ++++++ .../model/offer_class_add_message_response.ex | 46 ++ .../v1/model/offer_class_list_response.ex | 49 ++ .../wallet_objects/v1/model/offer_object.ex | 112 ++++ .../offer_object_add_message_response.ex | 46 ++ .../v1/model/offer_object_list_response.ex | 49 ++ .../wallet_objects/v1/model/pagination.ex | 52 ++ .../v1/model/pass_constraints.ex | 49 ++ .../wallet_objects/v1/model/permission.ex | 49 ++ .../wallet_objects/v1/model/permissions.ex | 49 ++ .../v1/model/purchase_details.ex | 58 ++ .../v1/model/reservation_info.ex | 55 ++ .../wallet_objects/v1/model/resources.ex | 81 +++ .../wallet_objects/v1/model/review.ex | 46 ++ .../v1/model/rotating_barcode.ex | 65 +++ .../v1/model/rotating_barcode_totp_details.ex | 59 ++ ...ng_barcode_totp_details_totp_parameters.ex | 54 ++ .../v1/model/rotating_barcode_values.ex | 52 ++ .../v1/model/security_animation.ex | 46 ++ .../wallet_objects/v1/model/sign_up_info.ex | 46 ++ .../wallet_objects/v1/model/smart_tap.ex | 55 ++ .../v1/model/smart_tap_merchant_data.ex | 50 ++ .../wallet_objects/v1/model/template_item.ex | 52 ++ .../v1/model/text_module_data.ex | 58 ++ .../wallet_objects/v1/model/ticket_cost.ex | 52 ++ .../wallet_objects/v1/model/ticket_leg.ex | 85 +++ .../v1/model/ticket_restrictions.ex | 55 ++ .../wallet_objects/v1/model/ticket_seat.ex | 58 ++ .../wallet_objects/v1/model/time_interval.ex | 52 ++ .../wallet_objects/v1/model/transit_class.ex | 211 ++++++++ .../transit_class_add_message_response.ex | 46 ++ .../v1/model/transit_class_list_response.ex | 49 ++ .../wallet_objects/v1/model/transit_object.ex | 157 ++++++ .../transit_object_add_message_response.ex | 46 ++ .../v1/model/transit_object_list_response.ex | 49 ++ ..._upload_rotating_barcode_values_request.ex | 54 ++ ...upload_rotating_barcode_values_response.ex | 46 ++ .../v1/model/translated_string.ex | 52 ++ .../v1/model/upcoming_notification.ex | 46 ++ .../google_api/wallet_objects/v1/model/uri.ex | 58 ++ clients/wallet_objects/mix.exs | 66 +++ clients/wallet_objects/test/test_helper.exs | 35 ++ 171 files changed, 16253 insertions(+) create mode 100644 clients/wallet_objects/.gitignore create mode 100644 clients/wallet_objects/LICENSE create mode 100644 clients/wallet_objects/README.md create mode 100644 clients/wallet_objects/config/config.exs create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketclass.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketobject.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightclass.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightobject.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericclass.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericobject.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardclass.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardobject.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/issuer.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/jwt.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyclass.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyobject.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/media.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerclass.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerobject.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/permissions.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/smarttap.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitclass.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitobject.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/connection.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/metadata.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_options.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_status.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/add_message_request.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/airport_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info_app_target.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/authentication_key.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode_section_detail.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/blobstore2_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_policy.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/callback_options.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_barcode_section_details.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_one_item.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_template_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_three_items.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_two_items.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_template_override.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/class_template_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/composite_media.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/content_type_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/date_time.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_item_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_template_override.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/device_context.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_checksums_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_download_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_request.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_version_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signin_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signup_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/download_parameters.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_date_time.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_reservation_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_seat.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_venue.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/expiry_notification.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_reference.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_selector.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/first_row_option.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_carrier.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_header.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/frequent_flyer_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/grouping_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_module_data.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_uri.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/info_module_data.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_contact_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_to_user_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_insert_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_resource.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value_row.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/lat_long_point.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/links_module_data.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/list_template_override.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/localized_string.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points_balance.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media_request_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/message.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects_request.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/money.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/notifications.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/object_id.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pagination.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pass_constraints.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permission.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permissions.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/purchase_details.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/reservation_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/resources.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/review.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details_totp_parameters.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_values.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/security_animation.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/sign_up_info.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap_merchant_data.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/template_item.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/text_module_data.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_cost.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_leg.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_restrictions.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_seat.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/time_interval.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_add_message_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_list_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_request.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_response.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/translated_string.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/upcoming_notification.ex create mode 100644 clients/wallet_objects/lib/google_api/wallet_objects/v1/model/uri.ex create mode 100644 clients/wallet_objects/mix.exs create mode 100644 clients/wallet_objects/test/test_helper.exs diff --git a/clients/wallet_objects/.gitignore b/clients/wallet_objects/.gitignore new file mode 100644 index 0000000000..6bf4496152 --- /dev/null +++ b/clients/wallet_objects/.gitignore @@ -0,0 +1,37 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +# The directory Mix will write compiled artifacts to. +/_build + +# If you run "mix test --cover", coverage assets end up here. +/cover + +# The directory Mix downloads your dependencies sources to. +/deps + +# Where 3rd-party dependencies like ExDoc output generated docs. +/doc + +# Ignore .fetch files in case you like to edit your project deps locally. +/.fetch + +# If the VM crashes, it generates a dump, let's ignore it too. +erl_crash.dump + +# Also ignore archive artifacts (built via "mix archive.build"). +*.ez diff --git a/clients/wallet_objects/LICENSE b/clients/wallet_objects/LICENSE new file mode 100644 index 0000000000..261eeb9e9f --- /dev/null +++ b/clients/wallet_objects/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/clients/wallet_objects/README.md b/clients/wallet_objects/README.md new file mode 100644 index 0000000000..095a7e9eb3 --- /dev/null +++ b/clients/wallet_objects/README.md @@ -0,0 +1,23 @@ +# GoogleApi.WalletObjects + +Google Wallet API client library. + +API for issuers to save and manage Google Wallet Objects. + +## Installation + +Install this package from [Hex](https://hex.pm) by adding +`google_api_wallet_objects` to your list of dependencies in `mix.exs`: + +```elixir +def deps do + [{:google_api_wallet_objects, "~> 0.2"}] +end +``` + +## For more information + +Product documentation is available at [https://developers.google.com/pay/passes](https://developers.google.com/pay/passes). + +Library reference documentation is published on Hexdocs at +[https://hexdocs.pm/google_api_wallet_objects](https://hexdocs.pm/google_api_wallet_objects). diff --git a/clients/wallet_objects/config/config.exs b/clients/wallet_objects/config/config.exs new file mode 100644 index 0000000000..07afe5f311 --- /dev/null +++ b/clients/wallet_objects/config/config.exs @@ -0,0 +1,20 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +use Mix.Config + + diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketclass.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketclass.ex new file mode 100644 index 0000000000..f629b0c178 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketclass.ex @@ -0,0 +1,429 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Eventticketclass do + @moduledoc """ + API calls for all endpoints tagged `Eventticketclass`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the event ticket class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketClassAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketclass_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketClassAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketclass_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/eventTicketClass/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketClassAddMessageResponse{}] + ) + end + + @doc """ + Returns the event ticket class with the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketclass_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketclass_get( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/eventTicketClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}]) + end + + @doc """ + Inserts an event ticket class with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketclass_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketclass_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/eventTicketClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}]) + end + + @doc """ + Returns a list of all event ticket classes for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:issuerId` (*type:* `String.t`) - The ID of the issuer authorized to list classes. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` classes are available in a list. For example, if you have a list of 200 classes and you call list with `maxResults` set to 20, list will return the first 20 classes and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 classes. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketClassListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketclass_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketClassListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketclass_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :issuerId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/eventTicketClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketClassListResponse{}] + ) + end + + @doc """ + Updates the event ticket class referenced by the given class ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketclass_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketclass_patch( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/eventTicketClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}]) + end + + @doc """ + Updates the event ticket class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketclass_update( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketclass_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/eventTicketClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketClass{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketobject.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketobject.ex new file mode 100644 index 0000000000..7f6d5a4fc2 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/eventticketobject.ex @@ -0,0 +1,509 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Eventticketobject do + @moduledoc """ + API calls for all endpoints tagged `Eventticketobject`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the event ticket object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketObjectAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketobject_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketObjectAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketobject_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/eventTicketObject/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketObjectAddMessageResponse{}] + ) + end + + @doc """ + Returns the event ticket object with the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketobject_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketobject_get( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/eventTicketObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}]) + end + + @doc """ + Inserts an event ticket object with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketobject_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketobject_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/eventTicketObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}]) + end + + @doc """ + Returns a list of all event ticket objects for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:classId` (*type:* `String.t`) - The ID of the class whose objects will be listed. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` objects are available in a list. For example, if you have a list of 200 objects and you call list with `maxResults` set to 20, list will return the first 20 objects and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 objects. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketObjectListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketobject_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketObjectListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketobject_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :classId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/eventTicketObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketObjectListResponse{}] + ) + end + + @doc """ + Modifies linked offer objects for the event ticket object with the given ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjectsRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketobject_modifylinkedofferobjects( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketobject_modifylinkedofferobjects( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url( + "/walletobjects/v1/eventTicketObject/{resourceId}/modifyLinkedOfferObjects", + %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + } + ) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}]) + end + + @doc """ + Updates the event ticket object referenced by the given object ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketobject_patch( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketobject_patch( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/eventTicketObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}]) + end + + @doc """ + Updates the event ticket object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_eventticketobject_update( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.EventTicketObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_eventticketobject_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/eventTicketObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.EventTicketObject{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightclass.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightclass.ex new file mode 100644 index 0000000000..49cf4ef039 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightclass.ex @@ -0,0 +1,404 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Flightclass do + @moduledoc """ + API calls for all endpoints tagged `Flightclass`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the flight class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightClassAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightclass_addmessage(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightClassAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightclass_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/flightClass/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightClassAddMessageResponse{}] + ) + end + + @doc """ + Returns the flight class with the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightclass_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightclass_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/flightClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightClass{}]) + end + + @doc """ + Inserts an flight class with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightclass_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightclass_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/flightClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightClass{}]) + end + + @doc """ + Returns a list of all flight classes for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:issuerId` (*type:* `String.t`) - The ID of the issuer authorized to list classes. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` classes are available in a list. For example, if you have a list of 200 classes and you call list with `maxResults` set to 20, list will return the first 20 classes and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 classes. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightClassListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightclass_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightClassListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightclass_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :issuerId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/flightClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightClassListResponse{}] + ) + end + + @doc """ + Updates the flight class referenced by the given class ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightclass_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightclass_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/flightClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightClass{}]) + end + + @doc """ + Updates the flight class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightclass_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightclass_update(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/flightClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightClass{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightobject.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightobject.ex new file mode 100644 index 0000000000..69cd47cbc6 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/flightobject.ex @@ -0,0 +1,414 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Flightobject do + @moduledoc """ + API calls for all endpoints tagged `Flightobject`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the flight object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightObjectAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightobject_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightObjectAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightobject_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/flightObject/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightObjectAddMessageResponse{}] + ) + end + + @doc """ + Returns the flight object with the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightobject_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightobject_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/flightObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightObject{}]) + end + + @doc """ + Inserts an flight object with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightobject_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightobject_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/flightObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightObject{}]) + end + + @doc """ + Returns a list of all flight objects for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:classId` (*type:* `String.t`) - The ID of the class whose objects will be listed. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` objects are available in a list. For example, if you have a list of 200 objects and you call list with `maxResults` set to 20, list will return the first 20 objects and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 objects. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightObjectListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightobject_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightObjectListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightobject_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :classId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/flightObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightObjectListResponse{}] + ) + end + + @doc """ + Updates the flight object referenced by the given object ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightobject_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightobject_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/flightObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightObject{}]) + end + + @doc """ + Updates the flight object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.FlightObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_flightobject_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.FlightObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_flightobject_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/flightObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.FlightObject{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericclass.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericclass.ex new file mode 100644 index 0000000000..4a80a0d55c --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericclass.ex @@ -0,0 +1,414 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Genericclass do + @moduledoc """ + API calls for all endpoints tagged `Genericclass`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the generic class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericClassAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericclass_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericClassAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericclass_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/genericClass/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericClassAddMessageResponse{}] + ) + end + + @doc """ + Returns the generic class with the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericclass_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericclass_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/genericClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericClass{}]) + end + + @doc """ + Inserts a generic class with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericclass_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericclass_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/genericClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericClass{}]) + end + + @doc """ + Returns a list of all generic classes for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:issuerId` (*type:* `String.t`) - The ID of the issuer authorized to list classes. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` classes are available in a list. For example, if you have a list of 200 classes and you call list with `maxResults` set to 20, list will return the first 20 classes and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 classes. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericClassListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericclass_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericClassListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericclass_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :issuerId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/genericClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericClassListResponse{}] + ) + end + + @doc """ + Updates the generic class referenced by the given class ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericclass_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericclass_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/genericClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericClass{}]) + end + + @doc """ + Updates the Generic class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericclass_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericclass_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/genericClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericClass{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericobject.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericobject.ex new file mode 100644 index 0000000000..4f77a0987f --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/genericobject.ex @@ -0,0 +1,419 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Genericobject do + @moduledoc """ + API calls for all endpoints tagged `Genericobject`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the generic object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericObjectAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericobject_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericObjectAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericobject_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/genericObject/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericObjectAddMessageResponse{}] + ) + end + + @doc """ + Returns the generic object with the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericobject_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericobject_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/genericObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericObject{}]) + end + + @doc """ + Inserts a generic object with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericobject_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericobject_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/genericObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericObject{}]) + end + + @doc """ + Returns a list of all generic objects for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:classId` (*type:* `String.t`) - The ID of the class whose objects will be listed. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` objects are available in a list. For example, if you have a list of 200 objects and you call list with `maxResults` set to 20, list will return the first 20 objects and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 objects. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericObjectListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericobject_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericObjectListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericobject_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :classId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/genericObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericObjectListResponse{}] + ) + end + + @doc """ + Updates the generic object referenced by the given object ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericobject_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericobject_patch( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/genericObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericObject{}]) + end + + @doc """ + Updates the generic object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GenericObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_genericobject_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GenericObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_genericobject_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/genericObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GenericObject{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardclass.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardclass.ex new file mode 100644 index 0000000000..3cd72c24a2 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardclass.ex @@ -0,0 +1,419 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Giftcardclass do + @moduledoc """ + API calls for all endpoints tagged `Giftcardclass`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the gift card class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardClassAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardclass_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardClassAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardclass_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/giftCardClass/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardClassAddMessageResponse{}] + ) + end + + @doc """ + Returns the gift card class with the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardclass_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardclass_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/giftCardClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}]) + end + + @doc """ + Inserts an gift card class with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardclass_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardclass_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/giftCardClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}]) + end + + @doc """ + Returns a list of all gift card classes for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:issuerId` (*type:* `String.t`) - The ID of the issuer authorized to list classes. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` classes are available in a list. For example, if you have a list of 200 classes and you call list with `maxResults` set to 20, list will return the first 20 classes and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 classes. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardClassListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardclass_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardClassListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardclass_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :issuerId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/giftCardClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardClassListResponse{}] + ) + end + + @doc """ + Updates the gift card class referenced by the given class ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardclass_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardclass_patch( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/giftCardClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}]) + end + + @doc """ + Updates the gift card class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardclass_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardclass_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/giftCardClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardClass{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardobject.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardobject.ex new file mode 100644 index 0000000000..d74d7386da --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/giftcardobject.ex @@ -0,0 +1,419 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Giftcardobject do + @moduledoc """ + API calls for all endpoints tagged `Giftcardobject`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the gift card object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardObjectAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardobject_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardObjectAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardobject_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/giftCardObject/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardObjectAddMessageResponse{}] + ) + end + + @doc """ + Returns the gift card object with the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardobject_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardobject_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/giftCardObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}]) + end + + @doc """ + Inserts an gift card object with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardobject_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardobject_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/giftCardObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}]) + end + + @doc """ + Returns a list of all gift card objects for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:classId` (*type:* `String.t`) - The ID of the class whose objects will be listed. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` objects are available in a list. For example, if you have a list of 200 objects and you call list with `maxResults` set to 20, list will return the first 20 objects and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 objects. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardObjectListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardobject_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardObjectListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardobject_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :classId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/giftCardObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardObjectListResponse{}] + ) + end + + @doc """ + Updates the gift card object referenced by the given object ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardobject_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardobject_patch( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/giftCardObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}]) + end + + @doc """ + Updates the gift card object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_giftcardobject_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.GiftCardObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_giftcardobject_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/giftCardObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.GiftCardObject{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/issuer.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/issuer.ex new file mode 100644 index 0000000000..f345e89477 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/issuer.ex @@ -0,0 +1,327 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Issuer do + @moduledoc """ + API calls for all endpoints tagged `Issuer`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Returns the issuer with the given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an issuer. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.Issuer{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_issuer_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.Issuer.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_issuer_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/issuer/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.Issuer{}]) + end + + @doc """ + Inserts an issuer with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.Issuer.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.Issuer{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_issuer_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.Issuer.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_issuer_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/issuer", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.Issuer{}]) + end + + @doc """ + Returns a list of all issuers shared to the caller. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.IssuerListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_issuer_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.IssuerListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_issuer_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/issuer", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.IssuerListResponse{}]) + end + + @doc """ + Updates the issuer referenced by the given issuer ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an issuer. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.Issuer.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.Issuer{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_issuer_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.Issuer.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_issuer_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/issuer/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.Issuer{}]) + end + + @doc """ + Updates the issuer referenced by the given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an issuer. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.Issuer.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.Issuer{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_issuer_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.Issuer.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_issuer_update(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/issuer/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.Issuer{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/jwt.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/jwt.ex new file mode 100644 index 0000000000..0713ee6402 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/jwt.ex @@ -0,0 +1,86 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Jwt do + @moduledoc """ + API calls for all endpoints tagged `Jwt`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Inserts the resources in the JWT. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.JwtResource.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.JwtInsertResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_jwt_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.JwtInsertResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_jwt_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/jwt", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.JwtInsertResponse{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyclass.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyclass.ex new file mode 100644 index 0000000000..77a2de0a86 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyclass.ex @@ -0,0 +1,414 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Loyaltyclass do + @moduledoc """ + API calls for all endpoints tagged `Loyaltyclass`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the loyalty class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyClassAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyclass_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyClassAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyclass_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/loyaltyClass/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyClassAddMessageResponse{}] + ) + end + + @doc """ + Returns the loyalty class with the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyclass_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyclass_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/loyaltyClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}]) + end + + @doc """ + Inserts an loyalty class with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyclass_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyclass_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/loyaltyClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}]) + end + + @doc """ + Returns a list of all loyalty classes for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:issuerId` (*type:* `String.t`) - The ID of the issuer authorized to list classes. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` classes are available in a list. For example, if you have a list of 200 classes and you call list with `maxResults` set to 20, list will return the first 20 classes and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 classes. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyClassListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyclass_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyClassListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyclass_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :issuerId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/loyaltyClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyClassListResponse{}] + ) + end + + @doc """ + Updates the loyalty class referenced by the given class ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyclass_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyclass_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/loyaltyClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}]) + end + + @doc """ + Updates the loyalty class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyclass_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyclass_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/loyaltyClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyClass{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyobject.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyobject.ex new file mode 100644 index 0000000000..69ce6fa975 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/loyaltyobject.ex @@ -0,0 +1,491 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Loyaltyobject do + @moduledoc """ + API calls for all endpoints tagged `Loyaltyobject`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the loyalty object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyObjectAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyobject_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyObjectAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyobject_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/loyaltyObject/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyObjectAddMessageResponse{}] + ) + end + + @doc """ + Returns the loyalty object with the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyobject_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyobject_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/loyaltyObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}]) + end + + @doc """ + Inserts an loyalty object with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyobject_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyobject_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/loyaltyObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}]) + end + + @doc """ + Returns a list of all loyalty objects for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:classId` (*type:* `String.t`) - The ID of the class whose objects will be listed. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` objects are available in a list. For example, if you have a list of 200 objects and you call list with `maxResults` set to 20, list will return the first 20 objects and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 objects. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyObjectListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyobject_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyObjectListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyobject_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :classId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/loyaltyObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyObjectListResponse{}] + ) + end + + @doc """ + Modifies linked offer objects for the loyalty object with the given ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjectsRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyobject_modifylinkedofferobjects( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyobject_modifylinkedofferobjects( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/loyaltyObject/{resourceId}/modifyLinkedOfferObjects", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}]) + end + + @doc """ + Updates the loyalty object referenced by the given object ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyobject_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyobject_patch( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/loyaltyObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}]) + end + + @doc """ + Updates the loyalty object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_loyaltyobject_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_loyaltyobject_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/loyaltyObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.LoyaltyObject{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/media.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/media.ex new file mode 100644 index 0000000000..801d888031 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/media.ex @@ -0,0 +1,351 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Media do + @moduledoc """ + API calls for all endpoints tagged `Media`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Downloads rotating barcode values for the transit object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.Media{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_media_download(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.Media.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_media_download(connection, resource_id, optional_params \\ [], opts \\ []) do + opts = + if Keyword.get(optional_params, :alt) == "media", + do: Keyword.put_new(opts, :decode, false), + else: opts + + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url( + "/walletobjects/v1/transitObject/{resourceId}/downloadRotatingBarcodeValues", + %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + } + ) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.Media{}]) + end + + @doc """ + Uploads rotating barcode values for the transit object referenced by the given object ID. Note the max upload size is specified in google3/production/config/cdd/apps-upload/customers/payments-consumer-passes/config.gcl and enforced by Scotty. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_media_upload(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, + GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_media_upload(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url( + "/walletobjects/v1/transitObject/{resourceId}/uploadRotatingBarcodeValues", + %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + } + ) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ + [ + struct: + %GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse{} + ] + ) + end + + @doc """ + Uploads rotating barcode values for the transit object referenced by the given object ID. Note the max upload size is specified in google3/production/config/cdd/apps-upload/customers/payments-consumer-passes/config.gcl and enforced by Scotty. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `upload_type` (*type:* `String.t`) - Upload type. Must be "multipart". + * `metadata` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest.t`) - object metadata + * `data` (*type:* `iodata`) - Content to upload, as a string or iolist + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_media_upload_iodata( + Tesla.Env.client(), + String.t(), + String.t(), + GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest.t(), + iodata, + keyword(), + keyword() + ) :: + {:ok, + GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_media_upload_iodata( + connection, + resource_id, + upload_type, + metadata, + data, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url( + "/upload/walletobjects/v1/transitObject/{resourceId}/uploadRotatingBarcodeValues", + %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + } + ) + |> Request.add_param(:query, :uploadType, upload_type) + |> Request.add_param(:body, :metadata, metadata) + |> Request.add_param(:body, :data, data) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ + [ + struct: + %GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse{} + ] + ) + end + + @doc """ + Uploads rotating barcode values for the transit object referenced by the given object ID. Note the max upload size is specified in google3/production/config/cdd/apps-upload/customers/payments-consumer-passes/config.gcl and enforced by Scotty. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `upload_type` (*type:* `String.t`) - Upload type. Must be "multipart". + * `metadata` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest.t`) - object metadata + * `data` (*type:* `String.t`) - Path to file containing content to upload + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_media_upload_simple( + Tesla.Env.client(), + String.t(), + String.t(), + GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest.t(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, + GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_media_upload_simple( + connection, + resource_id, + upload_type, + metadata, + data, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url( + "/upload/walletobjects/v1/transitObject/{resourceId}/uploadRotatingBarcodeValues", + %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + } + ) + |> Request.add_param(:query, :uploadType, upload_type) + |> Request.add_param(:body, :metadata, metadata) + |> Request.add_param(:file, :data, data) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ + [ + struct: + %GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse{} + ] + ) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerclass.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerclass.ex new file mode 100644 index 0000000000..26a096b00f --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerclass.ex @@ -0,0 +1,404 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Offerclass do + @moduledoc """ + API calls for all endpoints tagged `Offerclass`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the offer class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferClassAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerclass_addmessage(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferClassAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerclass_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/offerClass/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferClassAddMessageResponse{}] + ) + end + + @doc """ + Returns the offer class with the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerclass_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerclass_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/offerClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferClass{}]) + end + + @doc """ + Inserts an offer class with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerclass_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerclass_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/offerClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferClass{}]) + end + + @doc """ + Returns a list of all offer classes for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:issuerId` (*type:* `String.t`) - The ID of the issuer authorized to list classes. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` classes are available in a list. For example, if you have a list of 200 classes and you call list with `maxResults` set to 20, list will return the first 20 classes and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 classes. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferClassListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerclass_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferClassListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerclass_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :issuerId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/offerClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferClassListResponse{}] + ) + end + + @doc """ + Updates the offer class referenced by the given class ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerclass_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerclass_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/offerClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferClass{}]) + end + + @doc """ + Updates the offer class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerclass_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerclass_update(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/offerClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferClass{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerobject.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerobject.ex new file mode 100644 index 0000000000..0ae090d785 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/offerobject.ex @@ -0,0 +1,404 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Offerobject do + @moduledoc """ + API calls for all endpoints tagged `Offerobject`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the offer object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferObjectAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerobject_addmessage(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferObjectAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerobject_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/offerObject/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferObjectAddMessageResponse{}] + ) + end + + @doc """ + Returns the offer object with the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerobject_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerobject_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/offerObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferObject{}]) + end + + @doc """ + Inserts an offer object with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerobject_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerobject_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/offerObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferObject{}]) + end + + @doc """ + Returns a list of all offer objects for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:classId` (*type:* `String.t`) - The ID of the class whose objects will be listed. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` objects are available in a list. For example, if you have a list of 200 objects and you call list with `maxResults` set to 20, list will return the first 20 objects and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 objects. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferObjectListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerobject_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferObjectListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerobject_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :classId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/offerObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferObjectListResponse{}] + ) + end + + @doc """ + Updates the offer object referenced by the given object ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerobject_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerobject_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/offerObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferObject{}]) + end + + @doc """ + Updates the offer object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.OfferObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_offerobject_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.OfferObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_offerobject_update(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/offerObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.OfferObject{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/permissions.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/permissions.ex new file mode 100644 index 0000000000..ddab05fc69 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/permissions.ex @@ -0,0 +1,149 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Permissions do + @moduledoc """ + API calls for all endpoints tagged `Permissions`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Returns the permissions for the given issuer id. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an issuer. This ID must be unique across all issuers. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.Permissions{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_permissions_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.Permissions.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_permissions_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/permissions/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.Permissions{}]) + end + + @doc """ + Updates the permissions for the given issuer. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an issuer. This ID must be unique across all issuers. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.Permissions.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.Permissions{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_permissions_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.Permissions.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_permissions_update(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/permissions/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.Permissions{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/smarttap.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/smarttap.ex new file mode 100644 index 0000000000..269f456cc1 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/smarttap.ex @@ -0,0 +1,86 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Smarttap do + @moduledoc """ + API calls for all endpoints tagged `Smarttap`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Inserts the smart tap. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.SmartTap.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.SmartTap{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_smarttap_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.SmartTap.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_smarttap_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/smartTap", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.SmartTap{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitclass.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitclass.ex new file mode 100644 index 0000000000..301d89d8a5 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitclass.ex @@ -0,0 +1,414 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Transitclass do + @moduledoc """ + API calls for all endpoints tagged `Transitclass`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the transit class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitClassAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitclass_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitClassAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitclass_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/transitClass/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitClassAddMessageResponse{}] + ) + end + + @doc """ + Returns the transit class with the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitclass_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitclass_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/transitClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitClass{}]) + end + + @doc """ + Inserts a transit class with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitclass_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitclass_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/transitClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitClass{}]) + end + + @doc """ + Returns a list of all transit classes for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:issuerId` (*type:* `String.t`) - The ID of the issuer authorized to list classes. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` classes are available in a list. For example, if you have a list of 200 classes and you call list with `maxResults` set to 20, list will return the first 20 classes and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 classes. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitClassListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitclass_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitClassListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitclass_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :issuerId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/transitClass", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitClassListResponse{}] + ) + end + + @doc """ + Updates the transit class referenced by the given class ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitclass_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitclass_patch(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/transitClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitClass{}]) + end + + @doc """ + Updates the transit class referenced by the given class ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitClass.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitClass{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitclass_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitClass.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitclass_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/transitClass/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitClass{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitobject.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitobject.ex new file mode 100644 index 0000000000..37f45da051 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/api/transitobject.ex @@ -0,0 +1,419 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Api.Transitobject do + @moduledoc """ + API calls for all endpoints tagged `Transitobject`. + """ + + alias GoogleApi.WalletObjects.V1.Connection + alias GoogleApi.Gax.{Request, Response} + + @library_version Mix.Project.config() |> Keyword.get(:version, "") + + @doc """ + Adds a message to the transit object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.AddMessageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObjectAddMessageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitobject_addmessage( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitObjectAddMessageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitobject_addmessage( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/transitObject/{resourceId}/addMessage", %{ + "resourceId" => URI.encode(resource_id, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitObjectAddMessageResponse{}] + ) + end + + @doc """ + Returns the transit object with the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitobject_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitobject_get(connection, resource_id, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/transitObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitObject{}]) + end + + @doc """ + Inserts an transit object with the given ID and properties. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitobject_insert(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitobject_insert(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/walletobjects/v1/transitObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitObject{}]) + end + + @doc """ + Returns a list of all transit objects for a given issuer ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:classId` (*type:* `String.t`) - The ID of the class whose objects will be listed. + * `:maxResults` (*type:* `integer()`) - Identifies the max number of results returned by a list. All results are returned if `maxResults` isn't defined. + * `:token` (*type:* `String.t`) - Used to get the next set of results if `maxResults` is specified, but more than `maxResults` objects are available in a list. For example, if you have a list of 200 objects and you call list with `maxResults` set to 20, list will return the first 20 objects and a token. Call list again with `maxResults` set to 20 and the token to get the next 20 objects. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObjectListResponse{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitobject_list(Tesla.Env.client(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitObjectListResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitobject_list(connection, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :classId => :query, + :maxResults => :query, + :token => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/walletobjects/v1/transitObject", %{}) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitObjectListResponse{}] + ) + end + + @doc """ + Updates the transit object referenced by the given object ID. This method supports patch semantics. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitobject_patch(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitobject_patch( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/walletobjects/v1/transitObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitObject{}]) + end + + @doc """ + Updates the transit object referenced by the given object ID. + + ## Parameters + + * `connection` (*type:* `GoogleApi.WalletObjects.V1.Connection.t`) - Connection to server + * `resource_id` (*type:* `String.t`) - The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitObject.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.WalletObjects.V1.Model.TransitObject{}}` on success + * `{:error, info}` on failure + """ + @spec walletobjects_transitobject_update(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.WalletObjects.V1.Model.TransitObject.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def walletobjects_transitobject_update( + connection, + resource_id, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:put) + |> Request.url("/walletobjects/v1/transitObject/{resourceId}", %{ + "resourceId" => URI.encode(resource_id, &(URI.char_unreserved?(&1) || &1 == ?/)) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.WalletObjects.V1.Model.TransitObject{}]) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/connection.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/connection.ex new file mode 100644 index 0000000000..0ff6048964 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/connection.ex @@ -0,0 +1,32 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Connection do + @moduledoc """ + Handle Tesla connections for GoogleApi.WalletObjects.V1. + """ + + @type t :: Tesla.Env.client() + + use GoogleApi.Gax.Connection, + scopes: [ + # Private Service: https://www.googleapis.com/auth/wallet_object.issuer + "https://www.googleapis.com/auth/wallet_object.issuer" + ], + otp_app: :google_api_wallet_objects, + base_url: "https://walletobjects.googleapis.com/" +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/metadata.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/metadata.ex new file mode 100644 index 0000000000..bf2494311d --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/metadata.ex @@ -0,0 +1,26 @@ +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1 do + @moduledoc """ + API client metadata for GoogleApi.WalletObjects.V1. + """ + + @discovery_revision "20240312" + + def discovery_revision(), do: @discovery_revision +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_options.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_options.ex new file mode 100644 index 0000000000..db648001ee --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_options.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ActivationOptions do + @moduledoc """ + ActivationOptions for the class + + ## Attributes + + * `activationUrl` (*type:* `String.t`, *default:* `nil`) - HTTPS URL that supports REST semantics. Would be used for requesting activation from partners for given valuable, triggered by the users. + * `allowReactivation` (*type:* `boolean()`, *default:* `nil`) - Flag to allow users to make activation call from different device. This allows client to render the activation button enabled even if the activationStatus is ACTIVATED but the requested device is different than the current device. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :activationUrl => String.t() | nil, + :allowReactivation => boolean() | nil + } + + field(:activationUrl) + field(:allowReactivation) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ActivationOptions do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ActivationOptions.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ActivationOptions do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_status.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_status.ex new file mode 100644 index 0000000000..d81bb89c75 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/activation_status.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ActivationStatus do + @moduledoc """ + The activation status of the object. This field includes activation status if valuable supports activation. + + ## Attributes + + * `state` (*type:* `String.t`, *default:* `nil`) - + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :state => String.t() | nil + } + + field(:state) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ActivationStatus do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ActivationStatus.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ActivationStatus do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/add_message_request.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/add_message_request.ex new file mode 100644 index 0000000000..32b91f59c4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/add_message_request.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.AddMessageRequest do + @moduledoc """ + Resource used when the AddMessage endpoints are called. + + ## Attributes + + * `message` (*type:* `GoogleApi.WalletObjects.V1.Model.Message.t`, *default:* `nil`) - + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :message => GoogleApi.WalletObjects.V1.Model.Message.t() | nil + } + + field(:message, as: GoogleApi.WalletObjects.V1.Model.Message) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.AddMessageRequest do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.AddMessageRequest.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.AddMessageRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/airport_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/airport_info.ex new file mode 100644 index 0000000000..b8a585b8db --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/airport_info.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.AirportInfo do + @moduledoc """ + + + ## Attributes + + * `airportIataCode` (*type:* `String.t`, *default:* `nil`) - Three character IATA airport code. This is a required field for `origin` and `destination`. Eg: "SFO" + * `airportNameOverride` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Optional field that overrides the airport city name defined by IATA. By default, Google takes the `airportIataCode` provided and maps it to the official airport city name defined by IATA. Official IATA airport city names can be found at IATA airport city names website. For example, for the airport IATA code "LTN", IATA website tells us that the corresponding airport city is "London". If this field is not populated, Google would display "London". However, populating this field with a custom name (eg: "London Luton") would override it. + * `gate` (*type:* `String.t`, *default:* `nil`) - A name of the gate. Eg: "B59" or "59" + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#airportInfo"`. + * `terminal` (*type:* `String.t`, *default:* `nil`) - Terminal name. Eg: "INTL" or "I" + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :airportIataCode => String.t() | nil, + :airportNameOverride => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :gate => String.t() | nil, + :kind => String.t() | nil, + :terminal => String.t() | nil + } + + field(:airportIataCode) + field(:airportNameOverride, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:gate) + field(:kind) + field(:terminal) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.AirportInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.AirportInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.AirportInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data.ex new file mode 100644 index 0000000000..09fe3aa056 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data.ex @@ -0,0 +1,53 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.AppLinkData do + @moduledoc """ + + + ## Attributes + + * `androidAppLinkInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo.t`, *default:* `nil`) - Optional information about the partner app link. If included, the app link link module will be rendered on the valuable details on the android client. + * `iosAppLinkInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo.t`, *default:* `nil`) - Optional information about the partner app link. If included, the app link link module will be rendered on the valuable details on the ios client. + * `webAppLinkInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo.t`, *default:* `nil`) - Optional information about the partner app link. If included, the app link link module will be rendered on the valuable details on the web client. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :androidAppLinkInfo => + GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo.t() | nil, + :iosAppLinkInfo => GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo.t() | nil, + :webAppLinkInfo => GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo.t() | nil + } + + field(:androidAppLinkInfo, as: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo) + field(:iosAppLinkInfo, as: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo) + field(:webAppLinkInfo, as: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.AppLinkData do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.AppLinkData.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.AppLinkData do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info.ex new file mode 100644 index 0000000000..ac366637b0 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo do + @moduledoc """ + + + ## Attributes + + * `appLogoImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional image to be displayed in the App Link Module + * `appTarget` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfoAppTarget.t`, *default:* `nil`) - Url to follow when opening the App Link Module on clients. It will be used by partners to open their webpage or deeplink into their app. + * `description` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - String to be displayed in the description of the App Link Module Required + * `title` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - String to be displayed in the title of the App Link Module Required + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :appLogoImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :appTarget => + GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfoAppTarget.t() | nil, + :description => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :title => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:appLogoImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:appTarget, as: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfoAppTarget) + field(:description, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:title, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info_app_target.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info_app_target.ex new file mode 100644 index 0000000000..1a38cee826 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/app_link_data_app_link_info_app_target.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfoAppTarget do + @moduledoc """ + + + ## Attributes + + * `packageName` (*type:* `String.t`, *default:* `nil`) - Package name for AppTarget. For example: com.google.android.gm + * `targetUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - URI for AppTarget. The description on the URI must be set. Prefer setting package field instead, if this target is defined for your application. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :packageName => String.t() | nil, + :targetUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil + } + + field(:packageName) + field(:targetUri, as: GoogleApi.WalletObjects.V1.Model.Uri) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfoAppTarget do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfoAppTarget.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.AppLinkDataAppLinkInfoAppTarget do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/authentication_key.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/authentication_key.ex new file mode 100644 index 0000000000..5f1df81a64 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/authentication_key.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.AuthenticationKey do + @moduledoc """ + + + ## Attributes + + * `id` (*type:* `integer()`, *default:* `nil`) - Available only to Smart Tap enabled partners. Contact support for additional guidance. + * `publicKeyPem` (*type:* `String.t`, *default:* `nil`) - Available only to Smart Tap enabled partners. Contact support for additional guidance. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :id => integer() | nil, + :publicKeyPem => String.t() | nil + } + + field(:id) + field(:publicKeyPem) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.AuthenticationKey do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.AuthenticationKey.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.AuthenticationKey do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode.ex new file mode 100644 index 0000000000..b17c316ca8 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Barcode do + @moduledoc """ + + + ## Attributes + + * `alternateText` (*type:* `String.t`, *default:* `nil`) - An optional text that will override the default text that shows under the barcode. This field is intended for a human readable equivalent of the barcode value, used when the barcode cannot be scanned. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#barcode"`. + * `renderEncoding` (*type:* `String.t`, *default:* `nil`) - The render encoding for the barcode. When specified, barcode is rendered in the given encoding. Otherwise best known encoding is chosen by Google. + * `showCodeText` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Optional text that will be shown when the barcode is hidden behind a click action. This happens in cases where a pass has Smart Tap enabled. If not specified, a default is chosen by Google. + * `type` (*type:* `String.t`, *default:* `nil`) - The type of barcode. + * `value` (*type:* `String.t`, *default:* `nil`) - The value encoded in the barcode. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :alternateText => String.t() | nil, + :kind => String.t() | nil, + :renderEncoding => String.t() | nil, + :showCodeText => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :type => String.t() | nil, + :value => String.t() | nil + } + + field(:alternateText) + field(:kind) + field(:renderEncoding) + field(:showCodeText, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:type) + field(:value) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Barcode do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Barcode.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Barcode do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode_section_detail.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode_section_detail.ex new file mode 100644 index 0000000000..74ebc8ce0c --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/barcode_section_detail.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail do + @moduledoc """ + + + ## Attributes + + * `fieldSelector` (*type:* `GoogleApi.WalletObjects.V1.Model.FieldSelector.t`, *default:* `nil`) - A reference to an existing text-based or image field to display. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :fieldSelector => GoogleApi.WalletObjects.V1.Model.FieldSelector.t() | nil + } + + field(:fieldSelector, as: GoogleApi.WalletObjects.V1.Model.FieldSelector) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/blobstore2_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/blobstore2_info.ex new file mode 100644 index 0000000000..deea7fde75 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/blobstore2_info.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Blobstore2Info do + @moduledoc """ + Information to read/write to blobstore2. + + ## Attributes + + * `blobGeneration` (*type:* `String.t`, *default:* `nil`) - The blob generation id. + * `blobId` (*type:* `String.t`, *default:* `nil`) - The blob id, e.g., /blobstore/prod/playground/scotty + * `downloadReadHandle` (*type:* `String.t`, *default:* `nil`) - Read handle passed from Bigstore -> Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads. + * `readToken` (*type:* `String.t`, *default:* `nil`) - The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call. + * `uploadMetadataContainer` (*type:* `String.t`, *default:* `nil`) - Metadata passed from Blobstore -> Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :blobGeneration => String.t() | nil, + :blobId => String.t() | nil, + :downloadReadHandle => String.t() | nil, + :readToken => String.t() | nil, + :uploadMetadataContainer => String.t() | nil + } + + field(:blobGeneration) + field(:blobId) + field(:downloadReadHandle) + field(:readToken) + field(:uploadMetadataContainer) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Blobstore2Info do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Blobstore2Info.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Blobstore2Info do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_info.ex new file mode 100644 index 0000000000..53d1785884 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_info.ex @@ -0,0 +1,70 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingInfo do + @moduledoc """ + + + ## Attributes + + * `boardingDoor` (*type:* `String.t`, *default:* `nil`) - Set this field only if this flight boards through more than one door or bridge and you want to explicitly print the door location on the boarding pass. Most airlines route their passengers to the right door or bridge by refering to doors/bridges by the `seatClass`. In those cases `boardingDoor` should not be set. + * `boardingGroup` (*type:* `String.t`, *default:* `nil`) - The value of boarding group (or zone) this passenger shall board with. eg: "B" The label for this value will be determined by the `boardingPolicy` field in the `flightClass` referenced by this object. + * `boardingPosition` (*type:* `String.t`, *default:* `nil`) - The value of boarding position. eg: "76" + * `boardingPrivilegeImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - A small image shown above the boarding barcode. Airlines can use it to communicate any special boarding privileges. In the event the security program logo is also set, this image might be rendered alongside the logo for that security program. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#boardingAndSeatingInfo"`. + * `seatAssignment` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The passenger's seat assignment. To be used when there is no specific identifier to use in `seatNumber`. eg: "assigned at gate" + * `seatClass` (*type:* `String.t`, *default:* `nil`) - The value of the seat class. eg: "Economy" or "Economy Plus" + * `seatNumber` (*type:* `String.t`, *default:* `nil`) - The value of passenger seat. If there is no specific identifier, use `seatAssignment` instead. eg: "25A" + * `sequenceNumber` (*type:* `String.t`, *default:* `nil`) - The sequence number on the boarding pass. This usually matches the sequence in which the passengers checked in. Airline might use the number for manual boarding and bag tags. eg: "49" + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :boardingDoor => String.t() | nil, + :boardingGroup => String.t() | nil, + :boardingPosition => String.t() | nil, + :boardingPrivilegeImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :kind => String.t() | nil, + :seatAssignment => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :seatClass => String.t() | nil, + :seatNumber => String.t() | nil, + :sequenceNumber => String.t() | nil + } + + field(:boardingDoor) + field(:boardingGroup) + field(:boardingPosition) + field(:boardingPrivilegeImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:kind) + field(:seatAssignment, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:seatClass) + field(:seatNumber) + field(:sequenceNumber) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_policy.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_policy.ex new file mode 100644 index 0000000000..07c41d54f6 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/boarding_and_seating_policy.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingPolicy do + @moduledoc """ + + + ## Attributes + + * `boardingPolicy` (*type:* `String.t`, *default:* `nil`) - Indicates the policy the airline uses for boarding. If unset, Google will default to `zoneBased`. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#boardingAndSeatingPolicy"`. + * `seatClassPolicy` (*type:* `String.t`, *default:* `nil`) - Seating policy which dictates how we display the seat class. If unset, Google will default to `cabinBased`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :boardingPolicy => String.t() | nil, + :kind => String.t() | nil, + :seatClassPolicy => String.t() | nil + } + + field(:boardingPolicy) + field(:kind) + field(:seatClassPolicy) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingPolicy do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingPolicy.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingPolicy do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/callback_options.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/callback_options.ex new file mode 100644 index 0000000000..9441083788 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/callback_options.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CallbackOptions do + @moduledoc """ + + + ## Attributes + + * `updateRequestUrl` (*type:* `String.t`, *default:* `nil`) - URL for the merchant endpoint that would be called to request updates. The URL should be hosted on HTTPS and robots.txt should allow the URL path to be accessible by UserAgent:Googlebot. Deprecated. + * `url` (*type:* `String.t`, *default:* `nil`) - The HTTPS url configured by the merchant. The URL should be hosted on HTTPS and robots.txt should allow the URL path to be accessible by UserAgent:Googlebot. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :updateRequestUrl => String.t() | nil, + :url => String.t() | nil + } + + field(:updateRequestUrl) + field(:url) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CallbackOptions do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CallbackOptions.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CallbackOptions do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_barcode_section_details.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_barcode_section_details.ex new file mode 100644 index 0000000000..c88b89db72 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_barcode_section_details.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CardBarcodeSectionDetails do + @moduledoc """ + + + ## Attributes + + * `firstBottomDetail` (*type:* `GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail.t`, *default:* `nil`) - Optional information to display below the barcode. + * `firstTopDetail` (*type:* `GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail.t`, *default:* `nil`) - Optional information to display above the barcode. If `secondTopDetail` is defined, this will be displayed to the start side of this detail section. + * `secondTopDetail` (*type:* `GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail.t`, *default:* `nil`) - Optional second piece of information to display above the barcode. If `firstTopDetail` is defined, this will be displayed to the end side of this detail section. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :firstBottomDetail => GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail.t() | nil, + :firstTopDetail => GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail.t() | nil, + :secondTopDetail => GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail.t() | nil + } + + field(:firstBottomDetail, as: GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail) + field(:firstTopDetail, as: GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail) + field(:secondTopDetail, as: GoogleApi.WalletObjects.V1.Model.BarcodeSectionDetail) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CardBarcodeSectionDetails do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CardBarcodeSectionDetails.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CardBarcodeSectionDetails do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_one_item.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_one_item.ex new file mode 100644 index 0000000000..80acdb8ae5 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_one_item.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CardRowOneItem do + @moduledoc """ + + + ## Attributes + + * `item` (*type:* `GoogleApi.WalletObjects.V1.Model.TemplateItem.t`, *default:* `nil`) - The item to be displayed in the row. This item will be automatically centered. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :item => GoogleApi.WalletObjects.V1.Model.TemplateItem.t() | nil + } + + field(:item, as: GoogleApi.WalletObjects.V1.Model.TemplateItem) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CardRowOneItem do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CardRowOneItem.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CardRowOneItem do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_template_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_template_info.ex new file mode 100644 index 0000000000..d2ba62a9b4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_template_info.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CardRowTemplateInfo do + @moduledoc """ + + + ## Attributes + + * `oneItem` (*type:* `GoogleApi.WalletObjects.V1.Model.CardRowOneItem.t`, *default:* `nil`) - Template for a row containing one item. Exactly one of "one_item", "two_items", "three_items" must be set. + * `threeItems` (*type:* `GoogleApi.WalletObjects.V1.Model.CardRowThreeItems.t`, *default:* `nil`) - Template for a row containing three items. Exactly one of "one_item", "two_items", "three_items" must be set. + * `twoItems` (*type:* `GoogleApi.WalletObjects.V1.Model.CardRowTwoItems.t`, *default:* `nil`) - Template for a row containing two items. Exactly one of "one_item", "two_items", "three_items" must be set. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :oneItem => GoogleApi.WalletObjects.V1.Model.CardRowOneItem.t() | nil, + :threeItems => GoogleApi.WalletObjects.V1.Model.CardRowThreeItems.t() | nil, + :twoItems => GoogleApi.WalletObjects.V1.Model.CardRowTwoItems.t() | nil + } + + field(:oneItem, as: GoogleApi.WalletObjects.V1.Model.CardRowOneItem) + field(:threeItems, as: GoogleApi.WalletObjects.V1.Model.CardRowThreeItems) + field(:twoItems, as: GoogleApi.WalletObjects.V1.Model.CardRowTwoItems) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CardRowTemplateInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CardRowTemplateInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CardRowTemplateInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_three_items.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_three_items.ex new file mode 100644 index 0000000000..c20ef85652 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_three_items.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CardRowThreeItems do + @moduledoc """ + + + ## Attributes + + * `endItem` (*type:* `GoogleApi.WalletObjects.V1.Model.TemplateItem.t`, *default:* `nil`) - The item to be displayed at the end of the row. This item will be aligned to the right. + * `middleItem` (*type:* `GoogleApi.WalletObjects.V1.Model.TemplateItem.t`, *default:* `nil`) - The item to be displayed in the middle of the row. This item will be centered between the start and end items. + * `startItem` (*type:* `GoogleApi.WalletObjects.V1.Model.TemplateItem.t`, *default:* `nil`) - The item to be displayed at the start of the row. This item will be aligned to the left. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :endItem => GoogleApi.WalletObjects.V1.Model.TemplateItem.t() | nil, + :middleItem => GoogleApi.WalletObjects.V1.Model.TemplateItem.t() | nil, + :startItem => GoogleApi.WalletObjects.V1.Model.TemplateItem.t() | nil + } + + field(:endItem, as: GoogleApi.WalletObjects.V1.Model.TemplateItem) + field(:middleItem, as: GoogleApi.WalletObjects.V1.Model.TemplateItem) + field(:startItem, as: GoogleApi.WalletObjects.V1.Model.TemplateItem) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CardRowThreeItems do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CardRowThreeItems.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CardRowThreeItems do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_two_items.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_two_items.ex new file mode 100644 index 0000000000..c7b23e85f8 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_row_two_items.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CardRowTwoItems do + @moduledoc """ + + + ## Attributes + + * `endItem` (*type:* `GoogleApi.WalletObjects.V1.Model.TemplateItem.t`, *default:* `nil`) - The item to be displayed at the end of the row. This item will be aligned to the right. + * `startItem` (*type:* `GoogleApi.WalletObjects.V1.Model.TemplateItem.t`, *default:* `nil`) - The item to be displayed at the start of the row. This item will be aligned to the left. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :endItem => GoogleApi.WalletObjects.V1.Model.TemplateItem.t() | nil, + :startItem => GoogleApi.WalletObjects.V1.Model.TemplateItem.t() | nil + } + + field(:endItem, as: GoogleApi.WalletObjects.V1.Model.TemplateItem) + field(:startItem, as: GoogleApi.WalletObjects.V1.Model.TemplateItem) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CardRowTwoItems do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CardRowTwoItems.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CardRowTwoItems do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_template_override.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_template_override.ex new file mode 100644 index 0000000000..dab2a0f6f4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/card_template_override.ex @@ -0,0 +1,50 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CardTemplateOverride do + @moduledoc """ + + + ## Attributes + + * `cardRowTemplateInfos` (*type:* `list(GoogleApi.WalletObjects.V1.Model.CardRowTemplateInfo.t)`, *default:* `nil`) - Template information for rows in the card view. At most three rows are allowed to be specified. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :cardRowTemplateInfos => + list(GoogleApi.WalletObjects.V1.Model.CardRowTemplateInfo.t()) | nil + } + + field(:cardRowTemplateInfos, + as: GoogleApi.WalletObjects.V1.Model.CardRowTemplateInfo, + type: :list + ) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CardTemplateOverride do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CardTemplateOverride.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CardTemplateOverride do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/class_template_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/class_template_info.ex new file mode 100644 index 0000000000..89c2a4b93a --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/class_template_info.ex @@ -0,0 +1,59 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo do + @moduledoc """ + + + ## Attributes + + * `cardBarcodeSectionDetails` (*type:* `GoogleApi.WalletObjects.V1.Model.CardBarcodeSectionDetails.t`, *default:* `nil`) - Specifies extra information to be displayed above and below the barcode. + * `cardTemplateOverride` (*type:* `GoogleApi.WalletObjects.V1.Model.CardTemplateOverride.t`, *default:* `nil`) - Override for the card view. + * `detailsTemplateOverride` (*type:* `GoogleApi.WalletObjects.V1.Model.DetailsTemplateOverride.t`, *default:* `nil`) - Override for the details view (beneath the card view). + * `listTemplateOverride` (*type:* `GoogleApi.WalletObjects.V1.Model.ListTemplateOverride.t`, *default:* `nil`) - Override for the passes list view. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :cardBarcodeSectionDetails => + GoogleApi.WalletObjects.V1.Model.CardBarcodeSectionDetails.t() | nil, + :cardTemplateOverride => + GoogleApi.WalletObjects.V1.Model.CardTemplateOverride.t() | nil, + :detailsTemplateOverride => + GoogleApi.WalletObjects.V1.Model.DetailsTemplateOverride.t() | nil, + :listTemplateOverride => GoogleApi.WalletObjects.V1.Model.ListTemplateOverride.t() | nil + } + + field(:cardBarcodeSectionDetails, as: GoogleApi.WalletObjects.V1.Model.CardBarcodeSectionDetails) + + field(:cardTemplateOverride, as: GoogleApi.WalletObjects.V1.Model.CardTemplateOverride) + field(:detailsTemplateOverride, as: GoogleApi.WalletObjects.V1.Model.DetailsTemplateOverride) + field(:listTemplateOverride, as: GoogleApi.WalletObjects.V1.Model.ListTemplateOverride) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/composite_media.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/composite_media.ex new file mode 100644 index 0000000000..b2f1034bd9 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/composite_media.ex @@ -0,0 +1,76 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.CompositeMedia do + @moduledoc """ + A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites. + + ## Attributes + + * `blobRef` (*type:* `String.t`, *default:* `nil`) - Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef. + * `blobstore2Info` (*type:* `GoogleApi.WalletObjects.V1.Model.Blobstore2Info.t`, *default:* `nil`) - Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob. + * `cosmoBinaryReference` (*type:* `String.t`, *default:* `nil`) - A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field. + * `crc32cHash` (*type:* `integer()`, *default:* `nil`) - crc32.c hash for the payload. + * `inline` (*type:* `String.t`, *default:* `nil`) - Media data, set if reference_type is INLINE + * `length` (*type:* `String.t`, *default:* `nil`) - Size of the data, in bytes + * `md5Hash` (*type:* `String.t`, *default:* `nil`) - MD5 hash for the payload. + * `objectId` (*type:* `GoogleApi.WalletObjects.V1.Model.ObjectId.t`, *default:* `nil`) - Reference to a TI Blob, set if reference_type is BIGSTORE_REF. + * `path` (*type:* `String.t`, *default:* `nil`) - Path to the data, set if reference_type is PATH + * `referenceType` (*type:* `String.t`, *default:* `nil`) - Describes what the field reference contains. + * `sha1Hash` (*type:* `String.t`, *default:* `nil`) - SHA-1 hash for the payload. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :blobRef => String.t() | nil, + :blobstore2Info => GoogleApi.WalletObjects.V1.Model.Blobstore2Info.t() | nil, + :cosmoBinaryReference => String.t() | nil, + :crc32cHash => integer() | nil, + :inline => String.t() | nil, + :length => String.t() | nil, + :md5Hash => String.t() | nil, + :objectId => GoogleApi.WalletObjects.V1.Model.ObjectId.t() | nil, + :path => String.t() | nil, + :referenceType => String.t() | nil, + :sha1Hash => String.t() | nil + } + + field(:blobRef) + field(:blobstore2Info, as: GoogleApi.WalletObjects.V1.Model.Blobstore2Info) + field(:cosmoBinaryReference) + field(:crc32cHash) + field(:inline) + field(:length) + field(:md5Hash) + field(:objectId, as: GoogleApi.WalletObjects.V1.Model.ObjectId) + field(:path) + field(:referenceType) + field(:sha1Hash) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.CompositeMedia do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.CompositeMedia.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.CompositeMedia do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/content_type_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/content_type_info.ex new file mode 100644 index 0000000000..bf24ea78f6 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/content_type_info.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ContentTypeInfo do + @moduledoc """ + Detailed Content-Type information from Scotty. The Content-Type of the media will typically be filled in by the header or Scotty's best_guess, but this extended information provides the backend with more information so that it can make a better decision if needed. This is only used on media upload requests from Scotty. + + ## Attributes + + * `bestGuess` (*type:* `String.t`, *default:* `nil`) - Scotty's best guess of what the content type of the file is. + * `fromBytes` (*type:* `String.t`, *default:* `nil`) - The content type of the file derived by looking at specific bytes (i.e. "magic bytes") of the actual file. + * `fromFileName` (*type:* `String.t`, *default:* `nil`) - The content type of the file derived from the file extension of the original file name used by the client. + * `fromHeader` (*type:* `String.t`, *default:* `nil`) - The content type of the file as specified in the request headers, multipart headers, or RUPIO start request. + * `fromUrlPath` (*type:* `String.t`, *default:* `nil`) - The content type of the file derived from the file extension of the URL path. The URL path is assumed to represent a file name (which is typically only true for agents that are providing a REST API). + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :bestGuess => String.t() | nil, + :fromBytes => String.t() | nil, + :fromFileName => String.t() | nil, + :fromHeader => String.t() | nil, + :fromUrlPath => String.t() | nil + } + + field(:bestGuess) + field(:fromBytes) + field(:fromFileName) + field(:fromHeader) + field(:fromUrlPath) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ContentTypeInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ContentTypeInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ContentTypeInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/date_time.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/date_time.ex new file mode 100644 index 0000000000..6f8150a3bb --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/date_time.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DateTime do + @moduledoc """ + + + ## Attributes + + * `date` (*type:* `String.t`, *default:* `nil`) - An ISO 8601 extended format date/time. Offset may or may not be required (refer to the parent field's documentation). Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the date/time is intended for a physical location in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. Providing an offset makes this an absolute instant in time around the world. The date/time will be adjusted based on the user's time zone. For example, a time of `2018-06-19T18:30:00-04:00` will be 18:30:00 for a user in New York and 15:30:00 for a user in Los Angeles. Omitting the offset makes this a local date/time, representing several instants in time around the world. The date/time will always be in the user's current time zone. For example, a time of `2018-06-19T18:30:00` will be 18:30:00 for a user in New York and also 18:30:00 for a user in Los Angeles. This is useful when the same local date/time should apply to many physical locations across several time zones. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :date => String.t() | nil + } + + field(:date) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DateTime do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DateTime.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DateTime do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_item_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_item_info.ex new file mode 100644 index 0000000000..105225267b --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_item_info.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DetailsItemInfo do + @moduledoc """ + + + ## Attributes + + * `item` (*type:* `GoogleApi.WalletObjects.V1.Model.TemplateItem.t`, *default:* `nil`) - The item to be displayed in the details list. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :item => GoogleApi.WalletObjects.V1.Model.TemplateItem.t() | nil + } + + field(:item, as: GoogleApi.WalletObjects.V1.Model.TemplateItem) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DetailsItemInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DetailsItemInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DetailsItemInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_template_override.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_template_override.ex new file mode 100644 index 0000000000..173de0326c --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/details_template_override.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DetailsTemplateOverride do + @moduledoc """ + + + ## Attributes + + * `detailsItemInfos` (*type:* `list(GoogleApi.WalletObjects.V1.Model.DetailsItemInfo.t)`, *default:* `nil`) - Information for the "nth" item displayed in the details list. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :detailsItemInfos => list(GoogleApi.WalletObjects.V1.Model.DetailsItemInfo.t()) | nil + } + + field(:detailsItemInfos, as: GoogleApi.WalletObjects.V1.Model.DetailsItemInfo, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DetailsTemplateOverride do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DetailsTemplateOverride.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DetailsTemplateOverride do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/device_context.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/device_context.ex new file mode 100644 index 0000000000..41cd7efb19 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/device_context.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DeviceContext do + @moduledoc """ + Device context associated with the object. + + ## Attributes + + * `deviceToken` (*type:* `String.t`, *default:* `nil`) - If set, redemption information will only be returned to the given device upon activation of the object. This should not be used as a stable identifier to trace a user's device. It can change across different passes for the same device or even across different activations for the same device. When setting this, callers must also set has_linked_device on the object being activated. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :deviceToken => String.t() | nil + } + + field(:deviceToken) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DeviceContext do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DeviceContext.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DeviceContext do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_checksums_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_checksums_response.ex new file mode 100644 index 0000000000..ec33f55692 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_checksums_response.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiffChecksumsResponse do + @moduledoc """ + Backend response for a Diff get checksums response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. + + ## Attributes + + * `checksumsLocation` (*type:* `GoogleApi.WalletObjects.V1.Model.CompositeMedia.t`, *default:* `nil`) - Exactly one of these fields must be populated. If checksums_location is filled, the server will return the corresponding contents to the user. If object_location is filled, the server will calculate the checksums based on the content there and return that to the user. For details on the format of the checksums, see http://go/scotty-diff-protocol. + * `chunkSizeBytes` (*type:* `String.t`, *default:* `nil`) - The chunk size of checksums. Must be a multiple of 256KB. + * `objectLocation` (*type:* `GoogleApi.WalletObjects.V1.Model.CompositeMedia.t`, *default:* `nil`) - If set, calculate the checksums based on the contents and return them to the caller. + * `objectSizeBytes` (*type:* `String.t`, *default:* `nil`) - The total size of the server object. + * `objectVersion` (*type:* `String.t`, *default:* `nil`) - The object version of the object the checksums are being returned for. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :checksumsLocation => GoogleApi.WalletObjects.V1.Model.CompositeMedia.t() | nil, + :chunkSizeBytes => String.t() | nil, + :objectLocation => GoogleApi.WalletObjects.V1.Model.CompositeMedia.t() | nil, + :objectSizeBytes => String.t() | nil, + :objectVersion => String.t() | nil + } + + field(:checksumsLocation, as: GoogleApi.WalletObjects.V1.Model.CompositeMedia) + field(:chunkSizeBytes) + field(:objectLocation, as: GoogleApi.WalletObjects.V1.Model.CompositeMedia) + field(:objectSizeBytes) + field(:objectVersion) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DiffChecksumsResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiffChecksumsResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DiffChecksumsResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_download_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_download_response.ex new file mode 100644 index 0000000000..ec9507e196 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_download_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiffDownloadResponse do + @moduledoc """ + Backend response for a Diff download response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. + + ## Attributes + + * `objectLocation` (*type:* `GoogleApi.WalletObjects.V1.Model.CompositeMedia.t`, *default:* `nil`) - The original object location. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :objectLocation => GoogleApi.WalletObjects.V1.Model.CompositeMedia.t() | nil + } + + field(:objectLocation, as: GoogleApi.WalletObjects.V1.Model.CompositeMedia) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DiffDownloadResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiffDownloadResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DiffDownloadResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_request.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_request.ex new file mode 100644 index 0000000000..216aa82d45 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_request.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiffUploadRequest do + @moduledoc """ + A Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. + + ## Attributes + + * `checksumsInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.CompositeMedia.t`, *default:* `nil`) - The location of the checksums for the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received. For details on the format of the checksums, see http://go/scotty-diff-protocol. + * `objectInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.CompositeMedia.t`, *default:* `nil`) - The location of the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received. + * `objectVersion` (*type:* `String.t`, *default:* `nil`) - The object version of the object that is the base version the incoming diff script will be applied to. This field will always be filled in. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :checksumsInfo => GoogleApi.WalletObjects.V1.Model.CompositeMedia.t() | nil, + :objectInfo => GoogleApi.WalletObjects.V1.Model.CompositeMedia.t() | nil, + :objectVersion => String.t() | nil + } + + field(:checksumsInfo, as: GoogleApi.WalletObjects.V1.Model.CompositeMedia) + field(:objectInfo, as: GoogleApi.WalletObjects.V1.Model.CompositeMedia) + field(:objectVersion) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DiffUploadRequest do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiffUploadRequest.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DiffUploadRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_response.ex new file mode 100644 index 0000000000..8918a45c52 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_upload_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiffUploadResponse do + @moduledoc """ + Backend response for a Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. + + ## Attributes + + * `objectVersion` (*type:* `String.t`, *default:* `nil`) - The object version of the object at the server. Must be included in the end notification response. The version in the end notification response must correspond to the new version of the object that is now stored at the server, after the upload. + * `originalObject` (*type:* `GoogleApi.WalletObjects.V1.Model.CompositeMedia.t`, *default:* `nil`) - The location of the original file for a diff upload request. Must be filled in if responding to an upload start notification. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :objectVersion => String.t() | nil, + :originalObject => GoogleApi.WalletObjects.V1.Model.CompositeMedia.t() | nil + } + + field(:objectVersion) + field(:originalObject, as: GoogleApi.WalletObjects.V1.Model.CompositeMedia) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DiffUploadResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiffUploadResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DiffUploadResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_version_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_version_response.ex new file mode 100644 index 0000000000..1a561c13de --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/diff_version_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiffVersionResponse do + @moduledoc """ + Backend response for a Diff get version response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. + + ## Attributes + + * `objectSizeBytes` (*type:* `String.t`, *default:* `nil`) - The total size of the server object. + * `objectVersion` (*type:* `String.t`, *default:* `nil`) - The version of the object stored at the server. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :objectSizeBytes => String.t() | nil, + :objectVersion => String.t() | nil + } + + field(:objectSizeBytes) + field(:objectVersion) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DiffVersionResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiffVersionResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DiffVersionResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program.ex new file mode 100644 index 0000000000..f6490af2a4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program.ex @@ -0,0 +1,60 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiscoverableProgram do + @moduledoc """ + Information about how a class may be discovered and instantiated from within the Android Pay app. This is done by searching for a loyalty or gift card program and scanning or manually entering. + + ## Attributes + + * `merchantSigninInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSigninInfo.t`, *default:* `nil`) - Information about the ability to signin and add a valuable for this program through a merchant site. Used when MERCHANT_HOSTED_SIGNIN is enabled. + * `merchantSignupInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSignupInfo.t`, *default:* `nil`) - Information about the ability to signup and add a valuable for this program through a merchant site. Used when MERCHANT_HOSTED_SIGNUP is enabled. + * `state` (*type:* `String.t`, *default:* `nil`) - Visibility state of the discoverable program. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :merchantSigninInfo => + GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSigninInfo.t() | nil, + :merchantSignupInfo => + GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSignupInfo.t() | nil, + :state => String.t() | nil + } + + field(:merchantSigninInfo, + as: GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSigninInfo + ) + + field(:merchantSignupInfo, + as: GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSignupInfo + ) + + field(:state) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DiscoverableProgram do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiscoverableProgram.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DiscoverableProgram do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signin_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signin_info.ex new file mode 100644 index 0000000000..a7fedb00fb --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signin_info.ex @@ -0,0 +1,48 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSigninInfo do + @moduledoc """ + Information about the merchant hosted signin flow for a program. + + ## Attributes + + * `signinWebsite` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URL to direct the user to for the merchant's signin site. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :signinWebsite => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil + } + + field(:signinWebsite, as: GoogleApi.WalletObjects.V1.Model.Uri) +end + +defimpl Poison.Decoder, + for: GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSigninInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSigninInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSigninInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signup_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signup_info.ex new file mode 100644 index 0000000000..f7044c2673 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/discoverable_program_merchant_signup_info.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSignupInfo do + @moduledoc """ + Information about the merchant hosted signup flow for a program. + + ## Attributes + + * `signupSharedDatas` (*type:* `list(String.t)`, *default:* `nil`) - User data that is sent in a POST request to the signup website URL. This information is encoded and then shared so that the merchant's website can prefill fields used to enroll the user for the discoverable program. + * `signupWebsite` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URL to direct the user to for the merchant's signup site. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :signupSharedDatas => list(String.t()) | nil, + :signupWebsite => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil + } + + field(:signupSharedDatas, type: :list) + field(:signupWebsite, as: GoogleApi.WalletObjects.V1.Model.Uri) +end + +defimpl Poison.Decoder, + for: GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSignupInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSignupInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.WalletObjects.V1.Model.DiscoverableProgramMerchantSignupInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/download_parameters.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/download_parameters.ex new file mode 100644 index 0000000000..3ae47f7923 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/download_parameters.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.DownloadParameters do + @moduledoc """ + Parameters specific to media downloads. + + ## Attributes + + * `allowGzipCompression` (*type:* `boolean()`, *default:* `nil`) - A boolean to be returned in the response to Scotty. Allows/disallows gzip encoding of the payload content when the server thinks it's advantageous (hence, does not guarantee compression) which allows Scotty to GZip the response to the client. + * `ignoreRange` (*type:* `boolean()`, *default:* `nil`) - Determining whether or not Apiary should skip the inclusion of any Content-Range header on its response to Scotty. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :allowGzipCompression => boolean() | nil, + :ignoreRange => boolean() | nil + } + + field(:allowGzipCompression) + field(:ignoreRange) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.DownloadParameters do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.DownloadParameters.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.DownloadParameters do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_date_time.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_date_time.ex new file mode 100644 index 0000000000..19d01479f4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_date_time.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventDateTime do + @moduledoc """ + + + ## Attributes + + * `customDoorsOpenLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the doors open value (`doorsOpen`) on the card detail view. This should only be used if the default "Doors Open" label or one of the `doorsOpenLabel` options is not sufficient. Both `doorsOpenLabel` and `customDoorsOpenLabel` may not be set. If neither is set, the label will default to "Doors Open", localized. If the doors open field is unset, this label will not be used. + * `doorsOpen` (*type:* `String.t`, *default:* `nil`) - The date/time when the doors open at the venue. This is an ISO 8601 extended format date/time, with or without an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the event were in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. The portion of the date/time without the offset is considered the "local date/time". This should be the local date/time at the venue. For example, if the event occurs at the 20th hour of June 5th, 2018 at the venue, the local date/time portion should be `2018-06-05T20:00:00`. If the local date/time at the venue is 4 hours before UTC, an offset of `-04:00` may be appended. Without offset information, some rich features may not be available. + * `doorsOpenLabel` (*type:* `String.t`, *default:* `nil`) - The label to use for the doors open value (`doorsOpen`) on the card detail view. Each available option maps to a set of localized strings, so that translations are shown to the user based on their locale. Both `doorsOpenLabel` and `customDoorsOpenLabel` may not be set. If neither is set, the label will default to "Doors Open", localized. If the doors open field is unset, this label will not be used. + * `end` (*type:* `String.t`, *default:* `nil`) - The date/time when the event ends. If the event spans multiple days, it should be the end date/time on the last day. This is an ISO 8601 extended format date/time, with or without an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the event were in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. The portion of the date/time without the offset is considered the "local date/time". This should be the local date/time at the venue. For example, if the event occurs at the 20th hour of June 5th, 2018 at the venue, the local date/time portion should be `2018-06-05T20:00:00`. If the local date/time at the venue is 4 hours before UTC, an offset of `-04:00` may be appended. Without offset information, some rich features may not be available. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#eventDateTime"`. + * `start` (*type:* `String.t`, *default:* `nil`) - The date/time when the event starts. If the event spans multiple days, it should be the start date/time on the first day. This is an ISO 8601 extended format date/time, with or without an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the event were in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. The portion of the date/time without the offset is considered the "local date/time". This should be the local date/time at the venue. For example, if the event occurs at the 20th hour of June 5th, 2018 at the venue, the local date/time portion should be `2018-06-05T20:00:00`. If the local date/time at the venue is 4 hours before UTC, an offset of `-04:00` may be appended. Without offset information, some rich features may not be available. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :customDoorsOpenLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :doorsOpen => String.t() | nil, + :doorsOpenLabel => String.t() | nil, + :end => String.t() | nil, + :kind => String.t() | nil, + :start => String.t() | nil + } + + field(:customDoorsOpenLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:doorsOpen) + field(:doorsOpenLabel) + field(:end) + field(:kind) + field(:start) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventDateTime do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventDateTime.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventDateTime do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_reservation_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_reservation_info.ex new file mode 100644 index 0000000000..dfcaafc47d --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_reservation_info.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventReservationInfo do + @moduledoc """ + + + ## Attributes + + * `confirmationCode` (*type:* `String.t`, *default:* `nil`) - The confirmation code of the event reservation. This may also take the form of an "order number", "confirmation number", "reservation number", or other equivalent. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#eventReservationInfo"`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :confirmationCode => String.t() | nil, + :kind => String.t() | nil + } + + field(:confirmationCode) + field(:kind) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventReservationInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventReservationInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventReservationInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_seat.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_seat.ex new file mode 100644 index 0000000000..4877ca34c8 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_seat.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventSeat do + @moduledoc """ + + + ## Attributes + + * `gate` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The gate the ticket holder should enter to get to their seat, such as "A" or "West". This field is localizable so you may translate words or use different alphabets for the characters in an identifier. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#eventSeat"`. + * `row` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The row of the seat, such as "1", E", "BB", or "A5". This field is localizable so you may translate words or use different alphabets for the characters in an identifier. + * `seat` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The seat number, such as "1", "2", "3", or any other seat identifier. This field is localizable so you may translate words or use different alphabets for the characters in an identifier. + * `section` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The section of the seat, such as "121". This field is localizable so you may translate words or use different alphabets for the characters in an identifier. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :gate => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :kind => String.t() | nil, + :row => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :seat => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :section => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:gate, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:kind) + field(:row, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:seat, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:section, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventSeat do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventSeat.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventSeat do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class.ex new file mode 100644 index 0000000000..707de32250 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class.ex @@ -0,0 +1,173 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventTicketClass do + @moduledoc """ + + + ## Attributes + + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `homepageUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URI of your application's home page. Populating the URI in this field results in the exact same behavior as populating an URI in linksModuleData (when an object is rendered, a link to the homepage is shown in what would usually be thought of as the linksModuleData section of the object). + * `wordMark` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Deprecated. + * `countryCode` (*type:* `String.t`, *default:* `nil`) - Country code used to display the card's country (when the user is not in that country), as well as to display localized content when content is not available in the user's locale. + * `classTemplateInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t`, *default:* `nil`) - Template information about how the class should be displayed. If unset, Google will fallback to a default set of fields to display. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the object, both will be displayed. + * `eventName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Required. The name of the event, such as "LA Dodgers at SF Giants". + * `sectionLabel` (*type:* `String.t`, *default:* `nil`) - The label to use for the section value (`eventTicketObject.seatInfo.section`) on the card detail view. Each available option maps to a set of localized strings, so that translations are shown to the user based on their locale. Both `sectionLabel` and `customSectionLabel` may not be set. If neither is set, the label will default to "Section", localized. If the section field is unset, this label will not be used. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#eventTicketClass"`. + * `finePrint` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The fine print, terms, or conditions of the ticket. + * `customSectionLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the section value (`eventTicketObject.seatInfo.section`) on the card detail view. This should only be used if the default "Section" label or one of the `sectionLabel` options is not sufficient. Both `sectionLabel` and `customSectionLabel` may not be set. If neither is set, the label will default to "Section", localized. If the section field is unset, this label will not be used. + * `localizedIssuerName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the issuer_name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `multipleDevicesAndHoldersAllowedStatus` (*type:* `String.t`, *default:* `nil`) - Identifies whether multiple users and devices will save the same object referencing this class. + * `issuerName` (*type:* `String.t`, *default:* `nil`) - Required. The issuer name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `venue` (*type:* `GoogleApi.WalletObjects.V1.Model.EventVenue.t`, *default:* `nil`) - Event venue details. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `securityAnimation` (*type:* `GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t`, *default:* `nil`) - Optional information about the security animation. If this is set a security animation will be rendered on pass details. + * `seatLabel` (*type:* `String.t`, *default:* `nil`) - The label to use for the seat value (`eventTicketObject.seatInfo.seat`) on the card detail view. Each available option maps to a set of localized strings, so that translations are shown to the user based on their locale. Both `seatLabel` and `customSeatLabel` may not be set. If neither is set, the label will default to "Seat", localized. If the seat field is unset, this label will not be used. + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Callback options to be used to call the issuer back for every save/delete of an object for this class by the end-user. All objects of this class are eligible for the callback. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + * `viewUnlockRequirement` (*type:* `String.t`, *default:* `nil`) - View Unlock Requirement options for the event ticket. + * `customGateLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the gate value (`eventTicketObject.seatInfo.gate`) on the card detail view. This should only be used if the default "Gate" label or one of the `gateLabel` options is not sufficient. Both `gateLabel` and `customGateLabel` may not be set. If neither is set, the label will default to "Gate", localized. If the gate field is unset, this label will not be used. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `eventId` (*type:* `String.t`, *default:* `nil`) - The ID of the event. This ID should be unique for every event in an account. It is used to group tickets together if the user has saved multiple tickets for the same event. It can be at most 64 characters. If provided, the grouping will be stable. Be wary of unintentional collision to avoid grouping tickets that should not be grouped. If you use only one class per event, you can simply set this to the `classId` (with or without the issuer ID portion). If not provided, the platform will attempt to use other data to group tickets (potentially unstable). + * `customSeatLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the seat value (`eventTicketObject.seatInfo.seat`) on the card detail view. This should only be used if the default "Seat" label or one of the `seatLabel` options is not sufficient. Both `seatLabel` and `customSeatLabel` may not be set. If neither is set, the label will default to "Seat", localized. If the seat field is unset, this label will not be used. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `customConfirmationCodeLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the confirmation code value (`eventTicketObject.reservationInfo.confirmationCode`) on the card detail view. This should only be used if the default "Confirmation Code" label or one of the `confirmationCodeLabel` options is not sufficient. Both `confirmationCodeLabel` and `customConfirmationCodeLabel` may not be set. If neither is set, the label will default to "Confirmation Code", localized. If the confirmation code field is unset, this label will not be used. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, nothing will be displayed. The image will display at 100% width. + * `logo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The logo image of the ticket. This image is displayed in the card detail view of the app. + * `gateLabel` (*type:* `String.t`, *default:* `nil`) - The label to use for the gate value (`eventTicketObject.seatInfo.gate`) on the card detail view. Each available option maps to a set of localized strings, so that translations are shown to the user based on their locale. Both `gateLabel` and `customGateLabel` may not be set. If neither is set, the label will default to "Gate", localized. If the gate field is unset, this label will not be used. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `customRowLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the row value (`eventTicketObject.seatInfo.row`) on the card detail view. This should only be used if the default "Row" label or one of the `rowLabel` options is not sufficient. Both `rowLabel` and `customRowLabel` may not be set. If neither is set, the label will default to "Row", localized. If the row field is unset, this label will not be used. + * `enableSmartTap` (*type:* `boolean()`, *default:* `nil`) - Identifies whether this class supports Smart Tap. The `redemptionIssuers` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `reviewStatus` (*type:* `String.t`, *default:* `nil`) - Required. The status of the class. This field can be set to `draft` or `underReview` using the insert, patch, or update API calls. Once the review state is changed from `draft` it may not be changed back to `draft`. You should keep this field to `draft` when the class is under development. A `draft` class cannot be used to create any object. You should set this field to `underReview` when you believe the class is ready for use. The platform will automatically set this field to `approved` and it can be immediately used to create or migrate objects. When updating an already `approved` class you should keep setting this field to `underReview`. + * `allowMultipleUsersPerObject` (*type:* `boolean()`, *default:* `nil`) - Deprecated. Use `multipleDevicesAndHoldersAllowedStatus` instead. + * `wideLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The wide logo of the ticket. When provided, this will be used in place of the logo in the top left of the card view. + * `review` (*type:* `GoogleApi.WalletObjects.V1.Model.Review.t`, *default:* `nil`) - The review comments set by the platform when a class is marked `approved` or `rejected`. + * `confirmationCodeLabel` (*type:* `String.t`, *default:* `nil`) - The label to use for the confirmation code value (`eventTicketObject.reservationInfo.confirmationCode`) on the card detail view. Each available option maps to a set of localized strings, so that translations are shown to the user based on their locale. Both `confirmationCodeLabel` and `customConfirmationCodeLabel` may not be set. If neither is set, the label will default to "Confirmation Code", localized. If the confirmation code field is unset, this label will not be used. + * `redemptionIssuers` (*type:* `list(String.t)`, *default:* `nil`) - Identifies which redemption issuers can redeem the pass over Smart Tap. Redemption issuers are identified by their issuer ID. Redemption issuers must have at least one Smart Tap key configured. The `enableSmartTap` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `rowLabel` (*type:* `String.t`, *default:* `nil`) - The label to use for the row value (`eventTicketObject.seatInfo.row`) on the card detail view. Each available option maps to a set of localized strings, so that translations are shown to the user based on their locale. Both `rowLabel` and `customRowLabel` may not be set. If neither is set, the label will default to "Row", localized. If the row field is unset, this label will not be used. + * `dateTime` (*type:* `GoogleApi.WalletObjects.V1.Model.EventDateTime.t`, *default:* `nil`) - The date & time information of the event. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :homepageUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil, + :wordMark => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :countryCode => String.t() | nil, + :classTemplateInfo => GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :eventName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :sectionLabel => String.t() | nil, + :kind => String.t() | nil, + :finePrint => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :customSectionLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :localizedIssuerName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :multipleDevicesAndHoldersAllowedStatus => String.t() | nil, + :issuerName => String.t() | nil, + :venue => GoogleApi.WalletObjects.V1.Model.EventVenue.t() | nil, + :hexBackgroundColor => String.t() | nil, + :securityAnimation => GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t() | nil, + :seatLabel => String.t() | nil, + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :version => String.t() | nil, + :viewUnlockRequirement => String.t() | nil, + :customGateLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :eventId => String.t() | nil, + :customSeatLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :customConfirmationCodeLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :logo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :gateLabel => String.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :customRowLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :enableSmartTap => boolean() | nil, + :reviewStatus => String.t() | nil, + :allowMultipleUsersPerObject => boolean() | nil, + :wideLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :review => GoogleApi.WalletObjects.V1.Model.Review.t() | nil, + :confirmationCodeLabel => String.t() | nil, + :redemptionIssuers => list(String.t()) | nil, + :rowLabel => String.t() | nil, + :dateTime => GoogleApi.WalletObjects.V1.Model.EventDateTime.t() | nil + } + + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:homepageUri, as: GoogleApi.WalletObjects.V1.Model.Uri) + field(:wordMark, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:countryCode) + field(:classTemplateInfo, as: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:eventName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:sectionLabel) + field(:kind) + field(:finePrint, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:customSectionLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:localizedIssuerName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:multipleDevicesAndHoldersAllowedStatus) + field(:issuerName) + field(:venue, as: GoogleApi.WalletObjects.V1.Model.EventVenue) + field(:hexBackgroundColor) + field(:securityAnimation, as: GoogleApi.WalletObjects.V1.Model.SecurityAnimation) + field(:seatLabel) + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:version) + field(:viewUnlockRequirement) + field(:customGateLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:eventId) + field(:customSeatLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:customConfirmationCodeLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:logo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:gateLabel) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:customRowLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:enableSmartTap) + field(:reviewStatus) + field(:allowMultipleUsersPerObject) + field(:wideLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:review, as: GoogleApi.WalletObjects.V1.Model.Review) + field(:confirmationCodeLabel) + field(:redemptionIssuers, type: :list) + field(:rowLabel) + field(:dateTime, as: GoogleApi.WalletObjects.V1.Model.EventDateTime) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketClass do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventTicketClass.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketClass do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_add_message_response.ex new file mode 100644 index 0000000000..0117dc9f43 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventTicketClassAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketClass.t`, *default:* `nil`) - The updated EventTicketClass resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.EventTicketClass.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.EventTicketClass) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketClassAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventTicketClassAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketClassAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_list_response.ex new file mode 100644 index 0000000000..f41600c8e7 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_class_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventTicketClassListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.EventTicketClass.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.EventTicketClass.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.EventTicketClass, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketClassListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventTicketClassListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketClassListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object.ex new file mode 100644 index 0000000000..2f56bbb0af --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object.ex @@ -0,0 +1,136 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventTicketObject do + @moduledoc """ + + + ## Attributes + + * `appLinkData` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkData.t`, *default:* `nil`) - Optional information about the partner app link. + * `barcode` (*type:* `GoogleApi.WalletObjects.V1.Model.Barcode.t`, *default:* `nil`) - The barcode type and value. + * `classId` (*type:* `String.t`, *default:* `nil`) - Required. The class associated with this object. The class must be of the same type as this object, must already exist, and must be approved. Class IDs should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. + * `classReference` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketClass.t`, *default:* `nil`) - A copy of the inherited fields of the parent class. These fields are retrieved during a GET. + * `disableExpirationNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if notifications should explicitly be suppressed. If this field is set to true, regardless of the `messages` field, expiration notifications to the user will be suppressed. By default, this field is set to false. Currently, this can only be set for offers. + * `faceValue` (*type:* `GoogleApi.WalletObjects.V1.Model.Money.t`, *default:* `nil`) - The face value of the ticket, matching what would be printed on a physical version of the ticket. + * `groupingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.GroupingInfo.t`, *default:* `nil`) - Information that controls how passes are grouped together. + * `hasLinkedDevice` (*type:* `boolean()`, *default:* `nil`) - Whether this object is currently linked to a single device. This field is set by the platform when a user saves the object, linking it to their device. Intended for use by select partners. Contact support for additional information. + * `hasUsers` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object has users. This field is set by the platform. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, hero image of the class, if present, will be displayed. If hero image of the class is also not present, nothing will be displayed. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. The unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#eventTicketObject"`. + * `linkedOfferIds` (*type:* `list(String.t)`, *default:* `nil`) - A list of offer objects linked to this event ticket. The offer objects must already exist. Offer object IDs should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the class, both will be displayed. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `passConstraints` (*type:* `GoogleApi.WalletObjects.V1.Model.PassConstraints.t`, *default:* `nil`) - Pass constraints for the object. Includes limiting NFC and screenshot behaviors. + * `reservationInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.EventReservationInfo.t`, *default:* `nil`) - Reservation details for this ticket. This is expected to be shared amongst all tickets that were purchased in the same order. + * `rotatingBarcode` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t`, *default:* `nil`) - The rotating barcode type and value. + * `seatInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.EventSeat.t`, *default:* `nil`) - Seating details for this ticket. + * `smartTapRedemptionValue` (*type:* `String.t`, *default:* `nil`) - The value that will be transmitted to a Smart Tap certified terminal over NFC for this object. The class level fields `enableSmartTap` and `redemptionIssuers` must also be set up correctly in order for the pass to support Smart Tap. Only ASCII characters are supported. + * `state` (*type:* `String.t`, *default:* `nil`) - Required. The state of the object. This field is used to determine how an object is displayed in the app. For example, an `inactive` object is moved to the "Expired passes" section. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `ticketHolderName` (*type:* `String.t`, *default:* `nil`) - Name of the ticket holder, if the ticket is assigned to a person. E.g. "John Doe" or "Jane Doe". + * `ticketNumber` (*type:* `String.t`, *default:* `nil`) - The number of the ticket. This can be a unique identifier across all tickets in an issuer's system, all tickets for the event (e.g. XYZ1234512345), or all tickets in the order (1, 2, 3, etc.). + * `ticketType` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The type of the ticket, such as "Adult" or "Child", or "VIP" or "Standard". + * `validTimeInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The time period this object will be `active` and object can be used. An object's state will be changed to `expired` when this time period has passed. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :appLinkData => GoogleApi.WalletObjects.V1.Model.AppLinkData.t() | nil, + :barcode => GoogleApi.WalletObjects.V1.Model.Barcode.t() | nil, + :classId => String.t() | nil, + :classReference => GoogleApi.WalletObjects.V1.Model.EventTicketClass.t() | nil, + :disableExpirationNotification => boolean() | nil, + :faceValue => GoogleApi.WalletObjects.V1.Model.Money.t() | nil, + :groupingInfo => GoogleApi.WalletObjects.V1.Model.GroupingInfo.t() | nil, + :hasLinkedDevice => boolean() | nil, + :hasUsers => boolean() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :hexBackgroundColor => String.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :kind => String.t() | nil, + :linkedOfferIds => list(String.t()) | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :passConstraints => GoogleApi.WalletObjects.V1.Model.PassConstraints.t() | nil, + :reservationInfo => GoogleApi.WalletObjects.V1.Model.EventReservationInfo.t() | nil, + :rotatingBarcode => GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t() | nil, + :seatInfo => GoogleApi.WalletObjects.V1.Model.EventSeat.t() | nil, + :smartTapRedemptionValue => String.t() | nil, + :state => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :ticketHolderName => String.t() | nil, + :ticketNumber => String.t() | nil, + :ticketType => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :validTimeInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :version => String.t() | nil + } + + field(:appLinkData, as: GoogleApi.WalletObjects.V1.Model.AppLinkData) + field(:barcode, as: GoogleApi.WalletObjects.V1.Model.Barcode) + field(:classId) + field(:classReference, as: GoogleApi.WalletObjects.V1.Model.EventTicketClass) + field(:disableExpirationNotification) + field(:faceValue, as: GoogleApi.WalletObjects.V1.Model.Money) + field(:groupingInfo, as: GoogleApi.WalletObjects.V1.Model.GroupingInfo) + field(:hasLinkedDevice) + field(:hasUsers) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:hexBackgroundColor) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:kind) + field(:linkedOfferIds, type: :list) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:passConstraints, as: GoogleApi.WalletObjects.V1.Model.PassConstraints) + field(:reservationInfo, as: GoogleApi.WalletObjects.V1.Model.EventReservationInfo) + field(:rotatingBarcode, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcode) + field(:seatInfo, as: GoogleApi.WalletObjects.V1.Model.EventSeat) + field(:smartTapRedemptionValue) + field(:state) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:ticketHolderName) + field(:ticketNumber) + field(:ticketType, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:validTimeInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:version) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketObject do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventTicketObject.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketObject do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_add_message_response.ex new file mode 100644 index 0000000000..39ce50d028 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventTicketObjectAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.EventTicketObject.t`, *default:* `nil`) - The updated EventTicketObject resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.EventTicketObject.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.EventTicketObject) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketObjectAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventTicketObjectAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketObjectAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_list_response.ex new file mode 100644 index 0000000000..579d54478b --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_ticket_object_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventTicketObjectListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.EventTicketObject.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.EventTicketObject.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.EventTicketObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketObjectListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventTicketObjectListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventTicketObjectListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_venue.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_venue.ex new file mode 100644 index 0000000000..860490629e --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/event_venue.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.EventVenue do + @moduledoc """ + + + ## Attributes + + * `address` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The address of the venue, such as "24 Willie Mays Plaza\\nSan Francisco, CA 94107". Address lines are separated by line feed (`\\n`) characters. This is required. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#eventVenue"`. + * `name` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The name of the venue, such as "AT&T Park". This is required. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :address => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :kind => String.t() | nil, + :name => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:address, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:kind) + field(:name, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.EventVenue do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.EventVenue.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.EventVenue do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/expiry_notification.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/expiry_notification.ex new file mode 100644 index 0000000000..b441338f7a --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/expiry_notification.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ExpiryNotification do + @moduledoc """ + Indicates that the issuer would like Google Wallet to send expiry notifications 2 days prior to the card expiration. + + ## Attributes + + * `enableNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object needs to have expiry notification enabled. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :enableNotification => boolean() | nil + } + + field(:enableNotification) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ExpiryNotification do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ExpiryNotification.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ExpiryNotification do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_reference.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_reference.ex new file mode 100644 index 0000000000..0faf1f5dd6 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_reference.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FieldReference do + @moduledoc """ + Reference definition to use with field overrides. + + ## Attributes + + * `dateFormat` (*type:* `String.t`, *default:* `nil`) - Only valid if the `fieldPath` references a date field. Chooses how the date field will be formatted and displayed in the UI. + * `fieldPath` (*type:* `String.t`, *default:* `nil`) - Path to the field being referenced, prefixed with "object" or "class" and separated with dots. For example, it may be the string "object.purchaseDetails.purchasePrice". + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dateFormat => String.t() | nil, + :fieldPath => String.t() | nil + } + + field(:dateFormat) + field(:fieldPath) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FieldReference do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FieldReference.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FieldReference do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_selector.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_selector.ex new file mode 100644 index 0000000000..3dca003480 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/field_selector.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FieldSelector do + @moduledoc """ + Custom field selector to use with field overrides. + + ## Attributes + + * `fields` (*type:* `list(GoogleApi.WalletObjects.V1.Model.FieldReference.t)`, *default:* `nil`) - If more than one reference is supplied, then the first one that references a non-empty field will be displayed. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :fields => list(GoogleApi.WalletObjects.V1.Model.FieldReference.t()) | nil + } + + field(:fields, as: GoogleApi.WalletObjects.V1.Model.FieldReference, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FieldSelector do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FieldSelector.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FieldSelector do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/first_row_option.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/first_row_option.ex new file mode 100644 index 0000000000..7c5b4e62fd --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/first_row_option.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FirstRowOption do + @moduledoc """ + + + ## Attributes + + * `fieldOption` (*type:* `GoogleApi.WalletObjects.V1.Model.FieldSelector.t`, *default:* `nil`) - A reference to the field to be displayed in the first row. + * `transitOption` (*type:* `String.t`, *default:* `nil`) - + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :fieldOption => GoogleApi.WalletObjects.V1.Model.FieldSelector.t() | nil, + :transitOption => String.t() | nil + } + + field(:fieldOption, as: GoogleApi.WalletObjects.V1.Model.FieldSelector) + field(:transitOption) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FirstRowOption do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FirstRowOption.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FirstRowOption do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_carrier.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_carrier.ex new file mode 100644 index 0000000000..92b8583408 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_carrier.ex @@ -0,0 +1,64 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightCarrier do + @moduledoc """ + + + ## Attributes + + * `airlineAllianceLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - A logo for the airline alliance, displayed below the QR code that the passenger scans to board. + * `airlineLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - A logo for the airline described by carrierIataCode and localizedAirlineName. This logo will be rendered at the top of the detailed card view. + * `airlineName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A localized name of the airline specified by carrierIataCode. If unset, `issuer_name` or `localized_issuer_name` from `FlightClass` will be used for display purposes. eg: "Swiss Air" for "LX" + * `carrierIataCode` (*type:* `String.t`, *default:* `nil`) - Two character IATA airline code of the marketing carrier (as opposed to operating carrier). Exactly one of this or `carrierIcaoCode` needs to be provided for `carrier` and `operatingCarrier`. eg: "LX" for Swiss Air + * `carrierIcaoCode` (*type:* `String.t`, *default:* `nil`) - Three character ICAO airline code of the marketing carrier (as opposed to operating carrier). Exactly one of this or `carrierIataCode` needs to be provided for `carrier` and `operatingCarrier`. eg: "EZY" for Easy Jet + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#flightCarrier"`. + * `wideAirlineLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The wide logo of the airline. When provided, this will be used in place of the airline logo in the top left of the card view. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :airlineAllianceLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :airlineLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :airlineName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :carrierIataCode => String.t() | nil, + :carrierIcaoCode => String.t() | nil, + :kind => String.t() | nil, + :wideAirlineLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil + } + + field(:airlineAllianceLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:airlineLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:airlineName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:carrierIataCode) + field(:carrierIcaoCode) + field(:kind) + field(:wideAirlineLogo, as: GoogleApi.WalletObjects.V1.Model.Image) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightCarrier do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightCarrier.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightCarrier do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class.ex new file mode 100644 index 0000000000..4ce61dd4cd --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class.ex @@ -0,0 +1,158 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightClass do + @moduledoc """ + + + ## Attributes + + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `localGateClosingDateTime` (*type:* `String.t`, *default:* `nil`) - The gate closing time as it would be printed on the boarding pass. Do not set this field if you do not want to print it in the boarding pass. This is an ISO 8601 extended format date/time without an offset. Time may be specified up to millisecond precision. eg: `2027-03-05T06:30:00` This should be the local date/time at the airport (not a UTC time). Google will reject the request if UTC offset is provided. Time zones will be calculated by Google based on departure airport. + * `destination` (*type:* `GoogleApi.WalletObjects.V1.Model.AirportInfo.t`, *default:* `nil`) - Required. Destination airport. + * `homepageUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URI of your application's home page. Populating the URI in this field results in the exact same behavior as populating an URI in linksModuleData (when an object is rendered, a link to the homepage is shown in what would usually be thought of as the linksModuleData section of the object). + * `wordMark` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Deprecated. + * `countryCode` (*type:* `String.t`, *default:* `nil`) - Country code used to display the card's country (when the user is not in that country), as well as to display localized content when content is not available in the user's locale. + * `classTemplateInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t`, *default:* `nil`) - Template information about how the class should be displayed. If unset, Google will fallback to a default set of fields to display. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the object, both will be displayed. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#flightClass"`. + * `localizedIssuerName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the issuer_name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `multipleDevicesAndHoldersAllowedStatus` (*type:* `String.t`, *default:* `nil`) - Identifies whether multiple users and devices will save the same object referencing this class. + * `issuerName` (*type:* `String.t`, *default:* `nil`) - Required. The issuer name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `securityAnimation` (*type:* `GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t`, *default:* `nil`) - Optional information about the security animation. If this is set a security animation will be rendered on pass details. + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Callback options to be used to call the issuer back for every save/delete of an object for this class by the end-user. All objects of this class are eligible for the callback. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + * `origin` (*type:* `GoogleApi.WalletObjects.V1.Model.AirportInfo.t`, *default:* `nil`) - Required. Origin airport. + * `viewUnlockRequirement` (*type:* `String.t`, *default:* `nil`) - View Unlock Requirement options for the boarding pass. + * `flightStatus` (*type:* `String.t`, *default:* `nil`) - Status of this flight. If unset, Google will compute status based on data from other sources, such as FlightStats, etc. Note: Google-computed status will not be returned in API responses. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `flightHeader` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightHeader.t`, *default:* `nil`) - Required. Information about the flight carrier and number. + * `languageOverride` (*type:* `String.t`, *default:* `nil`) - If this field is present, boarding passes served to a user's device will always be in this language. Represents the BCP 47 language tag. Example values are "en-US", "en-GB", "de", or "de-AT". + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, nothing will be displayed. The image will display at 100% width. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `localScheduledArrivalDateTime` (*type:* `String.t`, *default:* `nil`) - The scheduled time the aircraft plans to reach the destination gate (not the runway). Note: This field should not change too close to the flight time. For updates to departure times (delays, etc), please set `localEstimatedOrActualArrivalDateTime`. This is an ISO 8601 extended format date/time without an offset. Time may be specified up to millisecond precision. eg: `2027-03-05T06:30:00` This should be the local date/time at the airport (not a UTC time). Google will reject the request if UTC offset is provided. Time zones will be calculated by Google based on arrival airport. If this is not set, Google will set it based on data from other sources. + * `boardingAndSeatingPolicy` (*type:* `GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingPolicy.t`, *default:* `nil`) - Policies for boarding and seating. These will inform which labels will be shown to users. + * `localEstimatedOrActualArrivalDateTime` (*type:* `String.t`, *default:* `nil`) - The estimated time the aircraft plans to reach the destination gate (not the runway) or the actual time it reached the gate. This field should be set if at least one of the below is true: - It differs from the scheduled time. Google will use it to calculate the delay. - The aircraft already arrived at the gate. Google will use it to inform the user that the flight has arrived at the gate. This is an ISO 8601 extended format date/time without an offset. Time may be specified up to millisecond precision. eg: `2027-03-05T06:30:00` This should be the local date/time at the airport (not a UTC time). Google will reject the request if UTC offset is provided. Time zones will be calculated by Google based on arrival airport. If this is not set, Google will set it based on data from other sources. + * `enableSmartTap` (*type:* `boolean()`, *default:* `nil`) - Identifies whether this class supports Smart Tap. The `redemptionIssuers` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `localEstimatedOrActualDepartureDateTime` (*type:* `String.t`, *default:* `nil`) - The estimated time the aircraft plans to pull from the gate or the actual time the aircraft already pulled from the gate. Note: This is not the runway time. This field should be set if at least one of the below is true: - It differs from the scheduled time. Google will use it to calculate the delay. - The aircraft already pulled from the gate. Google will use it to inform the user when the flight actually departed. This is an ISO 8601 extended format date/time without an offset. Time may be specified up to millisecond precision. eg: `2027-03-05T06:30:00` This should be the local date/time at the airport (not a UTC time). Google will reject the request if UTC offset is provided. Time zones will be calculated by Google based on departure airport. If this is not set, Google will set it based on data from other sources. + * `reviewStatus` (*type:* `String.t`, *default:* `nil`) - Required. The status of the class. This field can be set to `draft` or `underReview` using the insert, patch, or update API calls. Once the review state is changed from `draft` it may not be changed back to `draft`. You should keep this field to `draft` when the class is under development. A `draft` class cannot be used to create any object. You should set this field to `underReview` when you believe the class is ready for use. The platform will automatically set this field to `approved` and it can be immediately used to create or migrate objects. When updating an already `approved` class you should keep setting this field to `underReview`. + * `allowMultipleUsersPerObject` (*type:* `boolean()`, *default:* `nil`) - Deprecated. Use `multipleDevicesAndHoldersAllowedStatus` instead. + * `review` (*type:* `GoogleApi.WalletObjects.V1.Model.Review.t`, *default:* `nil`) - The review comments set by the platform when a class is marked `approved` or `rejected`. + * `redemptionIssuers` (*type:* `list(String.t)`, *default:* `nil`) - Identifies which redemption issuers can redeem the pass over Smart Tap. Redemption issuers are identified by their issuer ID. Redemption issuers must have at least one Smart Tap key configured. The `enableSmartTap` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `localScheduledDepartureDateTime` (*type:* `String.t`, *default:* `nil`) - Required. The scheduled date and time when the aircraft is expected to depart the gate (not the runway) Note: This field should not change too close to the departure time. For updates to departure times (delays, etc), please set `localEstimatedOrActualDepartureDateTime`. This is an ISO 8601 extended format date/time without an offset. Time may be specified up to millisecond precision. eg: `2027-03-05T06:30:00` This should be the local date/time at the airport (not a UTC time). Google will reject the request if UTC offset is provided. Time zones will be calculated by Google based on departure airport. + * `localBoardingDateTime` (*type:* `String.t`, *default:* `nil`) - The boarding time as it would be printed on the boarding pass. This is an ISO 8601 extended format date/time without an offset. Time may be specified up to millisecond precision. eg: `2027-03-05T06:30:00` This should be the local date/time at the airport (not a UTC time). Google will reject the request if UTC offset is provided. Time zones will be calculated by Google based on departure airport. If this is not set, Google will set it based on data from other sources. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :localGateClosingDateTime => String.t() | nil, + :destination => GoogleApi.WalletObjects.V1.Model.AirportInfo.t() | nil, + :homepageUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil, + :wordMark => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :countryCode => String.t() | nil, + :classTemplateInfo => GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :kind => String.t() | nil, + :localizedIssuerName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :multipleDevicesAndHoldersAllowedStatus => String.t() | nil, + :issuerName => String.t() | nil, + :hexBackgroundColor => String.t() | nil, + :securityAnimation => GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t() | nil, + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :version => String.t() | nil, + :origin => GoogleApi.WalletObjects.V1.Model.AirportInfo.t() | nil, + :viewUnlockRequirement => String.t() | nil, + :flightStatus => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :flightHeader => GoogleApi.WalletObjects.V1.Model.FlightHeader.t() | nil, + :languageOverride => String.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :localScheduledArrivalDateTime => String.t() | nil, + :boardingAndSeatingPolicy => + GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingPolicy.t() | nil, + :localEstimatedOrActualArrivalDateTime => String.t() | nil, + :enableSmartTap => boolean() | nil, + :localEstimatedOrActualDepartureDateTime => String.t() | nil, + :reviewStatus => String.t() | nil, + :allowMultipleUsersPerObject => boolean() | nil, + :review => GoogleApi.WalletObjects.V1.Model.Review.t() | nil, + :redemptionIssuers => list(String.t()) | nil, + :localScheduledDepartureDateTime => String.t() | nil, + :localBoardingDateTime => String.t() | nil + } + + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:localGateClosingDateTime) + field(:destination, as: GoogleApi.WalletObjects.V1.Model.AirportInfo) + field(:homepageUri, as: GoogleApi.WalletObjects.V1.Model.Uri) + field(:wordMark, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:countryCode) + field(:classTemplateInfo, as: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:kind) + field(:localizedIssuerName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:multipleDevicesAndHoldersAllowedStatus) + field(:issuerName) + field(:hexBackgroundColor) + field(:securityAnimation, as: GoogleApi.WalletObjects.V1.Model.SecurityAnimation) + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:version) + field(:origin, as: GoogleApi.WalletObjects.V1.Model.AirportInfo) + field(:viewUnlockRequirement) + field(:flightStatus) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:flightHeader, as: GoogleApi.WalletObjects.V1.Model.FlightHeader) + field(:languageOverride) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:localScheduledArrivalDateTime) + field(:boardingAndSeatingPolicy, as: GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingPolicy) + field(:localEstimatedOrActualArrivalDateTime) + field(:enableSmartTap) + field(:localEstimatedOrActualDepartureDateTime) + field(:reviewStatus) + field(:allowMultipleUsersPerObject) + field(:review, as: GoogleApi.WalletObjects.V1.Model.Review) + field(:redemptionIssuers, type: :list) + field(:localScheduledDepartureDateTime) + field(:localBoardingDateTime) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightClass do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightClass.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightClass do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_add_message_response.ex new file mode 100644 index 0000000000..32089574cf --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightClassAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightClass.t`, *default:* `nil`) - The updated FlightClass resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.FlightClass.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.FlightClass) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightClassAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightClassAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightClassAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_list_response.ex new file mode 100644 index 0000000000..c8ba9d192a --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_class_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightClassListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.FlightClass.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.FlightClass.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.FlightClass, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightClassListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightClassListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightClassListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_header.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_header.ex new file mode 100644 index 0000000000..f26b3f221e --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_header.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightHeader do + @moduledoc """ + + + ## Attributes + + * `carrier` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightCarrier.t`, *default:* `nil`) - Information about airline carrier. This is a required property of `flightHeader`. + * `flightNumber` (*type:* `String.t`, *default:* `nil`) - The flight number without IATA carrier code. This field should contain only digits. This is a required property of `flightHeader`. eg: "123" + * `flightNumberDisplayOverride` (*type:* `String.t`, *default:* `nil`) - Override value to use for flight number. The default value used for display purposes is carrier + flight_number. If a different value needs to be shown to passengers, use this field to override the default behavior. eg: "XX1234 / YY576" + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#flightHeader"`. + * `operatingCarrier` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightCarrier.t`, *default:* `nil`) - Information about operating airline carrier. + * `operatingFlightNumber` (*type:* `String.t`, *default:* `nil`) - The flight number used by the operating carrier without IATA carrier code. This field should contain only digits. eg: "234" + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :carrier => GoogleApi.WalletObjects.V1.Model.FlightCarrier.t() | nil, + :flightNumber => String.t() | nil, + :flightNumberDisplayOverride => String.t() | nil, + :kind => String.t() | nil, + :operatingCarrier => GoogleApi.WalletObjects.V1.Model.FlightCarrier.t() | nil, + :operatingFlightNumber => String.t() | nil + } + + field(:carrier, as: GoogleApi.WalletObjects.V1.Model.FlightCarrier) + field(:flightNumber) + field(:flightNumberDisplayOverride) + field(:kind) + field(:operatingCarrier, as: GoogleApi.WalletObjects.V1.Model.FlightCarrier) + field(:operatingFlightNumber) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightHeader do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightHeader.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightHeader do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object.ex new file mode 100644 index 0000000000..471ab3637c --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object.ex @@ -0,0 +1,128 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightObject do + @moduledoc """ + + + ## Attributes + + * `appLinkData` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkData.t`, *default:* `nil`) - Optional information about the partner app link. + * `barcode` (*type:* `GoogleApi.WalletObjects.V1.Model.Barcode.t`, *default:* `nil`) - The barcode type and value. + * `boardingAndSeatingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingInfo.t`, *default:* `nil`) - Passenger specific information about boarding and seating. + * `classId` (*type:* `String.t`, *default:* `nil`) - Required. The class associated with this object. The class must be of the same type as this object, must already exist, and must be approved. Class IDs should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. + * `classReference` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightClass.t`, *default:* `nil`) - A copy of the inherited fields of the parent class. These fields are retrieved during a GET. + * `disableExpirationNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if notifications should explicitly be suppressed. If this field is set to true, regardless of the `messages` field, expiration notifications to the user will be suppressed. By default, this field is set to false. Currently, this can only be set for Flights. + * `groupingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.GroupingInfo.t`, *default:* `nil`) - Information that controls how passes are grouped together. + * `hasLinkedDevice` (*type:* `boolean()`, *default:* `nil`) - Whether this object is currently linked to a single device. This field is set by the platform when a user saves the object, linking it to their device. Intended for use by select partners. Contact support for additional information. + * `hasUsers` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object has users. This field is set by the platform. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, hero image of the class, if present, will be displayed. If hero image of the class is also not present, nothing will be displayed. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. The unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#flightObject"`. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the class, both will be displayed. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `passConstraints` (*type:* `GoogleApi.WalletObjects.V1.Model.PassConstraints.t`, *default:* `nil`) - Pass constraints for the object. Includes limiting NFC and screenshot behaviors. + * `passengerName` (*type:* `String.t`, *default:* `nil`) - Required. Passenger name as it would appear on the boarding pass. eg: "Dave M Gahan" or "Gahan/Dave" or "GAHAN/DAVEM" + * `reservationInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ReservationInfo.t`, *default:* `nil`) - Required. Information about flight reservation. + * `rotatingBarcode` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t`, *default:* `nil`) - The rotating barcode type and value. + * `securityProgramLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - An image for the security program that applies to the passenger. + * `smartTapRedemptionValue` (*type:* `String.t`, *default:* `nil`) - The value that will be transmitted to a Smart Tap certified terminal over NFC for this object. The class level fields `enableSmartTap` and `redemptionIssuers` must also be set up correctly in order for the pass to support Smart Tap. Only ASCII characters are supported. + * `state` (*type:* `String.t`, *default:* `nil`) - Required. The state of the object. This field is used to determine how an object is displayed in the app. For example, an `inactive` object is moved to the "Expired passes" section. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `validTimeInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The time period this object will be `active` and object can be used. An object's state will be changed to `expired` when this time period has passed. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :appLinkData => GoogleApi.WalletObjects.V1.Model.AppLinkData.t() | nil, + :barcode => GoogleApi.WalletObjects.V1.Model.Barcode.t() | nil, + :boardingAndSeatingInfo => + GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingInfo.t() | nil, + :classId => String.t() | nil, + :classReference => GoogleApi.WalletObjects.V1.Model.FlightClass.t() | nil, + :disableExpirationNotification => boolean() | nil, + :groupingInfo => GoogleApi.WalletObjects.V1.Model.GroupingInfo.t() | nil, + :hasLinkedDevice => boolean() | nil, + :hasUsers => boolean() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :hexBackgroundColor => String.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :kind => String.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :passConstraints => GoogleApi.WalletObjects.V1.Model.PassConstraints.t() | nil, + :passengerName => String.t() | nil, + :reservationInfo => GoogleApi.WalletObjects.V1.Model.ReservationInfo.t() | nil, + :rotatingBarcode => GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t() | nil, + :securityProgramLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :smartTapRedemptionValue => String.t() | nil, + :state => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :validTimeInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :version => String.t() | nil + } + + field(:appLinkData, as: GoogleApi.WalletObjects.V1.Model.AppLinkData) + field(:barcode, as: GoogleApi.WalletObjects.V1.Model.Barcode) + field(:boardingAndSeatingInfo, as: GoogleApi.WalletObjects.V1.Model.BoardingAndSeatingInfo) + field(:classId) + field(:classReference, as: GoogleApi.WalletObjects.V1.Model.FlightClass) + field(:disableExpirationNotification) + field(:groupingInfo, as: GoogleApi.WalletObjects.V1.Model.GroupingInfo) + field(:hasLinkedDevice) + field(:hasUsers) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:hexBackgroundColor) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:kind) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:passConstraints, as: GoogleApi.WalletObjects.V1.Model.PassConstraints) + field(:passengerName) + field(:reservationInfo, as: GoogleApi.WalletObjects.V1.Model.ReservationInfo) + field(:rotatingBarcode, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcode) + field(:securityProgramLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:smartTapRedemptionValue) + field(:state) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:validTimeInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:version) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightObject do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightObject.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightObject do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_add_message_response.ex new file mode 100644 index 0000000000..45a1c5fa45 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightObjectAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.FlightObject.t`, *default:* `nil`) - The updated FlightObject resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.FlightObject.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.FlightObject) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightObjectAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightObjectAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightObjectAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_list_response.ex new file mode 100644 index 0000000000..6bb7cc1a75 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/flight_object_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FlightObjectListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.FlightObject.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.FlightObject.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.FlightObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FlightObjectListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FlightObjectListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FlightObjectListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/frequent_flyer_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/frequent_flyer_info.ex new file mode 100644 index 0000000000..b969353241 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/frequent_flyer_info.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.FrequentFlyerInfo do + @moduledoc """ + + + ## Attributes + + * `frequentFlyerNumber` (*type:* `String.t`, *default:* `nil`) - Frequent flyer number. Required for each nested object of kind `walletobjects#frequentFlyerInfo`. + * `frequentFlyerProgramName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Frequent flyer program name. eg: "Lufthansa Miles & More" + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#frequentFlyerInfo"`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :frequentFlyerNumber => String.t() | nil, + :frequentFlyerProgramName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :kind => String.t() | nil + } + + field(:frequentFlyerNumber) + field(:frequentFlyerProgramName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:kind) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.FrequentFlyerInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.FrequentFlyerInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.FrequentFlyerInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class.ex new file mode 100644 index 0000000000..5b2108a449 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class.ex @@ -0,0 +1,79 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GenericClass do + @moduledoc """ + Generic Class + + ## Attributes + + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Callback options to be used to call the issuer back for every save/delete of an object for this class by the end-user. All objects of this class are eligible for the callback. + * `classTemplateInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t`, *default:* `nil`) - Template information about how the class should be displayed. If unset, Google will fallback to a default set of fields to display. + * `enableSmartTap` (*type:* `boolean()`, *default:* `nil`) - Available only to Smart Tap enabled partners. Contact support for additional guidance. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for the class. This ID must be unique across all from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. If `imageModulesData` is also defined on the object, both will be displayed. Only one of the image from class and one from object level will be rendered when both set. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If `linksModuleData` is also defined on the object, both will be displayed. The maximum number of these fields displayed is 10 from class and 10 from object. + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `multipleDevicesAndHoldersAllowedStatus` (*type:* `String.t`, *default:* `nil`) - Identifies whether multiple users and devices will save the same object referencing this class. + * `redemptionIssuers` (*type:* `list(String.t)`, *default:* `nil`) - Identifies which redemption issuers can redeem the pass over Smart Tap. Redemption issuers are identified by their issuer ID. Redemption issuers must have at least one Smart Tap key configured. The `enableSmartTap` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `securityAnimation` (*type:* `GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t`, *default:* `nil`) - Optional information about the security animation. If this is set a security animation will be rendered on pass details. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If `textModulesData` is also defined on the object, both will be displayed. The maximum number of these fields displayed is 10 from class and 10 from object. + * `viewUnlockRequirement` (*type:* `String.t`, *default:* `nil`) - View Unlock Requirement options for the generic pass. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :classTemplateInfo => GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t() | nil, + :enableSmartTap => boolean() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :multipleDevicesAndHoldersAllowedStatus => String.t() | nil, + :redemptionIssuers => list(String.t()) | nil, + :securityAnimation => GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :viewUnlockRequirement => String.t() | nil + } + + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:classTemplateInfo, as: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo) + field(:enableSmartTap) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:multipleDevicesAndHoldersAllowedStatus) + field(:redemptionIssuers, type: :list) + field(:securityAnimation, as: GoogleApi.WalletObjects.V1.Model.SecurityAnimation) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:viewUnlockRequirement) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GenericClass do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GenericClass.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GenericClass do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_add_message_response.ex new file mode 100644 index 0000000000..a02c47c5c4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GenericClassAddMessageResponse do + @moduledoc """ + Response to adding a new issuer message to the class. This contains the entire updated GenericClass. + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericClass.t`, *default:* `nil`) - The updated EventTicketClass resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.GenericClass.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.GenericClass) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GenericClassAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GenericClassAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GenericClassAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_list_response.ex new file mode 100644 index 0000000000..3652220d00 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_class_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GenericClassListResponse do + @moduledoc """ + List response which contains the list of all generic classes for a given issuer ID. + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.GenericClass.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.GenericClass.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.GenericClass, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GenericClassListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GenericClassListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GenericClassListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object.ex new file mode 100644 index 0000000000..4e184fb548 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object.ex @@ -0,0 +1,112 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GenericObject do + @moduledoc """ + Generic Object Next ID: 121 + + ## Attributes + + * `appLinkData` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkData.t`, *default:* `nil`) - Information about the partner app link. The maximum number of these fields displayed is 10. + * `barcode` (*type:* `GoogleApi.WalletObjects.V1.Model.Barcode.t`, *default:* `nil`) - The barcode type and value. If pass does not have a barcode, we can allow the issuer to set Barcode.alternate_text and display just that. + * `cardTitle` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Required. The header of the pass. This is usually the Business name such as "XXX Gym", "AAA Insurance". This field is required and appears in the header row at the very top of the pass. + * `classId` (*type:* `String.t`, *default:* `nil`) - Required. The class associated with this object. The class must be of the same type as this object, must already exist, and must be approved. Class IDs should follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. + * `genericType` (*type:* `String.t`, *default:* `nil`) - Specify which `GenericType` the card belongs to. + * `groupingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.GroupingInfo.t`, *default:* `nil`) - Information that controls how passes are grouped together. + * `hasUsers` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object has users. This field is set by the platform. + * `header` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Required. The title of the pass, such as "50% off coupon" or "Library card" or "Voucher". This field is required and appears in the title row of the pass detail view. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Banner image displayed on the front of the card if present. The image will be displayed at 100% width. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set, the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used and if logo is not set, a color would be chosen by Google. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for an object. This ID must be unique across all objects from an issuer. This value needs to follow the format `issuerID.identifier` where `issuerID` is issued by Google and `identifier` is chosen by you. The unique identifier can only include alphanumeric characters, `.`, `_`, or `-`. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. Only one of the image from class and one from object level will be rendered when both set. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If `linksModuleData` is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from class and 10 from object. + * `logo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The logo image of the pass. This image is displayed in the card detail view in upper left, and also on the list/thumbnail view. If the logo is not present, the first letter of `cardTitle` would be shown as logo. + * `notifications` (*type:* `GoogleApi.WalletObjects.V1.Model.Notifications.t`, *default:* `nil`) - The notification settings that are enabled for this object. + * `passConstraints` (*type:* `GoogleApi.WalletObjects.V1.Model.PassConstraints.t`, *default:* `nil`) - Pass constraints for the object. Includes limiting NFC and screenshot behaviors. + * `rotatingBarcode` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t`, *default:* `nil`) - The rotating barcode settings/details. + * `smartTapRedemptionValue` (*type:* `String.t`, *default:* `nil`) - The value that will be transmitted to a Smart Tap certified terminal over NFC for this object. The class level fields `enableSmartTap` and `redemptionIssuers` must also be set up correctly in order for the pass to support Smart Tap. Only ASCII characters are supported. + * `state` (*type:* `String.t`, *default:* `nil`) - The state of the object. This field is used to determine how an object is displayed in the app. For example, an `inactive` object is moved to the "Expired passes" section. If this is not provided, the object would be considered `ACTIVE`. + * `subheader` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The title label of the pass, such as location where this pass can be used. Appears right above the title in the title row in the pass detail view. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If `textModulesData` is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from class and 10 from object. + * `validTimeInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The time period this object will be considered valid or usable. When the time period is passed, the object will be considered expired, which will affect the rendering on user's devices. + * `wideLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The wide logo of the pass. When provided, this will be used in place of the logo in the top left of the card view. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :appLinkData => GoogleApi.WalletObjects.V1.Model.AppLinkData.t() | nil, + :barcode => GoogleApi.WalletObjects.V1.Model.Barcode.t() | nil, + :cardTitle => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :classId => String.t() | nil, + :genericType => String.t() | nil, + :groupingInfo => GoogleApi.WalletObjects.V1.Model.GroupingInfo.t() | nil, + :hasUsers => boolean() | nil, + :header => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :hexBackgroundColor => String.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :logo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :notifications => GoogleApi.WalletObjects.V1.Model.Notifications.t() | nil, + :passConstraints => GoogleApi.WalletObjects.V1.Model.PassConstraints.t() | nil, + :rotatingBarcode => GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t() | nil, + :smartTapRedemptionValue => String.t() | nil, + :state => String.t() | nil, + :subheader => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :validTimeInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :wideLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil + } + + field(:appLinkData, as: GoogleApi.WalletObjects.V1.Model.AppLinkData) + field(:barcode, as: GoogleApi.WalletObjects.V1.Model.Barcode) + field(:cardTitle, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:classId) + field(:genericType) + field(:groupingInfo, as: GoogleApi.WalletObjects.V1.Model.GroupingInfo) + field(:hasUsers) + field(:header, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:hexBackgroundColor) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:logo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:notifications, as: GoogleApi.WalletObjects.V1.Model.Notifications) + field(:passConstraints, as: GoogleApi.WalletObjects.V1.Model.PassConstraints) + field(:rotatingBarcode, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcode) + field(:smartTapRedemptionValue) + field(:state) + field(:subheader, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:validTimeInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:wideLogo, as: GoogleApi.WalletObjects.V1.Model.Image) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GenericObject do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GenericObject.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GenericObject do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_add_message_response.ex new file mode 100644 index 0000000000..777ce8db2f --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GenericObjectAddMessageResponse do + @moduledoc """ + Response to adding a new issuer message to the object. This contains the entire updated GenericObject. + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.GenericObject.t`, *default:* `nil`) - The updated GenericObject resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.GenericObject.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.GenericObject) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GenericObjectAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GenericObjectAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GenericObjectAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_list_response.ex new file mode 100644 index 0000000000..ab5d432128 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/generic_object_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GenericObjectListResponse do + @moduledoc """ + List response which contains the list of all generic objects for a given issuer ID. + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.GenericObject.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.GenericObject.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.GenericObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GenericObjectListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GenericObjectListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GenericObjectListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class.ex new file mode 100644 index 0000000000..7443aa4443 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class.ex @@ -0,0 +1,155 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GiftCardClass do + @moduledoc """ + + + ## Attributes + + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `merchantName` (*type:* `String.t`, *default:* `nil`) - Merchant name, such as "Adam's Apparel". The app may display an ellipsis after the first 20 characters to ensure full string is displayed on smaller screens. + * `pinLabel` (*type:* `String.t`, *default:* `nil`) - The label to display for the PIN, such as "4-digit PIN". + * `homepageUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URI of your application's home page. Populating the URI in this field results in the exact same behavior as populating an URI in linksModuleData (when an object is rendered, a link to the homepage is shown in what would usually be thought of as the linksModuleData section of the object). + * `wordMark` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Deprecated. + * `countryCode` (*type:* `String.t`, *default:* `nil`) - Country code used to display the card's country (when the user is not in that country), as well as to display localized content when content is not available in the user's locale. + * `classTemplateInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t`, *default:* `nil`) - Template information about how the class should be displayed. If unset, Google will fallback to a default set of fields to display. + * `localizedPinLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the pin_label. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the object, both will be displayed. + * `eventNumberLabel` (*type:* `String.t`, *default:* `nil`) - The label to display for event number, such as "Target Event #". + * `allowBarcodeRedemption` (*type:* `boolean()`, *default:* `nil`) - Determines whether the merchant supports gift card redemption using barcode. If true, app displays a barcode for the gift card on the Gift card details screen. If false, a barcode is not displayed. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#giftCardClass"`. + * `localizedEventNumberLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the event_number_label. + * `localizedIssuerName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the issuer_name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `multipleDevicesAndHoldersAllowedStatus` (*type:* `String.t`, *default:* `nil`) - Identifies whether multiple users and devices will save the same object referencing this class. + * `issuerName` (*type:* `String.t`, *default:* `nil`) - Required. The issuer name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `securityAnimation` (*type:* `GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t`, *default:* `nil`) - Optional information about the security animation. If this is set a security animation will be rendered on pass details. + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Callback options to be used to call the issuer back for every save/delete of an object for this class by the end-user. All objects of this class are eligible for the callback. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + * `viewUnlockRequirement` (*type:* `String.t`, *default:* `nil`) - View Unlock Requirement options for the gift card. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `cardNumberLabel` (*type:* `String.t`, *default:* `nil`) - The label to display for the card number, such as "Card Number". + * `localizedCardNumberLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the card_number_label. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, nothing will be displayed. The image will display at 100% width. + * `wideProgramLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The wide logo of the gift card program or company. When provided, this will be used in place of the program logo in the top left of the card view. + * `programLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The logo of the gift card program or company. This logo is displayed in both the details and list views of the app. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `enableSmartTap` (*type:* `boolean()`, *default:* `nil`) - Identifies whether this class supports Smart Tap. The `redemptionIssuers` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `localizedMerchantName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the merchant_name. The app may display an ellipsis after the first 20 characters to ensure full string is displayed on smaller screens. + * `reviewStatus` (*type:* `String.t`, *default:* `nil`) - Required. The status of the class. This field can be set to `draft` or `underReview` using the insert, patch, or update API calls. Once the review state is changed from `draft` it may not be changed back to `draft`. You should keep this field to `draft` when the class is under development. A `draft` class cannot be used to create any object. You should set this field to `underReview` when you believe the class is ready for use. The platform will automatically set this field to `approved` and it can be immediately used to create or migrate objects. When updating an already `approved` class you should keep setting this field to `underReview`. + * `allowMultipleUsersPerObject` (*type:* `boolean()`, *default:* `nil`) - Deprecated. Use `multipleDevicesAndHoldersAllowedStatus` instead. + * `review` (*type:* `GoogleApi.WalletObjects.V1.Model.Review.t`, *default:* `nil`) - The review comments set by the platform when a class is marked `approved` or `rejected`. + * `redemptionIssuers` (*type:* `list(String.t)`, *default:* `nil`) - Identifies which redemption issuers can redeem the pass over Smart Tap. Redemption issuers are identified by their issuer ID. Redemption issuers must have at least one Smart Tap key configured. The `enableSmartTap` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :merchantName => String.t() | nil, + :pinLabel => String.t() | nil, + :homepageUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil, + :wordMark => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :countryCode => String.t() | nil, + :classTemplateInfo => GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t() | nil, + :localizedPinLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :eventNumberLabel => String.t() | nil, + :allowBarcodeRedemption => boolean() | nil, + :kind => String.t() | nil, + :localizedEventNumberLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :localizedIssuerName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :multipleDevicesAndHoldersAllowedStatus => String.t() | nil, + :issuerName => String.t() | nil, + :hexBackgroundColor => String.t() | nil, + :securityAnimation => GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t() | nil, + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :version => String.t() | nil, + :viewUnlockRequirement => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :cardNumberLabel => String.t() | nil, + :localizedCardNumberLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :wideProgramLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :programLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :enableSmartTap => boolean() | nil, + :localizedMerchantName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :reviewStatus => String.t() | nil, + :allowMultipleUsersPerObject => boolean() | nil, + :review => GoogleApi.WalletObjects.V1.Model.Review.t() | nil, + :redemptionIssuers => list(String.t()) | nil + } + + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:merchantName) + field(:pinLabel) + field(:homepageUri, as: GoogleApi.WalletObjects.V1.Model.Uri) + field(:wordMark, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:countryCode) + field(:classTemplateInfo, as: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo) + field(:localizedPinLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:eventNumberLabel) + field(:allowBarcodeRedemption) + field(:kind) + field(:localizedEventNumberLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:localizedIssuerName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:multipleDevicesAndHoldersAllowedStatus) + field(:issuerName) + field(:hexBackgroundColor) + field(:securityAnimation, as: GoogleApi.WalletObjects.V1.Model.SecurityAnimation) + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:version) + field(:viewUnlockRequirement) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:cardNumberLabel) + field(:localizedCardNumberLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:wideProgramLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:programLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:enableSmartTap) + field(:localizedMerchantName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:reviewStatus) + field(:allowMultipleUsersPerObject) + field(:review, as: GoogleApi.WalletObjects.V1.Model.Review) + field(:redemptionIssuers, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardClass do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GiftCardClass.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardClass do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_add_message_response.ex new file mode 100644 index 0000000000..59f85b1d03 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GiftCardClassAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardClass.t`, *default:* `nil`) - The updated GiftCardClass resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.GiftCardClass.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.GiftCardClass) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardClassAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GiftCardClassAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardClassAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_list_response.ex new file mode 100644 index 0000000000..b17a544977 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_class_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GiftCardClassListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.GiftCardClass.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.GiftCardClass.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.GiftCardClass, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardClassListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GiftCardClassListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardClassListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object.ex new file mode 100644 index 0000000000..5d7dcef16e --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object.ex @@ -0,0 +1,127 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GiftCardObject do + @moduledoc """ + + + ## Attributes + + * `appLinkData` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkData.t`, *default:* `nil`) - Optional information about the partner app link. + * `balance` (*type:* `GoogleApi.WalletObjects.V1.Model.Money.t`, *default:* `nil`) - The card's monetary balance. + * `balanceUpdateTime` (*type:* `GoogleApi.WalletObjects.V1.Model.DateTime.t`, *default:* `nil`) - The date and time when the balance was last updated. Offset is required. If balance is updated and this property is not provided, system will default to the current time. + * `barcode` (*type:* `GoogleApi.WalletObjects.V1.Model.Barcode.t`, *default:* `nil`) - The barcode type and value. + * `cardNumber` (*type:* `String.t`, *default:* `nil`) - Required. The card's number. + * `classId` (*type:* `String.t`, *default:* `nil`) - Required. The class associated with this object. The class must be of the same type as this object, must already exist, and must be approved. Class IDs should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. + * `classReference` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardClass.t`, *default:* `nil`) - A copy of the inherited fields of the parent class. These fields are retrieved during a GET. + * `disableExpirationNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if notifications should explicitly be suppressed. If this field is set to true, regardless of the `messages` field, expiration notifications to the user will be suppressed. By default, this field is set to false. Currently, this can only be set for offers. + * `eventNumber` (*type:* `String.t`, *default:* `nil`) - The card's event number, an optional field used by some gift cards. + * `groupingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.GroupingInfo.t`, *default:* `nil`) - Information that controls how passes are grouped together. + * `hasLinkedDevice` (*type:* `boolean()`, *default:* `nil`) - Whether this object is currently linked to a single device. This field is set by the platform when a user saves the object, linking it to their device. Intended for use by select partners. Contact support for additional information. + * `hasUsers` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object has users. This field is set by the platform. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, hero image of the class, if present, will be displayed. If hero image of the class is also not present, nothing will be displayed. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. The unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#giftCardObject"`. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the class, both will be displayed. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `passConstraints` (*type:* `GoogleApi.WalletObjects.V1.Model.PassConstraints.t`, *default:* `nil`) - Pass constraints for the object. Includes limiting NFC and screenshot behaviors. + * `pin` (*type:* `String.t`, *default:* `nil`) - The card's PIN. + * `rotatingBarcode` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t`, *default:* `nil`) - The rotating barcode type and value. + * `smartTapRedemptionValue` (*type:* `String.t`, *default:* `nil`) - The value that will be transmitted to a Smart Tap certified terminal over NFC for this object. The class level fields `enableSmartTap` and `redemptionIssuers` must also be set up correctly in order for the pass to support Smart Tap. Only ASCII characters are supported. + * `state` (*type:* `String.t`, *default:* `nil`) - Required. The state of the object. This field is used to determine how an object is displayed in the app. For example, an `inactive` object is moved to the "Expired passes" section. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `validTimeInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The time period this object will be `active` and object can be used. An object's state will be changed to `expired` when this time period has passed. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :appLinkData => GoogleApi.WalletObjects.V1.Model.AppLinkData.t() | nil, + :balance => GoogleApi.WalletObjects.V1.Model.Money.t() | nil, + :balanceUpdateTime => GoogleApi.WalletObjects.V1.Model.DateTime.t() | nil, + :barcode => GoogleApi.WalletObjects.V1.Model.Barcode.t() | nil, + :cardNumber => String.t() | nil, + :classId => String.t() | nil, + :classReference => GoogleApi.WalletObjects.V1.Model.GiftCardClass.t() | nil, + :disableExpirationNotification => boolean() | nil, + :eventNumber => String.t() | nil, + :groupingInfo => GoogleApi.WalletObjects.V1.Model.GroupingInfo.t() | nil, + :hasLinkedDevice => boolean() | nil, + :hasUsers => boolean() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :kind => String.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :passConstraints => GoogleApi.WalletObjects.V1.Model.PassConstraints.t() | nil, + :pin => String.t() | nil, + :rotatingBarcode => GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t() | nil, + :smartTapRedemptionValue => String.t() | nil, + :state => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :validTimeInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :version => String.t() | nil + } + + field(:appLinkData, as: GoogleApi.WalletObjects.V1.Model.AppLinkData) + field(:balance, as: GoogleApi.WalletObjects.V1.Model.Money) + field(:balanceUpdateTime, as: GoogleApi.WalletObjects.V1.Model.DateTime) + field(:barcode, as: GoogleApi.WalletObjects.V1.Model.Barcode) + field(:cardNumber) + field(:classId) + field(:classReference, as: GoogleApi.WalletObjects.V1.Model.GiftCardClass) + field(:disableExpirationNotification) + field(:eventNumber) + field(:groupingInfo, as: GoogleApi.WalletObjects.V1.Model.GroupingInfo) + field(:hasLinkedDevice) + field(:hasUsers) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:kind) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:passConstraints, as: GoogleApi.WalletObjects.V1.Model.PassConstraints) + field(:pin) + field(:rotatingBarcode, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcode) + field(:smartTapRedemptionValue) + field(:state) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:validTimeInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:version) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardObject do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GiftCardObject.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardObject do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_add_message_response.ex new file mode 100644 index 0000000000..adb919d129 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GiftCardObjectAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.GiftCardObject.t`, *default:* `nil`) - The updated GiftCardObject resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.GiftCardObject.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.GiftCardObject) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardObjectAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GiftCardObjectAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardObjectAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_list_response.ex new file mode 100644 index 0000000000..83b6f5ad90 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/gift_card_object_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GiftCardObjectListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.GiftCardObject.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.GiftCardObject.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.GiftCardObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardObjectListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GiftCardObjectListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GiftCardObjectListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/grouping_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/grouping_info.ex new file mode 100644 index 0000000000..038ab98b8b --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/grouping_info.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.GroupingInfo do + @moduledoc """ + + + ## Attributes + + * `groupingId` (*type:* `String.t`, *default:* `nil`) - Optional grouping ID for grouping the passes with the same ID visually together. Grouping with different types of passes is allowed. + * `sortIndex` (*type:* `integer()`, *default:* `nil`) - Optional index for sorting the passes when they are grouped with other passes. Passes with lower sort index are shown before passes with higher sort index. If unspecified, the value is assumed to be INT_MAX. For two passes with the same sort index, the sorting behavior is undefined. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :groupingId => String.t() | nil, + :sortIndex => integer() | nil + } + + field(:groupingId) + field(:sortIndex) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.GroupingInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.GroupingInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.GroupingInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image.ex new file mode 100644 index 0000000000..82e7234010 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Image do + @moduledoc """ + Wrapping type for Google hosted images. Next ID: 7 + + ## Attributes + + * `contentDescription` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Description of the image used for accessibility. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#image"`. + * `sourceUri` (*type:* `GoogleApi.WalletObjects.V1.Model.ImageUri.t`, *default:* `nil`) - The URI for the image. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :contentDescription => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :kind => String.t() | nil, + :sourceUri => GoogleApi.WalletObjects.V1.Model.ImageUri.t() | nil + } + + field(:contentDescription, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:kind) + field(:sourceUri, as: GoogleApi.WalletObjects.V1.Model.ImageUri) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Image do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Image.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Image do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_module_data.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_module_data.ex new file mode 100644 index 0000000000..db381d7a71 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_module_data.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ImageModuleData do + @moduledoc """ + + + ## Attributes + + * `id` (*type:* `String.t`, *default:* `nil`) - The ID associated with an image module. This field is here to enable ease of management of image modules. + * `mainImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - A 100% width image. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :id => String.t() | nil, + :mainImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil + } + + field(:id) + field(:mainImage, as: GoogleApi.WalletObjects.V1.Model.Image) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ImageModuleData do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ImageModuleData.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ImageModuleData do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_uri.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_uri.ex new file mode 100644 index 0000000000..e41838edf4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/image_uri.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ImageUri do + @moduledoc """ + + + ## Attributes + + * `description` (*type:* `String.t`, *default:* `nil`) - Additional information about the image, which is unused and retained only for backward compatibility. + * `localizedDescription` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the description, which are unused and retained only for backward compatibility. + * `uri` (*type:* `String.t`, *default:* `nil`) - The location of the image. URIs must have a scheme. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :description => String.t() | nil, + :localizedDescription => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :uri => String.t() | nil + } + + field(:description) + field(:localizedDescription, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:uri) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ImageUri do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ImageUri.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ImageUri do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/info_module_data.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/info_module_data.ex new file mode 100644 index 0000000000..9fa4dc7e20 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/info_module_data.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.InfoModuleData do + @moduledoc """ + + + ## Attributes + + * `labelValueRows` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LabelValueRow.t)`, *default:* `nil`) - A list of collections of labels and values. These will be displayed one after the other in a singular column. + * `showLastUpdateTime` (*type:* `boolean()`, *default:* `nil`) - + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :labelValueRows => list(GoogleApi.WalletObjects.V1.Model.LabelValueRow.t()) | nil, + :showLastUpdateTime => boolean() | nil + } + + field(:labelValueRows, as: GoogleApi.WalletObjects.V1.Model.LabelValueRow, type: :list) + field(:showLastUpdateTime) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.InfoModuleData do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.InfoModuleData.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.InfoModuleData do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer.ex new file mode 100644 index 0000000000..a6189f3c2e --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Issuer do + @moduledoc """ + + + ## Attributes + + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Allows the issuer to provide their callback settings. + * `contactInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.IssuerContactInfo.t`, *default:* `nil`) - Issuer contact information. + * `homepageUrl` (*type:* `String.t`, *default:* `nil`) - URL for the issuer's home page. + * `issuerId` (*type:* `String.t`, *default:* `nil`) - The unique identifier for an issuer account. This is automatically generated when the issuer is inserted. + * `name` (*type:* `String.t`, *default:* `nil`) - The account name of the issuer. + * `smartTapMerchantData` (*type:* `GoogleApi.WalletObjects.V1.Model.SmartTapMerchantData.t`, *default:* `nil`) - Available only to Smart Tap enabled partners. Contact support for additional guidance. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :contactInfo => GoogleApi.WalletObjects.V1.Model.IssuerContactInfo.t() | nil, + :homepageUrl => String.t() | nil, + :issuerId => String.t() | nil, + :name => String.t() | nil, + :smartTapMerchantData => GoogleApi.WalletObjects.V1.Model.SmartTapMerchantData.t() | nil + } + + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:contactInfo, as: GoogleApi.WalletObjects.V1.Model.IssuerContactInfo) + field(:homepageUrl) + field(:issuerId) + field(:name) + field(:smartTapMerchantData, as: GoogleApi.WalletObjects.V1.Model.SmartTapMerchantData) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Issuer do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Issuer.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Issuer do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_contact_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_contact_info.ex new file mode 100644 index 0000000000..0077e6734f --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_contact_info.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.IssuerContactInfo do + @moduledoc """ + + + ## Attributes + + * `alertsEmails` (*type:* `list(String.t)`, *default:* `nil`) - Email addresses which will receive alerts. + * `email` (*type:* `String.t`, *default:* `nil`) - The primary contact email address. + * `name` (*type:* `String.t`, *default:* `nil`) - The primary contact name. + * `phone` (*type:* `String.t`, *default:* `nil`) - The primary contact phone number. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :alertsEmails => list(String.t()) | nil, + :email => String.t() | nil, + :name => String.t() | nil, + :phone => String.t() | nil + } + + field(:alertsEmails, type: :list) + field(:email) + field(:name) + field(:phone) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.IssuerContactInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.IssuerContactInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.IssuerContactInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_list_response.ex new file mode 100644 index 0000000000..21eea7be51 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_list_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.IssuerListResponse do + @moduledoc """ + + + ## Attributes + + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Issuer.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resources => list(GoogleApi.WalletObjects.V1.Model.Issuer.t()) | nil + } + + field(:resources, as: GoogleApi.WalletObjects.V1.Model.Issuer, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.IssuerListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.IssuerListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.IssuerListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_to_user_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_to_user_info.ex new file mode 100644 index 0000000000..f1e207ccfe --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/issuer_to_user_info.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.IssuerToUserInfo do + @moduledoc """ + + + ## Attributes + + * `action` (*type:* `String.t`, *default:* `nil`) - + * `signUpInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.SignUpInfo.t`, *default:* `nil`) - + * `url` (*type:* `String.t`, *default:* `nil`) - Currently not used, consider deprecating. + * `value` (*type:* `String.t`, *default:* `nil`) - JSON web token for action S2AP. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :action => String.t() | nil, + :signUpInfo => GoogleApi.WalletObjects.V1.Model.SignUpInfo.t() | nil, + :url => String.t() | nil, + :value => String.t() | nil + } + + field(:action) + field(:signUpInfo, as: GoogleApi.WalletObjects.V1.Model.SignUpInfo) + field(:url) + field(:value) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.IssuerToUserInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.IssuerToUserInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.IssuerToUserInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_insert_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_insert_response.ex new file mode 100644 index 0000000000..261f1ca89c --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_insert_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.JwtInsertResponse do + @moduledoc """ + + + ## Attributes + + * `resources` (*type:* `GoogleApi.WalletObjects.V1.Model.Resources.t`, *default:* `nil`) - Data that corresponds to the ids of the provided classes and objects in the JWT. resources will only include the non-empty arrays (i.e. if the JWT only includes eventTicketObjects, then that is the only field that will be present in resources). + * `saveUri` (*type:* `String.t`, *default:* `nil`) - A URI that, when opened, will allow the end user to save the object(s) identified in the JWT to their Google account. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resources => GoogleApi.WalletObjects.V1.Model.Resources.t() | nil, + :saveUri => String.t() | nil + } + + field(:resources, as: GoogleApi.WalletObjects.V1.Model.Resources) + field(:saveUri) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.JwtInsertResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.JwtInsertResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.JwtInsertResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_resource.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_resource.ex new file mode 100644 index 0000000000..d57ad07790 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/jwt_resource.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.JwtResource do + @moduledoc """ + + + ## Attributes + + * `jwt` (*type:* `String.t`, *default:* `nil`) - A string representing a JWT of the format described at https://developers.google.com/wallet/reference/rest/v1/Jwt + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :jwt => String.t() | nil + } + + field(:jwt) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.JwtResource do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.JwtResource.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.JwtResource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value.ex new file mode 100644 index 0000000000..2605d34e94 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LabelValue do + @moduledoc """ + A pair of text strings to be displayed in the details view. Note we no longer display LabelValue/LabelValueRow as a table, instead a list of items. + + ## Attributes + + * `label` (*type:* `String.t`, *default:* `nil`) - The label for a specific row and column. Recommended maximum is 15 characters for a two-column layout and 30 characters for a one-column layout. + * `localizedLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the label. Recommended maximum is 15 characters for a two-column layout and 30 characters for a one-column layout. + * `localizedValue` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the value. Recommended maximum is 15 characters for a two-column layout and 30 characters for a one-column layout. + * `value` (*type:* `String.t`, *default:* `nil`) - The value for a specific row and column. Recommended maximum is 15 characters for a two-column layout and 30 characters for a one-column layout. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :label => String.t() | nil, + :localizedLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :localizedValue => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :value => String.t() | nil + } + + field(:label) + field(:localizedLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:localizedValue, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:value) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LabelValue do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LabelValue.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LabelValue do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value_row.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value_row.ex new file mode 100644 index 0000000000..ff1876d343 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/label_value_row.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LabelValueRow do + @moduledoc """ + + + ## Attributes + + * `columns` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LabelValue.t)`, *default:* `nil`) - A list of labels and values. These will be displayed in a singular column, one after the other, not in multiple columns, despite the field name. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :columns => list(GoogleApi.WalletObjects.V1.Model.LabelValue.t()) | nil + } + + field(:columns, as: GoogleApi.WalletObjects.V1.Model.LabelValue, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LabelValueRow do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LabelValueRow.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LabelValueRow do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/lat_long_point.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/lat_long_point.ex new file mode 100644 index 0000000000..7898a96e36 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/lat_long_point.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LatLongPoint do + @moduledoc """ + + + ## Attributes + + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#latLongPoint"`. + * `latitude` (*type:* `float()`, *default:* `nil`) - The latitude specified as any value in the range of -90.0 through +90.0, both inclusive. Values outside these bounds will be rejected. + * `longitude` (*type:* `float()`, *default:* `nil`) - The longitude specified in the range -180.0 through +180.0, both inclusive. Values outside these bounds will be rejected. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kind => String.t() | nil, + :latitude => float() | nil, + :longitude => float() | nil + } + + field(:kind) + field(:latitude) + field(:longitude) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LatLongPoint do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LatLongPoint.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LatLongPoint do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/links_module_data.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/links_module_data.ex new file mode 100644 index 0000000000..8f7bf27f26 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/links_module_data.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LinksModuleData do + @moduledoc """ + + + ## Attributes + + * `uris` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Uri.t)`, *default:* `nil`) - The list of URIs. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :uris => list(GoogleApi.WalletObjects.V1.Model.Uri.t()) | nil + } + + field(:uris, as: GoogleApi.WalletObjects.V1.Model.Uri, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LinksModuleData do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LinksModuleData.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LinksModuleData do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/list_template_override.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/list_template_override.ex new file mode 100644 index 0000000000..f53f6c8405 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/list_template_override.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ListTemplateOverride do + @moduledoc """ + + + ## Attributes + + * `firstRowOption` (*type:* `GoogleApi.WalletObjects.V1.Model.FirstRowOption.t`, *default:* `nil`) - Specifies from a predefined set of options or from a reference to the field what will be displayed in the first row. To set this override, set the FirstRowOption.fieldOption to the FieldSelector of your choice. + * `secondRowOption` (*type:* `GoogleApi.WalletObjects.V1.Model.FieldSelector.t`, *default:* `nil`) - A reference to the field to be displayed in the second row. This option is only displayed if there are not multiple user objects in a group. If there is a group, the second row will always display a field shared by all objects. To set this override, please set secondRowOption to the FieldSelector of you choice. + * `thirdRowOption` (*type:* `GoogleApi.WalletObjects.V1.Model.FieldSelector.t`, *default:* `nil`) - An unused/deprecated field. Setting it will have no effect on what the user sees. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :firstRowOption => GoogleApi.WalletObjects.V1.Model.FirstRowOption.t() | nil, + :secondRowOption => GoogleApi.WalletObjects.V1.Model.FieldSelector.t() | nil, + :thirdRowOption => GoogleApi.WalletObjects.V1.Model.FieldSelector.t() | nil + } + + field(:firstRowOption, as: GoogleApi.WalletObjects.V1.Model.FirstRowOption) + field(:secondRowOption, as: GoogleApi.WalletObjects.V1.Model.FieldSelector) + field(:thirdRowOption, as: GoogleApi.WalletObjects.V1.Model.FieldSelector) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ListTemplateOverride do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ListTemplateOverride.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ListTemplateOverride do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/localized_string.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/localized_string.ex new file mode 100644 index 0000000000..69ead23066 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/localized_string.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LocalizedString do + @moduledoc """ + + + ## Attributes + + * `defaultValue` (*type:* `GoogleApi.WalletObjects.V1.Model.TranslatedString.t`, *default:* `nil`) - Contains the string to be displayed if no appropriate translation is available. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#localizedString"`. + * `translatedValues` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TranslatedString.t)`, *default:* `nil`) - Contains the translations for the string. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :defaultValue => GoogleApi.WalletObjects.V1.Model.TranslatedString.t() | nil, + :kind => String.t() | nil, + :translatedValues => list(GoogleApi.WalletObjects.V1.Model.TranslatedString.t()) | nil + } + + field(:defaultValue, as: GoogleApi.WalletObjects.V1.Model.TranslatedString) + field(:kind) + field(:translatedValues, as: GoogleApi.WalletObjects.V1.Model.TranslatedString, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LocalizedString do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LocalizedString.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LocalizedString do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class.ex new file mode 100644 index 0000000000..56b5d8e713 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class.ex @@ -0,0 +1,176 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyClass do + @moduledoc """ + + + ## Attributes + + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `localizedRewardsTier` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the rewards_tier. Recommended maximum length is 7 characters to ensure full string is displayed on smaller screens. + * `homepageUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URI of your application's home page. Populating the URI in this field results in the exact same behavior as populating an URI in linksModuleData (when an object is rendered, a link to the homepage is shown in what would usually be thought of as the linksModuleData section of the object). + * `wordMark` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Deprecated. + * `countryCode` (*type:* `String.t`, *default:* `nil`) - Country code used to display the card's country (when the user is not in that country), as well as to display localized content when content is not available in the user's locale. + * `classTemplateInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t`, *default:* `nil`) - Template information about how the class should be displayed. If unset, Google will fallback to a default set of fields to display. + * `localizedSecondaryRewardsTierLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the secondary_rewards_tier_label. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the object, both will be displayed. + * `localizedRewardsTierLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the rewards_tier_label. Recommended maximum length is 9 characters to ensure full string is displayed on smaller screens. + * `localizedProgramName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the program_name. The app may display an ellipsis after the first 20 characters to ensure full string is displayed on smaller screens. + * `rewardsTier` (*type:* `String.t`, *default:* `nil`) - The rewards tier, such as "Gold" or "Platinum." Recommended maximum length is 7 characters to ensure full string is displayed on smaller screens. + * `localizedAccountNameLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the account_name_label. Recommended maximum length is 15 characters to ensure full string is displayed on smaller screens. + * `rewardsTierLabel` (*type:* `String.t`, *default:* `nil`) - The rewards tier label, such as "Rewards Tier." Recommended maximum length is 9 characters to ensure full string is displayed on smaller screens. + * `localizedSecondaryRewardsTier` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the secondary_rewards_tier. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#loyaltyClass"`. + * `localizedIssuerName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the issuer_name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `multipleDevicesAndHoldersAllowedStatus` (*type:* `String.t`, *default:* `nil`) - Identifies whether multiple users and devices will save the same object referencing this class. + * `localizedAccountIdLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the account_id_label. Recommended maximum length is 15 characters to ensure full string is displayed on smaller screens. + * `issuerName` (*type:* `String.t`, *default:* `nil`) - Required. The issuer name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `securityAnimation` (*type:* `GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t`, *default:* `nil`) - Optional information about the security animation. If this is set a security animation will be rendered on pass details. + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Callback options to be used to call the issuer back for every save/delete of an object for this class by the end-user. All objects of this class are eligible for the callback. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + * `secondaryRewardsTier` (*type:* `String.t`, *default:* `nil`) - The secondary rewards tier, such as "Gold" or "Platinum." + * `accountIdLabel` (*type:* `String.t`, *default:* `nil`) - The account ID label, such as "Member ID." Recommended maximum length is 15 characters to ensure full string is displayed on smaller screens. + * `viewUnlockRequirement` (*type:* `String.t`, *default:* `nil`) - View Unlock Requirement options for the loyalty card. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `secondaryRewardsTierLabel` (*type:* `String.t`, *default:* `nil`) - The secondary rewards tier label, such as "Rewards Tier." + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `programName` (*type:* `String.t`, *default:* `nil`) - Required. The program name, such as "Adam's Apparel". The app may display an ellipsis after the first 20 characters to ensure full string is displayed on smaller screens. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, nothing will be displayed. The image will display at 100% width. + * `wideProgramLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The wide logo of the loyalty program or company. When provided, this will be used in place of the program logo in the top left of the card view. + * `programLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Required. The logo of the loyalty program or company. This logo is displayed in both the details and list views of the app. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `discoverableProgram` (*type:* `GoogleApi.WalletObjects.V1.Model.DiscoverableProgram.t`, *default:* `nil`) - Information about how the class may be discovered and instantiated from within the Google Pay app. + * `enableSmartTap` (*type:* `boolean()`, *default:* `nil`) - Identifies whether this class supports Smart Tap. The `redemptionIssuers` and one of object level `smartTapRedemptionLevel`, barcode.value`, or `accountId` fields must also be set up correctly in order for a pass to support Smart Tap. + * `reviewStatus` (*type:* `String.t`, *default:* `nil`) - Required. The status of the class. This field can be set to `draft` or `underReview` using the insert, patch, or update API calls. Once the review state is changed from `draft` it may not be changed back to `draft`. You should keep this field to `draft` when the class is under development. A `draft` class cannot be used to create any object. You should set this field to `underReview` when you believe the class is ready for use. The platform will automatically set this field to `approved` and it can be immediately used to create or migrate objects. When updating an already `approved` class you should keep setting this field to `underReview`. + * `allowMultipleUsersPerObject` (*type:* `boolean()`, *default:* `nil`) - Deprecated. Use `multipleDevicesAndHoldersAllowedStatus` instead. + * `review` (*type:* `GoogleApi.WalletObjects.V1.Model.Review.t`, *default:* `nil`) - The review comments set by the platform when a class is marked `approved` or `rejected`. + * `redemptionIssuers` (*type:* `list(String.t)`, *default:* `nil`) - Identifies which redemption issuers can redeem the pass over Smart Tap. Redemption issuers are identified by their issuer ID. Redemption issuers must have at least one Smart Tap key configured. The `enableSmartTap` and one of object level `smartTapRedemptionValue`, barcode.value`, or `accountId` fields must also be set up correctly in order for a pass to support Smart Tap. + * `accountNameLabel` (*type:* `String.t`, *default:* `nil`) - The account name label, such as "Member Name." Recommended maximum length is 15 characters to ensure full string is displayed on smaller screens. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :localizedRewardsTier => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :homepageUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil, + :wordMark => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :countryCode => String.t() | nil, + :classTemplateInfo => GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t() | nil, + :localizedSecondaryRewardsTierLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :localizedRewardsTierLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :localizedProgramName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :rewardsTier => String.t() | nil, + :localizedAccountNameLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :rewardsTierLabel => String.t() | nil, + :localizedSecondaryRewardsTier => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :kind => String.t() | nil, + :localizedIssuerName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :multipleDevicesAndHoldersAllowedStatus => String.t() | nil, + :localizedAccountIdLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :issuerName => String.t() | nil, + :hexBackgroundColor => String.t() | nil, + :securityAnimation => GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t() | nil, + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :version => String.t() | nil, + :secondaryRewardsTier => String.t() | nil, + :accountIdLabel => String.t() | nil, + :viewUnlockRequirement => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :secondaryRewardsTierLabel => String.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :programName => String.t() | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :wideProgramLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :programLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :discoverableProgram => GoogleApi.WalletObjects.V1.Model.DiscoverableProgram.t() | nil, + :enableSmartTap => boolean() | nil, + :reviewStatus => String.t() | nil, + :allowMultipleUsersPerObject => boolean() | nil, + :review => GoogleApi.WalletObjects.V1.Model.Review.t() | nil, + :redemptionIssuers => list(String.t()) | nil, + :accountNameLabel => String.t() | nil + } + + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:localizedRewardsTier, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:homepageUri, as: GoogleApi.WalletObjects.V1.Model.Uri) + field(:wordMark, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:countryCode) + field(:classTemplateInfo, as: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo) + field(:localizedSecondaryRewardsTierLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:localizedRewardsTierLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:localizedProgramName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:rewardsTier) + field(:localizedAccountNameLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:rewardsTierLabel) + field(:localizedSecondaryRewardsTier, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:kind) + field(:localizedIssuerName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:multipleDevicesAndHoldersAllowedStatus) + field(:localizedAccountIdLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:issuerName) + field(:hexBackgroundColor) + field(:securityAnimation, as: GoogleApi.WalletObjects.V1.Model.SecurityAnimation) + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:version) + field(:secondaryRewardsTier) + field(:accountIdLabel) + field(:viewUnlockRequirement) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:secondaryRewardsTierLabel) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:programName) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:wideProgramLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:programLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:discoverableProgram, as: GoogleApi.WalletObjects.V1.Model.DiscoverableProgram) + field(:enableSmartTap) + field(:reviewStatus) + field(:allowMultipleUsersPerObject) + field(:review, as: GoogleApi.WalletObjects.V1.Model.Review) + field(:redemptionIssuers, type: :list) + field(:accountNameLabel) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyClass do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyClass.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyClass do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_add_message_response.ex new file mode 100644 index 0000000000..9c3bef1290 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyClassAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t`, *default:* `nil`) - The updated LoyaltyClass resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.LoyaltyClass) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyClassAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyClassAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyClassAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_list_response.ex new file mode 100644 index 0000000000..b23286a9bd --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_class_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyClassListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.LoyaltyClass, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyClassListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyClassListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyClassListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object.ex new file mode 100644 index 0000000000..e0e574e616 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object.ex @@ -0,0 +1,127 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyObject do + @moduledoc """ + + + ## Attributes + + * `accountId` (*type:* `String.t`, *default:* `nil`) - The loyalty account identifier. Recommended maximum length is 20 characters. + * `accountName` (*type:* `String.t`, *default:* `nil`) - The loyalty account holder name, such as "John Smith." Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `appLinkData` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkData.t`, *default:* `nil`) - Optional information about the partner app link. + * `barcode` (*type:* `GoogleApi.WalletObjects.V1.Model.Barcode.t`, *default:* `nil`) - The barcode type and value. + * `classId` (*type:* `String.t`, *default:* `nil`) - Required. The class associated with this object. The class must be of the same type as this object, must already exist, and must be approved. Class IDs should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. + * `classReference` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t`, *default:* `nil`) - A copy of the inherited fields of the parent class. These fields are retrieved during a GET. + * `disableExpirationNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if notifications should explicitly be suppressed. If this field is set to true, regardless of the `messages` field, expiration notifications to the user will be suppressed. By default, this field is set to false. Currently, this can only be set for offers. + * `groupingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.GroupingInfo.t`, *default:* `nil`) - Information that controls how passes are grouped together. + * `hasLinkedDevice` (*type:* `boolean()`, *default:* `nil`) - Whether this object is currently linked to a single device. This field is set by the platform when a user saves the object, linking it to their device. Intended for use by select partners. Contact support for additional information. + * `hasUsers` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object has users. This field is set by the platform. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, hero image of the class, if present, will be displayed. If hero image of the class is also not present, nothing will be displayed. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. The unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#loyaltyObject"`. + * `linkedOfferIds` (*type:* `list(String.t)`, *default:* `nil`) - A list of offer objects linked to this loyalty card. The offer objects must already exist. Offer object IDs should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the class, both will be displayed. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `loyaltyPoints` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyPoints.t`, *default:* `nil`) - The loyalty reward points label, balance, and type. + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `passConstraints` (*type:* `GoogleApi.WalletObjects.V1.Model.PassConstraints.t`, *default:* `nil`) - Pass constraints for the object. Includes limiting NFC and screenshot behaviors. + * `rotatingBarcode` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t`, *default:* `nil`) - The rotating barcode type and value. + * `secondaryLoyaltyPoints` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyPoints.t`, *default:* `nil`) - The secondary loyalty reward points label, balance, and type. Shown in addition to the primary loyalty points. + * `smartTapRedemptionValue` (*type:* `String.t`, *default:* `nil`) - The value that will be transmitted to a Smart Tap certified terminal over NFC for this object. The class level fields `enableSmartTap` and `redemptionIssuers` must also be set up correctly in order for the pass to support Smart Tap. Only ASCII characters are supported. If this value is not set but the class level fields `enableSmartTap` and `redemptionIssuers` are set up correctly, the `barcode.value` or the `accountId` fields are used as fallback if present. + * `state` (*type:* `String.t`, *default:* `nil`) - Required. The state of the object. This field is used to determine how an object is displayed in the app. For example, an `inactive` object is moved to the "Expired passes" section. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `validTimeInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The time period this object will be `active` and object can be used. An object's state will be changed to `expired` when this time period has passed. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :accountId => String.t() | nil, + :accountName => String.t() | nil, + :appLinkData => GoogleApi.WalletObjects.V1.Model.AppLinkData.t() | nil, + :barcode => GoogleApi.WalletObjects.V1.Model.Barcode.t() | nil, + :classId => String.t() | nil, + :classReference => GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t() | nil, + :disableExpirationNotification => boolean() | nil, + :groupingInfo => GoogleApi.WalletObjects.V1.Model.GroupingInfo.t() | nil, + :hasLinkedDevice => boolean() | nil, + :hasUsers => boolean() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :kind => String.t() | nil, + :linkedOfferIds => list(String.t()) | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :loyaltyPoints => GoogleApi.WalletObjects.V1.Model.LoyaltyPoints.t() | nil, + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :passConstraints => GoogleApi.WalletObjects.V1.Model.PassConstraints.t() | nil, + :rotatingBarcode => GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t() | nil, + :secondaryLoyaltyPoints => GoogleApi.WalletObjects.V1.Model.LoyaltyPoints.t() | nil, + :smartTapRedemptionValue => String.t() | nil, + :state => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :validTimeInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :version => String.t() | nil + } + + field(:accountId) + field(:accountName) + field(:appLinkData, as: GoogleApi.WalletObjects.V1.Model.AppLinkData) + field(:barcode, as: GoogleApi.WalletObjects.V1.Model.Barcode) + field(:classId) + field(:classReference, as: GoogleApi.WalletObjects.V1.Model.LoyaltyClass) + field(:disableExpirationNotification) + field(:groupingInfo, as: GoogleApi.WalletObjects.V1.Model.GroupingInfo) + field(:hasLinkedDevice) + field(:hasUsers) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:kind) + field(:linkedOfferIds, type: :list) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:loyaltyPoints, as: GoogleApi.WalletObjects.V1.Model.LoyaltyPoints) + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:passConstraints, as: GoogleApi.WalletObjects.V1.Model.PassConstraints) + field(:rotatingBarcode, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcode) + field(:secondaryLoyaltyPoints, as: GoogleApi.WalletObjects.V1.Model.LoyaltyPoints) + field(:smartTapRedemptionValue) + field(:state) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:validTimeInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:version) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyObject do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyObject.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyObject do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_add_message_response.ex new file mode 100644 index 0000000000..30dfecd3f7 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyObjectAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t`, *default:* `nil`) - The updated LoyaltyObject resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.LoyaltyObject) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyObjectAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyObjectAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyObjectAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_list_response.ex new file mode 100644 index 0000000000..70f3d3b341 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_object_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyObjectListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.LoyaltyObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyObjectListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyObjectListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyObjectListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points.ex new file mode 100644 index 0000000000..d8aa0e5ac7 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyPoints do + @moduledoc """ + + + ## Attributes + + * `balance` (*type:* `GoogleApi.WalletObjects.V1.Model.LoyaltyPointsBalance.t`, *default:* `nil`) - The account holder's loyalty point balance, such as "500" or "$10.00". Recommended maximum length is 7 characters. This is a required field of `loyaltyPoints` and `secondaryLoyaltyPoints`. + * `label` (*type:* `String.t`, *default:* `nil`) - The loyalty points label, such as "Points". Recommended maximum length is 9 characters. + * `localizedLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the label. Recommended maximum length is 9 characters. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :balance => GoogleApi.WalletObjects.V1.Model.LoyaltyPointsBalance.t() | nil, + :label => String.t() | nil, + :localizedLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:balance, as: GoogleApi.WalletObjects.V1.Model.LoyaltyPointsBalance) + field(:label) + field(:localizedLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyPoints do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyPoints.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyPoints do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points_balance.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points_balance.ex new file mode 100644 index 0000000000..49f8957176 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/loyalty_points_balance.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.LoyaltyPointsBalance do + @moduledoc """ + + + ## Attributes + + * `double` (*type:* `float()`, *default:* `nil`) - The double form of a balance. Only one of these subtypes (string, int, double, money) should be populated. + * `int` (*type:* `integer()`, *default:* `nil`) - The integer form of a balance. Only one of these subtypes (string, int, double, money) should be populated. + * `money` (*type:* `GoogleApi.WalletObjects.V1.Model.Money.t`, *default:* `nil`) - The money form of a balance. Only one of these subtypes (string, int, double, money) should be populated. + * `string` (*type:* `String.t`, *default:* `nil`) - The string form of a balance. Only one of these subtypes (string, int, double, money) should be populated. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :double => float() | nil, + :int => integer() | nil, + :money => GoogleApi.WalletObjects.V1.Model.Money.t() | nil, + :string => String.t() | nil + } + + field(:double) + field(:int) + field(:money, as: GoogleApi.WalletObjects.V1.Model.Money) + field(:string) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyPointsBalance do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.LoyaltyPointsBalance.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.LoyaltyPointsBalance do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media.ex new file mode 100644 index 0000000000..26ff9f41f7 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media.ex @@ -0,0 +1,135 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Media do + @moduledoc """ + A reference to data stored on the filesystem, on GFS or in blobstore. + + ## Attributes + + * `algorithm` (*type:* `String.t`, *default:* `nil`) - Deprecated, use one of explicit hash type fields instead. Algorithm used for calculating the hash. As of 2011/01/21, "MD5" is the only possible value for this field. New values may be added at any time. + * `bigstoreObjectRef` (*type:* `String.t`, *default:* `nil`) - Use object_id instead. + * `blobRef` (*type:* `String.t`, *default:* `nil`) - Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef. + * `blobstore2Info` (*type:* `GoogleApi.WalletObjects.V1.Model.Blobstore2Info.t`, *default:* `nil`) - Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob. + * `compositeMedia` (*type:* `list(GoogleApi.WalletObjects.V1.Model.CompositeMedia.t)`, *default:* `nil`) - A composite media composed of one or more media objects, set if reference_type is COMPOSITE_MEDIA. The media length field must be set to the sum of the lengths of all composite media objects. Note: All composite media must have length specified. + * `contentType` (*type:* `String.t`, *default:* `nil`) - MIME type of the data + * `contentTypeInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ContentTypeInfo.t`, *default:* `nil`) - Extended content type information provided for Scotty uploads. + * `cosmoBinaryReference` (*type:* `String.t`, *default:* `nil`) - A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field. + * `crc32cHash` (*type:* `integer()`, *default:* `nil`) - For Scotty Uploads: Scotty-provided hashes for uploads For Scotty Downloads: (WARNING: DO NOT USE WITHOUT PERMISSION FROM THE SCOTTY TEAM.) A Hash provided by the agent to be used to verify the data being downloaded. Currently only supported for inline payloads. Further, only crc32c_hash is currently supported. + * `diffChecksumsResponse` (*type:* `GoogleApi.WalletObjects.V1.Model.DiffChecksumsResponse.t`, *default:* `nil`) - Set if reference_type is DIFF_CHECKSUMS_RESPONSE. + * `diffDownloadResponse` (*type:* `GoogleApi.WalletObjects.V1.Model.DiffDownloadResponse.t`, *default:* `nil`) - Set if reference_type is DIFF_DOWNLOAD_RESPONSE. + * `diffUploadRequest` (*type:* `GoogleApi.WalletObjects.V1.Model.DiffUploadRequest.t`, *default:* `nil`) - Set if reference_type is DIFF_UPLOAD_REQUEST. + * `diffUploadResponse` (*type:* `GoogleApi.WalletObjects.V1.Model.DiffUploadResponse.t`, *default:* `nil`) - Set if reference_type is DIFF_UPLOAD_RESPONSE. + * `diffVersionResponse` (*type:* `GoogleApi.WalletObjects.V1.Model.DiffVersionResponse.t`, *default:* `nil`) - Set if reference_type is DIFF_VERSION_RESPONSE. + * `downloadParameters` (*type:* `GoogleApi.WalletObjects.V1.Model.DownloadParameters.t`, *default:* `nil`) - Parameters for a media download. + * `filename` (*type:* `String.t`, *default:* `nil`) - Original file name + * `hash` (*type:* `String.t`, *default:* `nil`) - Deprecated, use one of explicit hash type fields instead. These two hash related fields will only be populated on Scotty based media uploads and will contain the content of the hash group in the NotificationRequest: http://cs/#google3/uploader/service/proto/upload_listener.proto&q=class:Hash Hex encoded hash value of the uploaded media. + * `hashVerified` (*type:* `boolean()`, *default:* `nil`) - For Scotty uploads only. If a user sends a hash code and the backend has requested that Scotty verify the upload against the client hash, Scotty will perform the check on behalf of the backend and will reject it if the hashes don't match. This is set to true if Scotty performed this verification. + * `inline` (*type:* `String.t`, *default:* `nil`) - Media data, set if reference_type is INLINE + * `isPotentialRetry` (*type:* `boolean()`, *default:* `nil`) - |is_potential_retry| is set false only when Scotty is certain that it has not sent the request before. When a client resumes an upload, this field must be set true in agent calls, because Scotty cannot be certain that it has never sent the request before due to potential failure in the session state persistence. + * `length` (*type:* `String.t`, *default:* `nil`) - Size of the data, in bytes + * `md5Hash` (*type:* `String.t`, *default:* `nil`) - Scotty-provided MD5 hash for an upload. + * `mediaId` (*type:* `String.t`, *default:* `nil`) - Media id to forward to the operation GetMedia. Can be set if reference_type is GET_MEDIA. + * `objectId` (*type:* `GoogleApi.WalletObjects.V1.Model.ObjectId.t`, *default:* `nil`) - Reference to a TI Blob, set if reference_type is BIGSTORE_REF. + * `path` (*type:* `String.t`, *default:* `nil`) - Path to the data, set if reference_type is PATH + * `referenceType` (*type:* `String.t`, *default:* `nil`) - Describes what the field reference contains. + * `sha1Hash` (*type:* `String.t`, *default:* `nil`) - Scotty-provided SHA1 hash for an upload. + * `sha256Hash` (*type:* `String.t`, *default:* `nil`) - Scotty-provided SHA256 hash for an upload. + * `timestamp` (*type:* `String.t`, *default:* `nil`) - Time at which the media data was last updated, in milliseconds since UNIX epoch + * `token` (*type:* `String.t`, *default:* `nil`) - A unique fingerprint/version id for the media data + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :algorithm => String.t() | nil, + :bigstoreObjectRef => String.t() | nil, + :blobRef => String.t() | nil, + :blobstore2Info => GoogleApi.WalletObjects.V1.Model.Blobstore2Info.t() | nil, + :compositeMedia => list(GoogleApi.WalletObjects.V1.Model.CompositeMedia.t()) | nil, + :contentType => String.t() | nil, + :contentTypeInfo => GoogleApi.WalletObjects.V1.Model.ContentTypeInfo.t() | nil, + :cosmoBinaryReference => String.t() | nil, + :crc32cHash => integer() | nil, + :diffChecksumsResponse => + GoogleApi.WalletObjects.V1.Model.DiffChecksumsResponse.t() | nil, + :diffDownloadResponse => + GoogleApi.WalletObjects.V1.Model.DiffDownloadResponse.t() | nil, + :diffUploadRequest => GoogleApi.WalletObjects.V1.Model.DiffUploadRequest.t() | nil, + :diffUploadResponse => GoogleApi.WalletObjects.V1.Model.DiffUploadResponse.t() | nil, + :diffVersionResponse => GoogleApi.WalletObjects.V1.Model.DiffVersionResponse.t() | nil, + :downloadParameters => GoogleApi.WalletObjects.V1.Model.DownloadParameters.t() | nil, + :filename => String.t() | nil, + :hash => String.t() | nil, + :hashVerified => boolean() | nil, + :inline => String.t() | nil, + :isPotentialRetry => boolean() | nil, + :length => String.t() | nil, + :md5Hash => String.t() | nil, + :mediaId => String.t() | nil, + :objectId => GoogleApi.WalletObjects.V1.Model.ObjectId.t() | nil, + :path => String.t() | nil, + :referenceType => String.t() | nil, + :sha1Hash => String.t() | nil, + :sha256Hash => String.t() | nil, + :timestamp => String.t() | nil, + :token => String.t() | nil + } + + field(:algorithm) + field(:bigstoreObjectRef) + field(:blobRef) + field(:blobstore2Info, as: GoogleApi.WalletObjects.V1.Model.Blobstore2Info) + field(:compositeMedia, as: GoogleApi.WalletObjects.V1.Model.CompositeMedia, type: :list) + field(:contentType) + field(:contentTypeInfo, as: GoogleApi.WalletObjects.V1.Model.ContentTypeInfo) + field(:cosmoBinaryReference) + field(:crc32cHash) + field(:diffChecksumsResponse, as: GoogleApi.WalletObjects.V1.Model.DiffChecksumsResponse) + field(:diffDownloadResponse, as: GoogleApi.WalletObjects.V1.Model.DiffDownloadResponse) + field(:diffUploadRequest, as: GoogleApi.WalletObjects.V1.Model.DiffUploadRequest) + field(:diffUploadResponse, as: GoogleApi.WalletObjects.V1.Model.DiffUploadResponse) + field(:diffVersionResponse, as: GoogleApi.WalletObjects.V1.Model.DiffVersionResponse) + field(:downloadParameters, as: GoogleApi.WalletObjects.V1.Model.DownloadParameters) + field(:filename) + field(:hash) + field(:hashVerified) + field(:inline) + field(:isPotentialRetry) + field(:length) + field(:md5Hash) + field(:mediaId) + field(:objectId, as: GoogleApi.WalletObjects.V1.Model.ObjectId) + field(:path) + field(:referenceType) + field(:sha1Hash) + field(:sha256Hash) + field(:timestamp) + field(:token) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Media do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Media.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Media do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media_request_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media_request_info.ex new file mode 100644 index 0000000000..727aac0c7a --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/media_request_info.ex @@ -0,0 +1,70 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.MediaRequestInfo do + @moduledoc """ + Extra information added to operations that support Scotty media requests. + + ## Attributes + + * `currentBytes` (*type:* `String.t`, *default:* `nil`) - The number of current bytes uploaded or downloaded. + * `customData` (*type:* `String.t`, *default:* `nil`) - Data to be copied to backend requests. Custom data is returned to Scotty in the agent_state field, which Scotty will then provide in subsequent upload notifications. + * `diffObjectVersion` (*type:* `String.t`, *default:* `nil`) - Set if the http request info is diff encoded. The value of this field is the version number of the base revision. This is corresponding to Apiary's mediaDiffObjectVersion (//depot/google3/java/com/google/api/server/media/variable/DiffObjectVersionVariable.java). See go/esf-scotty-diff-upload for more information. + * `finalStatus` (*type:* `integer()`, *default:* `nil`) - The existence of the final_status field indicates that this is the last call to the agent for this request_id. http://google3/uploader/agent/scotty_agent.proto?l=737&rcl=347601929 + * `notificationType` (*type:* `String.t`, *default:* `nil`) - The type of notification received from Scotty. + * `requestId` (*type:* `String.t`, *default:* `nil`) - The Scotty request ID. + * `requestReceivedParamsServingInfo` (*type:* `String.t`, *default:* `nil`) - The partition of the Scotty server handling this request. type is uploader_service.RequestReceivedParamsServingInfo LINT.IfChange(request_received_params_serving_info_annotations) LINT.ThenChange() + * `totalBytes` (*type:* `String.t`, *default:* `nil`) - The total size of the file. + * `totalBytesIsEstimated` (*type:* `boolean()`, *default:* `nil`) - Whether the total bytes field contains an estimated data. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :currentBytes => String.t() | nil, + :customData => String.t() | nil, + :diffObjectVersion => String.t() | nil, + :finalStatus => integer() | nil, + :notificationType => String.t() | nil, + :requestId => String.t() | nil, + :requestReceivedParamsServingInfo => String.t() | nil, + :totalBytes => String.t() | nil, + :totalBytesIsEstimated => boolean() | nil + } + + field(:currentBytes) + field(:customData) + field(:diffObjectVersion) + field(:finalStatus) + field(:notificationType) + field(:requestId) + field(:requestReceivedParamsServingInfo) + field(:totalBytes) + field(:totalBytesIsEstimated) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.MediaRequestInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.MediaRequestInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.MediaRequestInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/message.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/message.ex new file mode 100644 index 0000000000..8b500b9b70 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/message.ex @@ -0,0 +1,67 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Message do + @moduledoc """ + A message that will be displayed with a Valuable + + ## Attributes + + * `body` (*type:* `String.t`, *default:* `nil`) - The message body. + * `displayInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The period of time that the message will be displayed to users. You can define both a `startTime` and `endTime` for each message. A message is displayed immediately after a Wallet Object is inserted unless a `startTime` is set. The message will appear in a list of messages indefinitely if `endTime` is not provided. + * `header` (*type:* `String.t`, *default:* `nil`) - The message header. + * `id` (*type:* `String.t`, *default:* `nil`) - The ID associated with a message. This field is here to enable ease of management of messages. Notice ID values could possibly duplicate across multiple messages in the same class/instance, and care must be taken to select a reasonable ID for each message. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#walletObjectMessage"`. + * `localizedBody` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the message body. + * `localizedHeader` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the message header. + * `messageType` (*type:* `String.t`, *default:* `nil`) - The message type. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :body => String.t() | nil, + :displayInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :header => String.t() | nil, + :id => String.t() | nil, + :kind => String.t() | nil, + :localizedBody => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :localizedHeader => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :messageType => String.t() | nil + } + + field(:body) + field(:displayInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:header) + field(:id) + field(:kind) + field(:localizedBody, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:localizedHeader, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:messageType) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Message do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Message.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Message do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects.ex new file mode 100644 index 0000000000..9557325b53 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjects do + @moduledoc """ + + + ## Attributes + + * `addLinkedOfferObjectIds` (*type:* `list(String.t)`, *default:* `nil`) - The linked offer object ids to add to the object. + * `removeLinkedOfferObjectIds` (*type:* `list(String.t)`, *default:* `nil`) - The linked offer object ids to remove from the object. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :addLinkedOfferObjectIds => list(String.t()) | nil, + :removeLinkedOfferObjectIds => list(String.t()) | nil + } + + field(:addLinkedOfferObjectIds, type: :list) + field(:removeLinkedOfferObjectIds, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjects do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjects.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjects do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects_request.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects_request.ex new file mode 100644 index 0000000000..5fea5d48a5 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/modify_linked_offer_objects_request.ex @@ -0,0 +1,47 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjectsRequest do + @moduledoc """ + + + ## Attributes + + * `linkedOfferObjectIds` (*type:* `GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjects.t`, *default:* `nil`) - The linked offer object ids to add or remove from the object. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :linkedOfferObjectIds => + GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjects.t() | nil + } + + field(:linkedOfferObjectIds, as: GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjects) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjectsRequest do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjectsRequest.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ModifyLinkedOfferObjectsRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/money.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/money.ex new file mode 100644 index 0000000000..031b755367 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/money.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Money do + @moduledoc """ + + + ## Attributes + + * `currencyCode` (*type:* `String.t`, *default:* `nil`) - The currency code, such as "USD" or "EUR." + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#money"`. + * `micros` (*type:* `String.t`, *default:* `nil`) - The unit of money amount in micros. For example, $1 USD would be represented as 1000000 micros. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :currencyCode => String.t() | nil, + :kind => String.t() | nil, + :micros => String.t() | nil + } + + field(:currencyCode) + field(:kind) + field(:micros) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Money do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Money.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Money do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/notifications.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/notifications.ex new file mode 100644 index 0000000000..140d2a0116 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/notifications.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Notifications do + @moduledoc """ + Indicates if the object needs to have notification enabled. We support only one of ExpiryNotification/UpcomingNotification. `expiryNotification` takes precedence over `upcomingNotification`. In other words if `expiryNotification` is set, we ignore the `upcomingNotification` field. + + ## Attributes + + * `expiryNotification` (*type:* `GoogleApi.WalletObjects.V1.Model.ExpiryNotification.t`, *default:* `nil`) - A notification would be triggered at a specific time before the card expires. + * `upcomingNotification` (*type:* `GoogleApi.WalletObjects.V1.Model.UpcomingNotification.t`, *default:* `nil`) - A notification would be triggered at a specific time before the card becomes usable. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :expiryNotification => GoogleApi.WalletObjects.V1.Model.ExpiryNotification.t() | nil, + :upcomingNotification => GoogleApi.WalletObjects.V1.Model.UpcomingNotification.t() | nil + } + + field(:expiryNotification, as: GoogleApi.WalletObjects.V1.Model.ExpiryNotification) + field(:upcomingNotification, as: GoogleApi.WalletObjects.V1.Model.UpcomingNotification) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Notifications do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Notifications.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Notifications do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/object_id.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/object_id.ex new file mode 100644 index 0000000000..a986f6519f --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/object_id.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ObjectId do + @moduledoc """ + This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763. + + ## Attributes + + * `bucketName` (*type:* `String.t`, *default:* `nil`) - The name of the bucket to which this object belongs. + * `generation` (*type:* `String.t`, *default:* `nil`) - Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions + * `objectName` (*type:* `String.t`, *default:* `nil`) - The name of the object. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :bucketName => String.t() | nil, + :generation => String.t() | nil, + :objectName => String.t() | nil + } + + field(:bucketName) + field(:generation) + field(:objectName) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ObjectId do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ObjectId.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ObjectId do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class.ex new file mode 100644 index 0000000000..d83e562cc0 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class.ex @@ -0,0 +1,163 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.OfferClass do + @moduledoc """ + + + ## Attributes + + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `homepageUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URI of your application's home page. Populating the URI in this field results in the exact same behavior as populating an URI in linksModuleData (when an object is rendered, a link to the homepage is shown in what would usually be thought of as the linksModuleData section of the object). + * `wordMark` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Deprecated. + * `countryCode` (*type:* `String.t`, *default:* `nil`) - Country code used to display the card's country (when the user is not in that country), as well as to display localized content when content is not available in the user's locale. + * `classTemplateInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t`, *default:* `nil`) - Template information about how the class should be displayed. If unset, Google will fallback to a default set of fields to display. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the object, both will be displayed. + * `localizedFinePrint` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the fine_print. + * `provider` (*type:* `String.t`, *default:* `nil`) - Required. The offer provider (either the aggregator name or merchant name). Recommended maximum length is 12 characters to ensure full string is displayed on smaller screens. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#offerClass"`. + * `finePrint` (*type:* `String.t`, *default:* `nil`) - The fine print or terms of the offer, such as "20% off any t-shirt at Adam's Apparel." + * `details` (*type:* `String.t`, *default:* `nil`) - The details of the offer. + * `localizedIssuerName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the issuer_name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `multipleDevicesAndHoldersAllowedStatus` (*type:* `String.t`, *default:* `nil`) - Identifies whether multiple users and devices will save the same object referencing this class. + * `issuerName` (*type:* `String.t`, *default:* `nil`) - Required. The issuer name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `securityAnimation` (*type:* `GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t`, *default:* `nil`) - Optional information about the security animation. If this is set a security animation will be rendered on pass details. + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Callback options to be used to call the issuer back for every save/delete of an object for this class by the end-user. All objects of this class are eligible for the callback. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + * `viewUnlockRequirement` (*type:* `String.t`, *default:* `nil`) - View Unlock Requirement options for the offer. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `localizedShortTitle` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the short title. Recommended maximum length is 20 characters. + * `helpUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The help link for the offer, such as `http://myownpersonaldomain.com/help` + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, nothing will be displayed. The image will display at 100% width. + * `shortTitle` (*type:* `String.t`, *default:* `nil`) - A shortened version of the title of the offer, such as "20% off," shown to users as a quick reference to the offer contents. Recommended maximum length is 20 characters. + * `wideTitleImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The wide title image of the offer. When provided, this will be used in place of the title image in the top left of the card view. + * `localizedProvider` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the provider. Recommended maximum length is 12 characters to ensure full string is displayed on smaller screens. + * `titleImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The title image of the offer. This image is displayed in both the details and list views of the app. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `enableSmartTap` (*type:* `boolean()`, *default:* `nil`) - Identifies whether this class supports Smart Tap. The `redemptionIssuers` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `localizedDetails` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the details. + * `reviewStatus` (*type:* `String.t`, *default:* `nil`) - Required. The status of the class. This field can be set to `draft` or The status of the class. This field can be set to `draft` or `underReview` using the insert, patch, or update API calls. Once the review state is changed from `draft` it may not be changed back to `draft`. You should keep this field to `draft` when the class is under development. A `draft` class cannot be used to create any object. You should set this field to `underReview` when you believe the class is ready for use. The platform will automatically set this field to `approved` and it can be immediately used to create or migrate objects. When updating an already `approved` class you should keep setting this field to `underReview`. + * `redemptionChannel` (*type:* `String.t`, *default:* `nil`) - Required. The redemption channels applicable to this offer. + * `allowMultipleUsersPerObject` (*type:* `boolean()`, *default:* `nil`) - Deprecated. Use `multipleDevicesAndHoldersAllowedStatus` instead. + * `review` (*type:* `GoogleApi.WalletObjects.V1.Model.Review.t`, *default:* `nil`) - The review comments set by the platform when a class is marked `approved` or `rejected`. + * `title` (*type:* `String.t`, *default:* `nil`) - Required. The title of the offer, such as "20% off any t-shirt." Recommended maximum length is 60 characters to ensure full string is displayed on smaller screens. + * `localizedTitle` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the title. Recommended maximum length is 60 characters to ensure full string is displayed on smaller screens. + * `redemptionIssuers` (*type:* `list(String.t)`, *default:* `nil`) - Identifies which redemption issuers can redeem the pass over Smart Tap. Redemption issuers are identified by their issuer ID. Redemption issuers must have at least one Smart Tap key configured. The `enableSmartTap` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :homepageUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil, + :wordMark => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :countryCode => String.t() | nil, + :classTemplateInfo => GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :localizedFinePrint => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :provider => String.t() | nil, + :kind => String.t() | nil, + :finePrint => String.t() | nil, + :details => String.t() | nil, + :localizedIssuerName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :multipleDevicesAndHoldersAllowedStatus => String.t() | nil, + :issuerName => String.t() | nil, + :hexBackgroundColor => String.t() | nil, + :securityAnimation => GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t() | nil, + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :version => String.t() | nil, + :viewUnlockRequirement => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :localizedShortTitle => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :helpUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :shortTitle => String.t() | nil, + :wideTitleImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :localizedProvider => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :titleImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :enableSmartTap => boolean() | nil, + :localizedDetails => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :reviewStatus => String.t() | nil, + :redemptionChannel => String.t() | nil, + :allowMultipleUsersPerObject => boolean() | nil, + :review => GoogleApi.WalletObjects.V1.Model.Review.t() | nil, + :title => String.t() | nil, + :localizedTitle => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :redemptionIssuers => list(String.t()) | nil + } + + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:homepageUri, as: GoogleApi.WalletObjects.V1.Model.Uri) + field(:wordMark, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:countryCode) + field(:classTemplateInfo, as: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:localizedFinePrint, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:provider) + field(:kind) + field(:finePrint) + field(:details) + field(:localizedIssuerName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:multipleDevicesAndHoldersAllowedStatus) + field(:issuerName) + field(:hexBackgroundColor) + field(:securityAnimation, as: GoogleApi.WalletObjects.V1.Model.SecurityAnimation) + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:version) + field(:viewUnlockRequirement) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:localizedShortTitle, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:helpUri, as: GoogleApi.WalletObjects.V1.Model.Uri) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:shortTitle) + field(:wideTitleImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:localizedProvider, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:titleImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:enableSmartTap) + field(:localizedDetails, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:reviewStatus) + field(:redemptionChannel) + field(:allowMultipleUsersPerObject) + field(:review, as: GoogleApi.WalletObjects.V1.Model.Review) + field(:title) + field(:localizedTitle, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:redemptionIssuers, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.OfferClass do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.OfferClass.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.OfferClass do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_add_message_response.ex new file mode 100644 index 0000000000..bf8c5944ec --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.OfferClassAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferClass.t`, *default:* `nil`) - The updated OfferClass resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.OfferClass.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.OfferClass) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.OfferClassAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.OfferClassAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.OfferClassAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_list_response.ex new file mode 100644 index 0000000000..22e92af0f4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_class_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.OfferClassListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.OfferClass.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.OfferClass.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.OfferClass, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.OfferClassListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.OfferClassListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.OfferClassListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object.ex new file mode 100644 index 0000000000..267d1af3b7 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object.ex @@ -0,0 +1,112 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.OfferObject do + @moduledoc """ + + + ## Attributes + + * `appLinkData` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkData.t`, *default:* `nil`) - Optional information about the partner app link. + * `barcode` (*type:* `GoogleApi.WalletObjects.V1.Model.Barcode.t`, *default:* `nil`) - The barcode type and value. + * `classId` (*type:* `String.t`, *default:* `nil`) - Required. The class associated with this object. The class must be of the same type as this object, must already exist, and must be approved. Class IDs should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. + * `classReference` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferClass.t`, *default:* `nil`) - A copy of the inherited fields of the parent class. These fields are retrieved during a GET. + * `disableExpirationNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if notifications should explicitly be suppressed. If this field is set to true, regardless of the `messages` field, expiration notifications to the user will be suppressed. By default, this field is set to false. Currently, this can only be set for offers. + * `groupingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.GroupingInfo.t`, *default:* `nil`) - Information that controls how passes are grouped together. + * `hasLinkedDevice` (*type:* `boolean()`, *default:* `nil`) - Whether this object is currently linked to a single device. This field is set by the platform when a user saves the object, linking it to their device. Intended for use by select partners. Contact support for additional information. + * `hasUsers` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object has users. This field is set by the platform. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, hero image of the class, if present, will be displayed. If hero image of the class is also not present, nothing will be displayed. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. The unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#offerObject"`. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the class, both will be displayed. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `passConstraints` (*type:* `GoogleApi.WalletObjects.V1.Model.PassConstraints.t`, *default:* `nil`) - Pass constraints for the object. Includes limiting NFC and screenshot behaviors. + * `rotatingBarcode` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t`, *default:* `nil`) - The rotating barcode type and value. + * `smartTapRedemptionValue` (*type:* `String.t`, *default:* `nil`) - The value that will be transmitted to a Smart Tap certified terminal over NFC for this object. The class level fields `enableSmartTap` and `redemptionIssuers` must also be set up correctly in order for the pass to support Smart Tap. Only ASCII characters are supported. + * `state` (*type:* `String.t`, *default:* `nil`) - Required. The state of the object. This field is used to determine how an object is displayed in the app. For example, an `inactive` object is moved to the "Expired passes" section. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `validTimeInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The time period this object will be `active` and object can be used. An object's state will be changed to `expired` when this time period has passed. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :appLinkData => GoogleApi.WalletObjects.V1.Model.AppLinkData.t() | nil, + :barcode => GoogleApi.WalletObjects.V1.Model.Barcode.t() | nil, + :classId => String.t() | nil, + :classReference => GoogleApi.WalletObjects.V1.Model.OfferClass.t() | nil, + :disableExpirationNotification => boolean() | nil, + :groupingInfo => GoogleApi.WalletObjects.V1.Model.GroupingInfo.t() | nil, + :hasLinkedDevice => boolean() | nil, + :hasUsers => boolean() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :kind => String.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :passConstraints => GoogleApi.WalletObjects.V1.Model.PassConstraints.t() | nil, + :rotatingBarcode => GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t() | nil, + :smartTapRedemptionValue => String.t() | nil, + :state => String.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :validTimeInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :version => String.t() | nil + } + + field(:appLinkData, as: GoogleApi.WalletObjects.V1.Model.AppLinkData) + field(:barcode, as: GoogleApi.WalletObjects.V1.Model.Barcode) + field(:classId) + field(:classReference, as: GoogleApi.WalletObjects.V1.Model.OfferClass) + field(:disableExpirationNotification) + field(:groupingInfo, as: GoogleApi.WalletObjects.V1.Model.GroupingInfo) + field(:hasLinkedDevice) + field(:hasUsers) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:kind) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:passConstraints, as: GoogleApi.WalletObjects.V1.Model.PassConstraints) + field(:rotatingBarcode, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcode) + field(:smartTapRedemptionValue) + field(:state) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:validTimeInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:version) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.OfferObject do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.OfferObject.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.OfferObject do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_add_message_response.ex new file mode 100644 index 0000000000..9ed8ea2cd7 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.OfferObjectAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.OfferObject.t`, *default:* `nil`) - The updated OfferObject resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.OfferObject.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.OfferObject) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.OfferObjectAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.OfferObjectAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.OfferObjectAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_list_response.ex new file mode 100644 index 0000000000..5797e100ef --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/offer_object_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.OfferObjectListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.OfferObject.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.OfferObject.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.OfferObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.OfferObjectListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.OfferObjectListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.OfferObjectListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pagination.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pagination.ex new file mode 100644 index 0000000000..fe84320206 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pagination.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Pagination do + @moduledoc """ + + + ## Attributes + + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#pagination"`. + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - Page token to send to fetch the next page. + * `resultsPerPage` (*type:* `integer()`, *default:* `nil`) - Number of results returned in this page. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kind => String.t() | nil, + :nextPageToken => String.t() | nil, + :resultsPerPage => integer() | nil + } + + field(:kind) + field(:nextPageToken) + field(:resultsPerPage) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Pagination do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Pagination.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Pagination do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pass_constraints.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pass_constraints.ex new file mode 100644 index 0000000000..c1f4c72f6d --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/pass_constraints.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.PassConstraints do + @moduledoc """ + Container for any constraints that may be placed on passes. + + ## Attributes + + * `nfcConstraint` (*type:* `list(String.t)`, *default:* `nil`) - The NFC constraints for the pass. + * `screenshotEligibility` (*type:* `String.t`, *default:* `nil`) - The screenshot eligibility for the pass. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :nfcConstraint => list(String.t()) | nil, + :screenshotEligibility => String.t() | nil + } + + field(:nfcConstraint, type: :list) + field(:screenshotEligibility) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.PassConstraints do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.PassConstraints.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.PassConstraints do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permission.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permission.ex new file mode 100644 index 0000000000..515cb1843b --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permission.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Permission do + @moduledoc """ + + + ## Attributes + + * `emailAddress` (*type:* `String.t`, *default:* `nil`) - The email address of the user, group, or service account to which this permission refers to. + * `role` (*type:* `String.t`, *default:* `nil`) - The role granted by this permission. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :emailAddress => String.t() | nil, + :role => String.t() | nil + } + + field(:emailAddress) + field(:role) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Permission do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Permission.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Permission do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permissions.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permissions.ex new file mode 100644 index 0000000000..573caf3c3e --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/permissions.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Permissions do + @moduledoc """ + + + ## Attributes + + * `issuerId` (*type:* `String.t`, *default:* `nil`) - ID of the issuer the list of permissions refer to. + * `permissions` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Permission.t)`, *default:* `nil`) - The complete list of permissions for the issuer account. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :issuerId => String.t() | nil, + :permissions => list(GoogleApi.WalletObjects.V1.Model.Permission.t()) | nil + } + + field(:issuerId) + field(:permissions, as: GoogleApi.WalletObjects.V1.Model.Permission, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Permissions do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Permissions.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Permissions do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/purchase_details.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/purchase_details.ex new file mode 100644 index 0000000000..dec86031ff --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/purchase_details.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.PurchaseDetails do + @moduledoc """ + + + ## Attributes + + * `accountId` (*type:* `String.t`, *default:* `nil`) - ID of the account used to purchase the ticket. + * `confirmationCode` (*type:* `String.t`, *default:* `nil`) - The confirmation code for the purchase. This may be the same for multiple different tickets and is used to group tickets together. + * `purchaseDateTime` (*type:* `String.t`, *default:* `nil`) - The purchase date/time of the ticket. This is an ISO 8601 extended format date/time, with or without an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the event were in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. Without offset information, some rich features may not be available. + * `purchaseReceiptNumber` (*type:* `String.t`, *default:* `nil`) - Receipt number/identifier for tracking the ticket purchase via the body that sold the ticket. + * `ticketCost` (*type:* `GoogleApi.WalletObjects.V1.Model.TicketCost.t`, *default:* `nil`) - The cost of the ticket. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :accountId => String.t() | nil, + :confirmationCode => String.t() | nil, + :purchaseDateTime => String.t() | nil, + :purchaseReceiptNumber => String.t() | nil, + :ticketCost => GoogleApi.WalletObjects.V1.Model.TicketCost.t() | nil + } + + field(:accountId) + field(:confirmationCode) + field(:purchaseDateTime) + field(:purchaseReceiptNumber) + field(:ticketCost, as: GoogleApi.WalletObjects.V1.Model.TicketCost) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.PurchaseDetails do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.PurchaseDetails.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.PurchaseDetails do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/reservation_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/reservation_info.ex new file mode 100644 index 0000000000..cab1b1a49a --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/reservation_info.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.ReservationInfo do + @moduledoc """ + + + ## Attributes + + * `confirmationCode` (*type:* `String.t`, *default:* `nil`) - Confirmation code needed to check into this flight. This is the number that the passenger would enter into a kiosk at the airport to look up the flight and print a boarding pass. + * `eticketNumber` (*type:* `String.t`, *default:* `nil`) - E-ticket number. + * `frequentFlyerInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.FrequentFlyerInfo.t`, *default:* `nil`) - Frequent flyer membership information. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#reservationInfo"`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :confirmationCode => String.t() | nil, + :eticketNumber => String.t() | nil, + :frequentFlyerInfo => GoogleApi.WalletObjects.V1.Model.FrequentFlyerInfo.t() | nil, + :kind => String.t() | nil + } + + field(:confirmationCode) + field(:eticketNumber) + field(:frequentFlyerInfo, as: GoogleApi.WalletObjects.V1.Model.FrequentFlyerInfo) + field(:kind) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.ReservationInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.ReservationInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.ReservationInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/resources.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/resources.ex new file mode 100644 index 0000000000..2fb3241d4a --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/resources.ex @@ -0,0 +1,81 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Resources do + @moduledoc """ + + + ## Attributes + + * `eventTicketClasses` (*type:* `list(GoogleApi.WalletObjects.V1.Model.EventTicketClass.t)`, *default:* `nil`) - + * `eventTicketObjects` (*type:* `list(GoogleApi.WalletObjects.V1.Model.EventTicketObject.t)`, *default:* `nil`) - + * `flightClasses` (*type:* `list(GoogleApi.WalletObjects.V1.Model.FlightClass.t)`, *default:* `nil`) - + * `flightObjects` (*type:* `list(GoogleApi.WalletObjects.V1.Model.FlightObject.t)`, *default:* `nil`) - + * `giftCardClasses` (*type:* `list(GoogleApi.WalletObjects.V1.Model.GiftCardClass.t)`, *default:* `nil`) - + * `giftCardObjects` (*type:* `list(GoogleApi.WalletObjects.V1.Model.GiftCardObject.t)`, *default:* `nil`) - + * `loyaltyClasses` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t)`, *default:* `nil`) - + * `loyaltyObjects` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t)`, *default:* `nil`) - + * `offerClasses` (*type:* `list(GoogleApi.WalletObjects.V1.Model.OfferClass.t)`, *default:* `nil`) - + * `offerObjects` (*type:* `list(GoogleApi.WalletObjects.V1.Model.OfferObject.t)`, *default:* `nil`) - + * `transitClasses` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TransitClass.t)`, *default:* `nil`) - + * `transitObjects` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TransitObject.t)`, *default:* `nil`) - + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :eventTicketClasses => + list(GoogleApi.WalletObjects.V1.Model.EventTicketClass.t()) | nil, + :eventTicketObjects => + list(GoogleApi.WalletObjects.V1.Model.EventTicketObject.t()) | nil, + :flightClasses => list(GoogleApi.WalletObjects.V1.Model.FlightClass.t()) | nil, + :flightObjects => list(GoogleApi.WalletObjects.V1.Model.FlightObject.t()) | nil, + :giftCardClasses => list(GoogleApi.WalletObjects.V1.Model.GiftCardClass.t()) | nil, + :giftCardObjects => list(GoogleApi.WalletObjects.V1.Model.GiftCardObject.t()) | nil, + :loyaltyClasses => list(GoogleApi.WalletObjects.V1.Model.LoyaltyClass.t()) | nil, + :loyaltyObjects => list(GoogleApi.WalletObjects.V1.Model.LoyaltyObject.t()) | nil, + :offerClasses => list(GoogleApi.WalletObjects.V1.Model.OfferClass.t()) | nil, + :offerObjects => list(GoogleApi.WalletObjects.V1.Model.OfferObject.t()) | nil, + :transitClasses => list(GoogleApi.WalletObjects.V1.Model.TransitClass.t()) | nil, + :transitObjects => list(GoogleApi.WalletObjects.V1.Model.TransitObject.t()) | nil + } + + field(:eventTicketClasses, as: GoogleApi.WalletObjects.V1.Model.EventTicketClass, type: :list) + field(:eventTicketObjects, as: GoogleApi.WalletObjects.V1.Model.EventTicketObject, type: :list) + field(:flightClasses, as: GoogleApi.WalletObjects.V1.Model.FlightClass, type: :list) + field(:flightObjects, as: GoogleApi.WalletObjects.V1.Model.FlightObject, type: :list) + field(:giftCardClasses, as: GoogleApi.WalletObjects.V1.Model.GiftCardClass, type: :list) + field(:giftCardObjects, as: GoogleApi.WalletObjects.V1.Model.GiftCardObject, type: :list) + field(:loyaltyClasses, as: GoogleApi.WalletObjects.V1.Model.LoyaltyClass, type: :list) + field(:loyaltyObjects, as: GoogleApi.WalletObjects.V1.Model.LoyaltyObject, type: :list) + field(:offerClasses, as: GoogleApi.WalletObjects.V1.Model.OfferClass, type: :list) + field(:offerObjects, as: GoogleApi.WalletObjects.V1.Model.OfferObject, type: :list) + field(:transitClasses, as: GoogleApi.WalletObjects.V1.Model.TransitClass, type: :list) + field(:transitObjects, as: GoogleApi.WalletObjects.V1.Model.TransitObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Resources do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Resources.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Resources do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/review.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/review.ex new file mode 100644 index 0000000000..874ae9e6b0 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/review.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Review do + @moduledoc """ + + + ## Attributes + + * `comments` (*type:* `String.t`, *default:* `nil`) - + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :comments => String.t() | nil + } + + field(:comments) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Review do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Review.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Review do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode.ex new file mode 100644 index 0000000000..94c5c2045f --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode.ex @@ -0,0 +1,65 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.RotatingBarcode do + @moduledoc """ + + + ## Attributes + + * `alternateText` (*type:* `String.t`, *default:* `nil`) - An optional text that will override the default text that shows under the barcode. This field is intended for a human readable equivalent of the barcode value, used when the barcode cannot be scanned. + * `initialRotatingBarcodeValues` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcodeValues.t`, *default:* `nil`) - Input only. NOTE: This feature is only available for the transit vertical. Optional set of initial rotating barcode values. This allows a small subset of barcodes to be included with the object. Further rotating barcode values must be uploaded with the UploadRotatingBarcodeValues endpoint. + * `renderEncoding` (*type:* `String.t`, *default:* `nil`) - The render encoding for the barcode. When specified, barcode is rendered in the given encoding. Otherwise best known encoding is chosen by Google. + * `showCodeText` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Optional text that will be shown when the barcode is hidden behind a click action. This happens in cases where a pass has Smart Tap enabled. If not specified, a default is chosen by Google. + * `totpDetails` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetails.t`, *default:* `nil`) - Details used to evaluate the {totp_value_n} substitutions. + * `type` (*type:* `String.t`, *default:* `nil`) - The type of this barcode. + * `valuePattern` (*type:* `String.t`, *default:* `nil`) - String encoded barcode value. This string supports the following substitutions: * {totp_value_n}: Replaced with the TOTP value (see TotpDetails.parameters). * {totp_timestamp_millis}: Replaced with the timestamp (millis since epoch) at which the barcode was generated. * {totp_timestamp_seconds}: Replaced with the timestamp (seconds since epoch) at which the barcode was generated. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :alternateText => String.t() | nil, + :initialRotatingBarcodeValues => + GoogleApi.WalletObjects.V1.Model.RotatingBarcodeValues.t() | nil, + :renderEncoding => String.t() | nil, + :showCodeText => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :totpDetails => GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetails.t() | nil, + :type => String.t() | nil, + :valuePattern => String.t() | nil + } + + field(:alternateText) + field(:initialRotatingBarcodeValues, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeValues) + field(:renderEncoding) + field(:showCodeText, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:totpDetails, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetails) + field(:type) + field(:valuePattern) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.RotatingBarcode do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.RotatingBarcode.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.RotatingBarcode do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details.ex new file mode 100644 index 0000000000..ceccd43033 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details.ex @@ -0,0 +1,59 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetails do + @moduledoc """ + Configuration for the time-based OTP substitutions. See https://tools.ietf.org/html/rfc6238 + + ## Attributes + + * `algorithm` (*type:* `String.t`, *default:* `nil`) - The TOTP algorithm used to generate the OTP. + * `parameters` (*type:* `list(GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetailsTotpParameters.t)`, *default:* `nil`) - The TOTP parameters for each of the {totp_value_*} substitutions. The TotpParameters at index n is used for the {totp_value_n} substitution. + * `periodMillis` (*type:* `String.t`, *default:* `nil`) - The time interval used for the TOTP value generation, in milliseconds. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :algorithm => String.t() | nil, + :parameters => + list(GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetailsTotpParameters.t()) + | nil, + :periodMillis => String.t() | nil + } + + field(:algorithm) + + field(:parameters, + as: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetailsTotpParameters, + type: :list + ) + + field(:periodMillis) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetails do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetails.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetails do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details_totp_parameters.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details_totp_parameters.ex new file mode 100644 index 0000000000..7d2f80284c --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_totp_details_totp_parameters.ex @@ -0,0 +1,54 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetailsTotpParameters do + @moduledoc """ + Configuration for the key and value length. See https://www.rfc-editor.org/rfc/rfc4226#section-5.3 + + ## Attributes + + * `key` (*type:* `String.t`, *default:* `nil`) - The secret key used for the TOTP value generation, encoded as a Base16 string. + * `valueLength` (*type:* `integer()`, *default:* `nil`) - The length of the TOTP value in decimal digits. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :key => String.t() | nil, + :valueLength => integer() | nil + } + + field(:key) + field(:valueLength) +end + +defimpl Poison.Decoder, + for: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetailsTotpParameters do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetailsTotpParameters.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeTotpDetailsTotpParameters do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_values.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_values.ex new file mode 100644 index 0000000000..128418a29e --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/rotating_barcode_values.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.RotatingBarcodeValues do + @moduledoc """ + A payload containing many barcode values and start date/time. + + ## Attributes + + * `periodMillis` (*type:* `String.t`, *default:* `nil`) - Required. The amount of time each barcode is valid for. + * `startDateTime` (*type:* `String.t`, *default:* `nil`) - Required. The date/time the first barcode is valid from. Barcodes will be rotated through using period_millis defined on the object's RotatingBarcodeValueInfo. This is an ISO 8601 extended format date/time, with an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the event were in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. + * `values` (*type:* `list(String.t)`, *default:* `nil`) - Required. The values to encode in the barcode. At least one value is required. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :periodMillis => String.t() | nil, + :startDateTime => String.t() | nil, + :values => list(String.t()) | nil + } + + field(:periodMillis) + field(:startDateTime) + field(:values, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeValues do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.RotatingBarcodeValues.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.RotatingBarcodeValues do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/security_animation.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/security_animation.ex new file mode 100644 index 0000000000..606573b610 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/security_animation.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.SecurityAnimation do + @moduledoc """ + + + ## Attributes + + * `animationType` (*type:* `String.t`, *default:* `nil`) - Type of animation. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :animationType => String.t() | nil + } + + field(:animationType) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.SecurityAnimation do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.SecurityAnimation.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.SecurityAnimation do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/sign_up_info.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/sign_up_info.ex new file mode 100644 index 0000000000..76175d6aa9 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/sign_up_info.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.SignUpInfo do + @moduledoc """ + + + ## Attributes + + * `classId` (*type:* `String.t`, *default:* `nil`) - ID of the class the user can sign up for. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :classId => String.t() | nil + } + + field(:classId) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.SignUpInfo do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.SignUpInfo.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.SignUpInfo do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap.ex new file mode 100644 index 0000000000..58b73734f6 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.SmartTap do + @moduledoc """ + + + ## Attributes + + * `id` (*type:* `String.t`, *default:* `nil`) - The unique identifier for a smart tap. This value should follow the format issuer ID.identifier where the former is issued by Google and latter is the Smart Tap id. The Smart Tap id is a Base64 encoded string which represents the id which was generated by the Google Pay app. + * `infos` (*type:* `list(GoogleApi.WalletObjects.V1.Model.IssuerToUserInfo.t)`, *default:* `nil`) - Communication from merchant to user. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#smartTap"`. + * `merchantId` (*type:* `String.t`, *default:* `nil`) - Smart Tap merchant ID of who engaged in the Smart Tap interaction. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :id => String.t() | nil, + :infos => list(GoogleApi.WalletObjects.V1.Model.IssuerToUserInfo.t()) | nil, + :kind => String.t() | nil, + :merchantId => String.t() | nil + } + + field(:id) + field(:infos, as: GoogleApi.WalletObjects.V1.Model.IssuerToUserInfo, type: :list) + field(:kind) + field(:merchantId) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.SmartTap do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.SmartTap.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.SmartTap do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap_merchant_data.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap_merchant_data.ex new file mode 100644 index 0000000000..3d7b6bf9f5 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/smart_tap_merchant_data.ex @@ -0,0 +1,50 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.SmartTapMerchantData do + @moduledoc """ + + + ## Attributes + + * `authenticationKeys` (*type:* `list(GoogleApi.WalletObjects.V1.Model.AuthenticationKey.t)`, *default:* `nil`) - Available only to Smart Tap enabled partners. Contact support for additional guidance. + * `smartTapMerchantId` (*type:* `String.t`, *default:* `nil`) - Available only to Smart Tap enabled partners. Contact support for additional guidance. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :authenticationKeys => + list(GoogleApi.WalletObjects.V1.Model.AuthenticationKey.t()) | nil, + :smartTapMerchantId => String.t() | nil + } + + field(:authenticationKeys, as: GoogleApi.WalletObjects.V1.Model.AuthenticationKey, type: :list) + field(:smartTapMerchantId) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.SmartTapMerchantData do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.SmartTapMerchantData.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.SmartTapMerchantData do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/template_item.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/template_item.ex new file mode 100644 index 0000000000..0e59e9cd23 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/template_item.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TemplateItem do + @moduledoc """ + + + ## Attributes + + * `firstValue` (*type:* `GoogleApi.WalletObjects.V1.Model.FieldSelector.t`, *default:* `nil`) - A reference to a field to display. If both `firstValue` and `secondValue` are populated, they will both appear as one item with a slash between them. For example, values A and B would be shown as "A / B". + * `predefinedItem` (*type:* `String.t`, *default:* `nil`) - A predefined item to display. Only one of `firstValue` or `predefinedItem` may be set. + * `secondValue` (*type:* `GoogleApi.WalletObjects.V1.Model.FieldSelector.t`, *default:* `nil`) - A reference to a field to display. This may only be populated if the `firstValue` field is populated. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :firstValue => GoogleApi.WalletObjects.V1.Model.FieldSelector.t() | nil, + :predefinedItem => String.t() | nil, + :secondValue => GoogleApi.WalletObjects.V1.Model.FieldSelector.t() | nil + } + + field(:firstValue, as: GoogleApi.WalletObjects.V1.Model.FieldSelector) + field(:predefinedItem) + field(:secondValue, as: GoogleApi.WalletObjects.V1.Model.FieldSelector) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TemplateItem do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TemplateItem.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TemplateItem do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/text_module_data.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/text_module_data.ex new file mode 100644 index 0000000000..495304f9d5 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/text_module_data.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TextModuleData do + @moduledoc """ + Data for Text module. All fields are optional. Header will be displayed if available, different types of bodies will be concatenated if they are defined. + + ## Attributes + + * `body` (*type:* `String.t`, *default:* `nil`) - The body of the Text Module, which is defined as an uninterrupted string. Recommended maximum length is 500 characters to ensure full string is displayed on smaller screens. + * `header` (*type:* `String.t`, *default:* `nil`) - The header of the Text Module. Recommended maximum length is 35 characters to ensure full string is displayed on smaller screens. + * `id` (*type:* `String.t`, *default:* `nil`) - The ID associated with a text module. This field is here to enable ease of management of text modules. + * `localizedBody` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the body. Recommended maximum length is 500 characters to ensure full string is displayed on smaller screens. + * `localizedHeader` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the header. Recommended maximum length is 35 characters to ensure full string is displayed on smaller screens. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :body => String.t() | nil, + :header => String.t() | nil, + :id => String.t() | nil, + :localizedBody => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :localizedHeader => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:body) + field(:header) + field(:id) + field(:localizedBody, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:localizedHeader, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TextModuleData do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TextModuleData.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TextModuleData do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_cost.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_cost.ex new file mode 100644 index 0000000000..1996f8853c --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_cost.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TicketCost do + @moduledoc """ + + + ## Attributes + + * `discountMessage` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A message describing any kind of discount that was applied. + * `faceValue` (*type:* `GoogleApi.WalletObjects.V1.Model.Money.t`, *default:* `nil`) - The face value of the ticket. + * `purchasePrice` (*type:* `GoogleApi.WalletObjects.V1.Model.Money.t`, *default:* `nil`) - The actual purchase price of the ticket, after tax and/or discounts. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :discountMessage => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :faceValue => GoogleApi.WalletObjects.V1.Model.Money.t() | nil, + :purchasePrice => GoogleApi.WalletObjects.V1.Model.Money.t() | nil + } + + field(:discountMessage, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:faceValue, as: GoogleApi.WalletObjects.V1.Model.Money) + field(:purchasePrice, as: GoogleApi.WalletObjects.V1.Model.Money) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TicketCost do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TicketCost.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TicketCost do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_leg.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_leg.ex new file mode 100644 index 0000000000..3ccadd3b24 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_leg.ex @@ -0,0 +1,85 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TicketLeg do + @moduledoc """ + + + ## Attributes + + * `arrivalDateTime` (*type:* `String.t`, *default:* `nil`) - The date/time of arrival. This is an ISO 8601 extended format date/time, with or without an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the event were in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. The portion of the date/time without the offset is considered the "local date/time". This should be the local date/time at the destination station. For example, if the event occurs at the 20th hour of June 5th, 2018 at the destination station, the local date/time portion should be `2018-06-05T20:00:00`. If the local date/time at the destination station is 4 hours before UTC, an offset of `-04:00` may be appended. Without offset information, some rich features may not be available. + * `carriage` (*type:* `String.t`, *default:* `nil`) - The train or ship name/number that the passsenger needs to board. + * `departureDateTime` (*type:* `String.t`, *default:* `nil`) - The date/time of departure. This is required if there is no validity time interval set on the transit object. This is an ISO 8601 extended format date/time, with or without an offset. Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the event were in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. The portion of the date/time without the offset is considered the "local date/time". This should be the local date/time at the origin station. For example, if the departure occurs at the 20th hour of June 5th, 2018 at the origin station, the local date/time portion should be `2018-06-05T20:00:00`. If the local date/time at the origin station is 4 hours before UTC, an offset of `-04:00` may be appended. Without offset information, some rich features may not be available. + * `destinationName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The destination name. + * `destinationStationCode` (*type:* `String.t`, *default:* `nil`) - The destination station code. + * `fareName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Short description/name of the fare for this leg of travel. Eg "Anytime Single Use". + * `originName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The name of the origin station. This is required if `desinationName` is present or if `originStationCode` is not present. + * `originStationCode` (*type:* `String.t`, *default:* `nil`) - The origin station code. This is required if `destinationStationCode` is present or if `originName` is not present. + * `platform` (*type:* `String.t`, *default:* `nil`) - The platform or gate where the passenger can board the carriage. + * `ticketSeat` (*type:* `GoogleApi.WalletObjects.V1.Model.TicketSeat.t`, *default:* `nil`) - The reserved seat for the passenger(s). If more than one seat is to be specified then use the `ticketSeats` field instead. Both `ticketSeat` and `ticketSeats` may not be set. + * `ticketSeats` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TicketSeat.t)`, *default:* `nil`) - The reserved seat for the passenger(s). If only one seat is to be specified then use the `ticketSeat` field instead. Both `ticketSeat` and `ticketSeats` may not be set. + * `transitOperatorName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The name of the transit operator that is operating this leg of a trip. + * `transitTerminusName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Terminus station or destination of the train/bus/etc. + * `zone` (*type:* `String.t`, *default:* `nil`) - The zone of boarding within the platform. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :arrivalDateTime => String.t() | nil, + :carriage => String.t() | nil, + :departureDateTime => String.t() | nil, + :destinationName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :destinationStationCode => String.t() | nil, + :fareName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :originName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :originStationCode => String.t() | nil, + :platform => String.t() | nil, + :ticketSeat => GoogleApi.WalletObjects.V1.Model.TicketSeat.t() | nil, + :ticketSeats => list(GoogleApi.WalletObjects.V1.Model.TicketSeat.t()) | nil, + :transitOperatorName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :transitTerminusName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :zone => String.t() | nil + } + + field(:arrivalDateTime) + field(:carriage) + field(:departureDateTime) + field(:destinationName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:destinationStationCode) + field(:fareName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:originName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:originStationCode) + field(:platform) + field(:ticketSeat, as: GoogleApi.WalletObjects.V1.Model.TicketSeat) + field(:ticketSeats, as: GoogleApi.WalletObjects.V1.Model.TicketSeat, type: :list) + field(:transitOperatorName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:transitTerminusName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:zone) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TicketLeg do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TicketLeg.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TicketLeg do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_restrictions.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_restrictions.ex new file mode 100644 index 0000000000..b6cc721543 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_restrictions.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TicketRestrictions do + @moduledoc """ + + + ## Attributes + + * `otherRestrictions` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Extra restrictions that don't fall under the "route" or "time" categories. + * `routeRestrictions` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Restrictions about routes that may be taken. For example, this may be the string "Reserved CrossCountry trains only". + * `routeRestrictionsDetails` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - More details about the above `routeRestrictions`. + * `timeRestrictions` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Restrictions about times this ticket may be used. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :otherRestrictions => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :routeRestrictions => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :routeRestrictionsDetails => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :timeRestrictions => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:otherRestrictions, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:routeRestrictions, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:routeRestrictionsDetails, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:timeRestrictions, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TicketRestrictions do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TicketRestrictions.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TicketRestrictions do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_seat.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_seat.ex new file mode 100644 index 0000000000..41a2d79db5 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/ticket_seat.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TicketSeat do + @moduledoc """ + + + ## Attributes + + * `coach` (*type:* `String.t`, *default:* `nil`) - The identifier of the train car or coach in which the ticketed seat is located. Eg. "10" + * `customFareClass` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custome fare class to be used if no `fareClass` applies. Both `fareClass` and `customFareClass` may not be set. + * `fareClass` (*type:* `String.t`, *default:* `nil`) - The fare class of the ticketed seat. + * `seat` (*type:* `String.t`, *default:* `nil`) - The identifier of where the ticketed seat is located. Eg. "42". If there is no specific identifier, use `seatAssigment` instead. + * `seatAssignment` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The passenger's seat assignment. Eg. "no specific seat". To be used when there is no specific identifier to use in `seat`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :coach => String.t() | nil, + :customFareClass => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :fareClass => String.t() | nil, + :seat => String.t() | nil, + :seatAssignment => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:coach) + field(:customFareClass, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:fareClass) + field(:seat) + field(:seatAssignment, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TicketSeat do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TicketSeat.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TicketSeat do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/time_interval.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/time_interval.ex new file mode 100644 index 0000000000..572bc296d4 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/time_interval.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TimeInterval do + @moduledoc """ + + + ## Attributes + + * `end` (*type:* `GoogleApi.WalletObjects.V1.Model.DateTime.t`, *default:* `nil`) - End time of the interval. Offset is not required. If an offset is provided and `start` time is set, `start` must also include an offset. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#timeInterval"`. + * `start` (*type:* `GoogleApi.WalletObjects.V1.Model.DateTime.t`, *default:* `nil`) - Start time of the interval. Offset is not required. If an offset is provided and `end` time is set, `end` must also include an offset. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :end => GoogleApi.WalletObjects.V1.Model.DateTime.t() | nil, + :kind => String.t() | nil, + :start => GoogleApi.WalletObjects.V1.Model.DateTime.t() | nil + } + + field(:end, as: GoogleApi.WalletObjects.V1.Model.DateTime) + field(:kind) + field(:start, as: GoogleApi.WalletObjects.V1.Model.DateTime) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TimeInterval do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TimeInterval.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TimeInterval do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class.ex new file mode 100644 index 0000000000..d6c9529ff7 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class.ex @@ -0,0 +1,211 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitClass do + @moduledoc """ + + + ## Attributes + + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `customCarriageLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the carriage value (`transitObject.ticketLeg.carriage`). + * `transitType` (*type:* `String.t`, *default:* `nil`) - Required. The type of transit this class represents, such as "bus". + * `customZoneLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the boarding zone value (`transitObject.ticketLeg.zone`). + * `customFareClassLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the fare class value (`transitObject.ticketLeg.ticketSeat.fareClass`). + * `customTicketNumberLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the ticket number value (`transitObject.ticketNumber`). + * `homepageUri` (*type:* `GoogleApi.WalletObjects.V1.Model.Uri.t`, *default:* `nil`) - The URI of your application's home page. Populating the URI in this field results in the exact same behavior as populating an URI in linksModuleData (when an object is rendered, a link to the homepage is shown in what would usually be thought of as the linksModuleData section of the object). + * `wordMark` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Deprecated. + * `countryCode` (*type:* `String.t`, *default:* `nil`) - Country code used to display the card's country (when the user is not in that country), as well as to display localized content when content is not available in the user's locale. + * `customRouteRestrictionsLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the route restrictions value (`transitObject.ticketRestrictions.routeRestrictions`). + * `classTemplateInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t`, *default:* `nil`) - Template information about how the class should be displayed. If unset, Google will fallback to a default set of fields to display. + * `customPurchaseFaceValueLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the purchase face value (`transitObject.purchaseDetails.ticketCost.faceValue`). + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the object, both will be displayed. + * `customTransitTerminusNameLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the transit terminus name value (`transitObject.ticketLeg.transitTerminusName`). + * `localizedIssuerName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the issuer_name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `multipleDevicesAndHoldersAllowedStatus` (*type:* `String.t`, *default:* `nil`) - Identifies whether multiple users and devices will save the same object referencing this class. + * `customPurchaseReceiptNumberLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the purchase receipt number value (`transitObject.purchaseDetails.purchaseReceiptNumber`). + * `customTimeRestrictionsLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the time restrictions details value (`transitObject.ticketRestrictions.timeRestrictions`). + * `issuerName` (*type:* `String.t`, *default:* `nil`) - Required. The issuer name. Recommended maximum length is 20 characters to ensure full string is displayed on smaller screens. + * `customFareNameLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the transit fare name value (`transitObject.ticketLeg.fareName`). + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `customOtherRestrictionsLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the other restrictions value (`transitObject.ticketRestrictions.otherRestrictions`). + * `securityAnimation` (*type:* `GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t`, *default:* `nil`) - Optional information about the security animation. If this is set a security animation will be rendered on pass details. + * `callbackOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.CallbackOptions.t`, *default:* `nil`) - Callback options to be used to call the issuer back for every save/delete of an object for this class by the end-user. All objects of this class are eligible for the callback. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + * `watermark` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Watermark image to display on the user's device. + * `viewUnlockRequirement` (*type:* `String.t`, *default:* `nil`) - View Unlock Requirement options for the transit ticket. + * `customDiscountMessageLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the transit discount message value (`transitObject.purchaseDetails.ticketCost.discountMessage`). + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `customConcessionCategoryLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the transit concession category value (`transitObject.concessionCategory`). + * `activationOptions` (*type:* `GoogleApi.WalletObjects.V1.Model.ActivationOptions.t`, *default:* `nil`) - Activation options for an activatable ticket. + * `languageOverride` (*type:* `String.t`, *default:* `nil`) - If this field is present, transit tickets served to a user's device will always be in this language. Represents the BCP 47 language tag. Example values are "en-US", "en-GB", "de", or "de-AT". + * `customSeatLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the seat location value (`transitObject.ticketLeg.ticketSeat.seat`). + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `customConfirmationCodeLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the confirmation code value (`transitObject.purchaseDetails.confirmationCode`). + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, nothing will be displayed. The image will display at 100% width. + * `customPurchasePriceLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the purchase price value (`transitObject.purchaseDetails.ticketCost.purchasePrice`). + * `logo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Required. The logo image of the ticket. This image is displayed in the card detail view of the app. + * `transitOperatorName` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - The name of the transit operator. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for a class. This ID must be unique across all classes from an issuer. This value should follow the format issuer ID. identifier where the former is issued by Google and latter is chosen by you. Your unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `enableSmartTap` (*type:* `boolean()`, *default:* `nil`) - Identifies whether this class supports Smart Tap. The `redemptionIssuers` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `reviewStatus` (*type:* `String.t`, *default:* `nil`) - Required. The status of the class. This field can be set to `draft` or `underReview` using the insert, patch, or update API calls. Once the review state is changed from `draft` it may not be changed back to `draft`. You should keep this field to `draft` when the class is under development. A `draft` class cannot be used to create any object. You should set this field to `underReview` when you believe the class is ready for use. The platform will automatically set this field to `approved` and it can be immediately used to create or migrate objects. When updating an already `approved` class you should keep setting this field to `underReview`. + * `allowMultipleUsersPerObject` (*type:* `boolean()`, *default:* `nil`) - Deprecated. Use `multipleDevicesAndHoldersAllowedStatus` instead. + * `wideLogo` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - The wide logo of the ticket. When provided, this will be used in place of the logo in the top left of the card view. + * `enableSingleLegItinerary` (*type:* `boolean()`, *default:* `nil`) - Controls the display of the single-leg itinerary for this class. By default, an itinerary will only display for multi-leg trips. + * `review` (*type:* `GoogleApi.WalletObjects.V1.Model.Review.t`, *default:* `nil`) - The review comments set by the platform when a class is marked `approved` or `rejected`. + * `customRouteRestrictionsDetailsLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the route restrictions details value (`transitObject.ticketRestrictions.routeRestrictionsDetails`). + * `redemptionIssuers` (*type:* `list(String.t)`, *default:* `nil`) - Identifies which redemption issuers can redeem the pass over Smart Tap. Redemption issuers are identified by their issuer ID. Redemption issuers must have at least one Smart Tap key configured. The `enableSmartTap` and object level `smartTapRedemptionLevel` fields must also be set up correctly in order for a pass to support Smart Tap. + * `customPlatformLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the boarding platform value (`transitObject.ticketLeg.platform`). + * `customCoachLabel` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom label to use for the coach value (`transitObject.ticketLeg.ticketSeat.coach`). + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :customCarriageLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :transitType => String.t() | nil, + :customZoneLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :customFareClassLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :customTicketNumberLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :homepageUri => GoogleApi.WalletObjects.V1.Model.Uri.t() | nil, + :wordMark => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :countryCode => String.t() | nil, + :customRouteRestrictionsLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :classTemplateInfo => GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo.t() | nil, + :customPurchaseFaceValueLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :customTransitTerminusNameLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :localizedIssuerName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :multipleDevicesAndHoldersAllowedStatus => String.t() | nil, + :customPurchaseReceiptNumberLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :customTimeRestrictionsLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :issuerName => String.t() | nil, + :customFareNameLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :hexBackgroundColor => String.t() | nil, + :customOtherRestrictionsLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :securityAnimation => GoogleApi.WalletObjects.V1.Model.SecurityAnimation.t() | nil, + :callbackOptions => GoogleApi.WalletObjects.V1.Model.CallbackOptions.t() | nil, + :version => String.t() | nil, + :watermark => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :viewUnlockRequirement => String.t() | nil, + :customDiscountMessageLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :customConcessionCategoryLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :activationOptions => GoogleApi.WalletObjects.V1.Model.ActivationOptions.t() | nil, + :languageOverride => String.t() | nil, + :customSeatLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :customConfirmationCodeLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :customPurchasePriceLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :logo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :transitOperatorName => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :enableSmartTap => boolean() | nil, + :reviewStatus => String.t() | nil, + :allowMultipleUsersPerObject => boolean() | nil, + :wideLogo => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :enableSingleLegItinerary => boolean() | nil, + :review => GoogleApi.WalletObjects.V1.Model.Review.t() | nil, + :customRouteRestrictionsDetailsLabel => + GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :redemptionIssuers => list(String.t()) | nil, + :customPlatformLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :customCoachLabel => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil + } + + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:customCarriageLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:transitType) + field(:customZoneLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:customFareClassLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:customTicketNumberLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:homepageUri, as: GoogleApi.WalletObjects.V1.Model.Uri) + field(:wordMark, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:countryCode) + field(:customRouteRestrictionsLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:classTemplateInfo, as: GoogleApi.WalletObjects.V1.Model.ClassTemplateInfo) + field(:customPurchaseFaceValueLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:customTransitTerminusNameLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:localizedIssuerName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:multipleDevicesAndHoldersAllowedStatus) + field(:customPurchaseReceiptNumberLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:customTimeRestrictionsLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:issuerName) + field(:customFareNameLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:hexBackgroundColor) + field(:customOtherRestrictionsLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:securityAnimation, as: GoogleApi.WalletObjects.V1.Model.SecurityAnimation) + field(:callbackOptions, as: GoogleApi.WalletObjects.V1.Model.CallbackOptions) + field(:version) + field(:watermark, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:viewUnlockRequirement) + field(:customDiscountMessageLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:customConcessionCategoryLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:activationOptions, as: GoogleApi.WalletObjects.V1.Model.ActivationOptions) + field(:languageOverride) + field(:customSeatLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:customConfirmationCodeLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:customPurchasePriceLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:logo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:transitOperatorName, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:enableSmartTap) + field(:reviewStatus) + field(:allowMultipleUsersPerObject) + field(:wideLogo, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:enableSingleLegItinerary) + field(:review, as: GoogleApi.WalletObjects.V1.Model.Review) + + field(:customRouteRestrictionsDetailsLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + + field(:redemptionIssuers, type: :list) + field(:customPlatformLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:customCoachLabel, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TransitClass do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitClass.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TransitClass do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_add_message_response.ex new file mode 100644 index 0000000000..deea8983d1 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitClassAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitClass.t`, *default:* `nil`) - The updated TransitClass resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.TransitClass.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.TransitClass) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TransitClassAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitClassAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TransitClassAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_list_response.ex new file mode 100644 index 0000000000..1f7c2a28b1 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_class_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitClassListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TransitClass.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.TransitClass.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.TransitClass, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TransitClassListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitClassListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TransitClassListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object.ex new file mode 100644 index 0000000000..5da57502db --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object.ex @@ -0,0 +1,157 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitObject do + @moduledoc """ + + + ## Attributes + + * `messages` (*type:* `list(GoogleApi.WalletObjects.V1.Model.Message.t)`, *default:* `nil`) - An array of messages displayed in the app. All users of this object will receive its associated messages. The maximum number of these fields is 10. + * `passengerNames` (*type:* `String.t`, *default:* `nil`) - The name(s) of the passengers the ticket is assigned to. The above `passengerType` field is meant to give Google context on this field. + * `tripType` (*type:* `String.t`, *default:* `nil`) - Required. The type of trip this transit object represents. Used to determine the pass title and/or which symbol to use between the origin and destination. + * `passengerType` (*type:* `String.t`, *default:* `nil`) - The number of passengers. + * `passConstraints` (*type:* `GoogleApi.WalletObjects.V1.Model.PassConstraints.t`, *default:* `nil`) - Pass constraints for the object. Includes limiting NFC and screenshot behaviors. + * `activationStatus` (*type:* `GoogleApi.WalletObjects.V1.Model.ActivationStatus.t`, *default:* `nil`) - The activation status for the object. Required if the class has `activationOptions` set. + * `tripId` (*type:* `String.t`, *default:* `nil`) - This id is used to group tickets together if the user has saved multiple tickets for the same trip. + * `linksModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.LinksModuleData.t`, *default:* `nil`) - Links module data. If links module data is also defined on the class, both will be displayed. + * `smartTapRedemptionValue` (*type:* `String.t`, *default:* `nil`) - The value that will be transmitted to a Smart Tap certified terminal over NFC for this object. The class level fields `enableSmartTap` and `redemptionIssuers` must also be set up correctly in order for the pass to support Smart Tap. Only ASCII characters are supported. + * `ticketStatus` (*type:* `String.t`, *default:* `nil`) - The status of the ticket. For states which affect display, use the `state` field instead. + * `hasUsers` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object has users. This field is set by the platform. + * `state` (*type:* `String.t`, *default:* `nil`) - Required. The state of the object. This field is used to determine how an object is displayed in the app. For example, an `inactive` object is moved to the "Expired passes" section. + * `hexBackgroundColor` (*type:* `String.t`, *default:* `nil`) - The background color for the card. If not set the dominant color of the hero image is used, and if no hero image is set, the dominant color of the logo is used. The format is #rrggbb where rrggbb is a hex RGB triplet, such as `#ffcc00`. You can also use the shorthand version of the RGB triplet which is #rgb, such as `#fc0`. + * `customTicketStatus` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom status to use for the ticket status value when `ticketStatus` does not provide the right option. Both `ticketStatus` and `customTicketStatus` may not be set. + * `ticketRestrictions` (*type:* `GoogleApi.WalletObjects.V1.Model.TicketRestrictions.t`, *default:* `nil`) - Information about what kind of restrictions there are on using this ticket. For example, which days of the week it must be used, or which routes are allowed to be taken. + * `classReference` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitClass.t`, *default:* `nil`) - A copy of the inherited fields of the parent class. These fields are retrieved during a GET. + * `version` (*type:* `String.t`, *default:* `nil`) - Deprecated + * `classId` (*type:* `String.t`, *default:* `nil`) - Required. The class associated with this object. The class must be of the same type as this object, must already exist, and must be approved. Class IDs should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. + * `ticketLeg` (*type:* `GoogleApi.WalletObjects.V1.Model.TicketLeg.t`, *default:* `nil`) - A single ticket leg contains departure and arrival information along with boarding and seating information. If more than one leg is to be specified then use the `ticketLegs` field instead. Both `ticketLeg` and `ticketLegs` may not be set. + * `hasLinkedDevice` (*type:* `boolean()`, *default:* `nil`) - Whether this object is currently linked to a single device. This field is set by the platform when a user saves the object, linking it to their device. Intended for use by select partners. Contact support for additional information. + * `textModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t)`, *default:* `nil`) - Text module data. If text module data is also defined on the class, both will be displayed. The maximum number of these fields displayed is 10 from the object and 10 from the class. + * `locations` (*type:* `list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t)`, *default:* `nil`) - Note: This field is currently not supported to trigger geo notifications. + * `validTimeInterval` (*type:* `GoogleApi.WalletObjects.V1.Model.TimeInterval.t`, *default:* `nil`) - The time period this object will be `active` and object can be used. An object's state will be changed to `expired` when this time period has passed. + * `infoModuleData` (*type:* `GoogleApi.WalletObjects.V1.Model.InfoModuleData.t`, *default:* `nil`) - Deprecated. Use textModulesData instead. + * `heroImage` (*type:* `GoogleApi.WalletObjects.V1.Model.Image.t`, *default:* `nil`) - Optional banner image displayed on the front of the card. If none is present, hero image of the class, if present, will be displayed. If hero image of the class is also not present, nothing will be displayed. + * `deviceContext` (*type:* `GoogleApi.WalletObjects.V1.Model.DeviceContext.t`, *default:* `nil`) - Device context associated with the object. + * `id` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier for an object. This ID must be unique across all objects from an issuer. This value should follow the format issuer ID.identifier where the former is issued by Google and latter is chosen by you. The unique identifier should only include alphanumeric characters, '.', '_', or '-'. + * `imageModulesData` (*type:* `list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t)`, *default:* `nil`) - Image module data. The maximum number of these fields displayed is 1 from object level and 1 for class object level. + * `disableExpirationNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if notifications should explicitly be suppressed. If this field is set to true, regardless of the `messages` field, expiration notifications to the user will be suppressed. By default, this field is set to false. Currently, this can only be set for offers. + * `concessionCategory` (*type:* `String.t`, *default:* `nil`) - The concession category for the ticket. + * `customConcessionCategory` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - A custom concession category to use when `concessionCategory` does not provide the right option. Both `concessionCategory` and `customConcessionCategory` may not be set. + * `groupingInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.GroupingInfo.t`, *default:* `nil`) - Information that controls how passes are grouped together. + * `appLinkData` (*type:* `GoogleApi.WalletObjects.V1.Model.AppLinkData.t`, *default:* `nil`) - Optional information about the partner app link. + * `ticketNumber` (*type:* `String.t`, *default:* `nil`) - The number of the ticket. This is a unique identifier for the ticket in the transit operator's system. + * `rotatingBarcode` (*type:* `GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t`, *default:* `nil`) - The rotating barcode type and value. + * `ticketLegs` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TicketLeg.t)`, *default:* `nil`) - Each ticket may contain one or more legs. Each leg contains departure and arrival information along with boarding and seating information. If only one leg is to be specified then use the `ticketLeg` field instead. Both `ticketLeg` and `ticketLegs` may not be set. + * `purchaseDetails` (*type:* `GoogleApi.WalletObjects.V1.Model.PurchaseDetails.t`, *default:* `nil`) - Purchase details for this ticket. + * `barcode` (*type:* `GoogleApi.WalletObjects.V1.Model.Barcode.t`, *default:* `nil`) - The barcode type and value. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :messages => list(GoogleApi.WalletObjects.V1.Model.Message.t()) | nil, + :passengerNames => String.t() | nil, + :tripType => String.t() | nil, + :passengerType => String.t() | nil, + :passConstraints => GoogleApi.WalletObjects.V1.Model.PassConstraints.t() | nil, + :activationStatus => GoogleApi.WalletObjects.V1.Model.ActivationStatus.t() | nil, + :tripId => String.t() | nil, + :linksModuleData => GoogleApi.WalletObjects.V1.Model.LinksModuleData.t() | nil, + :smartTapRedemptionValue => String.t() | nil, + :ticketStatus => String.t() | nil, + :hasUsers => boolean() | nil, + :state => String.t() | nil, + :hexBackgroundColor => String.t() | nil, + :customTicketStatus => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :ticketRestrictions => GoogleApi.WalletObjects.V1.Model.TicketRestrictions.t() | nil, + :classReference => GoogleApi.WalletObjects.V1.Model.TransitClass.t() | nil, + :version => String.t() | nil, + :classId => String.t() | nil, + :ticketLeg => GoogleApi.WalletObjects.V1.Model.TicketLeg.t() | nil, + :hasLinkedDevice => boolean() | nil, + :textModulesData => list(GoogleApi.WalletObjects.V1.Model.TextModuleData.t()) | nil, + :locations => list(GoogleApi.WalletObjects.V1.Model.LatLongPoint.t()) | nil, + :validTimeInterval => GoogleApi.WalletObjects.V1.Model.TimeInterval.t() | nil, + :infoModuleData => GoogleApi.WalletObjects.V1.Model.InfoModuleData.t() | nil, + :heroImage => GoogleApi.WalletObjects.V1.Model.Image.t() | nil, + :deviceContext => GoogleApi.WalletObjects.V1.Model.DeviceContext.t() | nil, + :id => String.t() | nil, + :imageModulesData => list(GoogleApi.WalletObjects.V1.Model.ImageModuleData.t()) | nil, + :disableExpirationNotification => boolean() | nil, + :concessionCategory => String.t() | nil, + :customConcessionCategory => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :groupingInfo => GoogleApi.WalletObjects.V1.Model.GroupingInfo.t() | nil, + :appLinkData => GoogleApi.WalletObjects.V1.Model.AppLinkData.t() | nil, + :ticketNumber => String.t() | nil, + :rotatingBarcode => GoogleApi.WalletObjects.V1.Model.RotatingBarcode.t() | nil, + :ticketLegs => list(GoogleApi.WalletObjects.V1.Model.TicketLeg.t()) | nil, + :purchaseDetails => GoogleApi.WalletObjects.V1.Model.PurchaseDetails.t() | nil, + :barcode => GoogleApi.WalletObjects.V1.Model.Barcode.t() | nil + } + + field(:messages, as: GoogleApi.WalletObjects.V1.Model.Message, type: :list) + field(:passengerNames) + field(:tripType) + field(:passengerType) + field(:passConstraints, as: GoogleApi.WalletObjects.V1.Model.PassConstraints) + field(:activationStatus, as: GoogleApi.WalletObjects.V1.Model.ActivationStatus) + field(:tripId) + field(:linksModuleData, as: GoogleApi.WalletObjects.V1.Model.LinksModuleData) + field(:smartTapRedemptionValue) + field(:ticketStatus) + field(:hasUsers) + field(:state) + field(:hexBackgroundColor) + field(:customTicketStatus, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:ticketRestrictions, as: GoogleApi.WalletObjects.V1.Model.TicketRestrictions) + field(:classReference, as: GoogleApi.WalletObjects.V1.Model.TransitClass) + field(:version) + field(:classId) + field(:ticketLeg, as: GoogleApi.WalletObjects.V1.Model.TicketLeg) + field(:hasLinkedDevice) + field(:textModulesData, as: GoogleApi.WalletObjects.V1.Model.TextModuleData, type: :list) + field(:locations, as: GoogleApi.WalletObjects.V1.Model.LatLongPoint, type: :list) + field(:validTimeInterval, as: GoogleApi.WalletObjects.V1.Model.TimeInterval) + field(:infoModuleData, as: GoogleApi.WalletObjects.V1.Model.InfoModuleData) + field(:heroImage, as: GoogleApi.WalletObjects.V1.Model.Image) + field(:deviceContext, as: GoogleApi.WalletObjects.V1.Model.DeviceContext) + field(:id) + field(:imageModulesData, as: GoogleApi.WalletObjects.V1.Model.ImageModuleData, type: :list) + field(:disableExpirationNotification) + field(:concessionCategory) + field(:customConcessionCategory, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:groupingInfo, as: GoogleApi.WalletObjects.V1.Model.GroupingInfo) + field(:appLinkData, as: GoogleApi.WalletObjects.V1.Model.AppLinkData) + field(:ticketNumber) + field(:rotatingBarcode, as: GoogleApi.WalletObjects.V1.Model.RotatingBarcode) + field(:ticketLegs, as: GoogleApi.WalletObjects.V1.Model.TicketLeg, type: :list) + field(:purchaseDetails, as: GoogleApi.WalletObjects.V1.Model.PurchaseDetails) + field(:barcode, as: GoogleApi.WalletObjects.V1.Model.Barcode) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TransitObject do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitObject.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TransitObject do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_add_message_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_add_message_response.ex new file mode 100644 index 0000000000..2bf38a3d2e --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_add_message_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitObjectAddMessageResponse do + @moduledoc """ + + + ## Attributes + + * `resource` (*type:* `GoogleApi.WalletObjects.V1.Model.TransitObject.t`, *default:* `nil`) - The updated TransitObject resource. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :resource => GoogleApi.WalletObjects.V1.Model.TransitObject.t() | nil + } + + field(:resource, as: GoogleApi.WalletObjects.V1.Model.TransitObject) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TransitObjectAddMessageResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitObjectAddMessageResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TransitObjectAddMessageResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_list_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_list_response.ex new file mode 100644 index 0000000000..27f98f3045 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_list_response.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitObjectListResponse do + @moduledoc """ + + + ## Attributes + + * `pagination` (*type:* `GoogleApi.WalletObjects.V1.Model.Pagination.t`, *default:* `nil`) - Pagination of the response. + * `resources` (*type:* `list(GoogleApi.WalletObjects.V1.Model.TransitObject.t)`, *default:* `nil`) - Resources corresponding to the list request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :pagination => GoogleApi.WalletObjects.V1.Model.Pagination.t() | nil, + :resources => list(GoogleApi.WalletObjects.V1.Model.TransitObject.t()) | nil + } + + field(:pagination, as: GoogleApi.WalletObjects.V1.Model.Pagination) + field(:resources, as: GoogleApi.WalletObjects.V1.Model.TransitObject, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TransitObjectListResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitObjectListResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TransitObjectListResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_request.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_request.ex new file mode 100644 index 0000000000..ce391630b5 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_request.ex @@ -0,0 +1,54 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest do + @moduledoc """ + Request to upload rotating barcode values. + + ## Attributes + + * `blob` (*type:* `GoogleApi.WalletObjects.V1.Model.Media.t`, *default:* `nil`) - A reference to the rotating barcode values payload that was uploaded. + * `mediaRequestInfo` (*type:* `GoogleApi.WalletObjects.V1.Model.MediaRequestInfo.t`, *default:* `nil`) - Extra information about the uploaded media. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :blob => GoogleApi.WalletObjects.V1.Model.Media.t() | nil, + :mediaRequestInfo => GoogleApi.WalletObjects.V1.Model.MediaRequestInfo.t() | nil + } + + field(:blob, as: GoogleApi.WalletObjects.V1.Model.Media) + field(:mediaRequestInfo, as: GoogleApi.WalletObjects.V1.Model.MediaRequestInfo) +end + +defimpl Poison.Decoder, + for: GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_response.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_response.ex new file mode 100644 index 0000000000..b5e9829223 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/transit_object_upload_rotating_barcode_values_response.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse do + @moduledoc """ + Response for uploading rotating barcode values. + + ## Attributes + + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{} +end + +defimpl Poison.Decoder, + for: GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.WalletObjects.V1.Model.TransitObjectUploadRotatingBarcodeValuesResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/translated_string.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/translated_string.ex new file mode 100644 index 0000000000..1940053b87 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/translated_string.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.TranslatedString do + @moduledoc """ + + + ## Attributes + + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#translatedString"`. + * `language` (*type:* `String.t`, *default:* `nil`) - Represents the BCP 47 language tag. Example values are "en-US", "en-GB", "de", or "de-AT". + * `value` (*type:* `String.t`, *default:* `nil`) - The UTF-8 encoded translated string. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kind => String.t() | nil, + :language => String.t() | nil, + :value => String.t() | nil + } + + field(:kind) + field(:language) + field(:value) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.TranslatedString do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.TranslatedString.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.TranslatedString do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/upcoming_notification.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/upcoming_notification.ex new file mode 100644 index 0000000000..69b9f71a50 --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/upcoming_notification.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.UpcomingNotification do + @moduledoc """ + Indicates that the issuer would like Google Wallet to send an upcoming card validity notification 1 day before card becomes valid/usable. + + ## Attributes + + * `enableNotification` (*type:* `boolean()`, *default:* `nil`) - Indicates if the object needs to have upcoming notification enabled. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :enableNotification => boolean() | nil + } + + field(:enableNotification) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.UpcomingNotification do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.UpcomingNotification.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.UpcomingNotification do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/uri.ex b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/uri.ex new file mode 100644 index 0000000000..c64a16d54f --- /dev/null +++ b/clients/wallet_objects/lib/google_api/wallet_objects/v1/model/uri.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.V1.Model.Uri do + @moduledoc """ + + + ## Attributes + + * `description` (*type:* `String.t`, *default:* `nil`) - The URI's title appearing in the app as text. Recommended maximum is 20 characters to ensure full string is displayed on smaller screens. Note that in some contexts this text is not used, such as when `description` is part of an image. + * `id` (*type:* `String.t`, *default:* `nil`) - The ID associated with a uri. This field is here to enable ease of management of uris. + * `kind` (*type:* `String.t`, *default:* `nil`) - Identifies what kind of resource this is. Value: the fixed string `"walletobjects#uri"`. + * `localizedDescription` (*type:* `GoogleApi.WalletObjects.V1.Model.LocalizedString.t`, *default:* `nil`) - Translated strings for the description. Recommended maximum is 20 characters to ensure full string is displayed on smaller screens. + * `uri` (*type:* `String.t`, *default:* `nil`) - The location of a web page, image, or other resource. URIs in the `LinksModuleData` module can have different prefixes indicating the type of URI (a link to a web page, a link to a map, a telephone number, or an email address). URIs must have a scheme. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :description => String.t() | nil, + :id => String.t() | nil, + :kind => String.t() | nil, + :localizedDescription => GoogleApi.WalletObjects.V1.Model.LocalizedString.t() | nil, + :uri => String.t() | nil + } + + field(:description) + field(:id) + field(:kind) + field(:localizedDescription, as: GoogleApi.WalletObjects.V1.Model.LocalizedString) + field(:uri) +end + +defimpl Poison.Decoder, for: GoogleApi.WalletObjects.V1.Model.Uri do + def decode(value, options) do + GoogleApi.WalletObjects.V1.Model.Uri.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.WalletObjects.V1.Model.Uri do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/wallet_objects/mix.exs b/clients/wallet_objects/mix.exs new file mode 100644 index 0000000000..fa75a06c04 --- /dev/null +++ b/clients/wallet_objects/mix.exs @@ -0,0 +1,66 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.WalletObjects.Mixfile do + use Mix.Project + + @version "0.2.0" + + def project() do + [ + app: :google_api_wallet_objects, + version: @version, + elixir: "~> 1.6", + build_embedded: Mix.env == :prod, + start_permanent: Mix.env == :prod, + description: description(), + package: package(), + deps: deps(), + source_url: "https://github.com/googleapis/elixir-google-api/tree/master/clients/wallet_objects" + ] + end + + def application() do + [extra_applications: [:logger]] + end + + defp deps() do + [ + {:google_gax, "~> 0.4"}, + + {:ex_doc, "~> 0.16", only: :dev} + ] + end + + defp description() do + """ + Google Wallet API client library. API for issuers to save and manage Google Wallet Objects. + """ + end + + defp package() do + [ + files: ["lib", "mix.exs", "README*", "LICENSE"], + maintainers: ["Jeff Ching", "Daniel Azuma"], + licenses: ["Apache 2.0"], + links: %{ + "GitHub" => "https://github.com/googleapis/elixir-google-api/tree/master/clients/wallet_objects", + "Homepage" => "https://developers.google.com/pay/passes" + } + ] + end +end diff --git a/clients/wallet_objects/test/test_helper.exs b/clients/wallet_objects/test/test_helper.exs new file mode 100644 index 0000000000..cb4f2da951 --- /dev/null +++ b/clients/wallet_objects/test/test_helper.exs @@ -0,0 +1,35 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +ExUnit.start() + +defmodule GoogleApi.WalletObjects.TestHelper do + + defmacro __using__(opts) do + quote do + use ExUnit.Case, unquote(opts) + import GoogleApi.WalletObjects.TestHelper + end + end + + def for_scope(scopes) when is_list(scopes), do: for_scope(Enum.join(scopes, " ")) + def for_scope(scope) do + {:ok, token} = Goth.Token.for_scope(scope) + token.token + end + +end