postfinancecheckout-ruby-sdk 3.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +8 -0
- data/LICENSE +201 -0
- data/README.md +137 -0
- data/Rakefile +13 -0
- data/lib/.DS_Store +0 -0
- data/lib/postfinancecheckout-ruby-sdk.rb +392 -0
- data/lib/postfinancecheckout-ruby-sdk/api/account_service_api.rb +368 -0
- data/lib/postfinancecheckout-ruby-sdk/api/application_user_service_api.rb +368 -0
- data/lib/postfinancecheckout-ruby-sdk/api/bank_account_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/bank_transaction_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/charge_attempt_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/charge_bank_transaction_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/charge_flow_level_payment_link_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/charge_flow_level_service_api.rb +276 -0
- data/lib/postfinancecheckout-ruby-sdk/api/charge_flow_service_api.rb +348 -0
- data/lib/postfinancecheckout-ruby-sdk/api/condition_type_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/country_service_api.rb +81 -0
- data/lib/postfinancecheckout-ruby-sdk/api/country_state_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/currency_bank_account_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/currency_service_api.rb +81 -0
- data/lib/postfinancecheckout-ruby-sdk/api/customer_address_service_api.rb +460 -0
- data/lib/postfinancecheckout-ruby-sdk/api/customer_comment_service_api.rb +522 -0
- data/lib/postfinancecheckout-ruby-sdk/api/customer_service_api.rb +398 -0
- data/lib/postfinancecheckout-ruby-sdk/api/delivery_indication_service_api.rb +337 -0
- data/lib/postfinancecheckout-ruby-sdk/api/document_template_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/document_template_type_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/external_transfer_bank_transaction_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/human_user_service_api.rb +425 -0
- data/lib/postfinancecheckout-ruby-sdk/api/internal_transfer_bank_transaction_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/label_description_group_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/label_description_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/language_service_api.rb +81 -0
- data/lib/postfinancecheckout-ruby-sdk/api/legal_organization_form_service_api.rb +197 -0
- data/lib/postfinancecheckout-ruby-sdk/api/manual_task_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_connector_configuration_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_connector_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_link_service_api.rb +398 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_method_brand_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_method_configuration_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_method_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_processor_configuration_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_processor_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_terminal_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/payment_terminal_till_service_api.rb +170 -0
- data/lib/postfinancecheckout-ruby-sdk/api/permission_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/refund_bank_transaction_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/refund_comment_service_api.rb +464 -0
- data/lib/postfinancecheckout-ruby-sdk/api/refund_recovery_bank_transaction_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/refund_service_api.rb +532 -0
- data/lib/postfinancecheckout-ruby-sdk/api/shopify_recurring_order_service_api.rb +274 -0
- data/lib/postfinancecheckout-ruby-sdk/api/shopify_subscriber_service_api.rb +275 -0
- data/lib/postfinancecheckout-ruby-sdk/api/shopify_subscription_product_service_api.rb +337 -0
- data/lib/postfinancecheckout-ruby-sdk/api/shopify_subscription_service_api.rb +466 -0
- data/lib/postfinancecheckout-ruby-sdk/api/shopify_subscription_suspension_service_api.rb +337 -0
- data/lib/postfinancecheckout-ruby-sdk/api/shopify_subscription_version_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/shopify_transaction_service_api.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/api/space_service_api.rb +368 -0
- data/lib/postfinancecheckout-ruby-sdk/api/static_value_service_api.rb +139 -0
- data/lib/postfinancecheckout-ruby-sdk/api/token_service_api.rb +650 -0
- data/lib/postfinancecheckout-ruby-sdk/api/token_version_service_api.rb +276 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_comment_service_api.rb +464 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_completion_service_api.rb +463 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_iframe_service_api.rb +91 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_invoice_comment_service_api.rb +464 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_invoice_service_api.rb +600 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_lightbox_service_api.rb +91 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_mobile_sdk_service_api.rb +86 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_payment_page_service_api.rb +91 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_service_api.rb +1210 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_terminal_service_api.rb +161 -0
- data/lib/postfinancecheckout-ruby-sdk/api/transaction_void_service_api.rb +339 -0
- data/lib/postfinancecheckout-ruby-sdk/api/user_account_role_service_api.rb +219 -0
- data/lib/postfinancecheckout-ruby-sdk/api/user_space_role_service_api.rb +216 -0
- data/lib/postfinancecheckout-ruby-sdk/api/webhook_listener_service_api.rb +398 -0
- data/lib/postfinancecheckout-ruby-sdk/api/webhook_url_service_api.rb +398 -0
- data/lib/postfinancecheckout-ruby-sdk/api_client.rb +405 -0
- data/lib/postfinancecheckout-ruby-sdk/api_error.rb +43 -0
- data/lib/postfinancecheckout-ruby-sdk/configuration.rb +140 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_account_update.rb +234 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_application_user_update.rb +225 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_customer_active.rb +312 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_customer_address_active.rb +200 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_customer_comment_active.rb +205 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_human_user_update.rb +320 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_payment_link_update.rb +309 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_refund_comment_active.rb +205 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_shopify_subscription_product_update.rb +320 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_space_update.rb +286 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_token_update.rb +270 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_transaction_comment_active.rb +205 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_transaction_invoice_comment_active.rb +205 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_transaction_pending.rb +486 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_webhook_listener_update.rb +237 -0
- data/lib/postfinancecheckout-ruby-sdk/models/abstract_webhook_url_update.rb +249 -0
- data/lib/postfinancecheckout-ruby-sdk/models/account.rb +375 -0
- data/lib/postfinancecheckout-ruby-sdk/models/account_create.rb +260 -0
- data/lib/postfinancecheckout-ruby-sdk/models/account_state.rb +39 -0
- data/lib/postfinancecheckout-ruby-sdk/models/account_type.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/account_update.rb +265 -0
- data/lib/postfinancecheckout-ruby-sdk/models/address.rb +606 -0
- data/lib/postfinancecheckout-ruby-sdk/models/address_create.rb +606 -0
- data/lib/postfinancecheckout-ruby-sdk/models/application_user.rb +286 -0
- data/lib/postfinancecheckout-ruby-sdk/models/application_user_create.rb +241 -0
- data/lib/postfinancecheckout-ruby-sdk/models/application_user_create_with_mac_key.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/application_user_update.rb +256 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_account.rb +291 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_account_environment.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_account_state.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_account_type.rb +227 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_transaction.rb +387 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_transaction_flow_direction.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_transaction_source.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_transaction_state.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/bank_transaction_type.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge.rb +331 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_attempt.rb +468 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_attempt_environment.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_attempt_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_bank_transaction.rb +291 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_flow.rb +263 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_flow_level.rb +311 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_flow_level_configuration.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_flow_level_configuration_type.rb +227 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_flow_level_payment_link.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_flow_level_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/charge_type.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/client_error.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/client_error_type.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/completion_line_item.rb +226 -0
- data/lib/postfinancecheckout-ruby-sdk/models/completion_line_item_create.rb +245 -0
- data/lib/postfinancecheckout-ruby-sdk/models/condition.rb +266 -0
- data/lib/postfinancecheckout-ruby-sdk/models/condition_type.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/connector_invocation.rb +271 -0
- data/lib/postfinancecheckout-ruby-sdk/models/connector_invocation_stage.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/creation_entity_state.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/criteria_operator.rb +45 -0
- data/lib/postfinancecheckout-ruby-sdk/models/currency_bank_account.rb +241 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer.rb +353 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_active.rb +343 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_address.rb +261 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_address_active.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_address_create.rb +216 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_address_type.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_comment.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_comment_active.rb +236 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_comment_create.rb +221 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_create.rb +313 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_postal_address.rb +606 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customer_postal_address_create.rb +606 -0
- data/lib/postfinancecheckout-ruby-sdk/models/customers_presence.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/data_collection_type.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/database_translated_string.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/database_translated_string_item.rb +226 -0
- data/lib/postfinancecheckout-ruby-sdk/models/delivery_indication.rb +321 -0
- data/lib/postfinancecheckout-ruby-sdk/models/delivery_indication_decision_reason.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/delivery_indication_state.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/document_template.rb +306 -0
- data/lib/postfinancecheckout-ruby-sdk/models/document_template_type.rb +235 -0
- data/lib/postfinancecheckout-ruby-sdk/models/document_template_type_group.rb +203 -0
- data/lib/postfinancecheckout-ruby-sdk/models/entity_export_request.rb +208 -0
- data/lib/postfinancecheckout-ruby-sdk/models/entity_query.rb +233 -0
- data/lib/postfinancecheckout-ruby-sdk/models/entity_query_filter.rb +238 -0
- data/lib/postfinancecheckout-ruby-sdk/models/entity_query_filter_type.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/entity_query_order_by.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/entity_query_order_by_type.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/environment.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/external_transfer_bank_transaction.rb +251 -0
- data/lib/postfinancecheckout-ruby-sdk/models/failure_category.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/failure_reason.rb +237 -0
- data/lib/postfinancecheckout-ruby-sdk/models/feature.rb +277 -0
- data/lib/postfinancecheckout-ruby-sdk/models/feature_category.rb +225 -0
- data/lib/postfinancecheckout-ruby-sdk/models/gender.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/human_user.rb +361 -0
- data/lib/postfinancecheckout-ruby-sdk/models/human_user_create.rb +331 -0
- data/lib/postfinancecheckout-ruby-sdk/models/human_user_update.rb +351 -0
- data/lib/postfinancecheckout-ruby-sdk/models/internal_transfer_bank_transaction.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/label.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/label_descriptor.rb +267 -0
- data/lib/postfinancecheckout-ruby-sdk/models/label_descriptor_category.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/label_descriptor_group.rb +225 -0
- data/lib/postfinancecheckout-ruby-sdk/models/label_descriptor_type.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/legal_organization_form.rb +235 -0
- data/lib/postfinancecheckout-ruby-sdk/models/line_item.rb +449 -0
- data/lib/postfinancecheckout-ruby-sdk/models/line_item_attribute.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/line_item_attribute_create.rb +249 -0
- data/lib/postfinancecheckout-ruby-sdk/models/line_item_create.rb +372 -0
- data/lib/postfinancecheckout-ruby-sdk/models/line_item_reduction.rb +226 -0
- data/lib/postfinancecheckout-ruby-sdk/models/line_item_reduction_create.rb +245 -0
- data/lib/postfinancecheckout-ruby-sdk/models/line_item_type.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/localized_string.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/manual_task.rb +283 -0
- data/lib/postfinancecheckout-ruby-sdk/models/manual_task_action.rb +223 -0
- data/lib/postfinancecheckout-ruby-sdk/models/manual_task_action_style.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/manual_task_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/manual_task_type.rb +227 -0
- data/lib/postfinancecheckout-ruby-sdk/models/one_click_payment_mode.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_adjustment.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_adjustment_type.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_connector.rb +321 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_connector_configuration.rb +342 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_connector_feature.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_contract.rb +331 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_contract_state.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_contract_type.rb +225 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_information_hash.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_information_hash_type.rb +203 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_link.rb +390 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_link_active.rb +350 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_link_address_handling_mode.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_link_create.rb +345 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_link_protection_mode.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_link_update.rb +340 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_method.rb +261 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_method_brand.rb +245 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_method_configuration.rb +370 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_primary_risk_taker.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_processor.rb +271 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_processor_configuration.rb +276 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal.rb +306 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_address.rb +396 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_configuration.rb +266 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_configuration_state.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_configuration_version.rb +323 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_configuration_version_state.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_location.rb +266 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_location_state.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_location_version.rb +281 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_location_version_state.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_receipt_type.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_state.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/payment_terminal_type.rb +215 -0
- data/lib/postfinancecheckout-ruby-sdk/models/permission.rb +299 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund.rb +567 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_bank_transaction.rb +281 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_comment.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_comment_active.rb +236 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_comment_create.rb +221 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_create.rb +306 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_recovery_bank_transaction.rb +293 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_state.rb +39 -0
- data/lib/postfinancecheckout-ruby-sdk/models/refund_type.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rendered_document.rb +223 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rendered_terminal_receipt.rb +223 -0
- data/lib/postfinancecheckout-ruby-sdk/models/resource_path.rb +275 -0
- data/lib/postfinancecheckout-ruby-sdk/models/resource_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rest_address_format.rb +227 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rest_address_format_field.rb +43 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rest_country.rb +243 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rest_country_state.rb +221 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rest_currency.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/rest_language.rb +241 -0
- data/lib/postfinancecheckout-ruby-sdk/models/role.rb +263 -0
- data/lib/postfinancecheckout-ruby-sdk/models/role_state.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/sales_channel.rb +245 -0
- data/lib/postfinancecheckout-ruby-sdk/models/scope.rb +350 -0
- data/lib/postfinancecheckout-ruby-sdk/models/server_error.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_additional_line_item_data.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_integration.rb +470 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_integration_payment_app_version.rb +34 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_integration_subscription_app_version.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_recurring_order.rb +351 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_recurring_order_state.rb +39 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_recurring_order_update_request.rb +201 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscriber.rb +281 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscriber_active.rb +241 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscriber_creation.rb +216 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscriber_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription.rb +375 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_address.rb +546 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_address_create.rb +546 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_billing_interval_unit.rb +39 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_creation_request.rb +363 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_model_billing_configuration.rb +271 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_model_item.rb +233 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_model_tax_line.rb +201 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_product.rb +471 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_product_create.rb +366 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_product_pricing_option.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_product_state.rb +39 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_product_update.rb +351 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_state.rb +39 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_suspension.rb +311 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_suspension_create.rb +226 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_suspension_initiator.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_suspension_state.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_suspension_type.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_update_addresses_request.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_update_request.rb +233 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_version.rb +463 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_version_item.rb +233 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_version_item_price_strategy.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_version_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_weekday.rb +40 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_tax_line.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_transaction.rb +301 -0
- data/lib/postfinancecheckout-ruby-sdk/models/shopify_transaction_state.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/space.rb +407 -0
- data/lib/postfinancecheckout-ruby-sdk/models/space_address.rb +416 -0
- data/lib/postfinancecheckout-ruby-sdk/models/space_address_create.rb +416 -0
- data/lib/postfinancecheckout-ruby-sdk/models/space_create.rb +302 -0
- data/lib/postfinancecheckout-ruby-sdk/models/space_update.rb +317 -0
- data/lib/postfinancecheckout-ruby-sdk/models/space_view.rb +275 -0
- data/lib/postfinancecheckout-ruby-sdk/models/static_value.rb +227 -0
- data/lib/postfinancecheckout-ruby-sdk/models/tax.rb +225 -0
- data/lib/postfinancecheckout-ruby-sdk/models/tax_create.rb +239 -0
- data/lib/postfinancecheckout-ruby-sdk/models/tenant_database.rb +226 -0
- data/lib/postfinancecheckout-ruby-sdk/models/terminal_receipt_fetch_request.rb +221 -0
- data/lib/postfinancecheckout-ruby-sdk/models/terminal_receipt_format.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/token.rb +341 -0
- data/lib/postfinancecheckout-ruby-sdk/models/token_create.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/token_update.rb +301 -0
- data/lib/postfinancecheckout-ruby-sdk/models/token_version.rb +445 -0
- data/lib/postfinancecheckout-ruby-sdk/models/token_version_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/token_version_type.rb +225 -0
- data/lib/postfinancecheckout-ruby-sdk/models/tokenization_mode.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction.rb +1011 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_aware_entity.rb +211 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_comment.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_comment_active.rb +236 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_comment_create.rb +221 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_completion.rb +528 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_completion_behavior.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_completion_mode.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_completion_request.rb +291 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_completion_state.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_create.rb +596 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_environment_selection_strategy.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_group.rb +276 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_group_state.rb +36 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_invoice.rb +452 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_invoice_comment.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_invoice_comment_active.rb +236 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_invoice_comment_create.rb +221 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_invoice_replacement.rb +296 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_invoice_state.rb +40 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_line_item_update_request.rb +208 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_line_item_version.rb +313 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_pending.rb +517 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_state.rb +43 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_user_interface_type.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_void.rb +373 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_void_mode.rb +35 -0
- data/lib/postfinancecheckout-ruby-sdk/models/transaction_void_state.rb +37 -0
- data/lib/postfinancecheckout-ruby-sdk/models/two_factor_authentication_type.rb +235 -0
- data/lib/postfinancecheckout-ruby-sdk/models/user.rb +241 -0
- data/lib/postfinancecheckout-ruby-sdk/models/user_account_role.rb +241 -0
- data/lib/postfinancecheckout-ruby-sdk/models/user_space_role.rb +231 -0
- data/lib/postfinancecheckout-ruby-sdk/models/user_type.rb +38 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_identity.rb +256 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_listener.rb +308 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_listener_create.rb +278 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_listener_entity.rb +213 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_listener_update.rb +268 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_url.rb +300 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_url_create.rb +250 -0
- data/lib/postfinancecheckout-ruby-sdk/models/webhook_url_update.rb +280 -0
- data/lib/postfinancecheckout-ruby-sdk/version.rb +20 -0
- data/postfinancecheckout-ruby-sdk.gemspec +44 -0
- data/test/condition_type_service_test.rb +22 -0
- data/test/transaction_create_service_test.rb +89 -0
- data/test/transaction_payment_page_service_test.rb +91 -0
- metadata +469 -0
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
The PostFinance Checkout API allows an easy interaction with the PostFinance Checkout web service.
|
3
|
+
|
4
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
+
you may not use this file except in compliance with the License.
|
6
|
+
You may obtain a copy of the License at
|
7
|
+
|
8
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
9
|
+
|
10
|
+
Unless required by applicable law or agreed to in writing, software
|
11
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
+
See the License for the specific language governing permissions and
|
14
|
+
limitations under the License.
|
15
|
+
|
16
|
+
=end
|
17
|
+
|
18
|
+
require 'date'
|
19
|
+
|
20
|
+
module PostFinanceCheckout
|
21
|
+
class ShopifySubscriptionBillingIntervalUnit
|
22
|
+
|
23
|
+
MINUTES = 'MINUTES'.freeze
|
24
|
+
HOURS = 'HOURS'.freeze
|
25
|
+
DAYS = 'DAYS'.freeze
|
26
|
+
WEEKS = 'WEEKS'.freeze
|
27
|
+
MONTHS = 'MONTHS'.freeze
|
28
|
+
YEARS = 'YEARS'.freeze
|
29
|
+
|
30
|
+
# Builds the enum from string
|
31
|
+
# @param [String] The enum value in the form of the string
|
32
|
+
# @return [String] The enum value
|
33
|
+
def build_from_hash(value)
|
34
|
+
constantValues = ShopifySubscriptionBillingIntervalUnit.constants.select { |c| ShopifySubscriptionBillingIntervalUnit::const_get(c) == value }
|
35
|
+
raise "Invalid ENUM value #{value} for class #ShopifySubscriptionBillingIntervalUnit" if constantValues.empty?
|
36
|
+
value
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,363 @@
|
|
1
|
+
=begin
|
2
|
+
The PostFinance Checkout API allows an easy interaction with the PostFinance Checkout web service.
|
3
|
+
|
4
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
+
you may not use this file except in compliance with the License.
|
6
|
+
You may obtain a copy of the License at
|
7
|
+
|
8
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
9
|
+
|
10
|
+
Unless required by applicable law or agreed to in writing, software
|
11
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
+
See the License for the specific language governing permissions and
|
14
|
+
limitations under the License.
|
15
|
+
|
16
|
+
=end
|
17
|
+
|
18
|
+
require 'date'
|
19
|
+
|
20
|
+
module PostFinanceCheckout
|
21
|
+
#
|
22
|
+
class ShopifySubscriptionCreationRequest
|
23
|
+
#
|
24
|
+
attr_accessor :billing_address
|
25
|
+
|
26
|
+
#
|
27
|
+
attr_accessor :billing_configuration
|
28
|
+
|
29
|
+
#
|
30
|
+
attr_accessor :currency
|
31
|
+
|
32
|
+
# A client generated nonce which identifies the entity to be created. Subsequent creation requests with the same external ID will not create new entities but return the initially created entity instead.
|
33
|
+
attr_accessor :external_id
|
34
|
+
|
35
|
+
#
|
36
|
+
attr_accessor :initial_execution_date
|
37
|
+
|
38
|
+
#
|
39
|
+
attr_accessor :integration
|
40
|
+
|
41
|
+
#
|
42
|
+
attr_accessor :items
|
43
|
+
|
44
|
+
#
|
45
|
+
attr_accessor :language
|
46
|
+
|
47
|
+
#
|
48
|
+
attr_accessor :shipping_address
|
49
|
+
|
50
|
+
#
|
51
|
+
attr_accessor :shipping_method_name
|
52
|
+
|
53
|
+
#
|
54
|
+
attr_accessor :space_view_id
|
55
|
+
|
56
|
+
#
|
57
|
+
attr_accessor :store_order_confirmation_email_enabled
|
58
|
+
|
59
|
+
#
|
60
|
+
attr_accessor :subscriber
|
61
|
+
|
62
|
+
#
|
63
|
+
attr_accessor :subscriber_suspension_allowed
|
64
|
+
|
65
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
66
|
+
def self.attribute_map
|
67
|
+
{
|
68
|
+
:'billing_address' => :'billingAddress',
|
69
|
+
:'billing_configuration' => :'billingConfiguration',
|
70
|
+
:'currency' => :'currency',
|
71
|
+
:'external_id' => :'externalId',
|
72
|
+
:'initial_execution_date' => :'initialExecutionDate',
|
73
|
+
:'integration' => :'integration',
|
74
|
+
:'items' => :'items',
|
75
|
+
:'language' => :'language',
|
76
|
+
:'shipping_address' => :'shippingAddress',
|
77
|
+
:'shipping_method_name' => :'shippingMethodName',
|
78
|
+
:'space_view_id' => :'spaceViewId',
|
79
|
+
:'store_order_confirmation_email_enabled' => :'storeOrderConfirmationEmailEnabled',
|
80
|
+
:'subscriber' => :'subscriber',
|
81
|
+
:'subscriber_suspension_allowed' => :'subscriberSuspensionAllowed'
|
82
|
+
}
|
83
|
+
end
|
84
|
+
|
85
|
+
# Attribute type mapping.
|
86
|
+
def self.swagger_types
|
87
|
+
{
|
88
|
+
:'billing_address' => :'ShopifySubscriptionAddressCreate',
|
89
|
+
:'billing_configuration' => :'ShopifySubscriptionModelBillingConfiguration',
|
90
|
+
:'currency' => :'String',
|
91
|
+
:'external_id' => :'String',
|
92
|
+
:'initial_execution_date' => :'DateTime',
|
93
|
+
:'integration' => :'Integer',
|
94
|
+
:'items' => :'Array<ShopifySubscriptionModelItem>',
|
95
|
+
:'language' => :'String',
|
96
|
+
:'shipping_address' => :'ShopifySubscriptionAddressCreate',
|
97
|
+
:'shipping_method_name' => :'String',
|
98
|
+
:'space_view_id' => :'Integer',
|
99
|
+
:'store_order_confirmation_email_enabled' => :'BOOLEAN',
|
100
|
+
:'subscriber' => :'ShopifySubscriberCreation',
|
101
|
+
:'subscriber_suspension_allowed' => :'BOOLEAN'
|
102
|
+
}
|
103
|
+
end
|
104
|
+
|
105
|
+
# Initializes the object
|
106
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
107
|
+
def initialize(attributes = {})
|
108
|
+
return unless attributes.is_a?(Hash)
|
109
|
+
|
110
|
+
# convert string to symbol for hash key
|
111
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
112
|
+
|
113
|
+
if attributes.has_key?(:'billingAddress')
|
114
|
+
self.billing_address = attributes[:'billingAddress']
|
115
|
+
end
|
116
|
+
|
117
|
+
if attributes.has_key?(:'billingConfiguration')
|
118
|
+
self.billing_configuration = attributes[:'billingConfiguration']
|
119
|
+
end
|
120
|
+
|
121
|
+
if attributes.has_key?(:'currency')
|
122
|
+
self.currency = attributes[:'currency']
|
123
|
+
end
|
124
|
+
|
125
|
+
if attributes.has_key?(:'externalId')
|
126
|
+
self.external_id = attributes[:'externalId']
|
127
|
+
end
|
128
|
+
|
129
|
+
if attributes.has_key?(:'initialExecutionDate')
|
130
|
+
self.initial_execution_date = attributes[:'initialExecutionDate']
|
131
|
+
end
|
132
|
+
|
133
|
+
if attributes.has_key?(:'integration')
|
134
|
+
self.integration = attributes[:'integration']
|
135
|
+
end
|
136
|
+
|
137
|
+
if attributes.has_key?(:'items')
|
138
|
+
if (value = attributes[:'items']).is_a?(Array)
|
139
|
+
self.items = value
|
140
|
+
end
|
141
|
+
end
|
142
|
+
|
143
|
+
if attributes.has_key?(:'language')
|
144
|
+
self.language = attributes[:'language']
|
145
|
+
end
|
146
|
+
|
147
|
+
if attributes.has_key?(:'shippingAddress')
|
148
|
+
self.shipping_address = attributes[:'shippingAddress']
|
149
|
+
end
|
150
|
+
|
151
|
+
if attributes.has_key?(:'shippingMethodName')
|
152
|
+
self.shipping_method_name = attributes[:'shippingMethodName']
|
153
|
+
end
|
154
|
+
|
155
|
+
if attributes.has_key?(:'spaceViewId')
|
156
|
+
self.space_view_id = attributes[:'spaceViewId']
|
157
|
+
end
|
158
|
+
|
159
|
+
if attributes.has_key?(:'storeOrderConfirmationEmailEnabled')
|
160
|
+
self.store_order_confirmation_email_enabled = attributes[:'storeOrderConfirmationEmailEnabled']
|
161
|
+
end
|
162
|
+
|
163
|
+
if attributes.has_key?(:'subscriber')
|
164
|
+
self.subscriber = attributes[:'subscriber']
|
165
|
+
end
|
166
|
+
|
167
|
+
if attributes.has_key?(:'subscriberSuspensionAllowed')
|
168
|
+
self.subscriber_suspension_allowed = attributes[:'subscriberSuspensionAllowed']
|
169
|
+
end
|
170
|
+
end
|
171
|
+
|
172
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
173
|
+
# @return Array for valid properties with the reasons
|
174
|
+
def list_invalid_properties
|
175
|
+
invalid_properties = Array.new
|
176
|
+
if @billing_address.nil?
|
177
|
+
invalid_properties.push('invalid value for "billing_address", billing_address cannot be nil.')
|
178
|
+
end
|
179
|
+
|
180
|
+
if @currency.nil?
|
181
|
+
invalid_properties.push('invalid value for "currency", currency cannot be nil.')
|
182
|
+
end
|
183
|
+
|
184
|
+
if @external_id.nil?
|
185
|
+
invalid_properties.push('invalid value for "external_id", external_id cannot be nil.')
|
186
|
+
end
|
187
|
+
|
188
|
+
if @integration.nil?
|
189
|
+
invalid_properties.push('invalid value for "integration", integration cannot be nil.')
|
190
|
+
end
|
191
|
+
|
192
|
+
if @items.nil?
|
193
|
+
invalid_properties.push('invalid value for "items", items cannot be nil.')
|
194
|
+
end
|
195
|
+
|
196
|
+
if @language.nil?
|
197
|
+
invalid_properties.push('invalid value for "language", language cannot be nil.')
|
198
|
+
end
|
199
|
+
|
200
|
+
if @shipping_address.nil?
|
201
|
+
invalid_properties.push('invalid value for "shipping_address", shipping_address cannot be nil.')
|
202
|
+
end
|
203
|
+
|
204
|
+
if @subscriber.nil?
|
205
|
+
invalid_properties.push('invalid value for "subscriber", subscriber cannot be nil.')
|
206
|
+
end
|
207
|
+
|
208
|
+
invalid_properties
|
209
|
+
end
|
210
|
+
|
211
|
+
# Check to see if the all the properties in the model are valid
|
212
|
+
# @return true if the model is valid
|
213
|
+
def valid?
|
214
|
+
return false if @billing_address.nil?
|
215
|
+
return false if @currency.nil?
|
216
|
+
return false if @external_id.nil?
|
217
|
+
return false if @integration.nil?
|
218
|
+
return false if @items.nil?
|
219
|
+
return false if @language.nil?
|
220
|
+
return false if @shipping_address.nil?
|
221
|
+
return false if @subscriber.nil?
|
222
|
+
true
|
223
|
+
end
|
224
|
+
|
225
|
+
# Checks equality by comparing each attribute.
|
226
|
+
# @param [Object] Object to be compared
|
227
|
+
def ==(o)
|
228
|
+
return true if self.equal?(o)
|
229
|
+
self.class == o.class &&
|
230
|
+
billing_address == o.billing_address &&
|
231
|
+
billing_configuration == o.billing_configuration &&
|
232
|
+
currency == o.currency &&
|
233
|
+
external_id == o.external_id &&
|
234
|
+
initial_execution_date == o.initial_execution_date &&
|
235
|
+
integration == o.integration &&
|
236
|
+
items == o.items &&
|
237
|
+
language == o.language &&
|
238
|
+
shipping_address == o.shipping_address &&
|
239
|
+
shipping_method_name == o.shipping_method_name &&
|
240
|
+
space_view_id == o.space_view_id &&
|
241
|
+
store_order_confirmation_email_enabled == o.store_order_confirmation_email_enabled &&
|
242
|
+
subscriber == o.subscriber &&
|
243
|
+
subscriber_suspension_allowed == o.subscriber_suspension_allowed
|
244
|
+
end
|
245
|
+
|
246
|
+
# @see the `==` method
|
247
|
+
# @param [Object] Object to be compared
|
248
|
+
def eql?(o)
|
249
|
+
self == o
|
250
|
+
end
|
251
|
+
|
252
|
+
# Calculates hash code according to all attributes.
|
253
|
+
# @return [Fixnum] Hash code
|
254
|
+
def hash
|
255
|
+
[billing_address, billing_configuration, currency, external_id, initial_execution_date, integration, items, language, shipping_address, shipping_method_name, space_view_id, store_order_confirmation_email_enabled, subscriber, subscriber_suspension_allowed].hash
|
256
|
+
end
|
257
|
+
|
258
|
+
# Builds the object from hash
|
259
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
260
|
+
# @return [Object] Returns the model itself
|
261
|
+
def build_from_hash(attributes)
|
262
|
+
return nil unless attributes.is_a?(Hash)
|
263
|
+
self.class.swagger_types.each_pair do |key, type|
|
264
|
+
if type =~ /\AArray<(.*)>/i
|
265
|
+
# check to ensure the input is an array given that the attribute
|
266
|
+
# is documented as an array but the input is not
|
267
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
268
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
269
|
+
end
|
270
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
271
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
272
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
273
|
+
end
|
274
|
+
|
275
|
+
self
|
276
|
+
end
|
277
|
+
|
278
|
+
# Deserializes the data based on type
|
279
|
+
# @param string type Data type
|
280
|
+
# @param string value Value to be deserialized
|
281
|
+
# @return [Object] Deserialized data
|
282
|
+
def _deserialize(type, value)
|
283
|
+
case type.to_sym
|
284
|
+
when :DateTime
|
285
|
+
DateTime.parse(value)
|
286
|
+
when :Date
|
287
|
+
Date.parse(value)
|
288
|
+
when :String
|
289
|
+
value.to_s
|
290
|
+
when :Integer
|
291
|
+
value.to_i
|
292
|
+
when :Float
|
293
|
+
value.to_f
|
294
|
+
when :BOOLEAN
|
295
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
296
|
+
true
|
297
|
+
else
|
298
|
+
false
|
299
|
+
end
|
300
|
+
when :Object
|
301
|
+
# generic object (usually a Hash), return directly
|
302
|
+
value
|
303
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
304
|
+
inner_type = Regexp.last_match[:inner_type]
|
305
|
+
value.map { |v| _deserialize(inner_type, v) }
|
306
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
307
|
+
k_type = Regexp.last_match[:k_type]
|
308
|
+
v_type = Regexp.last_match[:v_type]
|
309
|
+
{}.tap do |hash|
|
310
|
+
value.each do |k, v|
|
311
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
312
|
+
end
|
313
|
+
end
|
314
|
+
else # model
|
315
|
+
temp_model = PostFinanceCheckout.const_get(type).new
|
316
|
+
temp_model.build_from_hash(value)
|
317
|
+
end
|
318
|
+
end
|
319
|
+
|
320
|
+
# Returns the string representation of the object
|
321
|
+
# @return [String] String presentation of the object
|
322
|
+
def to_s
|
323
|
+
to_hash.to_s
|
324
|
+
end
|
325
|
+
|
326
|
+
# to_body is an alias to to_hash (backward compatibility)
|
327
|
+
# @return [Hash] Returns the object in the form of hash
|
328
|
+
def to_body
|
329
|
+
to_hash
|
330
|
+
end
|
331
|
+
|
332
|
+
# Returns the object in the form of hash
|
333
|
+
# @return [Hash] Returns the object in the form of hash
|
334
|
+
def to_hash
|
335
|
+
hash = {}
|
336
|
+
self.class.attribute_map.each_pair do |attr, param|
|
337
|
+
value = self.send(attr)
|
338
|
+
next if value.nil?
|
339
|
+
hash[param] = _to_hash(value)
|
340
|
+
end
|
341
|
+
hash
|
342
|
+
end
|
343
|
+
|
344
|
+
# Outputs non-array value in the form of hash
|
345
|
+
# For object, use to_hash. Otherwise, just return the value
|
346
|
+
# @param [Object] value Any valid value
|
347
|
+
# @return [Hash] Returns the value in the form of hash
|
348
|
+
def _to_hash(value)
|
349
|
+
if value.is_a?(Array)
|
350
|
+
value.compact.map{ |v| _to_hash(v) }
|
351
|
+
elsif value.is_a?(Hash)
|
352
|
+
{}.tap do |hash|
|
353
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
354
|
+
end
|
355
|
+
elsif value.respond_to? :to_hash
|
356
|
+
value.to_hash
|
357
|
+
else
|
358
|
+
value
|
359
|
+
end
|
360
|
+
end
|
361
|
+
|
362
|
+
end
|
363
|
+
end
|
data/lib/postfinancecheckout-ruby-sdk/models/shopify_subscription_model_billing_configuration.rb
ADDED
@@ -0,0 +1,271 @@
|
|
1
|
+
=begin
|
2
|
+
The PostFinance Checkout API allows an easy interaction with the PostFinance Checkout web service.
|
3
|
+
|
4
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
+
you may not use this file except in compliance with the License.
|
6
|
+
You may obtain a copy of the License at
|
7
|
+
|
8
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
9
|
+
|
10
|
+
Unless required by applicable law or agreed to in writing, software
|
11
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
+
See the License for the specific language governing permissions and
|
14
|
+
limitations under the License.
|
15
|
+
|
16
|
+
=end
|
17
|
+
|
18
|
+
require 'date'
|
19
|
+
|
20
|
+
module PostFinanceCheckout
|
21
|
+
#
|
22
|
+
class ShopifySubscriptionModelBillingConfiguration
|
23
|
+
# Define the day of the month on which the recurring orders should be created.
|
24
|
+
attr_accessor :billing_day_of_month
|
25
|
+
|
26
|
+
#
|
27
|
+
attr_accessor :billing_interval_amount
|
28
|
+
|
29
|
+
# Define how frequently recurring orders should be created.
|
30
|
+
attr_accessor :billing_interval_unit
|
31
|
+
|
32
|
+
# This date will be used as basis to calculate the dates of recurring orders.
|
33
|
+
attr_accessor :billing_reference_date
|
34
|
+
|
35
|
+
# Define the weekday on which the recurring orders should be created.
|
36
|
+
attr_accessor :billing_weekday
|
37
|
+
|
38
|
+
# Define the maximum number of orders the subscription will run for.
|
39
|
+
attr_accessor :maximal_billing_cycles
|
40
|
+
|
41
|
+
# Define the maximum number of orders the subscription can be suspended for at a time.
|
42
|
+
attr_accessor :maximal_suspendable_cycles
|
43
|
+
|
44
|
+
# Define the minimal number of orders the subscription will run for.
|
45
|
+
attr_accessor :minimal_billing_cycles
|
46
|
+
|
47
|
+
# Define the number of orders the subscription will keep running for after its termination has been requested.
|
48
|
+
attr_accessor :termination_billing_cycles
|
49
|
+
|
50
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
51
|
+
def self.attribute_map
|
52
|
+
{
|
53
|
+
:'billing_day_of_month' => :'billingDayOfMonth',
|
54
|
+
:'billing_interval_amount' => :'billingIntervalAmount',
|
55
|
+
:'billing_interval_unit' => :'billingIntervalUnit',
|
56
|
+
:'billing_reference_date' => :'billingReferenceDate',
|
57
|
+
:'billing_weekday' => :'billingWeekday',
|
58
|
+
:'maximal_billing_cycles' => :'maximalBillingCycles',
|
59
|
+
:'maximal_suspendable_cycles' => :'maximalSuspendableCycles',
|
60
|
+
:'minimal_billing_cycles' => :'minimalBillingCycles',
|
61
|
+
:'termination_billing_cycles' => :'terminationBillingCycles'
|
62
|
+
}
|
63
|
+
end
|
64
|
+
|
65
|
+
# Attribute type mapping.
|
66
|
+
def self.swagger_types
|
67
|
+
{
|
68
|
+
:'billing_day_of_month' => :'Integer',
|
69
|
+
:'billing_interval_amount' => :'Integer',
|
70
|
+
:'billing_interval_unit' => :'ShopifySubscriptionBillingIntervalUnit',
|
71
|
+
:'billing_reference_date' => :'DateTime',
|
72
|
+
:'billing_weekday' => :'ShopifySubscriptionWeekday',
|
73
|
+
:'maximal_billing_cycles' => :'Integer',
|
74
|
+
:'maximal_suspendable_cycles' => :'Integer',
|
75
|
+
:'minimal_billing_cycles' => :'Integer',
|
76
|
+
:'termination_billing_cycles' => :'Integer'
|
77
|
+
}
|
78
|
+
end
|
79
|
+
|
80
|
+
# Initializes the object
|
81
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
82
|
+
def initialize(attributes = {})
|
83
|
+
return unless attributes.is_a?(Hash)
|
84
|
+
|
85
|
+
# convert string to symbol for hash key
|
86
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
87
|
+
|
88
|
+
if attributes.has_key?(:'billingDayOfMonth')
|
89
|
+
self.billing_day_of_month = attributes[:'billingDayOfMonth']
|
90
|
+
end
|
91
|
+
|
92
|
+
if attributes.has_key?(:'billingIntervalAmount')
|
93
|
+
self.billing_interval_amount = attributes[:'billingIntervalAmount']
|
94
|
+
end
|
95
|
+
|
96
|
+
if attributes.has_key?(:'billingIntervalUnit')
|
97
|
+
self.billing_interval_unit = attributes[:'billingIntervalUnit']
|
98
|
+
end
|
99
|
+
|
100
|
+
if attributes.has_key?(:'billingReferenceDate')
|
101
|
+
self.billing_reference_date = attributes[:'billingReferenceDate']
|
102
|
+
end
|
103
|
+
|
104
|
+
if attributes.has_key?(:'billingWeekday')
|
105
|
+
self.billing_weekday = attributes[:'billingWeekday']
|
106
|
+
end
|
107
|
+
|
108
|
+
if attributes.has_key?(:'maximalBillingCycles')
|
109
|
+
self.maximal_billing_cycles = attributes[:'maximalBillingCycles']
|
110
|
+
end
|
111
|
+
|
112
|
+
if attributes.has_key?(:'maximalSuspendableCycles')
|
113
|
+
self.maximal_suspendable_cycles = attributes[:'maximalSuspendableCycles']
|
114
|
+
end
|
115
|
+
|
116
|
+
if attributes.has_key?(:'minimalBillingCycles')
|
117
|
+
self.minimal_billing_cycles = attributes[:'minimalBillingCycles']
|
118
|
+
end
|
119
|
+
|
120
|
+
if attributes.has_key?(:'terminationBillingCycles')
|
121
|
+
self.termination_billing_cycles = attributes[:'terminationBillingCycles']
|
122
|
+
end
|
123
|
+
end
|
124
|
+
|
125
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
126
|
+
# @return Array for valid properties with the reasons
|
127
|
+
def list_invalid_properties
|
128
|
+
invalid_properties = Array.new
|
129
|
+
invalid_properties
|
130
|
+
end
|
131
|
+
|
132
|
+
# Check to see if the all the properties in the model are valid
|
133
|
+
# @return true if the model is valid
|
134
|
+
def valid?
|
135
|
+
true
|
136
|
+
end
|
137
|
+
|
138
|
+
# Checks equality by comparing each attribute.
|
139
|
+
# @param [Object] Object to be compared
|
140
|
+
def ==(o)
|
141
|
+
return true if self.equal?(o)
|
142
|
+
self.class == o.class &&
|
143
|
+
billing_day_of_month == o.billing_day_of_month &&
|
144
|
+
billing_interval_amount == o.billing_interval_amount &&
|
145
|
+
billing_interval_unit == o.billing_interval_unit &&
|
146
|
+
billing_reference_date == o.billing_reference_date &&
|
147
|
+
billing_weekday == o.billing_weekday &&
|
148
|
+
maximal_billing_cycles == o.maximal_billing_cycles &&
|
149
|
+
maximal_suspendable_cycles == o.maximal_suspendable_cycles &&
|
150
|
+
minimal_billing_cycles == o.minimal_billing_cycles &&
|
151
|
+
termination_billing_cycles == o.termination_billing_cycles
|
152
|
+
end
|
153
|
+
|
154
|
+
# @see the `==` method
|
155
|
+
# @param [Object] Object to be compared
|
156
|
+
def eql?(o)
|
157
|
+
self == o
|
158
|
+
end
|
159
|
+
|
160
|
+
# Calculates hash code according to all attributes.
|
161
|
+
# @return [Fixnum] Hash code
|
162
|
+
def hash
|
163
|
+
[billing_day_of_month, billing_interval_amount, billing_interval_unit, billing_reference_date, billing_weekday, maximal_billing_cycles, maximal_suspendable_cycles, minimal_billing_cycles, termination_billing_cycles].hash
|
164
|
+
end
|
165
|
+
|
166
|
+
# Builds the object from hash
|
167
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
168
|
+
# @return [Object] Returns the model itself
|
169
|
+
def build_from_hash(attributes)
|
170
|
+
return nil unless attributes.is_a?(Hash)
|
171
|
+
self.class.swagger_types.each_pair do |key, type|
|
172
|
+
if type =~ /\AArray<(.*)>/i
|
173
|
+
# check to ensure the input is an array given that the attribute
|
174
|
+
# is documented as an array but the input is not
|
175
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
176
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
177
|
+
end
|
178
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
179
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
180
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
181
|
+
end
|
182
|
+
|
183
|
+
self
|
184
|
+
end
|
185
|
+
|
186
|
+
# Deserializes the data based on type
|
187
|
+
# @param string type Data type
|
188
|
+
# @param string value Value to be deserialized
|
189
|
+
# @return [Object] Deserialized data
|
190
|
+
def _deserialize(type, value)
|
191
|
+
case type.to_sym
|
192
|
+
when :DateTime
|
193
|
+
DateTime.parse(value)
|
194
|
+
when :Date
|
195
|
+
Date.parse(value)
|
196
|
+
when :String
|
197
|
+
value.to_s
|
198
|
+
when :Integer
|
199
|
+
value.to_i
|
200
|
+
when :Float
|
201
|
+
value.to_f
|
202
|
+
when :BOOLEAN
|
203
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
204
|
+
true
|
205
|
+
else
|
206
|
+
false
|
207
|
+
end
|
208
|
+
when :Object
|
209
|
+
# generic object (usually a Hash), return directly
|
210
|
+
value
|
211
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
212
|
+
inner_type = Regexp.last_match[:inner_type]
|
213
|
+
value.map { |v| _deserialize(inner_type, v) }
|
214
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
215
|
+
k_type = Regexp.last_match[:k_type]
|
216
|
+
v_type = Regexp.last_match[:v_type]
|
217
|
+
{}.tap do |hash|
|
218
|
+
value.each do |k, v|
|
219
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
220
|
+
end
|
221
|
+
end
|
222
|
+
else # model
|
223
|
+
temp_model = PostFinanceCheckout.const_get(type).new
|
224
|
+
temp_model.build_from_hash(value)
|
225
|
+
end
|
226
|
+
end
|
227
|
+
|
228
|
+
# Returns the string representation of the object
|
229
|
+
# @return [String] String presentation of the object
|
230
|
+
def to_s
|
231
|
+
to_hash.to_s
|
232
|
+
end
|
233
|
+
|
234
|
+
# to_body is an alias to to_hash (backward compatibility)
|
235
|
+
# @return [Hash] Returns the object in the form of hash
|
236
|
+
def to_body
|
237
|
+
to_hash
|
238
|
+
end
|
239
|
+
|
240
|
+
# Returns the object in the form of hash
|
241
|
+
# @return [Hash] Returns the object in the form of hash
|
242
|
+
def to_hash
|
243
|
+
hash = {}
|
244
|
+
self.class.attribute_map.each_pair do |attr, param|
|
245
|
+
value = self.send(attr)
|
246
|
+
next if value.nil?
|
247
|
+
hash[param] = _to_hash(value)
|
248
|
+
end
|
249
|
+
hash
|
250
|
+
end
|
251
|
+
|
252
|
+
# Outputs non-array value in the form of hash
|
253
|
+
# For object, use to_hash. Otherwise, just return the value
|
254
|
+
# @param [Object] value Any valid value
|
255
|
+
# @return [Hash] Returns the value in the form of hash
|
256
|
+
def _to_hash(value)
|
257
|
+
if value.is_a?(Array)
|
258
|
+
value.compact.map{ |v| _to_hash(v) }
|
259
|
+
elsif value.is_a?(Hash)
|
260
|
+
{}.tap do |hash|
|
261
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
262
|
+
end
|
263
|
+
elsif value.respond_to? :to_hash
|
264
|
+
value.to_hash
|
265
|
+
else
|
266
|
+
value
|
267
|
+
end
|
268
|
+
end
|
269
|
+
|
270
|
+
end
|
271
|
+
end
|