solifyn 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/README.md +344 -0
- data/Rakefile +10 -0
- data/docs/AddCollectionProductsDto.md +18 -0
- data/docs/Addon.md +26 -0
- data/docs/AddonCreate.md +26 -0
- data/docs/AddonUpdate.md +24 -0
- data/docs/AffiliateApi.md +845 -0
- data/docs/ApiKeyResponseDto.md +34 -0
- data/docs/AppPortalUrlResponseDto.md +18 -0
- data/docs/BalanceApi.md +184 -0
- data/docs/BillingApi.md +68 -0
- data/docs/Brand.md +40 -0
- data/docs/BrandCreate.md +28 -0
- data/docs/BrandUpdate.md +28 -0
- data/docs/BrandsApi.md +286 -0
- data/docs/Business.md +56 -0
- data/docs/BusinessCreate.md +18 -0
- data/docs/BusinessFullCreate.md +26 -0
- data/docs/BusinessFullCreateResponse.md +20 -0
- data/docs/BusinessesApi.md +350 -0
- data/docs/ChatApi.md +246 -0
- data/docs/CheckoutApi.md +405 -0
- data/docs/CheckoutLinkMessageResponseDto.md +18 -0
- data/docs/CheckoutLinkResponseDto.md +50 -0
- data/docs/CheckoutLinksApi.md +356 -0
- data/docs/CheckoutResponseDto.md +22 -0
- data/docs/CheckoutSessionDetailsDto.md +38 -0
- data/docs/CollectionArchivedResponseDto.md +18 -0
- data/docs/CollectionDetailResponseDto.md +36 -0
- data/docs/CollectionProductDeletedResponseDto.md +18 -0
- data/docs/CollectionProductDto.md +84 -0
- data/docs/CollectionProductEntry.md +20 -0
- data/docs/CollectionProductRefDto.md +20 -0
- data/docs/CollectionProductUpdatedResponseDto.md +18 -0
- data/docs/CollectionResponseDto.md +36 -0
- data/docs/CollectionUnarchivedResponseDto.md +18 -0
- data/docs/CollectionUpdatedResponseDto.md +18 -0
- data/docs/CollectionsApi.md +711 -0
- data/docs/CommunityApi.md +497 -0
- data/docs/CreateApiKeyDto.md +20 -0
- data/docs/CreateCheckoutDto.md +36 -0
- data/docs/CreateCheckoutLinkDto.md +44 -0
- data/docs/CreateCollectionCheckoutDto.md +26 -0
- data/docs/CreateCollectionDto.md +26 -0
- data/docs/CreateCustomerDto.md +26 -0
- data/docs/CreateMeterDto.md +32 -0
- data/docs/CreateSetupCheckoutDto.md +26 -0
- data/docs/CreateWebhookEndpointDto.md +22 -0
- data/docs/CustomerListResponseDto.md +20 -0
- data/docs/CustomerMessageResponseDto.md +18 -0
- data/docs/CustomerResponseDto.md +38 -0
- data/docs/CustomerSharedInviteResponseDto.md +22 -0
- data/docs/CustomersApi.md +356 -0
- data/docs/DashboardStatsDto.md +24 -0
- data/docs/DefaultApi.md +930 -0
- data/docs/DeveloperApi.md +628 -0
- data/docs/DigitalFileApi.md +187 -0
- data/docs/Discount.md +42 -0
- data/docs/DiscountCreate.md +36 -0
- data/docs/DiscountUpdate.md +34 -0
- data/docs/DiscountsApi.md +441 -0
- data/docs/DiscountsList200Response.md +24 -0
- data/docs/DiscountsList200ResponsePagination.md +22 -0
- data/docs/Dispute.md +58 -0
- data/docs/DisputeAttachmentDto.md +18 -0
- data/docs/DisputeEvidenceDto.md +24 -0
- data/docs/DisputeEvidenceUpdate.md +24 -0
- data/docs/DisputeFileUpload.md +24 -0
- data/docs/DisputeList.md +20 -0
- data/docs/DisputeListMetaDto.md +24 -0
- data/docs/DisputesApi.md +442 -0
- data/docs/Instance.md +30 -0
- data/docs/Invoice.md +26 -0
- data/docs/License.md +48 -0
- data/docs/LicenseApi.md +716 -0
- data/docs/LicenseKeysApi.md +716 -0
- data/docs/LicenseKeysClientApi.md +289 -0
- data/docs/LicenseSubDto.md +30 -0
- data/docs/LicenseValidationResponse.md +22 -0
- data/docs/LicensesActivateRequest.md +22 -0
- data/docs/LicensesCreateRequest.md +26 -0
- data/docs/LicensesDeactivate200Response.md +18 -0
- data/docs/LicensesDeactivateRequest.md +18 -0
- data/docs/LicensesUpdateInstancePostRequest.md +20 -0
- data/docs/LicensesUpdateRequest.md +22 -0
- data/docs/LicensesVerifyRequest.md +20 -0
- data/docs/MeterDetailResponseDto.md +44 -0
- data/docs/MeterEventsResponseDto.md +22 -0
- data/docs/MeterIngestEventDto.md +28 -0
- data/docs/MeterIngestRequestDto.md +18 -0
- data/docs/MeterIngestResponseDto.md +22 -0
- data/docs/MeterQuantitiesCostDto.md +26 -0
- data/docs/MeterQuantitiesResponseDto.md +24 -0
- data/docs/MeterResponseDto.md +40 -0
- data/docs/MeterUsageEventDto.md +30 -0
- data/docs/MetersApi.md +515 -0
- data/docs/OperationalWebhookEndpointHeadersInDto.md +18 -0
- data/docs/OperationalWebhookEndpointHeadersResponseDto.md +20 -0
- data/docs/OperationalWebhookEndpointInDto.md +32 -0
- data/docs/OperationalWebhookEndpointListResponseDto.md +24 -0
- data/docs/OperationalWebhookEndpointResponseDto.md +38 -0
- data/docs/OperationalWebhookEndpointSecretInDto.md +18 -0
- data/docs/OperationalWebhookEndpointSecretResponseDto.md +18 -0
- data/docs/OperationalWebhookEndpointUpdateDto.md +30 -0
- data/docs/Order.md +68 -0
- data/docs/OrderBilling.md +26 -0
- data/docs/OrderBillingUpdate.md +26 -0
- data/docs/OrderCustomer.md +24 -0
- data/docs/OrderDetail.md +22 -0
- data/docs/OrderList.md +20 -0
- data/docs/OrderProductCart.md +26 -0
- data/docs/OrderRefund.md +32 -0
- data/docs/OrderRefundCreate.md +26 -0
- data/docs/OrderUpdate.md +18 -0
- data/docs/OrdersApi.md +369 -0
- data/docs/PartnerApi.md +125 -0
- data/docs/PayoutAccessToken.md +20 -0
- data/docs/PayoutAccount.md +22 -0
- data/docs/PayoutAccountLink.md +20 -0
- data/docs/PayoutMethod.md +24 -0
- data/docs/PayoutMethodList.md +18 -0
- data/docs/PayoutVerification.md +24 -0
- data/docs/PayoutVerificationList.md +18 -0
- data/docs/PayoutsApi.md +579 -0
- data/docs/PricePreviewResponseDto.md +24 -0
- data/docs/Product.md +82 -0
- data/docs/ProductAddOnsApi.md +433 -0
- data/docs/ProductCreate.md +62 -0
- data/docs/ProductCreateAddonsInner.md +26 -0
- data/docs/ProductCreateCustomFieldsInner.md +24 -0
- data/docs/ProductMessageResponseDto.md +18 -0
- data/docs/ProductSubDto.md +22 -0
- data/docs/ProductUpdate.md +62 -0
- data/docs/ProductsApi.md +445 -0
- data/docs/ProductsArchive200Response.md +18 -0
- data/docs/ProductsList200Response.md +20 -0
- data/docs/ProductsList200ResponsePagination.md +20 -0
- data/docs/ProductsUnarchive200Response.md +18 -0
- data/docs/Refund.md +42 -0
- data/docs/RefundRequestsApi.md +311 -0
- data/docs/RefundsChargebacksApi.md +215 -0
- data/docs/ResolvedAddon.md +24 -0
- data/docs/RevokeSeatDto.md +20 -0
- data/docs/Subscription.md +68 -0
- data/docs/SubscriptionAction.md +30 -0
- data/docs/SubscriptionCompanyDto.md +20 -0
- data/docs/SubscriptionDetail.md +24 -0
- data/docs/SubscriptionDetailProduct.md +28 -0
- data/docs/SubscriptionList.md +20 -0
- data/docs/SubscriptionMemberDto.md +18 -0
- data/docs/SubscriptionPlanDto.md +20 -0
- data/docs/SubscriptionProductDto.md +22 -0
- data/docs/SubscriptionSeatAdjustment.md +34 -0
- data/docs/SubscriptionUserDto.md +24 -0
- data/docs/SubscriptionsAction201Response.md +49 -0
- data/docs/SubscriptionsApi.md +223 -0
- data/docs/SupportedCurrenciesResponseDto.md +20 -0
- data/docs/TicketApi.md +318 -0
- data/docs/UpdateCheckoutLinkDto.md +44 -0
- data/docs/UpdateCollectionDto.md +22 -0
- data/docs/UpdateCollectionProductDto.md +18 -0
- data/docs/UpdateCustomerDto.md +24 -0
- data/docs/UpdateInstanceDto.md +20 -0
- data/docs/UpdateMeterDto.md +32 -0
- data/docs/UpdateWebhookEndpointDto.md +24 -0
- data/docs/UserPage.md +26 -0
- data/docs/UserProfileThemesApi.md +345 -0
- data/docs/UserSettings.md +34 -0
- data/docs/UserSettingsUpdate.md +76 -0
- data/docs/UserStats.md +20 -0
- data/docs/UserTheme.md +26 -0
- data/docs/UserThemeUpdate.md +22 -0
- data/docs/WebhookApi.md +128 -0
- data/docs/WebhookDeliveryResponseDto.md +34 -0
- data/docs/WebhookDisputePayload.md +42 -0
- data/docs/WebhookEndpointApi.md +574 -0
- data/docs/WebhookEndpointResponseDto.md +34 -0
- data/docs/WebhookLicensePayload.md +48 -0
- data/docs/WebhookPaymentPayload.md +116 -0
- data/docs/WebhookPaymentPayloadBillingAddress.md +30 -0
- data/docs/WebhookRefundPayload.md +38 -0
- data/docs/WebhookSubscriptionPayload.md +44 -0
- data/docs/WhopApiKeysRotation.md +18 -0
- data/docs/Withdrawal.md +46 -0
- data/docs/WithdrawalCreate.md +22 -0
- data/docs/WithdrawalList.md +20 -0
- data/git_push.sh +57 -0
- data/lib/solifyn/api/affiliate_api.rb +760 -0
- data/lib/solifyn/api/balance_api.rb +175 -0
- data/lib/solifyn/api/billing_api.rb +77 -0
- data/lib/solifyn/api/brands_api.rb +284 -0
- data/lib/solifyn/api/businesses_api.rb +338 -0
- data/lib/solifyn/api/chat_api.rb +232 -0
- data/lib/solifyn/api/checkout_api.rb +427 -0
- data/lib/solifyn/api/checkout_links_api.rb +347 -0
- data/lib/solifyn/api/collections_api.rb +690 -0
- data/lib/solifyn/api/community_api.rb +466 -0
- data/lib/solifyn/api/customers_api.rb +347 -0
- data/lib/solifyn/api/default_api.rb +828 -0
- data/lib/solifyn/api/developer_api.rb +631 -0
- data/lib/solifyn/api/digital_file_api.rb +181 -0
- data/lib/solifyn/api/discounts_api.rb +437 -0
- data/lib/solifyn/api/disputes_api.rb +424 -0
- data/lib/solifyn/api/license_api.rb +702 -0
- data/lib/solifyn/api/license_keys_api.rb +702 -0
- data/lib/solifyn/api/license_keys_client_api.rb +295 -0
- data/lib/solifyn/api/meters_api.rb +508 -0
- data/lib/solifyn/api/orders_api.rb +372 -0
- data/lib/solifyn/api/partner_api.rb +124 -0
- data/lib/solifyn/api/payouts_api.rb +520 -0
- data/lib/solifyn/api/product_add_ons_api.rb +432 -0
- data/lib/solifyn/api/products_api.rb +438 -0
- data/lib/solifyn/api/refund_requests_api.rb +305 -0
- data/lib/solifyn/api/refunds_chargebacks_api.rb +214 -0
- data/lib/solifyn/api/subscriptions_api.rb +230 -0
- data/lib/solifyn/api/ticket_api.rb +328 -0
- data/lib/solifyn/api/user_profile_themes_api.rb +313 -0
- data/lib/solifyn/api/webhook_api.rb +131 -0
- data/lib/solifyn/api/webhook_endpoint_api.rb +597 -0
- data/lib/solifyn/api_client.rb +394 -0
- data/lib/solifyn/api_error.rb +58 -0
- data/lib/solifyn/configuration.rb +313 -0
- data/lib/solifyn/models/add_collection_products_dto.rb +224 -0
- data/lib/solifyn/models/addon.rb +290 -0
- data/lib/solifyn/models/addon_create.rb +276 -0
- data/lib/solifyn/models/addon_update.rb +245 -0
- data/lib/solifyn/models/api_key_response_dto.rb +336 -0
- data/lib/solifyn/models/app_portal_url_response_dto.rb +221 -0
- data/lib/solifyn/models/brand.rb +367 -0
- data/lib/solifyn/models/brand_create.rb +310 -0
- data/lib/solifyn/models/brand_update.rb +303 -0
- data/lib/solifyn/models/business.rb +482 -0
- data/lib/solifyn/models/business_create.rb +241 -0
- data/lib/solifyn/models/business_full_create.rb +288 -0
- data/lib/solifyn/models/business_full_create_response.rb +239 -0
- data/lib/solifyn/models/checkout_link_message_response_dto.rb +222 -0
- data/lib/solifyn/models/checkout_link_response_dto.rb +410 -0
- data/lib/solifyn/models/checkout_response_dto.rb +256 -0
- data/lib/solifyn/models/checkout_session_details_dto.rb +350 -0
- data/lib/solifyn/models/collection_archived_response_dto.rb +222 -0
- data/lib/solifyn/models/collection_detail_response_dto.rb +390 -0
- data/lib/solifyn/models/collection_product_deleted_response_dto.rb +222 -0
- data/lib/solifyn/models/collection_product_dto.rb +826 -0
- data/lib/solifyn/models/collection_product_entry.rb +258 -0
- data/lib/solifyn/models/collection_product_ref_dto.rb +239 -0
- data/lib/solifyn/models/collection_product_updated_response_dto.rb +222 -0
- data/lib/solifyn/models/collection_response_dto.rb +390 -0
- data/lib/solifyn/models/collection_unarchived_response_dto.rb +222 -0
- data/lib/solifyn/models/collection_updated_response_dto.rb +222 -0
- data/lib/solifyn/models/create_api_key_dto.rb +234 -0
- data/lib/solifyn/models/create_checkout_dto.rb +314 -0
- data/lib/solifyn/models/create_checkout_link_dto.rb +582 -0
- data/lib/solifyn/models/create_collection_checkout_dto.rb +264 -0
- data/lib/solifyn/models/create_collection_dto.rb +305 -0
- data/lib/solifyn/models/create_customer_dto.rb +345 -0
- data/lib/solifyn/models/create_meter_dto.rb +344 -0
- data/lib/solifyn/models/create_setup_checkout_dto.rb +264 -0
- data/lib/solifyn/models/create_webhook_endpoint_dto.rb +251 -0
- data/lib/solifyn/models/customer_list_response_dto.rb +241 -0
- data/lib/solifyn/models/customer_message_response_dto.rb +222 -0
- data/lib/solifyn/models/customer_response_dto.rb +350 -0
- data/lib/solifyn/models/customer_shared_invite_response_dto.rb +249 -0
- data/lib/solifyn/models/dashboard_stats_dto.rb +273 -0
- data/lib/solifyn/models/discount.rb +466 -0
- data/lib/solifyn/models/discount_create.rb +362 -0
- data/lib/solifyn/models/discount_update.rb +331 -0
- data/lib/solifyn/models/discounts_list200_response.rb +273 -0
- data/lib/solifyn/models/discounts_list200_response_pagination.rb +256 -0
- data/lib/solifyn/models/dispute.rb +492 -0
- data/lib/solifyn/models/dispute_attachment_dto.rb +222 -0
- data/lib/solifyn/models/dispute_evidence_dto.rb +245 -0
- data/lib/solifyn/models/dispute_evidence_update.rb +245 -0
- data/lib/solifyn/models/dispute_file_upload.rb +259 -0
- data/lib/solifyn/models/dispute_list.rb +241 -0
- data/lib/solifyn/models/dispute_list_meta_dto.rb +273 -0
- data/lib/solifyn/models/instance.rb +325 -0
- data/lib/solifyn/models/invoice.rb +291 -0
- data/lib/solifyn/models/license.rb +512 -0
- data/lib/solifyn/models/license_sub_dto.rb +310 -0
- data/lib/solifyn/models/license_validation_response.rb +253 -0
- data/lib/solifyn/models/licenses_activate_request.rb +256 -0
- data/lib/solifyn/models/licenses_create_request.rb +269 -0
- data/lib/solifyn/models/licenses_deactivate200_response.rb +214 -0
- data/lib/solifyn/models/licenses_deactivate_request.rb +222 -0
- data/lib/solifyn/models/licenses_update_instance_post_request.rb +225 -0
- data/lib/solifyn/models/licenses_update_request.rb +266 -0
- data/lib/solifyn/models/licenses_verify_request.rb +239 -0
- data/lib/solifyn/models/meter_detail_response_dto.rb +454 -0
- data/lib/solifyn/models/meter_events_response_dto.rb +259 -0
- data/lib/solifyn/models/meter_ingest_event_dto.rb +290 -0
- data/lib/solifyn/models/meter_ingest_request_dto.rb +224 -0
- data/lib/solifyn/models/meter_ingest_response_dto.rb +258 -0
- data/lib/solifyn/models/meter_quantities_cost_dto.rb +290 -0
- data/lib/solifyn/models/meter_quantities_response_dto.rb +276 -0
- data/lib/solifyn/models/meter_response_dto.rb +418 -0
- data/lib/solifyn/models/meter_usage_event_dto.rb +319 -0
- data/lib/solifyn/models/operational_webhook_endpoint_headers_in_dto.rb +222 -0
- data/lib/solifyn/models/operational_webhook_endpoint_headers_response_dto.rb +241 -0
- data/lib/solifyn/models/operational_webhook_endpoint_in_dto.rb +315 -0
- data/lib/solifyn/models/operational_webhook_endpoint_list_response_dto.rb +257 -0
- data/lib/solifyn/models/operational_webhook_endpoint_response_dto.rb +363 -0
- data/lib/solifyn/models/operational_webhook_endpoint_secret_in_dto.rb +215 -0
- data/lib/solifyn/models/operational_webhook_endpoint_secret_response_dto.rb +221 -0
- data/lib/solifyn/models/operational_webhook_endpoint_update_dto.rb +303 -0
- data/lib/solifyn/models/order.rb +582 -0
- data/lib/solifyn/models/order_billing.rb +255 -0
- data/lib/solifyn/models/order_billing_update.rb +250 -0
- data/lib/solifyn/models/order_customer.rb +266 -0
- data/lib/solifyn/models/order_detail.rb +237 -0
- data/lib/solifyn/models/order_list.rb +241 -0
- data/lib/solifyn/models/order_product_cart.rb +283 -0
- data/lib/solifyn/models/order_refund.rb +334 -0
- data/lib/solifyn/models/order_refund_create.rb +278 -0
- data/lib/solifyn/models/order_update.rb +214 -0
- data/lib/solifyn/models/payout_access_token.rb +239 -0
- data/lib/solifyn/models/payout_account.rb +249 -0
- data/lib/solifyn/models/payout_account_link.rb +239 -0
- data/lib/solifyn/models/payout_method.rb +266 -0
- data/lib/solifyn/models/payout_method_list.rb +224 -0
- data/lib/solifyn/models/payout_verification.rb +266 -0
- data/lib/solifyn/models/payout_verification_list.rb +224 -0
- data/lib/solifyn/models/price_preview_response_dto.rb +273 -0
- data/lib/solifyn/models/product.rb +810 -0
- data/lib/solifyn/models/product_create.rb +527 -0
- data/lib/solifyn/models/product_create_addons_inner.rb +250 -0
- data/lib/solifyn/models/product_create_custom_fields_inner.rb +241 -0
- data/lib/solifyn/models/product_message_response_dto.rb +222 -0
- data/lib/solifyn/models/product_sub_dto.rb +253 -0
- data/lib/solifyn/models/product_update.rb +501 -0
- data/lib/solifyn/models/products_archive200_response.rb +214 -0
- data/lib/solifyn/models/products_list200_response.rb +239 -0
- data/lib/solifyn/models/products_list200_response_pagination.rb +239 -0
- data/lib/solifyn/models/products_unarchive200_response.rb +214 -0
- data/lib/solifyn/models/refund.rb +425 -0
- data/lib/solifyn/models/resolved_addon.rb +273 -0
- data/lib/solifyn/models/revoke_seat_dto.rb +239 -0
- data/lib/solifyn/models/subscription.rb +627 -0
- data/lib/solifyn/models/subscription_action.rb +392 -0
- data/lib/solifyn/models/subscription_company_dto.rb +239 -0
- data/lib/solifyn/models/subscription_detail.rb +278 -0
- data/lib/solifyn/models/subscription_detail_product.rb +300 -0
- data/lib/solifyn/models/subscription_list.rb +241 -0
- data/lib/solifyn/models/subscription_member_dto.rb +222 -0
- data/lib/solifyn/models/subscription_plan_dto.rb +232 -0
- data/lib/solifyn/models/subscription_product_dto.rb +249 -0
- data/lib/solifyn/models/subscription_seat_adjustment.rb +359 -0
- data/lib/solifyn/models/subscription_user_dto.rb +273 -0
- data/lib/solifyn/models/subscriptions_action201_response.rb +105 -0
- data/lib/solifyn/models/supported_currencies_response_dto.rb +239 -0
- data/lib/solifyn/models/update_checkout_link_dto.rb +575 -0
- data/lib/solifyn/models/update_collection_dto.rb +235 -0
- data/lib/solifyn/models/update_collection_product_dto.rb +241 -0
- data/lib/solifyn/models/update_customer_dto.rb +302 -0
- data/lib/solifyn/models/update_instance_dto.rb +225 -0
- data/lib/solifyn/models/update_meter_dto.rb +321 -0
- data/lib/solifyn/models/update_webhook_endpoint_dto.rb +281 -0
- data/lib/solifyn/models/user_page.rb +290 -0
- data/lib/solifyn/models/user_settings.rb +337 -0
- data/lib/solifyn/models/user_settings_update.rb +505 -0
- data/lib/solifyn/models/user_stats.rb +241 -0
- data/lib/solifyn/models/user_theme.rb +276 -0
- data/lib/solifyn/models/user_theme_update.rb +235 -0
- data/lib/solifyn/models/webhook_delivery_response_dto.rb +328 -0
- data/lib/solifyn/models/webhook_dispute_payload.rb +324 -0
- data/lib/solifyn/models/webhook_endpoint_response_dto.rb +339 -0
- data/lib/solifyn/models/webhook_license_payload.rb +512 -0
- data/lib/solifyn/models/webhook_payment_payload.rb +659 -0
- data/lib/solifyn/models/webhook_payment_payload_billing_address.rb +268 -0
- data/lib/solifyn/models/webhook_refund_payload.rb +306 -0
- data/lib/solifyn/models/webhook_subscription_payload.rb +333 -0
- data/lib/solifyn/models/whop_api_keys_rotation.rb +222 -0
- data/lib/solifyn/models/withdrawal.rb +411 -0
- data/lib/solifyn/models/withdrawal_create.rb +249 -0
- data/lib/solifyn/models/withdrawal_list.rb +241 -0
- data/lib/solifyn/version.rb +15 -0
- data/lib/solifyn.rb +191 -0
- data/solifyn.gemspec +39 -0
- data/spec/api/affiliate_api_spec.rb +165 -0
- data/spec/api/balance_api_spec.rb +62 -0
- data/spec/api/billing_api_spec.rb +46 -0
- data/spec/api/brands_api_spec.rb +83 -0
- data/spec/api/businesses_api_spec.rb +93 -0
- data/spec/api/chat_api_spec.rb +72 -0
- data/spec/api/checkout_api_spec.rb +99 -0
- data/spec/api/checkout_links_api_spec.rb +95 -0
- data/spec/api/collections_api_spec.rb +158 -0
- data/spec/api/community_api_spec.rb +113 -0
- data/spec/api/customers_api_spec.rb +95 -0
- data/spec/api/default_api_spec.rb +191 -0
- data/spec/api/developer_api_spec.rb +120 -0
- data/spec/api/digital_file_api_spec.rb +63 -0
- data/spec/api/discounts_api_spec.rb +113 -0
- data/spec/api/disputes_api_spec.rb +113 -0
- data/spec/api/license_api_spec.rb +160 -0
- data/spec/api/license_keys_api_spec.rb +160 -0
- data/spec/api/license_keys_client_api_spec.rb +84 -0
- data/spec/api/meters_api_spec.rb +125 -0
- data/spec/api/orders_api_spec.rb +103 -0
- data/spec/api/partner_api_spec.rb +53 -0
- data/spec/api/payouts_api_spec.rb +133 -0
- data/spec/api/product_add_ons_api_spec.rb +111 -0
- data/spec/api/products_api_spec.rb +115 -0
- data/spec/api/refund_requests_api_spec.rb +88 -0
- data/spec/api/refunds_chargebacks_api_spec.rb +71 -0
- data/spec/api/subscriptions_api_spec.rb +73 -0
- data/spec/api/ticket_api_spec.rb +86 -0
- data/spec/api/user_profile_themes_api_spec.rb +91 -0
- data/spec/api/webhook_api_spec.rb +54 -0
- data/spec/api/webhook_endpoint_api_spec.rb +136 -0
- data/spec/models/add_collection_products_dto_spec.rb +36 -0
- data/spec/models/addon_create_spec.rb +60 -0
- data/spec/models/addon_spec.rb +60 -0
- data/spec/models/addon_update_spec.rb +54 -0
- data/spec/models/api_key_response_dto_spec.rb +84 -0
- data/spec/models/app_portal_url_response_dto_spec.rb +36 -0
- data/spec/models/brand_create_spec.rb +66 -0
- data/spec/models/brand_spec.rb +102 -0
- data/spec/models/brand_update_spec.rb +66 -0
- data/spec/models/business_create_spec.rb +36 -0
- data/spec/models/business_full_create_response_spec.rb +42 -0
- data/spec/models/business_full_create_spec.rb +60 -0
- data/spec/models/business_spec.rb +150 -0
- data/spec/models/checkout_link_message_response_dto_spec.rb +36 -0
- data/spec/models/checkout_link_response_dto_spec.rb +132 -0
- data/spec/models/checkout_response_dto_spec.rb +48 -0
- data/spec/models/checkout_session_details_dto_spec.rb +96 -0
- data/spec/models/collection_archived_response_dto_spec.rb +36 -0
- data/spec/models/collection_detail_response_dto_spec.rb +94 -0
- data/spec/models/collection_product_deleted_response_dto_spec.rb +36 -0
- data/spec/models/collection_product_dto_spec.rb +236 -0
- data/spec/models/collection_product_entry_spec.rb +42 -0
- data/spec/models/collection_product_ref_dto_spec.rb +42 -0
- data/spec/models/collection_product_updated_response_dto_spec.rb +36 -0
- data/spec/models/collection_response_dto_spec.rb +94 -0
- data/spec/models/collection_unarchived_response_dto_spec.rb +36 -0
- data/spec/models/collection_updated_response_dto_spec.rb +36 -0
- data/spec/models/create_api_key_dto_spec.rb +42 -0
- data/spec/models/create_checkout_dto_spec.rb +90 -0
- data/spec/models/create_checkout_link_dto_spec.rb +114 -0
- data/spec/models/create_collection_checkout_dto_spec.rb +60 -0
- data/spec/models/create_collection_dto_spec.rb +64 -0
- data/spec/models/create_customer_dto_spec.rb +60 -0
- data/spec/models/create_meter_dto_spec.rb +82 -0
- data/spec/models/create_setup_checkout_dto_spec.rb +60 -0
- data/spec/models/create_webhook_endpoint_dto_spec.rb +48 -0
- data/spec/models/customer_list_response_dto_spec.rb +42 -0
- data/spec/models/customer_message_response_dto_spec.rb +36 -0
- data/spec/models/customer_response_dto_spec.rb +96 -0
- data/spec/models/customer_shared_invite_response_dto_spec.rb +48 -0
- data/spec/models/dashboard_stats_dto_spec.rb +54 -0
- data/spec/models/discount_create_spec.rb +94 -0
- data/spec/models/discount_spec.rb +116 -0
- data/spec/models/discount_update_spec.rb +88 -0
- data/spec/models/discounts_list200_response_pagination_spec.rb +48 -0
- data/spec/models/discounts_list200_response_spec.rb +54 -0
- data/spec/models/dispute_attachment_dto_spec.rb +36 -0
- data/spec/models/dispute_evidence_dto_spec.rb +54 -0
- data/spec/models/dispute_evidence_update_spec.rb +54 -0
- data/spec/models/dispute_file_upload_spec.rb +54 -0
- data/spec/models/dispute_list_meta_dto_spec.rb +54 -0
- data/spec/models/dispute_list_spec.rb +42 -0
- data/spec/models/dispute_spec.rb +156 -0
- data/spec/models/instance_spec.rb +72 -0
- data/spec/models/invoice_spec.rb +60 -0
- data/spec/models/license_spec.rb +130 -0
- data/spec/models/license_sub_dto_spec.rb +72 -0
- data/spec/models/license_validation_response_spec.rb +48 -0
- data/spec/models/licenses_activate_request_spec.rb +48 -0
- data/spec/models/licenses_create_request_spec.rb +60 -0
- data/spec/models/licenses_deactivate200_response_spec.rb +36 -0
- data/spec/models/licenses_deactivate_request_spec.rb +36 -0
- data/spec/models/licenses_update_instance_post_request_spec.rb +42 -0
- data/spec/models/licenses_update_request_spec.rb +52 -0
- data/spec/models/licenses_verify_request_spec.rb +42 -0
- data/spec/models/meter_detail_response_dto_spec.rb +118 -0
- data/spec/models/meter_events_response_dto_spec.rb +48 -0
- data/spec/models/meter_ingest_event_dto_spec.rb +66 -0
- data/spec/models/meter_ingest_request_dto_spec.rb +36 -0
- data/spec/models/meter_ingest_response_dto_spec.rb +48 -0
- data/spec/models/meter_quantities_cost_dto_spec.rb +60 -0
- data/spec/models/meter_quantities_response_dto_spec.rb +54 -0
- data/spec/models/meter_response_dto_spec.rb +106 -0
- data/spec/models/meter_usage_event_dto_spec.rb +72 -0
- data/spec/models/operational_webhook_endpoint_headers_in_dto_spec.rb +36 -0
- data/spec/models/operational_webhook_endpoint_headers_response_dto_spec.rb +42 -0
- data/spec/models/operational_webhook_endpoint_in_dto_spec.rb +78 -0
- data/spec/models/operational_webhook_endpoint_list_response_dto_spec.rb +54 -0
- data/spec/models/operational_webhook_endpoint_response_dto_spec.rb +96 -0
- data/spec/models/operational_webhook_endpoint_secret_in_dto_spec.rb +36 -0
- data/spec/models/operational_webhook_endpoint_secret_response_dto_spec.rb +36 -0
- data/spec/models/operational_webhook_endpoint_update_dto_spec.rb +72 -0
- data/spec/models/order_billing_spec.rb +60 -0
- data/spec/models/order_billing_update_spec.rb +60 -0
- data/spec/models/order_customer_spec.rb +54 -0
- data/spec/models/order_detail_spec.rb +48 -0
- data/spec/models/order_list_spec.rb +42 -0
- data/spec/models/order_product_cart_spec.rb +60 -0
- data/spec/models/order_refund_create_spec.rb +60 -0
- data/spec/models/order_refund_spec.rb +78 -0
- data/spec/models/order_spec.rb +180 -0
- data/spec/models/order_update_spec.rb +36 -0
- data/spec/models/payout_access_token_spec.rb +42 -0
- data/spec/models/payout_account_link_spec.rb +42 -0
- data/spec/models/payout_account_spec.rb +48 -0
- data/spec/models/payout_method_list_spec.rb +36 -0
- data/spec/models/payout_method_spec.rb +54 -0
- data/spec/models/payout_verification_list_spec.rb +36 -0
- data/spec/models/payout_verification_spec.rb +54 -0
- data/spec/models/price_preview_response_dto_spec.rb +54 -0
- data/spec/models/product_create_addons_inner_spec.rb +60 -0
- data/spec/models/product_create_custom_fields_inner_spec.rb +54 -0
- data/spec/models/product_create_spec.rb +170 -0
- data/spec/models/product_message_response_dto_spec.rb +36 -0
- data/spec/models/product_spec.rb +230 -0
- data/spec/models/product_sub_dto_spec.rb +48 -0
- data/spec/models/product_update_spec.rb +170 -0
- data/spec/models/products_archive200_response_spec.rb +36 -0
- data/spec/models/products_list200_response_pagination_spec.rb +42 -0
- data/spec/models/products_list200_response_spec.rb +42 -0
- data/spec/models/products_unarchive200_response_spec.rb +36 -0
- data/spec/models/refund_spec.rb +112 -0
- data/spec/models/resolved_addon_spec.rb +54 -0
- data/spec/models/revoke_seat_dto_spec.rb +42 -0
- data/spec/models/subscription_action_spec.rb +80 -0
- data/spec/models/subscription_company_dto_spec.rb +42 -0
- data/spec/models/subscription_detail_product_spec.rb +66 -0
- data/spec/models/subscription_detail_spec.rb +54 -0
- data/spec/models/subscription_list_spec.rb +42 -0
- data/spec/models/subscription_member_dto_spec.rb +36 -0
- data/spec/models/subscription_plan_dto_spec.rb +42 -0
- data/spec/models/subscription_product_dto_spec.rb +48 -0
- data/spec/models/subscription_seat_adjustment_spec.rb +84 -0
- data/spec/models/subscription_spec.rb +186 -0
- data/spec/models/subscription_user_dto_spec.rb +54 -0
- data/spec/models/subscriptions_action201_response_spec.rb +32 -0
- data/spec/models/supported_currencies_response_dto_spec.rb +42 -0
- data/spec/models/update_checkout_link_dto_spec.rb +114 -0
- data/spec/models/update_collection_dto_spec.rb +48 -0
- data/spec/models/update_collection_product_dto_spec.rb +36 -0
- data/spec/models/update_customer_dto_spec.rb +54 -0
- data/spec/models/update_instance_dto_spec.rb +42 -0
- data/spec/models/update_meter_dto_spec.rb +82 -0
- data/spec/models/update_webhook_endpoint_dto_spec.rb +58 -0
- data/spec/models/user_page_spec.rb +60 -0
- data/spec/models/user_settings_spec.rb +84 -0
- data/spec/models/user_settings_update_spec.rb +210 -0
- data/spec/models/user_stats_spec.rb +42 -0
- data/spec/models/user_theme_spec.rb +60 -0
- data/spec/models/user_theme_update_spec.rb +48 -0
- data/spec/models/webhook_delivery_response_dto_spec.rb +84 -0
- data/spec/models/webhook_dispute_payload_spec.rb +108 -0
- data/spec/models/webhook_endpoint_response_dto_spec.rb +84 -0
- data/spec/models/webhook_license_payload_spec.rb +130 -0
- data/spec/models/webhook_payment_payload_billing_address_spec.rb +72 -0
- data/spec/models/webhook_payment_payload_spec.rb +330 -0
- data/spec/models/webhook_refund_payload_spec.rb +96 -0
- data/spec/models/webhook_subscription_payload_spec.rb +114 -0
- data/spec/models/whop_api_keys_rotation_spec.rb +36 -0
- data/spec/models/withdrawal_create_spec.rb +48 -0
- data/spec/models/withdrawal_list_spec.rb +42 -0
- data/spec/models/withdrawal_spec.rb +120 -0
- data/spec/spec_helper.rb +111 -0
- metadata +831 -0
|
@@ -0,0 +1,582 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Solifyn API
|
|
3
|
+
|
|
4
|
+
#Welcome to the Solifyn API Reference. Leverage our secure endpoints to manage products and issue, validate, and manage software license keys programmatically.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.10.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module Solifyn
|
|
17
|
+
class CreateCheckoutLinkDto
|
|
18
|
+
# The friendly display title of this checkout link
|
|
19
|
+
attr_accessor :title
|
|
20
|
+
|
|
21
|
+
# Product database/Whop ID to sell
|
|
22
|
+
attr_accessor :product_id
|
|
23
|
+
|
|
24
|
+
# Optional collection database ID to sell
|
|
25
|
+
attr_accessor :collection_id
|
|
26
|
+
|
|
27
|
+
# Prefilled customer name for checkout inputs
|
|
28
|
+
attr_accessor :customer_name
|
|
29
|
+
|
|
30
|
+
# Prefilled customer email for checkout inputs
|
|
31
|
+
attr_accessor :customer_email
|
|
32
|
+
|
|
33
|
+
# Prefilled customer billing address line 1
|
|
34
|
+
attr_accessor :address_line1
|
|
35
|
+
|
|
36
|
+
# Prefilled customer billing city
|
|
37
|
+
attr_accessor :city
|
|
38
|
+
|
|
39
|
+
# Prefilled customer billing state
|
|
40
|
+
attr_accessor :state
|
|
41
|
+
|
|
42
|
+
# Prefilled customer billing zip/postal code
|
|
43
|
+
attr_accessor :postal_code
|
|
44
|
+
|
|
45
|
+
# Prefilled customer billing country (2-letter ISO)
|
|
46
|
+
attr_accessor :country
|
|
47
|
+
|
|
48
|
+
# Override quantity for checkout session
|
|
49
|
+
attr_accessor :quantity
|
|
50
|
+
|
|
51
|
+
# The absolute URL to redirect to upon successful payment completion
|
|
52
|
+
attr_accessor :redirect_url
|
|
53
|
+
|
|
54
|
+
# The absolute URL to redirect to if a customer cancels the payment
|
|
55
|
+
attr_accessor :cancel_url
|
|
56
|
+
|
|
57
|
+
# Whether to display discount input form fields on checkout screen
|
|
58
|
+
attr_accessor :show_discounts
|
|
59
|
+
|
|
60
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
61
|
+
def self.attribute_map
|
|
62
|
+
{
|
|
63
|
+
:'title' => :'title',
|
|
64
|
+
:'product_id' => :'productId',
|
|
65
|
+
:'collection_id' => :'collectionId',
|
|
66
|
+
:'customer_name' => :'customerName',
|
|
67
|
+
:'customer_email' => :'customerEmail',
|
|
68
|
+
:'address_line1' => :'addressLine1',
|
|
69
|
+
:'city' => :'city',
|
|
70
|
+
:'state' => :'state',
|
|
71
|
+
:'postal_code' => :'postalCode',
|
|
72
|
+
:'country' => :'country',
|
|
73
|
+
:'quantity' => :'quantity',
|
|
74
|
+
:'redirect_url' => :'redirectUrl',
|
|
75
|
+
:'cancel_url' => :'cancelUrl',
|
|
76
|
+
:'show_discounts' => :'showDiscounts'
|
|
77
|
+
}
|
|
78
|
+
end
|
|
79
|
+
|
|
80
|
+
# Returns all the JSON keys this model knows about
|
|
81
|
+
def self.acceptable_attributes
|
|
82
|
+
attribute_map.values
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
# Attribute type mapping.
|
|
86
|
+
def self.openapi_types
|
|
87
|
+
{
|
|
88
|
+
:'title' => :'String',
|
|
89
|
+
:'product_id' => :'String',
|
|
90
|
+
:'collection_id' => :'String',
|
|
91
|
+
:'customer_name' => :'String',
|
|
92
|
+
:'customer_email' => :'String',
|
|
93
|
+
:'address_line1' => :'String',
|
|
94
|
+
:'city' => :'String',
|
|
95
|
+
:'state' => :'String',
|
|
96
|
+
:'postal_code' => :'String',
|
|
97
|
+
:'country' => :'String',
|
|
98
|
+
:'quantity' => :'Object',
|
|
99
|
+
:'redirect_url' => :'String',
|
|
100
|
+
:'cancel_url' => :'String',
|
|
101
|
+
:'show_discounts' => :'Boolean'
|
|
102
|
+
}
|
|
103
|
+
end
|
|
104
|
+
|
|
105
|
+
# List of attributes with nullable: true
|
|
106
|
+
def self.openapi_nullable
|
|
107
|
+
Set.new([
|
|
108
|
+
])
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
# Initializes the object
|
|
112
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
113
|
+
def initialize(attributes = {})
|
|
114
|
+
if (!attributes.is_a?(Hash))
|
|
115
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Solifyn::CreateCheckoutLinkDto` initialize method"
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
119
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
120
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
121
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Solifyn::CreateCheckoutLinkDto`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
122
|
+
end
|
|
123
|
+
h[k.to_sym] = v
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
if attributes.key?(:'title')
|
|
127
|
+
self.title = attributes[:'title']
|
|
128
|
+
end
|
|
129
|
+
|
|
130
|
+
if attributes.key?(:'product_id')
|
|
131
|
+
self.product_id = attributes[:'product_id']
|
|
132
|
+
else
|
|
133
|
+
self.product_id = nil
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
if attributes.key?(:'collection_id')
|
|
137
|
+
self.collection_id = attributes[:'collection_id']
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
if attributes.key?(:'customer_name')
|
|
141
|
+
self.customer_name = attributes[:'customer_name']
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
if attributes.key?(:'customer_email')
|
|
145
|
+
self.customer_email = attributes[:'customer_email']
|
|
146
|
+
end
|
|
147
|
+
|
|
148
|
+
if attributes.key?(:'address_line1')
|
|
149
|
+
self.address_line1 = attributes[:'address_line1']
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
if attributes.key?(:'city')
|
|
153
|
+
self.city = attributes[:'city']
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
if attributes.key?(:'state')
|
|
157
|
+
self.state = attributes[:'state']
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
if attributes.key?(:'postal_code')
|
|
161
|
+
self.postal_code = attributes[:'postal_code']
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
if attributes.key?(:'country')
|
|
165
|
+
self.country = attributes[:'country']
|
|
166
|
+
end
|
|
167
|
+
|
|
168
|
+
if attributes.key?(:'quantity')
|
|
169
|
+
self.quantity = attributes[:'quantity']
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
if attributes.key?(:'redirect_url')
|
|
173
|
+
self.redirect_url = attributes[:'redirect_url']
|
|
174
|
+
end
|
|
175
|
+
|
|
176
|
+
if attributes.key?(:'cancel_url')
|
|
177
|
+
self.cancel_url = attributes[:'cancel_url']
|
|
178
|
+
end
|
|
179
|
+
|
|
180
|
+
if attributes.key?(:'show_discounts')
|
|
181
|
+
self.show_discounts = attributes[:'show_discounts']
|
|
182
|
+
else
|
|
183
|
+
self.show_discounts = true
|
|
184
|
+
end
|
|
185
|
+
end
|
|
186
|
+
|
|
187
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
188
|
+
# @return Array for valid properties with the reasons
|
|
189
|
+
def list_invalid_properties
|
|
190
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
191
|
+
invalid_properties = Array.new
|
|
192
|
+
if !@title.nil? && @title.to_s.length > 100
|
|
193
|
+
invalid_properties.push('invalid value for "title", the character length must be smaller than or equal to 100.')
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
if @product_id.nil?
|
|
197
|
+
invalid_properties.push('invalid value for "product_id", product_id cannot be nil.')
|
|
198
|
+
end
|
|
199
|
+
|
|
200
|
+
if @product_id.to_s.length > 50
|
|
201
|
+
invalid_properties.push('invalid value for "product_id", the character length must be smaller than or equal to 50.')
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
if !@collection_id.nil? && @collection_id.to_s.length > 50
|
|
205
|
+
invalid_properties.push('invalid value for "collection_id", the character length must be smaller than or equal to 50.')
|
|
206
|
+
end
|
|
207
|
+
|
|
208
|
+
if !@customer_name.nil? && @customer_name.to_s.length > 100
|
|
209
|
+
invalid_properties.push('invalid value for "customer_name", the character length must be smaller than or equal to 100.')
|
|
210
|
+
end
|
|
211
|
+
|
|
212
|
+
if !@customer_email.nil? && @customer_email.to_s.length > 255
|
|
213
|
+
invalid_properties.push('invalid value for "customer_email", the character length must be smaller than or equal to 255.')
|
|
214
|
+
end
|
|
215
|
+
|
|
216
|
+
if !@address_line1.nil? && @address_line1.to_s.length > 255
|
|
217
|
+
invalid_properties.push('invalid value for "address_line1", the character length must be smaller than or equal to 255.')
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
if !@city.nil? && @city.to_s.length > 100
|
|
221
|
+
invalid_properties.push('invalid value for "city", the character length must be smaller than or equal to 100.')
|
|
222
|
+
end
|
|
223
|
+
|
|
224
|
+
if !@state.nil? && @state.to_s.length > 100
|
|
225
|
+
invalid_properties.push('invalid value for "state", the character length must be smaller than or equal to 100.')
|
|
226
|
+
end
|
|
227
|
+
|
|
228
|
+
if !@postal_code.nil? && @postal_code.to_s.length > 20
|
|
229
|
+
invalid_properties.push('invalid value for "postal_code", the character length must be smaller than or equal to 20.')
|
|
230
|
+
end
|
|
231
|
+
|
|
232
|
+
if !@country.nil? && @country.to_s.length > 10
|
|
233
|
+
invalid_properties.push('invalid value for "country", the character length must be smaller than or equal to 10.')
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
if !@redirect_url.nil? && @redirect_url.to_s.length > 2048
|
|
237
|
+
invalid_properties.push('invalid value for "redirect_url", the character length must be smaller than or equal to 2048.')
|
|
238
|
+
end
|
|
239
|
+
|
|
240
|
+
if !@cancel_url.nil? && @cancel_url.to_s.length > 2048
|
|
241
|
+
invalid_properties.push('invalid value for "cancel_url", the character length must be smaller than or equal to 2048.')
|
|
242
|
+
end
|
|
243
|
+
|
|
244
|
+
invalid_properties
|
|
245
|
+
end
|
|
246
|
+
|
|
247
|
+
# Check to see if the all the properties in the model are valid
|
|
248
|
+
# @return true if the model is valid
|
|
249
|
+
def valid?
|
|
250
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
251
|
+
return false if !@title.nil? && @title.to_s.length > 100
|
|
252
|
+
return false if @product_id.nil?
|
|
253
|
+
return false if @product_id.to_s.length > 50
|
|
254
|
+
return false if !@collection_id.nil? && @collection_id.to_s.length > 50
|
|
255
|
+
return false if !@customer_name.nil? && @customer_name.to_s.length > 100
|
|
256
|
+
return false if !@customer_email.nil? && @customer_email.to_s.length > 255
|
|
257
|
+
return false if !@address_line1.nil? && @address_line1.to_s.length > 255
|
|
258
|
+
return false if !@city.nil? && @city.to_s.length > 100
|
|
259
|
+
return false if !@state.nil? && @state.to_s.length > 100
|
|
260
|
+
return false if !@postal_code.nil? && @postal_code.to_s.length > 20
|
|
261
|
+
return false if !@country.nil? && @country.to_s.length > 10
|
|
262
|
+
return false if !@redirect_url.nil? && @redirect_url.to_s.length > 2048
|
|
263
|
+
return false if !@cancel_url.nil? && @cancel_url.to_s.length > 2048
|
|
264
|
+
true
|
|
265
|
+
end
|
|
266
|
+
|
|
267
|
+
# Custom attribute writer method with validation
|
|
268
|
+
# @param [Object] title Value to be assigned
|
|
269
|
+
def title=(title)
|
|
270
|
+
if title.nil?
|
|
271
|
+
fail ArgumentError, 'title cannot be nil'
|
|
272
|
+
end
|
|
273
|
+
|
|
274
|
+
if title.to_s.length > 100
|
|
275
|
+
fail ArgumentError, 'invalid value for "title", the character length must be smaller than or equal to 100.'
|
|
276
|
+
end
|
|
277
|
+
|
|
278
|
+
@title = title
|
|
279
|
+
end
|
|
280
|
+
|
|
281
|
+
# Custom attribute writer method with validation
|
|
282
|
+
# @param [Object] product_id Value to be assigned
|
|
283
|
+
def product_id=(product_id)
|
|
284
|
+
if product_id.nil?
|
|
285
|
+
fail ArgumentError, 'product_id cannot be nil'
|
|
286
|
+
end
|
|
287
|
+
|
|
288
|
+
if product_id.to_s.length > 50
|
|
289
|
+
fail ArgumentError, 'invalid value for "product_id", the character length must be smaller than or equal to 50.'
|
|
290
|
+
end
|
|
291
|
+
|
|
292
|
+
@product_id = product_id
|
|
293
|
+
end
|
|
294
|
+
|
|
295
|
+
# Custom attribute writer method with validation
|
|
296
|
+
# @param [Object] collection_id Value to be assigned
|
|
297
|
+
def collection_id=(collection_id)
|
|
298
|
+
if collection_id.nil?
|
|
299
|
+
fail ArgumentError, 'collection_id cannot be nil'
|
|
300
|
+
end
|
|
301
|
+
|
|
302
|
+
if collection_id.to_s.length > 50
|
|
303
|
+
fail ArgumentError, 'invalid value for "collection_id", the character length must be smaller than or equal to 50.'
|
|
304
|
+
end
|
|
305
|
+
|
|
306
|
+
@collection_id = collection_id
|
|
307
|
+
end
|
|
308
|
+
|
|
309
|
+
# Custom attribute writer method with validation
|
|
310
|
+
# @param [Object] customer_name Value to be assigned
|
|
311
|
+
def customer_name=(customer_name)
|
|
312
|
+
if customer_name.nil?
|
|
313
|
+
fail ArgumentError, 'customer_name cannot be nil'
|
|
314
|
+
end
|
|
315
|
+
|
|
316
|
+
if customer_name.to_s.length > 100
|
|
317
|
+
fail ArgumentError, 'invalid value for "customer_name", the character length must be smaller than or equal to 100.'
|
|
318
|
+
end
|
|
319
|
+
|
|
320
|
+
@customer_name = customer_name
|
|
321
|
+
end
|
|
322
|
+
|
|
323
|
+
# Custom attribute writer method with validation
|
|
324
|
+
# @param [Object] customer_email Value to be assigned
|
|
325
|
+
def customer_email=(customer_email)
|
|
326
|
+
if customer_email.nil?
|
|
327
|
+
fail ArgumentError, 'customer_email cannot be nil'
|
|
328
|
+
end
|
|
329
|
+
|
|
330
|
+
if customer_email.to_s.length > 255
|
|
331
|
+
fail ArgumentError, 'invalid value for "customer_email", the character length must be smaller than or equal to 255.'
|
|
332
|
+
end
|
|
333
|
+
|
|
334
|
+
@customer_email = customer_email
|
|
335
|
+
end
|
|
336
|
+
|
|
337
|
+
# Custom attribute writer method with validation
|
|
338
|
+
# @param [Object] address_line1 Value to be assigned
|
|
339
|
+
def address_line1=(address_line1)
|
|
340
|
+
if address_line1.nil?
|
|
341
|
+
fail ArgumentError, 'address_line1 cannot be nil'
|
|
342
|
+
end
|
|
343
|
+
|
|
344
|
+
if address_line1.to_s.length > 255
|
|
345
|
+
fail ArgumentError, 'invalid value for "address_line1", the character length must be smaller than or equal to 255.'
|
|
346
|
+
end
|
|
347
|
+
|
|
348
|
+
@address_line1 = address_line1
|
|
349
|
+
end
|
|
350
|
+
|
|
351
|
+
# Custom attribute writer method with validation
|
|
352
|
+
# @param [Object] city Value to be assigned
|
|
353
|
+
def city=(city)
|
|
354
|
+
if city.nil?
|
|
355
|
+
fail ArgumentError, 'city cannot be nil'
|
|
356
|
+
end
|
|
357
|
+
|
|
358
|
+
if city.to_s.length > 100
|
|
359
|
+
fail ArgumentError, 'invalid value for "city", the character length must be smaller than or equal to 100.'
|
|
360
|
+
end
|
|
361
|
+
|
|
362
|
+
@city = city
|
|
363
|
+
end
|
|
364
|
+
|
|
365
|
+
# Custom attribute writer method with validation
|
|
366
|
+
# @param [Object] state Value to be assigned
|
|
367
|
+
def state=(state)
|
|
368
|
+
if state.nil?
|
|
369
|
+
fail ArgumentError, 'state cannot be nil'
|
|
370
|
+
end
|
|
371
|
+
|
|
372
|
+
if state.to_s.length > 100
|
|
373
|
+
fail ArgumentError, 'invalid value for "state", the character length must be smaller than or equal to 100.'
|
|
374
|
+
end
|
|
375
|
+
|
|
376
|
+
@state = state
|
|
377
|
+
end
|
|
378
|
+
|
|
379
|
+
# Custom attribute writer method with validation
|
|
380
|
+
# @param [Object] postal_code Value to be assigned
|
|
381
|
+
def postal_code=(postal_code)
|
|
382
|
+
if postal_code.nil?
|
|
383
|
+
fail ArgumentError, 'postal_code cannot be nil'
|
|
384
|
+
end
|
|
385
|
+
|
|
386
|
+
if postal_code.to_s.length > 20
|
|
387
|
+
fail ArgumentError, 'invalid value for "postal_code", the character length must be smaller than or equal to 20.'
|
|
388
|
+
end
|
|
389
|
+
|
|
390
|
+
@postal_code = postal_code
|
|
391
|
+
end
|
|
392
|
+
|
|
393
|
+
# Custom attribute writer method with validation
|
|
394
|
+
# @param [Object] country Value to be assigned
|
|
395
|
+
def country=(country)
|
|
396
|
+
if country.nil?
|
|
397
|
+
fail ArgumentError, 'country cannot be nil'
|
|
398
|
+
end
|
|
399
|
+
|
|
400
|
+
if country.to_s.length > 10
|
|
401
|
+
fail ArgumentError, 'invalid value for "country", the character length must be smaller than or equal to 10.'
|
|
402
|
+
end
|
|
403
|
+
|
|
404
|
+
@country = country
|
|
405
|
+
end
|
|
406
|
+
|
|
407
|
+
# Custom attribute writer method with validation
|
|
408
|
+
# @param [Object] redirect_url Value to be assigned
|
|
409
|
+
def redirect_url=(redirect_url)
|
|
410
|
+
if redirect_url.nil?
|
|
411
|
+
fail ArgumentError, 'redirect_url cannot be nil'
|
|
412
|
+
end
|
|
413
|
+
|
|
414
|
+
if redirect_url.to_s.length > 2048
|
|
415
|
+
fail ArgumentError, 'invalid value for "redirect_url", the character length must be smaller than or equal to 2048.'
|
|
416
|
+
end
|
|
417
|
+
|
|
418
|
+
@redirect_url = redirect_url
|
|
419
|
+
end
|
|
420
|
+
|
|
421
|
+
# Custom attribute writer method with validation
|
|
422
|
+
# @param [Object] cancel_url Value to be assigned
|
|
423
|
+
def cancel_url=(cancel_url)
|
|
424
|
+
if cancel_url.nil?
|
|
425
|
+
fail ArgumentError, 'cancel_url cannot be nil'
|
|
426
|
+
end
|
|
427
|
+
|
|
428
|
+
if cancel_url.to_s.length > 2048
|
|
429
|
+
fail ArgumentError, 'invalid value for "cancel_url", the character length must be smaller than or equal to 2048.'
|
|
430
|
+
end
|
|
431
|
+
|
|
432
|
+
@cancel_url = cancel_url
|
|
433
|
+
end
|
|
434
|
+
|
|
435
|
+
# Checks equality by comparing each attribute.
|
|
436
|
+
# @param [Object] Object to be compared
|
|
437
|
+
def ==(o)
|
|
438
|
+
return true if self.equal?(o)
|
|
439
|
+
self.class == o.class &&
|
|
440
|
+
title == o.title &&
|
|
441
|
+
product_id == o.product_id &&
|
|
442
|
+
collection_id == o.collection_id &&
|
|
443
|
+
customer_name == o.customer_name &&
|
|
444
|
+
customer_email == o.customer_email &&
|
|
445
|
+
address_line1 == o.address_line1 &&
|
|
446
|
+
city == o.city &&
|
|
447
|
+
state == o.state &&
|
|
448
|
+
postal_code == o.postal_code &&
|
|
449
|
+
country == o.country &&
|
|
450
|
+
quantity == o.quantity &&
|
|
451
|
+
redirect_url == o.redirect_url &&
|
|
452
|
+
cancel_url == o.cancel_url &&
|
|
453
|
+
show_discounts == o.show_discounts
|
|
454
|
+
end
|
|
455
|
+
|
|
456
|
+
# @see the `==` method
|
|
457
|
+
# @param [Object] Object to be compared
|
|
458
|
+
def eql?(o)
|
|
459
|
+
self == o
|
|
460
|
+
end
|
|
461
|
+
|
|
462
|
+
# Calculates hash code according to all attributes.
|
|
463
|
+
# @return [Integer] Hash code
|
|
464
|
+
def hash
|
|
465
|
+
[title, product_id, collection_id, customer_name, customer_email, address_line1, city, state, postal_code, country, quantity, redirect_url, cancel_url, show_discounts].hash
|
|
466
|
+
end
|
|
467
|
+
|
|
468
|
+
# Builds the object from hash
|
|
469
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
470
|
+
# @return [Object] Returns the model itself
|
|
471
|
+
def self.build_from_hash(attributes)
|
|
472
|
+
return nil unless attributes.is_a?(Hash)
|
|
473
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
474
|
+
transformed_hash = {}
|
|
475
|
+
openapi_types.each_pair do |key, type|
|
|
476
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
477
|
+
transformed_hash["#{key}"] = nil
|
|
478
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
479
|
+
# check to ensure the input is an array given that the attribute
|
|
480
|
+
# is documented as an array but the input is not
|
|
481
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
482
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
483
|
+
end
|
|
484
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
485
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
486
|
+
end
|
|
487
|
+
end
|
|
488
|
+
new(transformed_hash)
|
|
489
|
+
end
|
|
490
|
+
|
|
491
|
+
# Deserializes the data based on type
|
|
492
|
+
# @param string type Data type
|
|
493
|
+
# @param string value Value to be deserialized
|
|
494
|
+
# @return [Object] Deserialized data
|
|
495
|
+
def self._deserialize(type, value)
|
|
496
|
+
case type.to_sym
|
|
497
|
+
when :Time
|
|
498
|
+
Time.parse(value)
|
|
499
|
+
when :Date
|
|
500
|
+
Date.parse(value)
|
|
501
|
+
when :String
|
|
502
|
+
value.to_s
|
|
503
|
+
when :Integer
|
|
504
|
+
value.to_i
|
|
505
|
+
when :Float
|
|
506
|
+
value.to_f
|
|
507
|
+
when :Boolean
|
|
508
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
509
|
+
true
|
|
510
|
+
else
|
|
511
|
+
false
|
|
512
|
+
end
|
|
513
|
+
when :Object
|
|
514
|
+
# generic object (usually a Hash), return directly
|
|
515
|
+
value
|
|
516
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
517
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
518
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
519
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
520
|
+
k_type = Regexp.last_match[:k_type]
|
|
521
|
+
v_type = Regexp.last_match[:v_type]
|
|
522
|
+
{}.tap do |hash|
|
|
523
|
+
value.each do |k, v|
|
|
524
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
525
|
+
end
|
|
526
|
+
end
|
|
527
|
+
else # model
|
|
528
|
+
# models (e.g. Pet) or oneOf
|
|
529
|
+
klass = Solifyn.const_get(type)
|
|
530
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
531
|
+
end
|
|
532
|
+
end
|
|
533
|
+
|
|
534
|
+
# Returns the string representation of the object
|
|
535
|
+
# @return [String] String presentation of the object
|
|
536
|
+
def to_s
|
|
537
|
+
to_hash.to_s
|
|
538
|
+
end
|
|
539
|
+
|
|
540
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
541
|
+
# @return [Hash] Returns the object in the form of hash
|
|
542
|
+
def to_body
|
|
543
|
+
to_hash
|
|
544
|
+
end
|
|
545
|
+
|
|
546
|
+
# Returns the object in the form of hash
|
|
547
|
+
# @return [Hash] Returns the object in the form of hash
|
|
548
|
+
def to_hash
|
|
549
|
+
hash = {}
|
|
550
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
551
|
+
value = self.send(attr)
|
|
552
|
+
if value.nil?
|
|
553
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
554
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
555
|
+
end
|
|
556
|
+
|
|
557
|
+
hash[param] = _to_hash(value)
|
|
558
|
+
end
|
|
559
|
+
hash
|
|
560
|
+
end
|
|
561
|
+
|
|
562
|
+
# Outputs non-array value in the form of hash
|
|
563
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
564
|
+
# @param [Object] value Any valid value
|
|
565
|
+
# @return [Hash] Returns the value in the form of hash
|
|
566
|
+
def _to_hash(value)
|
|
567
|
+
if value.is_a?(Array)
|
|
568
|
+
value.compact.map { |v| _to_hash(v) }
|
|
569
|
+
elsif value.is_a?(Hash)
|
|
570
|
+
{}.tap do |hash|
|
|
571
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
572
|
+
end
|
|
573
|
+
elsif value.respond_to? :to_hash
|
|
574
|
+
value.to_hash
|
|
575
|
+
else
|
|
576
|
+
value
|
|
577
|
+
end
|
|
578
|
+
end
|
|
579
|
+
|
|
580
|
+
end
|
|
581
|
+
|
|
582
|
+
end
|