order_cloud 0.0.6 → 1.0.43
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -13
- metadata +45 -594
- data/Gemfile +0 -28
- data/Gemfile.lock +0 -34
- data/LICENSE +0 -201
- data/README.md +0 -498
- data/Rakefile +0 -31
- data/docs/AccessToken.md +0 -10
- data/docs/Address.md +0 -20
- data/docs/AddressApi.md +0 -520
- data/docs/AddressAssignment.md +0 -12
- data/docs/AdminAddressApi.md +0 -324
- data/docs/AdminCompany.md +0 -10
- data/docs/AdminModelOnView.md +0 -7
- data/docs/AdminUserApi.md +0 -323
- data/docs/AdminUserGroupApi.md +0 -482
- data/docs/ApprovalRule.md +0 -20
- data/docs/ApprovalRuleApi.md +0 -342
- data/docs/BaseSpec.md +0 -15
- data/docs/Buyer.md +0 -11
- data/docs/BuyerAddress.md +0 -11
- data/docs/BuyerApi.md +0 -324
- data/docs/BuyerCreditCard.md +0 -9
- data/docs/BuyerProduct.md +0 -9
- data/docs/BuyerSpec.md +0 -9
- data/docs/Category.md +0 -15
- data/docs/CategoryApi.md +0 -685
- data/docs/CategoryAssignment.md +0 -10
- data/docs/CategoryProductAssignment.md +0 -10
- data/docs/CostCenter.md +0 -11
- data/docs/CostCenterApi.md +0 -516
- data/docs/CostCenterAssignment.md +0 -10
- data/docs/CreditCard.md +0 -15
- data/docs/CreditCardApi.md +0 -516
- data/docs/CreditCardAssignment.md +0 -10
- data/docs/EmailTemplate.md +0 -12
- data/docs/EmailTemplateApi.md +0 -223
- data/docs/File.md +0 -10
- data/docs/ImpersonateTokenRequest.md +0 -9
- data/docs/Inventory.md +0 -12
- data/docs/LineItem.md +0 -23
- data/docs/LineItemApi.md +0 -478
- data/docs/LineItemSpec.md +0 -11
- data/docs/ListAddress.md +0 -9
- data/docs/ListAddressAssignment.md +0 -9
- data/docs/ListAdminCompany.md +0 -9
- data/docs/ListApprovalRule.md +0 -9
- data/docs/ListBuyer.md +0 -9
- data/docs/ListBuyerAddress.md +0 -9
- data/docs/ListBuyerCreditCard.md +0 -9
- data/docs/ListBuyerProduct.md +0 -9
- data/docs/ListBuyerSpec.md +0 -9
- data/docs/ListCategory.md +0 -9
- data/docs/ListCategoryAssignment.md +0 -9
- data/docs/ListCategoryProductAssignment.md +0 -9
- data/docs/ListCostCenter.md +0 -9
- data/docs/ListCostCenterAssignment.md +0 -9
- data/docs/ListCreditCard.md +0 -9
- data/docs/ListCreditCardAssignment.md +0 -9
- data/docs/ListFile.md +0 -9
- data/docs/ListInventory.md +0 -9
- data/docs/ListLineItem.md +0 -9
- data/docs/ListMessageCCListenerAssignment.md +0 -9
- data/docs/ListMessageConfig.md +0 -9
- data/docs/ListMessageSender.md +0 -9
- data/docs/ListMessageSenderAssignment.md +0 -9
- data/docs/ListOrder.md +0 -9
- data/docs/ListOrderApproval.md +0 -9
- data/docs/ListOrderPromotion.md +0 -9
- data/docs/ListPayment.md +0 -9
- data/docs/ListPriceSchedule.md +0 -9
- data/docs/ListProduct.md +0 -9
- data/docs/ListProductAssignment.md +0 -9
- data/docs/ListPromotion.md +0 -9
- data/docs/ListPromotionAssignment.md +0 -9
- data/docs/ListSecurityProfile.md +0 -9
- data/docs/ListSecurityProfileAssignment.md +0 -9
- data/docs/ListShipment.md +0 -9
- data/docs/ListSpec.md +0 -9
- data/docs/ListSpecOption.md +0 -9
- data/docs/ListSpecProductAssignment.md +0 -9
- data/docs/ListSpendingAccount.md +0 -9
- data/docs/ListSpendingAccountAssignment.md +0 -9
- data/docs/ListUser.md +0 -9
- data/docs/ListUserGroup.md +0 -9
- data/docs/ListUserGroupAssignment.md +0 -9
- data/docs/ListVariant.md +0 -9
- data/docs/ListWebHook.md +0 -9
- data/docs/ListWebHookRoute.md +0 -9
- data/docs/ListXpIndex.md +0 -9
- data/docs/MeApi.md +0 -1488
- data/docs/MessageCCListenerAssignment.md +0 -13
- data/docs/MessageConfig.md +0 -11
- data/docs/MessageSender.md +0 -10
- data/docs/MessageSenderAssignment.md +0 -12
- data/docs/MessageSendersApi.md +0 -398
- data/docs/Meta.md +0 -12
- data/docs/Order.md +0 -31
- data/docs/OrderApi.md +0 -1277
- data/docs/OrderApproval.md +0 -16
- data/docs/OrderPromotion.md +0 -8
- data/docs/PasswordReset.md +0 -10
- data/docs/PasswordResetApi.md +0 -109
- data/docs/PasswordResetRequest.md +0 -11
- data/docs/Payment.md +0 -16
- data/docs/PaymentApi.md +0 -601
- data/docs/PaymentTransaction.md +0 -15
- data/docs/PingResponse.md +0 -8
- data/docs/PriceBreak.md +0 -9
- data/docs/PriceSchedule.md +0 -18
- data/docs/PriceScheduleApi.md +0 -429
- data/docs/Product.md +0 -26
- data/docs/ProductApi.md +0 -1116
- data/docs/ProductAssignment.md +0 -13
- data/docs/Promotion.md +0 -21
- data/docs/PromotionApi.md +0 -495
- data/docs/PromotionAssignment.md +0 -11
- data/docs/SecurityProfile.md +0 -11
- data/docs/SecurityProfileApi.md +0 -290
- data/docs/SecurityProfileAssignment.md +0 -11
- data/docs/Shipment.md +0 -14
- data/docs/ShipmentApi.md +0 -459
- data/docs/ShipmentItem.md +0 -10
- data/docs/Spec.md +0 -8
- data/docs/SpecApi.md +0 -816
- data/docs/SpecOption.md +0 -14
- data/docs/SpecProductAssignment.md +0 -10
- data/docs/SpendingAccount.md +0 -15
- data/docs/SpendingAccountApi.md +0 -516
- data/docs/SpendingAccountAssignment.md +0 -11
- data/docs/User.md +0 -18
- data/docs/UserApi.md +0 -400
- data/docs/UserGroup.md +0 -11
- data/docs/UserGroupApi.md +0 -509
- data/docs/UserGroupAssignment.md +0 -9
- data/docs/Variant.md +0 -12
- data/docs/WebHook.md +0 -18
- data/docs/WebHookRoute.md +0 -10
- data/docs/XpIndex.md +0 -9
- data/git_push.sh +0 -67
- data/lib/order_cloud.rb +0 -183
- data/lib/order_cloud/api/address_api.rb +0 -628
- data/lib/order_cloud/api/admin_address_api.rb +0 -397
- data/lib/order_cloud/api/admin_user_api.rb +0 -396
- data/lib/order_cloud/api/admin_user_group_api.rb +0 -578
- data/lib/order_cloud/api/approval_rule_api.rb +0 -421
- data/lib/order_cloud/api/buyer_api.rb +0 -397
- data/lib/order_cloud/api/category_api.rb +0 -818
- data/lib/order_cloud/api/cost_center_api.rb +0 -622
- data/lib/order_cloud/api/credit_card_api.rb +0 -622
- data/lib/order_cloud/api/email_template_api.rb +0 -283
- data/lib/order_cloud/api/line_item_api.rb +0 -583
- data/lib/order_cloud/api/me_api.rb +0 -1747
- data/lib/order_cloud/api/message_senders_api.rb +0 -484
- data/lib/order_cloud/api/order_api.rb +0 -1509
- data/lib/order_cloud/api/password_reset_api.rb +0 -150
- data/lib/order_cloud/api/payment_api.rb +0 -728
- data/lib/order_cloud/api/price_schedule_api.rb +0 -519
- data/lib/order_cloud/api/product_api.rb +0 -1312
- data/lib/order_cloud/api/promotion_api.rb +0 -596
- data/lib/order_cloud/api/security_profile_api.rb +0 -361
- data/lib/order_cloud/api/shipment_api.rb +0 -558
- data/lib/order_cloud/api/spec_api.rb +0 -965
- data/lib/order_cloud/api/spending_account_api.rb +0 -622
- data/lib/order_cloud/api/user_api.rb +0 -489
- data/lib/order_cloud/api/user_group_api.rb +0 -614
- data/lib/order_cloud/api_auth.rb +0 -108
- data/lib/order_cloud/api_client.rb +0 -385
- data/lib/order_cloud/api_error.rb +0 -47
- data/lib/order_cloud/configuration.rb +0 -245
- data/lib/order_cloud/models/access_token.rb +0 -217
- data/lib/order_cloud/models/address.rb +0 -307
- data/lib/order_cloud/models/address_assignment.rb +0 -235
- data/lib/order_cloud/models/admin_company.rb +0 -217
- data/lib/order_cloud/models/admin_model_on_view.rb +0 -190
- data/lib/order_cloud/models/approval_rule.rb +0 -307
- data/lib/order_cloud/models/base_spec.rb +0 -262
- data/lib/order_cloud/models/buyer.rb +0 -226
- data/lib/order_cloud/models/buyer_address.rb +0 -226
- data/lib/order_cloud/models/buyer_credit_card.rb +0 -208
- data/lib/order_cloud/models/buyer_product.rb +0 -208
- data/lib/order_cloud/models/buyer_spec.rb +0 -210
- data/lib/order_cloud/models/category.rb +0 -262
- data/lib/order_cloud/models/category_assignment.rb +0 -217
- data/lib/order_cloud/models/category_product_assignment.rb +0 -217
- data/lib/order_cloud/models/cost_center.rb +0 -226
- data/lib/order_cloud/models/cost_center_assignment.rb +0 -217
- data/lib/order_cloud/models/credit_card.rb +0 -262
- data/lib/order_cloud/models/credit_card_assignment.rb +0 -217
- data/lib/order_cloud/models/email_template.rb +0 -235
- data/lib/order_cloud/models/file.rb +0 -217
- data/lib/order_cloud/models/impersonate_token_request.rb +0 -208
- data/lib/order_cloud/models/inventory.rb +0 -235
- data/lib/order_cloud/models/line_item.rb +0 -336
- data/lib/order_cloud/models/line_item_spec.rb +0 -226
- data/lib/order_cloud/models/list_address.rb +0 -210
- data/lib/order_cloud/models/list_address_assignment.rb +0 -210
- data/lib/order_cloud/models/list_admin_company.rb +0 -210
- data/lib/order_cloud/models/list_approval_rule.rb +0 -210
- data/lib/order_cloud/models/list_buyer.rb +0 -210
- data/lib/order_cloud/models/list_buyer_address.rb +0 -210
- data/lib/order_cloud/models/list_buyer_credit_card.rb +0 -210
- data/lib/order_cloud/models/list_buyer_product.rb +0 -210
- data/lib/order_cloud/models/list_buyer_spec.rb +0 -210
- data/lib/order_cloud/models/list_category.rb +0 -210
- data/lib/order_cloud/models/list_category_assignment.rb +0 -210
- data/lib/order_cloud/models/list_category_product_assignment.rb +0 -210
- data/lib/order_cloud/models/list_cost_center.rb +0 -210
- data/lib/order_cloud/models/list_cost_center_assignment.rb +0 -210
- data/lib/order_cloud/models/list_credit_card.rb +0 -210
- data/lib/order_cloud/models/list_credit_card_assignment.rb +0 -210
- data/lib/order_cloud/models/list_file.rb +0 -210
- data/lib/order_cloud/models/list_inventory.rb +0 -210
- data/lib/order_cloud/models/list_line_item.rb +0 -210
- data/lib/order_cloud/models/list_message_cc_listener_assignment.rb +0 -210
- data/lib/order_cloud/models/list_message_config.rb +0 -210
- data/lib/order_cloud/models/list_message_sender.rb +0 -210
- data/lib/order_cloud/models/list_message_sender_assignment.rb +0 -210
- data/lib/order_cloud/models/list_order.rb +0 -210
- data/lib/order_cloud/models/list_order_approval.rb +0 -210
- data/lib/order_cloud/models/list_order_promotion.rb +0 -210
- data/lib/order_cloud/models/list_payment.rb +0 -210
- data/lib/order_cloud/models/list_price_schedule.rb +0 -210
- data/lib/order_cloud/models/list_product.rb +0 -210
- data/lib/order_cloud/models/list_product_assignment.rb +0 -210
- data/lib/order_cloud/models/list_promotion.rb +0 -210
- data/lib/order_cloud/models/list_promotion_assignment.rb +0 -210
- data/lib/order_cloud/models/list_security_profile.rb +0 -210
- data/lib/order_cloud/models/list_security_profile_assignment.rb +0 -210
- data/lib/order_cloud/models/list_shipment.rb +0 -210
- data/lib/order_cloud/models/list_spec.rb +0 -210
- data/lib/order_cloud/models/list_spec_option.rb +0 -210
- data/lib/order_cloud/models/list_spec_product_assignment.rb +0 -210
- data/lib/order_cloud/models/list_spending_account.rb +0 -210
- data/lib/order_cloud/models/list_spending_account_assignment.rb +0 -210
- data/lib/order_cloud/models/list_user.rb +0 -210
- data/lib/order_cloud/models/list_user_group.rb +0 -210
- data/lib/order_cloud/models/list_user_group_assignment.rb +0 -210
- data/lib/order_cloud/models/list_variant.rb +0 -210
- data/lib/order_cloud/models/list_web_hook.rb +0 -210
- data/lib/order_cloud/models/list_web_hook_route.rb +0 -210
- data/lib/order_cloud/models/list_xp_index.rb +0 -210
- data/lib/order_cloud/models/message_cc_listener_assignment.rb +0 -244
- data/lib/order_cloud/models/message_config.rb +0 -226
- data/lib/order_cloud/models/message_sender.rb +0 -217
- data/lib/order_cloud/models/message_sender_assignment.rb +0 -235
- data/lib/order_cloud/models/meta.rb +0 -237
- data/lib/order_cloud/models/order.rb +0 -406
- data/lib/order_cloud/models/order_approval.rb +0 -271
- data/lib/order_cloud/models/order_promotion.rb +0 -199
- data/lib/order_cloud/models/password_reset.rb +0 -217
- data/lib/order_cloud/models/password_reset_request.rb +0 -226
- data/lib/order_cloud/models/payment.rb +0 -273
- data/lib/order_cloud/models/payment_transaction.rb +0 -262
- data/lib/order_cloud/models/ping_response.rb +0 -199
- data/lib/order_cloud/models/price_break.rb +0 -208
- data/lib/order_cloud/models/price_schedule.rb +0 -291
- data/lib/order_cloud/models/product.rb +0 -361
- data/lib/order_cloud/models/product_assignment.rb +0 -244
- data/lib/order_cloud/models/promotion.rb +0 -316
- data/lib/order_cloud/models/promotion_assignment.rb +0 -226
- data/lib/order_cloud/models/security_profile.rb +0 -228
- data/lib/order_cloud/models/security_profile_assignment.rb +0 -226
- data/lib/order_cloud/models/shipment.rb +0 -255
- data/lib/order_cloud/models/shipment_item.rb +0 -217
- data/lib/order_cloud/models/spec.rb +0 -199
- data/lib/order_cloud/models/spec_option.rb +0 -253
- data/lib/order_cloud/models/spec_product_assignment.rb +0 -217
- data/lib/order_cloud/models/spending_account.rb +0 -262
- data/lib/order_cloud/models/spending_account_assignment.rb +0 -226
- data/lib/order_cloud/models/user.rb +0 -291
- data/lib/order_cloud/models/user_group.rb +0 -226
- data/lib/order_cloud/models/user_group_assignment.rb +0 -208
- data/lib/order_cloud/models/variant.rb +0 -235
- data/lib/order_cloud/models/web_hook.rb +0 -289
- data/lib/order_cloud/models/web_hook_route.rb +0 -217
- data/lib/order_cloud/models/xp_index.rb +0 -208
- data/lib/order_cloud/version.rb +0 -26
- data/order_cloud.gemspec +0 -56
- data/spec/api/address_api_spec.rb +0 -179
- data/spec/api/admin_address_api_spec.rb +0 -125
- data/spec/api/admin_user_api_spec.rb +0 -125
- data/spec/api/admin_user_group_api_spec.rb +0 -165
- data/spec/api/approval_rule_api_spec.rb +0 -131
- data/spec/api/buyer_api_spec.rb +0 -125
- data/spec/api/category_api_spec.rb +0 -221
- data/spec/api/cost_center_api_spec.rb +0 -177
- data/spec/api/credit_card_api_spec.rb +0 -177
- data/spec/api/email_template_api_spec.rb +0 -100
- data/spec/api/line_item_api_spec.rb +0 -167
- data/spec/api/me_api_spec.rb +0 -431
- data/spec/api/message_senders_api_spec.rb +0 -149
- data/spec/api/order_api_spec.rb +0 -375
- data/spec/api/password_reset_api_spec.rb +0 -71
- data/spec/api/payment_api_spec.rb +0 -199
- data/spec/api/price_schedule_api_spec.rb +0 -151
- data/spec/api/product_api_spec.rb +0 -330
- data/spec/api/promotion_api_spec.rb +0 -170
- data/spec/api/security_profile_api_spec.rb +0 -120
- data/spec/api/shipment_api_spec.rb +0 -161
- data/spec/api/spec_api_spec.rb +0 -250
- data/spec/api/spending_account_api_spec.rb +0 -177
- data/spec/api/user_api_spec.rb +0 -146
- data/spec/api/user_group_api_spec.rb +0 -174
- data/spec/api_auth_spec.rb +0 -165
- data/spec/api_client_spec.rb +0 -237
- data/spec/configuration_spec.rb +0 -80
- data/spec/models/access_token_spec.rb +0 -65
- data/spec/models/address_assignment_spec.rb +0 -77
- data/spec/models/address_spec.rb +0 -125
- data/spec/models/admin_company_spec.rb +0 -65
- data/spec/models/admin_model_on_view_spec.rb +0 -47
- data/spec/models/approval_rule_spec.rb +0 -125
- data/spec/models/base_spec_spec.rb +0 -95
- data/spec/models/buyer_address_spec.rb +0 -71
- data/spec/models/buyer_credit_card_spec.rb +0 -59
- data/spec/models/buyer_product_spec.rb +0 -59
- data/spec/models/buyer_spec.rb +0 -71
- data/spec/models/buyer_spec_spec.rb +0 -59
- data/spec/models/category_assignment_spec.rb +0 -65
- data/spec/models/category_product_assignment_spec.rb +0 -65
- data/spec/models/category_spec.rb +0 -95
- data/spec/models/cost_center_assignment_spec.rb +0 -65
- data/spec/models/cost_center_spec.rb +0 -71
- data/spec/models/credit_card_assignment_spec.rb +0 -65
- data/spec/models/credit_card_spec.rb +0 -95
- data/spec/models/email_template_spec.rb +0 -77
- data/spec/models/file_spec.rb +0 -65
- data/spec/models/impersonate_token_request_spec.rb +0 -59
- data/spec/models/inventory_spec.rb +0 -77
- data/spec/models/line_item_spec.rb +0 -143
- data/spec/models/line_item_spec_spec.rb +0 -71
- data/spec/models/list_address_assignment_spec.rb +0 -59
- data/spec/models/list_address_spec.rb +0 -59
- data/spec/models/list_admin_company_spec.rb +0 -59
- data/spec/models/list_approval_rule_spec.rb +0 -59
- data/spec/models/list_buyer_address_spec.rb +0 -59
- data/spec/models/list_buyer_credit_card_spec.rb +0 -59
- data/spec/models/list_buyer_product_spec.rb +0 -59
- data/spec/models/list_buyer_spec.rb +0 -59
- data/spec/models/list_buyer_spec_spec.rb +0 -59
- data/spec/models/list_category_assignment_spec.rb +0 -59
- data/spec/models/list_category_product_assignment_spec.rb +0 -59
- data/spec/models/list_category_spec.rb +0 -59
- data/spec/models/list_cost_center_assignment_spec.rb +0 -59
- data/spec/models/list_cost_center_spec.rb +0 -59
- data/spec/models/list_credit_card_assignment_spec.rb +0 -59
- data/spec/models/list_credit_card_spec.rb +0 -59
- data/spec/models/list_file_spec.rb +0 -59
- data/spec/models/list_inventory_spec.rb +0 -59
- data/spec/models/list_line_item_spec.rb +0 -59
- data/spec/models/list_message_cc_listener_assignment_spec.rb +0 -59
- data/spec/models/list_message_config_spec.rb +0 -59
- data/spec/models/list_message_sender_assignment_spec.rb +0 -59
- data/spec/models/list_message_sender_spec.rb +0 -59
- data/spec/models/list_order_approval_spec.rb +0 -59
- data/spec/models/list_order_promotion_spec.rb +0 -59
- data/spec/models/list_order_spec.rb +0 -59
- data/spec/models/list_payment_spec.rb +0 -59
- data/spec/models/list_price_schedule_spec.rb +0 -59
- data/spec/models/list_product_assignment_spec.rb +0 -59
- data/spec/models/list_product_spec.rb +0 -59
- data/spec/models/list_promotion_assignment_spec.rb +0 -59
- data/spec/models/list_promotion_spec.rb +0 -59
- data/spec/models/list_security_profile_assignment_spec.rb +0 -59
- data/spec/models/list_security_profile_spec.rb +0 -59
- data/spec/models/list_shipment_spec.rb +0 -59
- data/spec/models/list_spec_option_spec.rb +0 -59
- data/spec/models/list_spec_product_assignment_spec.rb +0 -59
- data/spec/models/list_spec_spec.rb +0 -59
- data/spec/models/list_spending_account_assignment_spec.rb +0 -59
- data/spec/models/list_spending_account_spec.rb +0 -59
- data/spec/models/list_user_group_assignment_spec.rb +0 -59
- data/spec/models/list_user_group_spec.rb +0 -59
- data/spec/models/list_user_spec.rb +0 -59
- data/spec/models/list_variant_spec.rb +0 -59
- data/spec/models/list_web_hook_route_spec.rb +0 -59
- data/spec/models/list_web_hook_spec.rb +0 -59
- data/spec/models/list_xp_index_spec.rb +0 -59
- data/spec/models/message_cc_listener_assignment_spec.rb +0 -83
- data/spec/models/message_config_spec.rb +0 -71
- data/spec/models/message_sender_assignment_spec.rb +0 -77
- data/spec/models/message_sender_spec.rb +0 -65
- data/spec/models/meta_spec.rb +0 -77
- data/spec/models/order_approval_spec.rb +0 -101
- data/spec/models/order_promotion_spec.rb +0 -53
- data/spec/models/order_spec.rb +0 -191
- data/spec/models/password_reset_request_spec.rb +0 -71
- data/spec/models/password_reset_spec.rb +0 -65
- data/spec/models/payment_spec.rb +0 -101
- data/spec/models/payment_transaction_spec.rb +0 -95
- data/spec/models/ping_response_spec.rb +0 -53
- data/spec/models/price_break_spec.rb +0 -59
- data/spec/models/price_schedule_spec.rb +0 -113
- data/spec/models/product_assignment_spec.rb +0 -83
- data/spec/models/product_spec.rb +0 -161
- data/spec/models/promotion_assignment_spec.rb +0 -71
- data/spec/models/promotion_spec.rb +0 -131
- data/spec/models/security_profile_assignment_spec.rb +0 -71
- data/spec/models/security_profile_spec.rb +0 -71
- data/spec/models/shipment_item_spec.rb +0 -65
- data/spec/models/shipment_spec.rb +0 -89
- data/spec/models/spec_option_spec.rb +0 -89
- data/spec/models/spec_product_assignment_spec.rb +0 -65
- data/spec/models/spec_spec.rb +0 -53
- data/spec/models/spending_account_assignment_spec.rb +0 -71
- data/spec/models/spending_account_spec.rb +0 -95
- data/spec/models/user_group_assignment_spec.rb +0 -59
- data/spec/models/user_group_spec.rb +0 -71
- data/spec/models/user_spec.rb +0 -113
- data/spec/models/variant_spec.rb +0 -77
- data/spec/models/web_hook_route_spec.rb +0 -65
- data/spec/models/web_hook_spec.rb +0 -113
- data/spec/models/xp_index_spec.rb +0 -59
- data/spec/spec_helper.rb +0 -122
@@ -1,47 +0,0 @@
|
|
1
|
-
=begin
|
2
|
-
#OrderCloud
|
3
|
-
|
4
|
-
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
|
-
|
6
|
-
OpenAPI spec version: 1.0
|
7
|
-
Contact: ordercloud@four51.com
|
8
|
-
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
|
10
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
11
|
-
you may not use this file except in compliance with the License.
|
12
|
-
You may obtain a copy of the License at
|
13
|
-
|
14
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
15
|
-
|
16
|
-
Unless required by applicable law or agreed to in writing, software
|
17
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
18
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
19
|
-
See the License for the specific language governing permissions and
|
20
|
-
limitations under the License.
|
21
|
-
|
22
|
-
=end
|
23
|
-
|
24
|
-
module OrderCloud
|
25
|
-
class ApiError < StandardError
|
26
|
-
attr_reader :code, :response_headers, :response_body
|
27
|
-
|
28
|
-
# Usage examples:
|
29
|
-
# ApiError.new
|
30
|
-
# ApiError.new("message")
|
31
|
-
# ApiError.new(:code => 500, :response_headers => {}, :response_body => "")
|
32
|
-
# ApiError.new(:code => 404, :message => "Not Found")
|
33
|
-
def initialize(arg = nil)
|
34
|
-
if arg.is_a? Hash
|
35
|
-
arg.each do |k, v|
|
36
|
-
if k.to_s == 'message'
|
37
|
-
super v
|
38
|
-
else
|
39
|
-
instance_variable_set "@#{k}", v
|
40
|
-
end
|
41
|
-
end
|
42
|
-
else
|
43
|
-
super arg
|
44
|
-
end
|
45
|
-
end
|
46
|
-
end
|
47
|
-
end
|
@@ -1,245 +0,0 @@
|
|
1
|
-
=begin
|
2
|
-
#OrderCloud
|
3
|
-
|
4
|
-
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
|
-
|
6
|
-
OpenAPI spec version: 1.0
|
7
|
-
Contact: ordercloud@four51.com
|
8
|
-
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
|
10
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
11
|
-
you may not use this file except in compliance with the License.
|
12
|
-
You may obtain a copy of the License at
|
13
|
-
|
14
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
15
|
-
|
16
|
-
Unless required by applicable law or agreed to in writing, software
|
17
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
18
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
19
|
-
See the License for the specific language governing permissions and
|
20
|
-
limitations under the License.
|
21
|
-
|
22
|
-
=end
|
23
|
-
|
24
|
-
require 'uri'
|
25
|
-
|
26
|
-
module OrderCloud
|
27
|
-
class Configuration
|
28
|
-
## OrderCloud specific configuration
|
29
|
-
attr_accessor :client_id
|
30
|
-
attr_accessor :scopes
|
31
|
-
attr_accessor :auth_url
|
32
|
-
attr_accessor :impersonation_token
|
33
|
-
|
34
|
-
# Returns true if impersonation is on, false otherwise
|
35
|
-
def impersonating?
|
36
|
-
@impersonation_token
|
37
|
-
end
|
38
|
-
|
39
|
-
# Returns the appropriate token
|
40
|
-
def get_access_token
|
41
|
-
if impersonating?
|
42
|
-
@impersonation_token
|
43
|
-
else
|
44
|
-
@access_token
|
45
|
-
end
|
46
|
-
end
|
47
|
-
|
48
|
-
# Defines url scheme
|
49
|
-
attr_accessor :scheme
|
50
|
-
|
51
|
-
# Defines url host
|
52
|
-
attr_accessor :host
|
53
|
-
|
54
|
-
# Defines url base path
|
55
|
-
attr_accessor :base_path
|
56
|
-
|
57
|
-
# Defines API keys used with API Key authentications.
|
58
|
-
#
|
59
|
-
# @return [Hash] key: parameter name, value: parameter value (API key)
|
60
|
-
#
|
61
|
-
# @example parameter name is "api_key", API key is "xxx" (e.g. "api_key=xxx" in query string)
|
62
|
-
# config.api_key['api_key'] = 'xxx'
|
63
|
-
attr_accessor :api_key
|
64
|
-
|
65
|
-
# Defines API key prefixes used with API Key authentications.
|
66
|
-
#
|
67
|
-
# @return [Hash] key: parameter name, value: API key prefix
|
68
|
-
#
|
69
|
-
# @example parameter name is "Authorization", API key prefix is "Token" (e.g. "Authorization: Token xxx" in headers)
|
70
|
-
# config.api_key_prefix['api_key'] = 'Token'
|
71
|
-
attr_accessor :api_key_prefix
|
72
|
-
|
73
|
-
# Defines the username used with HTTP basic authentication.
|
74
|
-
#
|
75
|
-
# @return [String]
|
76
|
-
attr_accessor :username
|
77
|
-
|
78
|
-
# Defines the password used with HTTP basic authentication.
|
79
|
-
#
|
80
|
-
# @return [String]
|
81
|
-
attr_accessor :password
|
82
|
-
|
83
|
-
# Defines the access token (Bearer) used with OAuth2.
|
84
|
-
attr_accessor :access_token
|
85
|
-
|
86
|
-
# Set this to enable/disable debugging. When enabled (set to true), HTTP request/response
|
87
|
-
# details will be logged with `logger.debug` (see the `logger` attribute).
|
88
|
-
# Default to false.
|
89
|
-
#
|
90
|
-
# @return [true, false]
|
91
|
-
attr_accessor :debugging
|
92
|
-
|
93
|
-
# Defines the logger used for debugging.
|
94
|
-
# Default to `Rails.logger` (when in Rails) or logging to STDOUT.
|
95
|
-
#
|
96
|
-
# @return [#debug]
|
97
|
-
attr_accessor :logger
|
98
|
-
|
99
|
-
# Defines the temporary folder to store downloaded files
|
100
|
-
# (for API endpoints that have file response).
|
101
|
-
# Default to use `Tempfile`.
|
102
|
-
#
|
103
|
-
# @return [String]
|
104
|
-
attr_accessor :temp_folder_path
|
105
|
-
|
106
|
-
# The time limit for HTTP request in seconds.
|
107
|
-
# Default to 0 (never times out).
|
108
|
-
attr_accessor :timeout
|
109
|
-
|
110
|
-
### TLS/SSL setting
|
111
|
-
# Set this to false to skip verifying SSL certificate when calling API from https server.
|
112
|
-
# Default to true.
|
113
|
-
#
|
114
|
-
# @note Do NOT set it to false in production code, otherwise you would face multiple types of cryptographic attacks.
|
115
|
-
#
|
116
|
-
# @return [true, false]
|
117
|
-
attr_accessor :verify_ssl
|
118
|
-
|
119
|
-
### TLS/SSL setting
|
120
|
-
# Set this to false to skip verifying SSL host name
|
121
|
-
# Default to true.
|
122
|
-
#
|
123
|
-
# @note Do NOT set it to false in production code, otherwise you would face multiple types of cryptographic attacks.
|
124
|
-
#
|
125
|
-
# @return [true, false]
|
126
|
-
attr_accessor :verify_ssl_host
|
127
|
-
|
128
|
-
### TLS/SSL setting
|
129
|
-
# Set this to customize the certificate file to verify the peer.
|
130
|
-
#
|
131
|
-
# @return [String] the path to the certificate file
|
132
|
-
#
|
133
|
-
# @see The `cainfo` option of Typhoeus, `--cert` option of libcurl. Related source code:
|
134
|
-
# https://github.com/typhoeus/typhoeus/blob/master/lib/typhoeus/easy_factory.rb#L145
|
135
|
-
attr_accessor :ssl_ca_cert
|
136
|
-
|
137
|
-
### TLS/SSL setting
|
138
|
-
# Client certificate file (for client certificate)
|
139
|
-
attr_accessor :cert_file
|
140
|
-
|
141
|
-
### TLS/SSL setting
|
142
|
-
# Client private key file (for client certificate)
|
143
|
-
attr_accessor :key_file
|
144
|
-
|
145
|
-
# Set this to customize parameters encoding of array parameter with multi collectionFormat.
|
146
|
-
# Default to nil.
|
147
|
-
#
|
148
|
-
# @see The params_encoding option of Ethon. Related source code:
|
149
|
-
# https://github.com/typhoeus/ethon/blob/master/lib/ethon/easy/queryable.rb#L96
|
150
|
-
attr_accessor :params_encoding
|
151
|
-
|
152
|
-
attr_accessor :inject_format
|
153
|
-
|
154
|
-
attr_accessor :force_ending_format
|
155
|
-
|
156
|
-
def initialize
|
157
|
-
@scheme = 'https'
|
158
|
-
@host = 'api.ordercloud.io'
|
159
|
-
@base_path = '/v1'
|
160
|
-
@api_key = {}
|
161
|
-
@api_key_prefix = {}
|
162
|
-
@timeout = 0
|
163
|
-
@verify_ssl = true
|
164
|
-
@verify_ssl_host = true
|
165
|
-
@params_encoding = nil
|
166
|
-
@cert_file = nil
|
167
|
-
@key_file = nil
|
168
|
-
@debugging = false
|
169
|
-
@inject_format = false
|
170
|
-
@force_ending_format = false
|
171
|
-
@logger = defined?(Rails) ? Rails.logger : Logger.new(STDOUT)
|
172
|
-
|
173
|
-
@auth_url = 'https://auth.ordercloud.io/oauth/token'
|
174
|
-
@impersonation_token = nil
|
175
|
-
@access_token = nil
|
176
|
-
@client_id = ''
|
177
|
-
@scopes = []
|
178
|
-
|
179
|
-
yield(self) if block_given?
|
180
|
-
end
|
181
|
-
|
182
|
-
# The default Configuration object.
|
183
|
-
def self.default
|
184
|
-
@@default ||= Configuration.new
|
185
|
-
end
|
186
|
-
|
187
|
-
## Resets the default configuration object to a clean one
|
188
|
-
def self.reset
|
189
|
-
@@default = Configuration.new
|
190
|
-
end
|
191
|
-
|
192
|
-
def configure
|
193
|
-
yield(self) if block_given?
|
194
|
-
end
|
195
|
-
|
196
|
-
def scheme=(scheme)
|
197
|
-
# remove :// from scheme
|
198
|
-
@scheme = scheme.sub(/:\/\//, '')
|
199
|
-
end
|
200
|
-
|
201
|
-
def host=(host)
|
202
|
-
# remove http(s):// and anything after a slash
|
203
|
-
@host = host.sub(/https?:\/\//, '').split('/').first
|
204
|
-
end
|
205
|
-
|
206
|
-
def base_path=(base_path)
|
207
|
-
# Add leading and trailing slashes to base_path
|
208
|
-
@base_path = "/#{base_path}".gsub(/\/+/, '/')
|
209
|
-
@base_path = "" if @base_path == "/"
|
210
|
-
end
|
211
|
-
|
212
|
-
def base_url
|
213
|
-
url = "#{scheme}://#{[host, base_path].join('/').gsub(/\/+/, '/')}".sub(/\/+\z/, '')
|
214
|
-
URI.encode(url)
|
215
|
-
end
|
216
|
-
|
217
|
-
# Gets API key (with prefix if set).
|
218
|
-
# @param [String] param_name the parameter name of API key auth
|
219
|
-
def api_key_with_prefix(param_name)
|
220
|
-
if @api_key_prefix[param_name]
|
221
|
-
"#{@api_key_prefix[param_name]} #{@api_key[param_name]}"
|
222
|
-
else
|
223
|
-
@api_key[param_name]
|
224
|
-
end
|
225
|
-
end
|
226
|
-
|
227
|
-
# Gets Basic Auth token string
|
228
|
-
def basic_auth_token
|
229
|
-
'Basic ' + ["#{username}:#{password}"].pack('m').delete("\r\n")
|
230
|
-
end
|
231
|
-
|
232
|
-
# Returns Auth Settings hash for api client.
|
233
|
-
def auth_settings
|
234
|
-
{
|
235
|
-
'oauth2' =>
|
236
|
-
{
|
237
|
-
type: 'oauth2',
|
238
|
-
in: 'header',
|
239
|
-
key: 'Authorization',
|
240
|
-
value: "Bearer #{get_access_token.access_token}"
|
241
|
-
},
|
242
|
-
}
|
243
|
-
end
|
244
|
-
end
|
245
|
-
end
|
@@ -1,217 +0,0 @@
|
|
1
|
-
=begin
|
2
|
-
#OrderCloud
|
3
|
-
|
4
|
-
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
|
-
|
6
|
-
OpenAPI spec version: 1.0
|
7
|
-
Contact: ordercloud@four51.com
|
8
|
-
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
|
10
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
11
|
-
you may not use this file except in compliance with the License.
|
12
|
-
You may obtain a copy of the License at
|
13
|
-
|
14
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
15
|
-
|
16
|
-
Unless required by applicable law or agreed to in writing, software
|
17
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
18
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
19
|
-
See the License for the specific language governing permissions and
|
20
|
-
limitations under the License.
|
21
|
-
|
22
|
-
=end
|
23
|
-
|
24
|
-
require 'date'
|
25
|
-
|
26
|
-
module OrderCloud
|
27
|
-
|
28
|
-
class AccessToken
|
29
|
-
attr_accessor :access_token
|
30
|
-
|
31
|
-
attr_accessor :expires_in
|
32
|
-
|
33
|
-
attr_accessor :token_type
|
34
|
-
|
35
|
-
|
36
|
-
# Attribute mapping from ruby-style variable name to JSON key.
|
37
|
-
def self.attribute_map
|
38
|
-
{
|
39
|
-
:'access_token' => :'access_token',
|
40
|
-
:'expires_in' => :'expires_in',
|
41
|
-
:'token_type' => :'token_type'
|
42
|
-
}
|
43
|
-
end
|
44
|
-
|
45
|
-
# Attribute type mapping.
|
46
|
-
def self.swagger_types
|
47
|
-
{
|
48
|
-
:'access_token' => :'String',
|
49
|
-
:'expires_in' => :'Integer',
|
50
|
-
:'token_type' => :'String'
|
51
|
-
}
|
52
|
-
end
|
53
|
-
|
54
|
-
# Initializes the object
|
55
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
56
|
-
def initialize(attributes = {})
|
57
|
-
return unless attributes.is_a?(Hash)
|
58
|
-
|
59
|
-
# convert string to symbol for hash key
|
60
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
61
|
-
|
62
|
-
if attributes.has_key?(:'access_token')
|
63
|
-
self.access_token = attributes[:'access_token']
|
64
|
-
end
|
65
|
-
|
66
|
-
if attributes.has_key?(:'expires_in')
|
67
|
-
self.expires_in = attributes[:'expires_in']
|
68
|
-
end
|
69
|
-
|
70
|
-
if attributes.has_key?(:'token_type')
|
71
|
-
self.token_type = attributes[:'token_type']
|
72
|
-
end
|
73
|
-
|
74
|
-
end
|
75
|
-
|
76
|
-
# Show invalid properties with the reasons. Usually used together with valid?
|
77
|
-
# @return Array for valid properies with the reasons
|
78
|
-
def list_invalid_properties
|
79
|
-
invalid_properties = Array.new
|
80
|
-
return invalid_properties
|
81
|
-
end
|
82
|
-
|
83
|
-
# Check to see if the all the properties in the model are valid
|
84
|
-
# @return true if the model is valid
|
85
|
-
def valid?
|
86
|
-
return true
|
87
|
-
end
|
88
|
-
|
89
|
-
# Checks equality by comparing each attribute.
|
90
|
-
# @param [Object] Object to be compared
|
91
|
-
def ==(o)
|
92
|
-
return true if self.equal?(o)
|
93
|
-
self.class == o.class &&
|
94
|
-
access_token == o.access_token &&
|
95
|
-
expires_in == o.expires_in &&
|
96
|
-
token_type == o.token_type
|
97
|
-
end
|
98
|
-
|
99
|
-
# @see the `==` method
|
100
|
-
# @param [Object] Object to be compared
|
101
|
-
def eql?(o)
|
102
|
-
self == o
|
103
|
-
end
|
104
|
-
|
105
|
-
# Calculates hash code according to all attributes.
|
106
|
-
# @return [Fixnum] Hash code
|
107
|
-
def hash
|
108
|
-
[access_token, expires_in, token_type].hash
|
109
|
-
end
|
110
|
-
|
111
|
-
# Builds the object from hash
|
112
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
113
|
-
# @return [Object] Returns the model itself
|
114
|
-
def build_from_hash(attributes)
|
115
|
-
return nil unless attributes.is_a?(Hash)
|
116
|
-
self.class.swagger_types.each_pair do |key, type|
|
117
|
-
if type =~ /^Array<(.*)>/i
|
118
|
-
# check to ensure the input is an array given that the the attribute
|
119
|
-
# is documented as an array but the input is not
|
120
|
-
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
121
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
122
|
-
end
|
123
|
-
elsif !attributes[self.class.attribute_map[key]].nil?
|
124
|
-
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
125
|
-
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
126
|
-
end
|
127
|
-
|
128
|
-
self
|
129
|
-
end
|
130
|
-
|
131
|
-
# Deserializes the data based on type
|
132
|
-
# @param string type Data type
|
133
|
-
# @param string value Value to be deserialized
|
134
|
-
# @return [Object] Deserialized data
|
135
|
-
def _deserialize(type, value)
|
136
|
-
case type.to_sym
|
137
|
-
when :DateTime
|
138
|
-
DateTime.parse(value)
|
139
|
-
when :Date
|
140
|
-
Date.parse(value)
|
141
|
-
when :String
|
142
|
-
value.to_s
|
143
|
-
when :Integer
|
144
|
-
value.to_i
|
145
|
-
when :Float
|
146
|
-
value.to_f
|
147
|
-
when :BOOLEAN
|
148
|
-
if value.to_s =~ /^(true|t|yes|y|1)$/i
|
149
|
-
true
|
150
|
-
else
|
151
|
-
false
|
152
|
-
end
|
153
|
-
when :Object
|
154
|
-
# generic object (usually a Hash), return directly
|
155
|
-
value
|
156
|
-
when /\AArray<(?<inner_type>.+)>\z/
|
157
|
-
inner_type = Regexp.last_match[:inner_type]
|
158
|
-
value.map { |v| _deserialize(inner_type, v) }
|
159
|
-
when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
|
160
|
-
k_type = Regexp.last_match[:k_type]
|
161
|
-
v_type = Regexp.last_match[:v_type]
|
162
|
-
{}.tap do |hash|
|
163
|
-
value.each do |k, v|
|
164
|
-
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
165
|
-
end
|
166
|
-
end
|
167
|
-
else # model
|
168
|
-
temp_model = OrderCloud.const_get(type).new
|
169
|
-
temp_model.build_from_hash(value)
|
170
|
-
end
|
171
|
-
end
|
172
|
-
|
173
|
-
# Returns the string representation of the object
|
174
|
-
# @return [String] String presentation of the object
|
175
|
-
def to_s
|
176
|
-
to_hash.to_s
|
177
|
-
end
|
178
|
-
|
179
|
-
# to_body is an alias to to_hash (backward compatibility)
|
180
|
-
# @return [Hash] Returns the object in the form of hash
|
181
|
-
def to_body
|
182
|
-
to_hash
|
183
|
-
end
|
184
|
-
|
185
|
-
# Returns the object in the form of hash
|
186
|
-
# @return [Hash] Returns the object in the form of hash
|
187
|
-
def to_hash
|
188
|
-
hash = {}
|
189
|
-
self.class.attribute_map.each_pair do |attr, param|
|
190
|
-
value = self.send(attr)
|
191
|
-
next if value.nil?
|
192
|
-
hash[param] = _to_hash(value)
|
193
|
-
end
|
194
|
-
hash
|
195
|
-
end
|
196
|
-
|
197
|
-
# Outputs non-array value in the form of hash
|
198
|
-
# For object, use to_hash. Otherwise, just return the value
|
199
|
-
# @param [Object] value Any valid value
|
200
|
-
# @return [Hash] Returns the value in the form of hash
|
201
|
-
def _to_hash(value)
|
202
|
-
if value.is_a?(Array)
|
203
|
-
value.compact.map{ |v| _to_hash(v) }
|
204
|
-
elsif value.is_a?(Hash)
|
205
|
-
{}.tap do |hash|
|
206
|
-
value.each { |k, v| hash[k] = _to_hash(v) }
|
207
|
-
end
|
208
|
-
elsif value.respond_to? :to_hash
|
209
|
-
value.to_hash
|
210
|
-
else
|
211
|
-
value
|
212
|
-
end
|
213
|
-
end
|
214
|
-
|
215
|
-
end
|
216
|
-
|
217
|
-
end
|