togai_client 1.0.1 → 1.0.2
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 +4 -4
- data/README.md +3 -4
- data/docs/Account.md +26 -2
- data/docs/AccountAlias.md +28 -0
- data/docs/AccountAliases.md +1 -3
- data/docs/AccountAliasesPaginatedResponse.md +20 -0
- data/docs/AccountSchedule.md +38 -0
- data/docs/AccountsApi.md +840 -124
- data/docs/AccountsBillingInformation.md +20 -0
- data/docs/ActivatePricePlanRequest.md +18 -0
- data/docs/AddAccountAliasesRequest.md +3 -1
- data/docs/AddOn.md +30 -0
- data/docs/AddOnPaginatedResponse.md +22 -0
- data/docs/AddOnType.md +15 -0
- data/docs/AddOnsApi.md +365 -0
- data/docs/Address.md +30 -0
- data/docs/Alert.md +40 -0
- data/docs/AlertStatus.md +15 -0
- data/docs/AlertTemplate.md +38 -0
- data/docs/AlertTemplatesPaginatedResponse.md +20 -0
- data/docs/AlertsApi.md +566 -0
- data/docs/AlertsPaginatedResponse.md +20 -0
- data/docs/AliasPaginatedResponse.md +20 -0
- data/docs/AliasesApi.md +291 -0
- data/docs/AssociationConfig.md +24 -0
- data/docs/Attribute.md +22 -0
- data/docs/AuthenticationApi.md +74 -0
- data/docs/BillingConfig.md +20 -0
- data/docs/BillingEntitlementRateCard.md +34 -0
- data/docs/BillingEntitlementRevenueSummary.md +18 -0
- data/docs/BulkRateCardOperationsRequest.md +18 -0
- data/docs/BulkRateCardOperationsResponse.md +18 -0
- data/docs/CalculateRevenueRequest.md +30 -0
- data/docs/CalculateRevenueResponse.md +24 -0
- data/docs/CalculateRevenueResponseV2.md +22 -0
- data/docs/Computation.md +5 -3
- data/docs/CreateAccountAliasRequest.md +22 -0
- data/docs/CreateAccountRequest.md +27 -5
- data/docs/CreateAccountRequestWithoutCustomerId.md +42 -0
- data/docs/CreateAddOnRequest.md +22 -0
- data/docs/CreateAlertRequest.md +32 -0
- data/docs/CreateAliasRequest.md +18 -0
- data/docs/CreateBulkAliasRequest.md +18 -0
- data/docs/CreateCreditRequest.md +18 -0
- data/docs/CreateCreditResponse.md +18 -0
- data/docs/CreateCustomInvoiceRequest.md +36 -0
- data/docs/CreateCustomerContactRequest.md +30 -0
- data/docs/CreateCustomerContactResponse.md +34 -0
- data/docs/CreateCustomerRequest.md +9 -7
- data/docs/CreateCustomerResponse.md +8 -2
- data/docs/CreateEntitySetting.md +26 -0
- data/docs/CreateEventSchemaRequest.md +7 -1
- data/docs/CreateFeatureRequest.md +22 -0
- data/docs/CreateInvoiceGroupRequest.md +28 -0
- data/docs/CreatePaymentRequest.md +30 -0
- data/docs/CreatePricePlanDetails.md +38 -0
- data/docs/CreatePricePlanDetailsOverride.md +34 -0
- data/docs/CreatePricePlanMigrationRequest.md +32 -0
- data/docs/CreatePricePlanRequest.md +6 -2
- data/docs/CreatePricePlanV2Request.md +30 -0
- data/docs/CreatePricingRule.md +28 -0
- data/docs/CreateProposalRequest.md +40 -0
- data/docs/CreatePurchaseRequest.md +38 -0
- data/docs/CreateUsageMeterRequest.md +12 -6
- data/docs/Credit.md +50 -0
- data/docs/CreditBalanceResponse.md +28 -0
- data/docs/CreditDetailsResponse.md +52 -0
- data/docs/CreditGrantRateCard.md +34 -0
- data/docs/CreditGrantRevenueSummary.md +18 -0
- data/docs/CreditGrantType.md +15 -0
- data/docs/CreditRateDetails.md +20 -0
- data/docs/CreditRequest.md +34 -0
- data/docs/CreditTransaction.md +30 -0
- data/docs/CreditsApi.md +369 -0
- data/docs/CurrencyConfig.md +22 -0
- data/docs/CurrencyRateValue.md +20 -0
- data/docs/CurrencySlabRateDetail.md +24 -0
- data/docs/CustomInvoiceLineItem.md +28 -0
- data/docs/Customer.md +6 -2
- data/docs/CustomerPortalApi.md +77 -0
- data/docs/CustomersApi.md +85 -13
- data/docs/Dependency.md +22 -0
- data/docs/EditAccountScheduleRequest.md +18 -0
- data/docs/EditPricingScheduleRequest.md +18 -0
- data/docs/EnrichedField.md +22 -0
- data/docs/EnrichmentDependency.md +24 -0
- data/docs/Enrichments.md +20 -0
- data/docs/EntitlementOverageConfig.md +22 -0
- data/docs/EntitlementOverageConfigLookupCycle.md +20 -0
- data/docs/EntitlementOverageEntry.md +20 -0
- data/docs/EntitlementOverageRateCard.md +32 -0
- data/docs/EntitlementOverageRevenueSummary.md +18 -0
- data/docs/EntitlementsApi.md +599 -0
- data/docs/Event.md +11 -11
- data/docs/EventCorrectionInfo.md +32 -0
- data/docs/EventCorrectionRequest.md +18 -0
- data/docs/EventIngestionApi.md +16 -15
- data/docs/EventManagementApi.md +95 -21
- data/docs/EventPipelineInfo.md +15 -3
- data/docs/EventPipelineInfoAccount.md +3 -1
- data/docs/EventPipelineInfoEnrichments.md +22 -0
- data/docs/EventPipelineInfoFeatureDetails.md +24 -0
- data/docs/EventPipelineInfoPricePlans.md +28 -0
- data/docs/EventPipelineInfoRevenueDetails.md +22 -0
- data/docs/EventPipelineInfoUsageMeters.md +26 -0
- data/docs/EventSchema.md +11 -1
- data/docs/EventSchemaListData.md +11 -1
- data/docs/EventSchemasApi.md +82 -84
- data/docs/EventSchemasForFeature.md +20 -0
- data/docs/EventSource.md +20 -0
- data/docs/EventWithStatus.md +9 -1
- data/docs/EventWithStatusAndEventPipelineInfo.md +9 -1
- data/docs/EventsCorrectionResponse.md +18 -0
- data/docs/ExpiryType.md +15 -0
- data/docs/ExternalPaymentReference.md +26 -0
- data/docs/Feature.md +30 -0
- data/docs/FeatureApi.md +293 -0
- data/docs/FeatureConfig.md +22 -0
- data/docs/FeatureCreditEntry.md +32 -0
- data/docs/FeatureDetails.md +20 -0
- data/docs/FeatureListResponse.md +30 -0
- data/docs/FeaturePaginatedListData.md +22 -0
- data/docs/Field.md +26 -0
- data/docs/FileDownloadUrlResponse.md +18 -0
- data/docs/FileStorageApi.md +151 -0
- data/docs/FinalizeAccountSchedules.md +20 -0
- data/docs/FinalizePricePlanRequest.md +20 -0
- data/docs/FixedFeeRateCard.md +34 -0
- data/docs/FixedFeeRevenueSummary.md +18 -0
- data/docs/FixedFeeType.md +15 -0
- data/docs/GetCustomerPortalDelegateTokenRequest.md +24 -0
- data/docs/GetEntitlementValuesResponse.md +18 -0
- data/docs/GetEntitlementValuesResponseDataInner.md +20 -0
- data/docs/GetFeatureCreditEntriesPaginatedResponse.md +20 -0
- data/docs/GetFeatureCreditsResponse.md +28 -0
- data/docs/GetJobResponse.md +36 -0
- data/docs/GetLicenseUpdatesResponse.md +20 -0
- data/docs/GetMetricsRequest.md +4 -4
- data/docs/GetProposalResponse.md +62 -0
- data/docs/GetPurchaseResponse.md +62 -0
- data/docs/GrantDetails.md +24 -0
- data/docs/Incident.md +36 -0
- data/docs/IncidentsPaginatedResponse.md +20 -0
- data/docs/IngestEventRequest.md +1 -1
- data/docs/IngestEventResponse.md +12 -2
- data/docs/Invoice.md +68 -0
- data/docs/InvoiceDetails.md +28 -0
- data/docs/InvoiceDetailsAccount.md +24 -0
- data/docs/InvoiceDetailsCustomer.md +24 -0
- data/docs/InvoiceDetailsInvoiceGroup.md +28 -0
- data/docs/InvoiceDetailsOrganization.md +24 -0
- data/docs/InvoiceGroupAccountsPaginatedResponse.md +40 -0
- data/docs/InvoiceGroupDetails.md +30 -0
- data/docs/InvoiceGroupPaginatedResponse.md +20 -0
- data/docs/InvoiceGroups.md +36 -0
- data/docs/InvoiceGroupsApi.md +358 -0
- data/docs/InvoiceInfoInner.md +20 -0
- data/docs/InvoiceLineItem.md +34 -0
- data/docs/InvoiceSummary.md +58 -0
- data/docs/InvoiceTiming.md +15 -0
- data/docs/InvoicesApi.md +751 -0
- data/docs/InvoicesClass.md +15 -0
- data/docs/InvoicesStatus.md +15 -0
- data/docs/InvoicesType.md +15 -0
- data/docs/JobEntriesPaginatedResponse.md +22 -0
- data/docs/JobEntriesResponse.md +26 -0
- data/docs/JobsApi.md +361 -0
- data/docs/JobsPaginatedResponse.md +22 -0
- data/docs/JobsWithoutStatusInfoResponse.md +24 -0
- data/docs/LicenseEntriesConfig.md +24 -0
- data/docs/LicenseEntriesConfigLookupCycle.md +20 -0
- data/docs/LicenseEntriesConfigLookupRange.md +22 -0
- data/docs/LicenseEntry.md +22 -0
- data/docs/LicenseEntryDetailsUpdateRequest.md +22 -0
- data/docs/LicenseRateCard.md +40 -0
- data/docs/LicenseRateCardConfig.md +20 -0
- data/docs/LicenseUpdate.md +26 -0
- data/docs/LicenseUpdateRequest.md +30 -0
- data/docs/LicenseUpdateResponse.md +28 -0
- data/docs/LicensesApi.md +300 -0
- data/docs/ListCreditsResponse.md +20 -0
- data/docs/ListInvoicesResponse.md +20 -0
- data/docs/ListPaymentResponse.md +20 -0
- data/docs/ManageMiscellaneousChargesRequest.md +18 -0
- data/docs/MaxQuantityBreachAction.md +15 -0
- data/docs/MetricQuery.md +7 -5
- data/docs/MetricQueryFilterEntry.md +1 -1
- data/docs/MetricQueryResponse.md +1 -1
- data/docs/MetricsApi.md +7 -7
- data/docs/MigrationMode.md +15 -0
- data/docs/MinimumCommitment.md +20 -0
- data/docs/MiscellaneousCharge.md +26 -0
- data/docs/MiscellaneousChargesResponse.md +18 -0
- data/docs/ModelAlias.md +20 -0
- data/docs/NamedLicenseEntriesConfig.md +24 -0
- data/docs/NamedLicenseEntriesConfigLookupCycle.md +20 -0
- data/docs/NamedLicenseEntriesConfigLookupRange.md +22 -0
- data/docs/NamedLicenseEntry.md +24 -0
- data/docs/NamedLicenseUpdate.md +32 -0
- data/docs/NamedLicenseUpdatesPaginatedResponse.md +20 -0
- data/docs/Payment.md +38 -0
- data/docs/PaymentLineItemRecord.md +24 -0
- data/docs/PaymentsApi.md +227 -0
- data/docs/PlanOverride.md +6 -0
- data/docs/PreAction.md +20 -0
- data/docs/PriceExperimentationApi.md +147 -0
- data/docs/PricePlan.md +4 -0
- data/docs/PricePlanDetails.md +25 -3
- data/docs/PricePlanDetailsConfig.md +28 -0
- data/docs/PricePlanDetailsOverride.md +16 -2
- data/docs/PricePlanInfo.md +20 -0
- data/docs/PricePlanListData.md +10 -2
- data/docs/PricePlanMigrationConfig.md +30 -0
- data/docs/PricePlanType.md +15 -0
- data/docs/PricePlanV2.md +42 -0
- data/docs/PricePlanV2Api.md +953 -0
- data/docs/PricePlanV2PaginatedResponse.md +20 -0
- data/docs/PricePlansApi.md +202 -52
- data/docs/PricingCycleConfig.md +6 -6
- data/docs/PricingCycleConfigStartOffset.md +1 -1
- data/docs/PricingCycleInterval.md +15 -0
- data/docs/PricingRule.md +32 -0
- data/docs/PricingRuleAction.md +26 -0
- data/docs/PricingRuleChangesLog.md +30 -0
- data/docs/PricingRuleInfo.md +24 -0
- data/docs/PricingRuleTiming.md +15 -0
- data/docs/PricingRulesApi.md +83 -0
- data/docs/PricingRulesLog.md +28 -0
- data/docs/PricingRulesLogsPaginatedResponse.md +18 -0
- data/docs/PricingRulesPaginatedResponse.md +18 -0
- data/docs/PricingRulesValues.md +20 -0
- data/docs/PricingSchedule.md +9 -1
- data/docs/PricingSchedulePaginatedResponse.md +22 -0
- data/docs/PricingScheduleWithPricePlanId.md +36 -0
- data/docs/Proposal.md +62 -0
- data/docs/ProposalsListResponse.md +40 -0
- data/docs/ProposalsPaginatedResponse.md +22 -0
- data/docs/ProratedRefundMode.md +15 -0
- data/docs/ProrationConfig.md +22 -0
- data/docs/ProrationConfigCustomConfig.md +22 -0
- data/docs/ProrationConfigLookupCycleConfig.md +22 -0
- data/docs/Purchase.md +58 -0
- data/docs/PurchaseFeatureDetails.md +30 -0
- data/docs/PurchaseListResponse.md +46 -0
- data/docs/PurchasePaginatedListData.md +22 -0
- data/docs/PurchasePlanOverride.md +22 -0
- data/docs/PurchaseStatus.md +15 -0
- data/docs/PurchaseType.md +15 -0
- data/docs/QueryColumn.md +26 -0
- data/docs/QueryFilter.md +22 -0
- data/docs/QueryFunction.md +20 -0
- data/docs/QueryInput.md +28 -0
- data/docs/QueryInputSortInner.md +20 -0
- data/docs/RateCard.md +23 -5
- data/docs/RateCardData.md +28 -0
- data/docs/RateCardDetails.md +30 -0
- data/docs/RateCardOperation.md +22 -0
- data/docs/RateCardPaginatedResponse.md +20 -0
- data/docs/RatePlan.md +20 -0
- data/docs/RateValue.md +22 -0
- data/docs/RecurrenceConfig.md +20 -0
- data/docs/RemoveAccountAliasRequest.md +20 -0
- data/docs/RemoveAccountAliasesRequest.md +4 -2
- data/docs/Report.md +38 -0
- data/docs/ReportStatus.md +15 -0
- data/docs/ReportType.md +15 -0
- data/docs/ReportsApi.md +83 -0
- data/docs/ReportsPaginatedResponse.md +20 -0
- data/docs/RevenueInfo.md +42 -0
- data/docs/RevenueInfoV2.md +32 -0
- data/docs/RevenueSummaryWithMetadata.md +24 -0
- data/docs/ScheduleInfo.md +22 -0
- data/docs/SchedulesApi.md +667 -0
- data/docs/SchedulesPaginatedResponse.md +22 -0
- data/docs/Setting.md +30 -0
- data/docs/SettingDataType.md +15 -0
- data/docs/SettingPaginatedResponse.md +22 -0
- data/docs/SettingsApi.md +301 -0
- data/docs/Slab.md +24 -0
- data/docs/SlabDetail.md +26 -0
- data/docs/SlabRate.md +22 -0
- data/docs/SlabRevenue.md +22 -0
- data/docs/SlabRevenueMetadata.md +22 -0
- data/docs/SlabRevenueSummary.md +24 -0
- data/docs/SlabRevenueWithMetadata.md +24 -0
- data/docs/TokenResponse.md +18 -0
- data/docs/TopupWalletRequest.md +18 -0
- data/docs/UpdateAccountRequest.md +18 -2
- data/docs/UpdateAccountScheduleV2Request.md +26 -0
- data/docs/UpdateAddOnRequest.md +20 -0
- data/docs/UpdateAlertRequest.md +26 -0
- data/docs/UpdateCustomerRequest.md +5 -5
- data/docs/UpdateEventSchemaRequest.md +9 -3
- data/docs/UpdateFeatureCreditsRequest.md +20 -0
- data/docs/UpdateFeatureRequest.md +22 -0
- data/docs/UpdateIncidentStatusRequest.md +18 -0
- data/docs/UpdateInvoiceGroupAccounts.md +18 -0
- data/docs/UpdateInvoiceRequest.md +26 -0
- data/docs/UpdatePricePlanRequest.md +8 -2
- data/docs/UpdatePricePlanV2Request.md +22 -0
- data/docs/UpdatePricingRulesRequest.md +18 -0
- data/docs/UpdatePricingScheduleRequest.md +30 -0
- data/docs/UpdatePricingScheduleRequestWithActions.md +32 -0
- data/docs/UpdatePricingScheduleResponse.md +22 -0
- data/docs/UpdateProposalStatus.md +18 -0
- data/docs/UpdateSettingRequest.md +22 -0
- data/docs/UpdateUsageMeterRequest.md +13 -5
- data/docs/UpdateWalletRequest.md +20 -0
- data/docs/UsageConfig.md +24 -0
- data/docs/UsageConfigLookupCycle.md +20 -0
- data/docs/UsageConfigLookupRange.md +22 -0
- data/docs/UsageCycleInterval.md +15 -0
- data/docs/UsageLookupRange.md +20 -0
- data/docs/UsageMeter.md +12 -2
- data/docs/UsageMeterAggregation.md +15 -0
- data/docs/UsageMeterFilterEntry.md +20 -0
- data/docs/UsageMetersApi.md +64 -74
- data/docs/UsageRateCard.md +28 -0
- data/docs/ValidateEntitlementValueRequest.md +18 -0
- data/docs/ValidatedEntityError.md +24 -0
- data/docs/ValidatedEntityErrorsPaginatedResponse.md +20 -0
- data/docs/VersionsToMigrate.md +15 -0
- data/docs/WalletApi.md +301 -0
- data/docs/WalletBalanceResponse.md +40 -0
- data/docs/WalletEntriesPaginatedResponse.md +20 -0
- data/docs/WalletEntry.md +34 -0
- data/docs/WalletStatus.md +15 -0
- data/docs/WalletTopupDetails.md +20 -0
- data/lib/togai_client/api/accounts_api.rb +881 -220
- data/lib/togai_client/api/add_ons_api.rb +372 -0
- data/lib/togai_client/api/alerts_api.rb +527 -0
- data/lib/togai_client/api/aliases_api.rb +279 -0
- data/lib/togai_client/api/authentication_api.rb +79 -0
- data/lib/togai_client/api/credits_api.rb +351 -0
- data/lib/togai_client/api/customer_portal_api.rb +90 -0
- data/lib/togai_client/api/customers_api.rb +96 -18
- data/lib/togai_client/api/entitlements_api.rb +655 -0
- data/lib/togai_client/api/event_ingestion_api.rb +15 -15
- data/lib/togai_client/api/event_management_api.rb +97 -21
- data/lib/togai_client/api/event_schemas_api.rb +104 -107
- data/lib/togai_client/api/feature_api.rb +298 -0
- data/lib/togai_client/api/file_storage_api.rb +151 -0
- data/lib/togai_client/api/invoice_groups_api.rb +370 -0
- data/lib/togai_client/api/invoices_api.rb +705 -0
- data/lib/togai_client/api/jobs_api.rb +337 -0
- data/lib/togai_client/api/licenses_api.rb +282 -0
- data/lib/togai_client/api/metrics_api.rb +6 -6
- data/lib/togai_client/api/payments_api.rb +215 -0
- data/lib/togai_client/api/price_experimentation_api.rb +158 -0
- data/lib/togai_client/api/price_plan_v2_api.rb +960 -0
- data/lib/togai_client/api/price_plans_api.rb +214 -62
- data/lib/togai_client/api/pricing_rules_api.rb +106 -0
- data/lib/togai_client/api/reports_api.rb +92 -0
- data/lib/togai_client/api/schedules_api.rb +685 -0
- data/lib/togai_client/api/settings_api.rb +302 -0
- data/lib/togai_client/api/usage_meters_api.rb +97 -153
- data/lib/togai_client/api/wallet_api.rb +310 -0
- data/lib/togai_client/api_client.rb +25 -23
- data/lib/togai_client/api_error.rb +2 -1
- data/lib/togai_client/configuration.rb +51 -18
- data/lib/togai_client/models/account.rb +260 -28
- data/lib/togai_client/models/account_alias.rb +329 -0
- data/lib/togai_client/models/account_aliases.rb +23 -67
- data/lib/togai_client/models/account_aliases_paginated_response.rb +233 -0
- data/lib/togai_client/models/account_paginated_response.rb +14 -19
- data/lib/togai_client/models/account_schedule.rb +375 -0
- data/lib/togai_client/models/accounts_billing_information.rb +228 -0
- data/lib/togai_client/models/activate_price_plan_request.rb +235 -0
- data/lib/togai_client/models/add_account_aliases_request.rb +64 -25
- data/lib/togai_client/models/add_on.rb +395 -0
- data/lib/togai_client/models/add_on_paginated_response.rb +241 -0
- data/lib/togai_client/models/add_on_type.rb +42 -0
- data/lib/togai_client/models/address.rb +276 -0
- data/lib/togai_client/models/alert.rb +391 -0
- data/lib/togai_client/models/alert_status.rb +40 -0
- data/lib/togai_client/models/alert_template.rb +343 -0
- data/lib/togai_client/models/alert_templates_paginated_response.rb +232 -0
- data/lib/togai_client/models/alerts_paginated_response.rb +232 -0
- data/lib/togai_client/models/alias_paginated_response.rb +226 -0
- data/lib/togai_client/models/association_config.rb +244 -0
- data/lib/togai_client/models/attribute.rb +327 -0
- data/lib/togai_client/models/base_success_response.rb +16 -19
- data/lib/togai_client/models/billing_config.rb +225 -0
- data/lib/togai_client/models/billing_entitlement_rate_card.rb +370 -0
- data/lib/togai_client/models/billing_entitlement_revenue_summary.rb +221 -0
- data/lib/togai_client/models/bulk_rate_card_operations_request.rb +224 -0
- data/lib/togai_client/models/bulk_rate_card_operations_response.rb +224 -0
- data/lib/togai_client/models/calculate_revenue_request.rb +297 -0
- data/lib/togai_client/models/calculate_revenue_response.rb +264 -0
- data/lib/togai_client/models/calculate_revenue_response_v2.rb +248 -0
- data/lib/togai_client/models/computation.rb +49 -27
- data/lib/togai_client/models/create_account_alias_request.rb +270 -0
- data/lib/togai_client/models/create_account_request.rb +306 -27
- data/lib/togai_client/models/create_account_request_without_customer_id.rb +551 -0
- data/lib/togai_client/models/create_add_on_request.rb +309 -0
- data/lib/togai_client/models/create_alert_request.rb +327 -0
- data/lib/togai_client/models/create_alias_request.rb +241 -0
- data/lib/togai_client/models/create_bulk_alias_request.rb +252 -0
- data/lib/togai_client/models/create_credit_request.rb +224 -0
- data/lib/togai_client/models/create_credit_response.rb +223 -0
- data/lib/togai_client/models/create_custom_invoice_request.rb +411 -0
- data/lib/togai_client/models/create_customer_contact_request.rb +402 -0
- data/lib/togai_client/models/create_customer_contact_response.rb +435 -0
- data/lib/togai_client/models/create_customer_request.rb +69 -47
- data/lib/togai_client/models/create_customer_response.rb +81 -40
- data/lib/togai_client/models/create_entity_setting.rb +308 -0
- data/lib/togai_client/models/create_event_schema_request.rb +70 -24
- data/lib/togai_client/models/create_feature_request.rb +309 -0
- data/lib/togai_client/models/create_invoice_group_request.rb +344 -0
- data/lib/togai_client/models/create_payment_request.rb +394 -0
- data/lib/togai_client/models/create_price_plan_details.rb +339 -0
- data/lib/togai_client/models/create_price_plan_details_override.rb +319 -0
- data/lib/togai_client/models/create_price_plan_migration_request.rb +385 -0
- data/lib/togai_client/models/create_price_plan_request.rb +69 -24
- data/lib/togai_client/models/create_price_plan_v2_request.rb +367 -0
- data/lib/togai_client/models/create_pricing_rule.rb +313 -0
- data/lib/togai_client/models/create_proposal_request.rb +371 -0
- data/lib/togai_client/models/create_purchase_request.rb +330 -0
- data/lib/togai_client/models/create_usage_meter_request.rb +85 -42
- data/lib/togai_client/models/credit.rb +490 -0
- data/lib/togai_client/models/credit_balance_response.rb +302 -0
- data/lib/togai_client/models/credit_details_response.rb +508 -0
- data/lib/togai_client/models/credit_grant_rate_card.rb +332 -0
- data/lib/togai_client/models/credit_grant_revenue_summary.rb +221 -0
- data/lib/togai_client/models/credit_grant_type.rb +40 -0
- data/lib/togai_client/models/credit_rate_details.rb +262 -0
- data/lib/togai_client/models/credit_request.rb +330 -0
- data/lib/togai_client/models/credit_transaction.rb +357 -0
- data/lib/togai_client/models/currency_config.rb +296 -0
- data/lib/togai_client/models/currency_rate_value.rb +237 -0
- data/lib/togai_client/models/currency_slab_rate_detail.rb +287 -0
- data/lib/togai_client/models/custom_invoice_line_item.rb +260 -0
- data/lib/togai_client/models/customer.rb +68 -26
- data/lib/togai_client/models/customer_paginated_response.rb +14 -19
- data/lib/togai_client/models/dependency.rb +287 -0
- data/lib/togai_client/models/dimensions_schema.rb +16 -19
- data/lib/togai_client/models/edit_account_schedule_request.rb +252 -0
- data/lib/togai_client/models/edit_pricing_schedule_request.rb +252 -0
- data/lib/togai_client/models/enriched_field.rb +288 -0
- data/lib/togai_client/models/enrichment_dependency.rb +297 -0
- data/lib/togai_client/models/enrichments.rb +234 -0
- data/lib/togai_client/models/entitlement_overage_config.rb +278 -0
- data/lib/togai_client/models/entitlement_overage_config_lookup_cycle.rb +258 -0
- data/lib/togai_client/models/entitlement_overage_entry.rb +256 -0
- data/lib/togai_client/models/entitlement_overage_rate_card.rb +324 -0
- data/lib/togai_client/models/entitlement_overage_revenue_summary.rb +221 -0
- data/lib/togai_client/models/error_response.rb +16 -19
- data/lib/togai_client/models/event.rb +104 -84
- data/lib/togai_client/models/event_attribute_schema.rb +22 -21
- data/lib/togai_client/models/event_correction_info.rb +384 -0
- data/lib/togai_client/models/event_correction_request.rb +215 -0
- data/lib/togai_client/models/event_pipeline_info.rb +76 -25
- data/lib/togai_client/models/event_pipeline_info_account.rb +31 -23
- data/lib/togai_client/models/event_pipeline_info_customer.rb +18 -19
- data/lib/togai_client/models/event_pipeline_info_enrichments.rb +238 -0
- data/lib/togai_client/models/event_pipeline_info_event_schema.rb +18 -19
- data/lib/togai_client/models/event_pipeline_info_feature_details.rb +255 -0
- data/lib/togai_client/models/event_pipeline_info_price_plans.rb +306 -0
- data/lib/togai_client/models/event_pipeline_info_revenue_details.rb +253 -0
- data/lib/togai_client/models/event_pipeline_info_usage_meters.rb +312 -0
- data/lib/togai_client/models/event_schema.rb +89 -29
- data/lib/togai_client/models/event_schema_list_data.rb +90 -31
- data/lib/togai_client/models/event_schema_list_paginated_response.rb +14 -19
- data/lib/togai_client/models/event_schema_versions_response.rb +16 -19
- data/lib/togai_client/models/event_schemas_for_feature.rb +259 -0
- data/lib/togai_client/models/event_source.rb +278 -0
- data/lib/togai_client/models/event_with_status.rb +94 -23
- data/lib/togai_client/models/event_with_status_and_event_pipeline_info.rb +100 -23
- data/lib/togai_client/models/events_correction_response.rb +252 -0
- data/lib/togai_client/models/expiry_type.rb +41 -0
- data/lib/togai_client/models/external_payment_reference.rb +309 -0
- data/lib/togai_client/models/feature.rb +365 -0
- data/lib/togai_client/models/feature_config.rb +266 -0
- data/lib/togai_client/models/feature_credit_entry.rb +387 -0
- data/lib/togai_client/models/feature_details.rb +238 -0
- data/lib/togai_client/models/feature_list_response.rb +343 -0
- data/lib/togai_client/models/feature_paginated_list_data.rb +234 -0
- data/lib/togai_client/models/field.rb +331 -0
- data/lib/togai_client/models/file_download_url_response.rb +221 -0
- data/lib/togai_client/models/finalize_account_schedules.rb +228 -0
- data/lib/togai_client/models/finalize_price_plan_request.rb +246 -0
- data/lib/togai_client/models/fixed_fee_rate_card.rb +354 -0
- data/lib/togai_client/models/fixed_fee_revenue_summary.rb +221 -0
- data/lib/togai_client/models/fixed_fee_type.rb +40 -0
- data/lib/togai_client/models/get_customer_portal_delegate_token_request.rb +255 -0
- data/lib/togai_client/models/get_entitlement_values_response.rb +223 -0
- data/lib/togai_client/models/get_entitlement_values_response_data_inner.rb +239 -0
- data/lib/togai_client/models/get_event_response.rb +16 -19
- data/lib/togai_client/models/get_events_response.rb +21 -20
- data/lib/togai_client/models/get_feature_credit_entries_paginated_response.rb +225 -0
- data/lib/togai_client/models/get_feature_credits_response.rb +333 -0
- data/lib/togai_client/models/get_job_response.rb +399 -0
- data/lib/togai_client/models/get_license_updates_response.rb +252 -0
- data/lib/togai_client/models/get_metrics_request.rb +22 -19
- data/lib/togai_client/models/get_metrics_response.rb +16 -19
- data/lib/togai_client/models/get_proposal_response.rb +536 -0
- data/lib/togai_client/models/get_purchase_response.rb +519 -0
- data/lib/togai_client/models/grant_details.rb +299 -0
- data/lib/togai_client/models/incident.rb +347 -0
- data/lib/togai_client/models/incidents_paginated_response.rb +232 -0
- data/lib/togai_client/models/ingest_batch_event_request.rb +21 -24
- data/lib/togai_client/models/ingest_event_request.rb +21 -19
- data/lib/togai_client/models/ingest_event_response.rb +76 -42
- data/lib/togai_client/models/ingestion_status.rb +23 -22
- data/lib/togai_client/models/invoice.rb +571 -0
- data/lib/togai_client/models/invoice_details.rb +259 -0
- data/lib/togai_client/models/invoice_details_account.rb +269 -0
- data/lib/togai_client/models/invoice_details_customer.rb +255 -0
- data/lib/togai_client/models/invoice_details_invoice_group.rb +294 -0
- data/lib/togai_client/models/invoice_details_organization.rb +264 -0
- data/lib/togai_client/models/invoice_group_accounts_paginated_response.rb +430 -0
- data/lib/togai_client/models/invoice_group_details.rb +330 -0
- data/lib/togai_client/models/invoice_group_paginated_response.rb +225 -0
- data/lib/togai_client/models/invoice_groups.rb +403 -0
- data/lib/togai_client/models/invoice_info_inner.rb +239 -0
- data/lib/togai_client/models/invoice_line_item.rb +381 -0
- data/lib/togai_client/models/invoice_summary.rb +520 -0
- data/lib/togai_client/models/invoice_timing.rb +41 -0
- data/lib/togai_client/models/invoices_class.rb +41 -0
- data/lib/togai_client/models/invoices_status.rb +47 -0
- data/lib/togai_client/models/invoices_type.rb +44 -0
- data/lib/togai_client/models/job_entries_paginated_response.rb +234 -0
- data/lib/togai_client/models/job_entries_response.rb +314 -0
- data/lib/togai_client/models/jobs_paginated_response.rb +234 -0
- data/lib/togai_client/models/jobs_without_status_info_response.rb +269 -0
- data/lib/togai_client/models/license_entries_config.rb +287 -0
- data/lib/togai_client/models/license_entries_config_lookup_cycle.rb +251 -0
- data/lib/togai_client/models/license_entries_config_lookup_range.rb +273 -0
- data/lib/togai_client/models/license_entry.rb +272 -0
- data/lib/togai_client/models/license_entry_details_update_request.rb +277 -0
- data/lib/togai_client/models/license_rate_card.rb +388 -0
- data/lib/togai_client/models/license_rate_card_config.rb +246 -0
- data/lib/togai_client/models/license_update.rb +320 -0
- data/lib/togai_client/models/license_update_request.rb +377 -0
- data/lib/togai_client/models/license_update_response.rb +342 -0
- data/lib/togai_client/models/list_credits_response.rb +280 -0
- data/lib/togai_client/models/list_invoices_response.rb +280 -0
- data/lib/togai_client/models/list_payment_response.rb +280 -0
- data/lib/togai_client/models/manage_miscellaneous_charges_request.rb +224 -0
- data/lib/togai_client/models/max_quantity_breach_action.rb +39 -0
- data/lib/togai_client/models/metric_data_points.rb +28 -29
- data/lib/togai_client/models/metric_data_points_grouped_by.rb +18 -19
- data/lib/togai_client/models/metric_name.rb +11 -4
- data/lib/togai_client/models/metric_query.rb +45 -24
- data/lib/togai_client/models/metric_query_filter_entry.rb +19 -20
- data/lib/togai_client/models/metric_query_response.rb +42 -19
- data/lib/togai_client/models/migration_mode.rb +44 -0
- data/lib/togai_client/models/minimum_commitment.rb +258 -0
- data/lib/togai_client/models/miscellaneous_charge.rb +265 -0
- data/lib/togai_client/models/miscellaneous_charges_response.rb +224 -0
- data/lib/togai_client/models/model_alias.rb +238 -0
- data/lib/togai_client/models/named_license_entries_config.rb +287 -0
- data/lib/togai_client/models/named_license_entries_config_lookup_cycle.rb +251 -0
- data/lib/togai_client/models/named_license_entries_config_lookup_range.rb +273 -0
- data/lib/togai_client/models/named_license_entry.rb +281 -0
- data/lib/togai_client/models/named_license_update.rb +396 -0
- data/lib/togai_client/models/named_license_updates_paginated_response.rb +252 -0
- data/lib/togai_client/models/pagination_options.rb +14 -19
- data/lib/togai_client/models/payment.rb +380 -0
- data/lib/togai_client/models/payment_line_item_record.rb +290 -0
- data/lib/togai_client/models/plan_override.rb +64 -20
- data/lib/togai_client/models/pre_action.rb +269 -0
- data/lib/togai_client/models/price_plan.rb +59 -21
- data/lib/togai_client/models/price_plan_details.rb +182 -45
- data/lib/togai_client/models/price_plan_details_config.rb +344 -0
- data/lib/togai_client/models/price_plan_details_override.rb +135 -35
- data/lib/togai_client/models/price_plan_info.rb +230 -0
- data/lib/togai_client/models/price_plan_list_data.rb +116 -25
- data/lib/togai_client/models/price_plan_migration_config.rb +368 -0
- data/lib/togai_client/models/price_plan_paginated_response.rb +16 -19
- data/lib/togai_client/models/price_plan_type.rb +40 -0
- data/lib/togai_client/models/price_plan_v2.rb +519 -0
- data/lib/togai_client/models/price_plan_v2_paginated_response.rb +233 -0
- data/lib/togai_client/models/price_type.rb +7 -4
- data/lib/togai_client/models/pricing_cycle_config.rb +34 -67
- data/lib/togai_client/models/pricing_cycle_config_start_offset.rb +20 -21
- data/lib/togai_client/models/pricing_cycle_interval.rb +43 -0
- data/lib/togai_client/models/pricing_model.rb +7 -4
- data/lib/togai_client/models/pricing_rule.rb +382 -0
- data/lib/togai_client/models/pricing_rule_action.rb +293 -0
- data/lib/togai_client/models/pricing_rule_changes_log.rb +290 -0
- data/lib/togai_client/models/pricing_rule_info.rb +249 -0
- data/lib/togai_client/models/pricing_rule_timing.rb +40 -0
- data/lib/togai_client/models/pricing_rules_log.rb +318 -0
- data/lib/togai_client/models/pricing_rules_logs_paginated_response.rb +224 -0
- data/lib/togai_client/models/pricing_rules_paginated_response.rb +223 -0
- data/lib/togai_client/models/pricing_rules_values.rb +223 -0
- data/lib/togai_client/models/pricing_schedule.rb +100 -23
- data/lib/togai_client/models/pricing_schedule_paginated_response.rb +234 -0
- data/lib/togai_client/models/pricing_schedule_with_price_plan_id.rb +365 -0
- data/lib/togai_client/models/proposal.rb +536 -0
- data/lib/togai_client/models/proposals_list_response.rb +390 -0
- data/lib/togai_client/models/proposals_paginated_response.rb +234 -0
- data/lib/togai_client/models/prorated_refund_mode.rb +42 -0
- data/lib/togai_client/models/proration_config.rb +275 -0
- data/lib/togai_client/models/proration_config_custom_config.rb +254 -0
- data/lib/togai_client/models/proration_config_lookup_cycle_config.rb +261 -0
- data/lib/togai_client/models/purchase.rb +493 -0
- data/lib/togai_client/models/purchase_feature_details.rb +317 -0
- data/lib/togai_client/models/purchase_list_response.rb +393 -0
- data/lib/togai_client/models/purchase_paginated_list_data.rb +234 -0
- data/lib/togai_client/models/purchase_plan_override.rb +296 -0
- data/lib/togai_client/models/purchase_status.rb +46 -0
- data/lib/togai_client/models/purchase_type.rb +42 -0
- data/lib/togai_client/models/query_column.rb +259 -0
- data/lib/togai_client/models/query_filter.rb +255 -0
- data/lib/togai_client/models/query_function.rb +239 -0
- data/lib/togai_client/models/query_input.rb +295 -0
- data/lib/togai_client/models/query_input_sort_inner.rb +237 -0
- data/lib/togai_client/models/rate_card.rb +342 -38
- data/lib/togai_client/models/rate_card_data.rb +370 -0
- data/lib/togai_client/models/rate_card_details.rb +269 -0
- data/lib/togai_client/models/rate_card_operation.rb +302 -0
- data/lib/togai_client/models/rate_card_paginated_response.rb +233 -0
- data/lib/togai_client/models/rate_card_type.rb +13 -5
- data/lib/togai_client/models/rate_plan.rb +282 -0
- data/lib/togai_client/models/rate_value.rb +270 -0
- data/lib/togai_client/models/recurrence_config.rb +225 -0
- data/lib/togai_client/models/remove_account_alias_request.rb +232 -0
- data/lib/togai_client/models/remove_account_aliases_request.rb +30 -49
- data/lib/togai_client/models/report.rb +362 -0
- data/lib/togai_client/models/report_status.rb +43 -0
- data/lib/togai_client/models/report_type.rb +41 -0
- data/lib/togai_client/models/reports_paginated_response.rb +226 -0
- data/lib/togai_client/models/revenue_info.rb +335 -0
- data/lib/togai_client/models/revenue_info_v2.rb +297 -0
- data/lib/togai_client/models/revenue_summary_with_metadata.rb +255 -0
- data/lib/togai_client/models/schedule_info.rb +250 -0
- data/lib/togai_client/models/schedules_paginated_response.rb +241 -0
- data/lib/togai_client/models/setting.rb +340 -0
- data/lib/togai_client/models/setting_data_type.rb +42 -0
- data/lib/togai_client/models/setting_paginated_response.rb +234 -0
- data/lib/togai_client/models/slab.rb +315 -0
- data/lib/togai_client/models/slab_detail.rb +298 -0
- data/lib/togai_client/models/slab_rate.rb +249 -0
- data/lib/togai_client/models/slab_revenue.rb +281 -0
- data/lib/togai_client/models/slab_revenue_metadata.rb +232 -0
- data/lib/togai_client/models/slab_revenue_summary.rb +262 -0
- data/lib/togai_client/models/slab_revenue_with_metadata.rb +299 -0
- data/lib/togai_client/models/token_response.rb +221 -0
- data/lib/togai_client/models/topup_wallet_request.rb +222 -0
- data/lib/togai_client/models/update_account_request.rb +196 -26
- data/lib/togai_client/models/update_account_schedule_v2_request.rb +303 -0
- data/lib/togai_client/models/update_add_on_request.rb +264 -0
- data/lib/togai_client/models/update_alert_request.rb +274 -0
- data/lib/togai_client/models/update_customer_request.rb +36 -49
- data/lib/togai_client/models/update_event_schema_request.rb +68 -38
- data/lib/togai_client/models/update_feature_credits_request.rb +225 -0
- data/lib/togai_client/models/update_feature_request.rb +295 -0
- data/lib/togai_client/models/update_incident_status_request.rb +256 -0
- data/lib/togai_client/models/update_invoice_group_accounts.rb +252 -0
- data/lib/togai_client/models/update_invoice_request.rb +317 -0
- data/lib/togai_client/models/update_price_plan_request.rb +81 -25
- data/lib/togai_client/models/update_price_plan_v2_request.rb +266 -0
- data/lib/togai_client/models/update_pricing_rules_request.rb +216 -0
- data/lib/togai_client/models/update_pricing_schedule_request.rb +323 -0
- data/lib/togai_client/models/update_pricing_schedule_request_with_actions.rb +343 -0
- data/lib/togai_client/models/update_pricing_schedule_response.rb +276 -0
- data/lib/togai_client/models/update_proposal_status.rb +256 -0
- data/lib/togai_client/models/update_setting_request.rb +255 -0
- data/lib/togai_client/models/update_usage_meter_request.rb +105 -50
- data/lib/togai_client/models/update_wallet_request.rb +246 -0
- data/lib/togai_client/models/usage_config.rb +287 -0
- data/lib/togai_client/models/usage_config_lookup_cycle.rb +250 -0
- data/lib/togai_client/models/usage_config_lookup_range.rb +273 -0
- data/lib/togai_client/models/usage_cycle_interval.rb +43 -0
- data/lib/togai_client/models/usage_lookup_range.rb +238 -0
- data/lib/togai_client/models/usage_meter.rb +156 -39
- data/lib/togai_client/models/usage_meter_aggregation.rb +40 -0
- data/lib/togai_client/models/usage_meter_filter_entry.rb +238 -0
- data/lib/togai_client/models/usage_meter_paginated_response.rb +14 -19
- data/lib/togai_client/models/usage_rate_card.rb +285 -0
- data/lib/togai_client/models/validate_entitlement_value_request.rb +222 -0
- data/lib/togai_client/models/validated_entity_error.rb +273 -0
- data/lib/togai_client/models/validated_entity_errors_paginated_response.rb +232 -0
- data/lib/togai_client/models/versions_to_migrate.rb +40 -0
- data/lib/togai_client/models/wallet_balance_response.rb +388 -0
- data/lib/togai_client/models/wallet_entries_paginated_response.rb +280 -0
- data/lib/togai_client/models/wallet_entry.rb +421 -0
- data/lib/togai_client/models/wallet_status.rb +40 -0
- data/lib/togai_client/models/wallet_topup_details.rb +233 -0
- data/lib/togai_client/version.rb +2 -2
- data/lib/togai_client.rb +279 -21
- data/spec/spec_helper.rb +1 -1
- data/togai_client.gemspec +4 -3
- metadata +561 -5
@@ -0,0 +1,960 @@
|
|
1
|
+
=begin
|
2
|
+
#Togai Apis
|
3
|
+
|
4
|
+
#APIs for Togai App
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0
|
7
|
+
Contact: engg@togai.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.10.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module TogaiClient
|
16
|
+
class PricePlanV2Api
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Bulk rate card operations of a price plan
|
23
|
+
# Bulk rate card operations of a price plan
|
24
|
+
# @param price_plan_id [String]
|
25
|
+
# @param bulk_rate_card_operations_request [BulkRateCardOperationsRequest] Payload to bulk rate card operations
|
26
|
+
# @param [Hash] opts the optional parameters
|
27
|
+
# @return [BulkRateCardOperationsResponse]
|
28
|
+
def bulk_price_plan_rate_card_operations(price_plan_id, bulk_rate_card_operations_request, opts = {})
|
29
|
+
data, _status_code, _headers = bulk_price_plan_rate_card_operations_with_http_info(price_plan_id, bulk_rate_card_operations_request, opts)
|
30
|
+
data
|
31
|
+
end
|
32
|
+
|
33
|
+
# Bulk rate card operations of a price plan
|
34
|
+
# Bulk rate card operations of a price plan
|
35
|
+
# @param price_plan_id [String]
|
36
|
+
# @param bulk_rate_card_operations_request [BulkRateCardOperationsRequest] Payload to bulk rate card operations
|
37
|
+
# @param [Hash] opts the optional parameters
|
38
|
+
# @return [Array<(BulkRateCardOperationsResponse, Integer, Hash)>] BulkRateCardOperationsResponse data, response status code and response headers
|
39
|
+
def bulk_price_plan_rate_card_operations_with_http_info(price_plan_id, bulk_rate_card_operations_request, opts = {})
|
40
|
+
if @api_client.config.debugging
|
41
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.bulk_price_plan_rate_card_operations ...'
|
42
|
+
end
|
43
|
+
# verify the required parameter 'price_plan_id' is set
|
44
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
45
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.bulk_price_plan_rate_card_operations"
|
46
|
+
end
|
47
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
48
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.bulk_price_plan_rate_card_operations, the character length must be smaller than or equal to 50.'
|
49
|
+
end
|
50
|
+
|
51
|
+
# verify the required parameter 'bulk_rate_card_operations_request' is set
|
52
|
+
if @api_client.config.client_side_validation && bulk_rate_card_operations_request.nil?
|
53
|
+
fail ArgumentError, "Missing the required parameter 'bulk_rate_card_operations_request' when calling PricePlanV2Api.bulk_price_plan_rate_card_operations"
|
54
|
+
end
|
55
|
+
# resource path
|
56
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/rate_cards'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
57
|
+
|
58
|
+
# query parameters
|
59
|
+
query_params = opts[:query_params] || {}
|
60
|
+
|
61
|
+
# header parameters
|
62
|
+
header_params = opts[:header_params] || {}
|
63
|
+
# HTTP header 'Accept' (if needed)
|
64
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
65
|
+
# HTTP header 'Content-Type'
|
66
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
67
|
+
if !content_type.nil?
|
68
|
+
header_params['Content-Type'] = content_type
|
69
|
+
end
|
70
|
+
|
71
|
+
# form parameters
|
72
|
+
form_params = opts[:form_params] || {}
|
73
|
+
|
74
|
+
# http body (model)
|
75
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(bulk_rate_card_operations_request)
|
76
|
+
|
77
|
+
# return_type
|
78
|
+
return_type = opts[:debug_return_type] || 'BulkRateCardOperationsResponse'
|
79
|
+
|
80
|
+
# auth_names
|
81
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
82
|
+
|
83
|
+
new_options = opts.merge(
|
84
|
+
:operation => :"PricePlanV2Api.bulk_price_plan_rate_card_operations",
|
85
|
+
:header_params => header_params,
|
86
|
+
:query_params => query_params,
|
87
|
+
:form_params => form_params,
|
88
|
+
:body => post_body,
|
89
|
+
:auth_names => auth_names,
|
90
|
+
:return_type => return_type
|
91
|
+
)
|
92
|
+
|
93
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
94
|
+
if @api_client.config.debugging
|
95
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#bulk_price_plan_rate_card_operations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
96
|
+
end
|
97
|
+
return data, status_code, headers
|
98
|
+
end
|
99
|
+
|
100
|
+
# Create a price plan
|
101
|
+
# Create a price plan
|
102
|
+
# @param create_price_plan_v2_request [CreatePricePlanV2Request] Payload to create price plan
|
103
|
+
# @param [Hash] opts the optional parameters
|
104
|
+
# @option opts [String] :source_price_plan_id The source price plan id to be used as a reference for creating a new price plan. This is optional and can be used to copy the pricing rules and rate cards from the source price plan.
|
105
|
+
# @return [PricePlanV2]
|
106
|
+
def create_price_plan_v2(create_price_plan_v2_request, opts = {})
|
107
|
+
data, _status_code, _headers = create_price_plan_v2_with_http_info(create_price_plan_v2_request, opts)
|
108
|
+
data
|
109
|
+
end
|
110
|
+
|
111
|
+
# Create a price plan
|
112
|
+
# Create a price plan
|
113
|
+
# @param create_price_plan_v2_request [CreatePricePlanV2Request] Payload to create price plan
|
114
|
+
# @param [Hash] opts the optional parameters
|
115
|
+
# @option opts [String] :source_price_plan_id The source price plan id to be used as a reference for creating a new price plan. This is optional and can be used to copy the pricing rules and rate cards from the source price plan.
|
116
|
+
# @return [Array<(PricePlanV2, Integer, Hash)>] PricePlanV2 data, response status code and response headers
|
117
|
+
def create_price_plan_v2_with_http_info(create_price_plan_v2_request, opts = {})
|
118
|
+
if @api_client.config.debugging
|
119
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.create_price_plan_v2 ...'
|
120
|
+
end
|
121
|
+
# verify the required parameter 'create_price_plan_v2_request' is set
|
122
|
+
if @api_client.config.client_side_validation && create_price_plan_v2_request.nil?
|
123
|
+
fail ArgumentError, "Missing the required parameter 'create_price_plan_v2_request' when calling PricePlanV2Api.create_price_plan_v2"
|
124
|
+
end
|
125
|
+
if @api_client.config.client_side_validation && !opts[:'source_price_plan_id'].nil? && opts[:'source_price_plan_id'].to_s.length > 50
|
126
|
+
fail ArgumentError, 'invalid value for "opts[:"source_price_plan_id"]" when calling PricePlanV2Api.create_price_plan_v2, the character length must be smaller than or equal to 50.'
|
127
|
+
end
|
128
|
+
|
129
|
+
# resource path
|
130
|
+
local_var_path = '/v2/price_plans'
|
131
|
+
|
132
|
+
# query parameters
|
133
|
+
query_params = opts[:query_params] || {}
|
134
|
+
query_params[:'source_price_plan_id'] = opts[:'source_price_plan_id'] if !opts[:'source_price_plan_id'].nil?
|
135
|
+
|
136
|
+
# header parameters
|
137
|
+
header_params = opts[:header_params] || {}
|
138
|
+
# HTTP header 'Accept' (if needed)
|
139
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
140
|
+
# HTTP header 'Content-Type'
|
141
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
142
|
+
if !content_type.nil?
|
143
|
+
header_params['Content-Type'] = content_type
|
144
|
+
end
|
145
|
+
|
146
|
+
# form parameters
|
147
|
+
form_params = opts[:form_params] || {}
|
148
|
+
|
149
|
+
# http body (model)
|
150
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(create_price_plan_v2_request)
|
151
|
+
|
152
|
+
# return_type
|
153
|
+
return_type = opts[:debug_return_type] || 'PricePlanV2'
|
154
|
+
|
155
|
+
# auth_names
|
156
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
157
|
+
|
158
|
+
new_options = opts.merge(
|
159
|
+
:operation => :"PricePlanV2Api.create_price_plan_v2",
|
160
|
+
:header_params => header_params,
|
161
|
+
:query_params => query_params,
|
162
|
+
:form_params => form_params,
|
163
|
+
:body => post_body,
|
164
|
+
:auth_names => auth_names,
|
165
|
+
:return_type => return_type
|
166
|
+
)
|
167
|
+
|
168
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
169
|
+
if @api_client.config.debugging
|
170
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#create_price_plan_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
171
|
+
end
|
172
|
+
return data, status_code, headers
|
173
|
+
end
|
174
|
+
|
175
|
+
# Discard a price plan
|
176
|
+
# Discard a price plan
|
177
|
+
# @param price_plan_id [String]
|
178
|
+
# @param [Hash] opts the optional parameters
|
179
|
+
# @return [BaseSuccessResponse]
|
180
|
+
def discard_price_plan(price_plan_id, opts = {})
|
181
|
+
data, _status_code, _headers = discard_price_plan_with_http_info(price_plan_id, opts)
|
182
|
+
data
|
183
|
+
end
|
184
|
+
|
185
|
+
# Discard a price plan
|
186
|
+
# Discard a price plan
|
187
|
+
# @param price_plan_id [String]
|
188
|
+
# @param [Hash] opts the optional parameters
|
189
|
+
# @return [Array<(BaseSuccessResponse, Integer, Hash)>] BaseSuccessResponse data, response status code and response headers
|
190
|
+
def discard_price_plan_with_http_info(price_plan_id, opts = {})
|
191
|
+
if @api_client.config.debugging
|
192
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.discard_price_plan ...'
|
193
|
+
end
|
194
|
+
# verify the required parameter 'price_plan_id' is set
|
195
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
196
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.discard_price_plan"
|
197
|
+
end
|
198
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
199
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.discard_price_plan, the character length must be smaller than or equal to 50.'
|
200
|
+
end
|
201
|
+
|
202
|
+
# resource path
|
203
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/discard'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
204
|
+
|
205
|
+
# query parameters
|
206
|
+
query_params = opts[:query_params] || {}
|
207
|
+
|
208
|
+
# header parameters
|
209
|
+
header_params = opts[:header_params] || {}
|
210
|
+
# HTTP header 'Accept' (if needed)
|
211
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
212
|
+
|
213
|
+
# form parameters
|
214
|
+
form_params = opts[:form_params] || {}
|
215
|
+
|
216
|
+
# http body (model)
|
217
|
+
post_body = opts[:debug_body]
|
218
|
+
|
219
|
+
# return_type
|
220
|
+
return_type = opts[:debug_return_type] || 'BaseSuccessResponse'
|
221
|
+
|
222
|
+
# auth_names
|
223
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
224
|
+
|
225
|
+
new_options = opts.merge(
|
226
|
+
:operation => :"PricePlanV2Api.discard_price_plan",
|
227
|
+
:header_params => header_params,
|
228
|
+
:query_params => query_params,
|
229
|
+
:form_params => form_params,
|
230
|
+
:body => post_body,
|
231
|
+
:auth_names => auth_names,
|
232
|
+
:return_type => return_type
|
233
|
+
)
|
234
|
+
|
235
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
236
|
+
if @api_client.config.debugging
|
237
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#discard_price_plan\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
238
|
+
end
|
239
|
+
return data, status_code, headers
|
240
|
+
end
|
241
|
+
|
242
|
+
# Finalize a price plan
|
243
|
+
# Finalize a price plan
|
244
|
+
# @param price_plan_id [String]
|
245
|
+
# @param finalize_price_plan_request [FinalizePricePlanRequest] Payload to finalize price plan
|
246
|
+
# @param [Hash] opts the optional parameters
|
247
|
+
# @return [BaseSuccessResponse]
|
248
|
+
def finalize_price_plan(price_plan_id, finalize_price_plan_request, opts = {})
|
249
|
+
data, _status_code, _headers = finalize_price_plan_with_http_info(price_plan_id, finalize_price_plan_request, opts)
|
250
|
+
data
|
251
|
+
end
|
252
|
+
|
253
|
+
# Finalize a price plan
|
254
|
+
# Finalize a price plan
|
255
|
+
# @param price_plan_id [String]
|
256
|
+
# @param finalize_price_plan_request [FinalizePricePlanRequest] Payload to finalize price plan
|
257
|
+
# @param [Hash] opts the optional parameters
|
258
|
+
# @return [Array<(BaseSuccessResponse, Integer, Hash)>] BaseSuccessResponse data, response status code and response headers
|
259
|
+
def finalize_price_plan_with_http_info(price_plan_id, finalize_price_plan_request, opts = {})
|
260
|
+
if @api_client.config.debugging
|
261
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.finalize_price_plan ...'
|
262
|
+
end
|
263
|
+
# verify the required parameter 'price_plan_id' is set
|
264
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
265
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.finalize_price_plan"
|
266
|
+
end
|
267
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
268
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.finalize_price_plan, the character length must be smaller than or equal to 50.'
|
269
|
+
end
|
270
|
+
|
271
|
+
# verify the required parameter 'finalize_price_plan_request' is set
|
272
|
+
if @api_client.config.client_side_validation && finalize_price_plan_request.nil?
|
273
|
+
fail ArgumentError, "Missing the required parameter 'finalize_price_plan_request' when calling PricePlanV2Api.finalize_price_plan"
|
274
|
+
end
|
275
|
+
# resource path
|
276
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/finalize'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
277
|
+
|
278
|
+
# query parameters
|
279
|
+
query_params = opts[:query_params] || {}
|
280
|
+
|
281
|
+
# header parameters
|
282
|
+
header_params = opts[:header_params] || {}
|
283
|
+
# HTTP header 'Accept' (if needed)
|
284
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
285
|
+
# HTTP header 'Content-Type'
|
286
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
287
|
+
if !content_type.nil?
|
288
|
+
header_params['Content-Type'] = content_type
|
289
|
+
end
|
290
|
+
|
291
|
+
# form parameters
|
292
|
+
form_params = opts[:form_params] || {}
|
293
|
+
|
294
|
+
# http body (model)
|
295
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(finalize_price_plan_request)
|
296
|
+
|
297
|
+
# return_type
|
298
|
+
return_type = opts[:debug_return_type] || 'BaseSuccessResponse'
|
299
|
+
|
300
|
+
# auth_names
|
301
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
302
|
+
|
303
|
+
new_options = opts.merge(
|
304
|
+
:operation => :"PricePlanV2Api.finalize_price_plan",
|
305
|
+
:header_params => header_params,
|
306
|
+
:query_params => query_params,
|
307
|
+
:form_params => form_params,
|
308
|
+
:body => post_body,
|
309
|
+
:auth_names => auth_names,
|
310
|
+
:return_type => return_type
|
311
|
+
)
|
312
|
+
|
313
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
314
|
+
if @api_client.config.debugging
|
315
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#finalize_price_plan\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
316
|
+
end
|
317
|
+
return data, status_code, headers
|
318
|
+
end
|
319
|
+
|
320
|
+
# Get a price plan
|
321
|
+
# Get a price plan
|
322
|
+
# @param price_plan_id [String]
|
323
|
+
# @param [Hash] opts the optional parameters
|
324
|
+
# @option opts [String] :version Optional version to get a specific version. Gets latest version if it is not provided. Possible values: 1. LATEST - Get the latest version of the price plan, can be draft 2. ACTIVE - Get the latest active version of the price plan 3. NUMBER - Get the specific version of the price plans
|
325
|
+
# @return [PricePlanV2]
|
326
|
+
def get_price_plan_v2(price_plan_id, opts = {})
|
327
|
+
data, _status_code, _headers = get_price_plan_v2_with_http_info(price_plan_id, opts)
|
328
|
+
data
|
329
|
+
end
|
330
|
+
|
331
|
+
# Get a price plan
|
332
|
+
# Get a price plan
|
333
|
+
# @param price_plan_id [String]
|
334
|
+
# @param [Hash] opts the optional parameters
|
335
|
+
# @option opts [String] :version Optional version to get a specific version. Gets latest version if it is not provided. Possible values: 1. LATEST - Get the latest version of the price plan, can be draft 2. ACTIVE - Get the latest active version of the price plan 3. NUMBER - Get the specific version of the price plans
|
336
|
+
# @return [Array<(PricePlanV2, Integer, Hash)>] PricePlanV2 data, response status code and response headers
|
337
|
+
def get_price_plan_v2_with_http_info(price_plan_id, opts = {})
|
338
|
+
if @api_client.config.debugging
|
339
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.get_price_plan_v2 ...'
|
340
|
+
end
|
341
|
+
# verify the required parameter 'price_plan_id' is set
|
342
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
343
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.get_price_plan_v2"
|
344
|
+
end
|
345
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
346
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.get_price_plan_v2, the character length must be smaller than or equal to 50.'
|
347
|
+
end
|
348
|
+
|
349
|
+
# resource path
|
350
|
+
local_var_path = '/v2/price_plans/{price_plan_id}'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
351
|
+
|
352
|
+
# query parameters
|
353
|
+
query_params = opts[:query_params] || {}
|
354
|
+
query_params[:'version'] = opts[:'version'] if !opts[:'version'].nil?
|
355
|
+
|
356
|
+
# header parameters
|
357
|
+
header_params = opts[:header_params] || {}
|
358
|
+
# HTTP header 'Accept' (if needed)
|
359
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
360
|
+
|
361
|
+
# form parameters
|
362
|
+
form_params = opts[:form_params] || {}
|
363
|
+
|
364
|
+
# http body (model)
|
365
|
+
post_body = opts[:debug_body]
|
366
|
+
|
367
|
+
# return_type
|
368
|
+
return_type = opts[:debug_return_type] || 'PricePlanV2'
|
369
|
+
|
370
|
+
# auth_names
|
371
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
372
|
+
|
373
|
+
new_options = opts.merge(
|
374
|
+
:operation => :"PricePlanV2Api.get_price_plan_v2",
|
375
|
+
:header_params => header_params,
|
376
|
+
:query_params => query_params,
|
377
|
+
:form_params => form_params,
|
378
|
+
:body => post_body,
|
379
|
+
:auth_names => auth_names,
|
380
|
+
:return_type => return_type
|
381
|
+
)
|
382
|
+
|
383
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
384
|
+
if @api_client.config.debugging
|
385
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#get_price_plan_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
386
|
+
end
|
387
|
+
return data, status_code, headers
|
388
|
+
end
|
389
|
+
|
390
|
+
# Get list of errors of a price plan
|
391
|
+
# Get list of errors of a price plan
|
392
|
+
# @param price_plan_id [String]
|
393
|
+
# @param [Hash] opts the optional parameters
|
394
|
+
# @return [ValidatedEntityErrorsPaginatedResponse]
|
395
|
+
def list_price_plan_errors(price_plan_id, opts = {})
|
396
|
+
data, _status_code, _headers = list_price_plan_errors_with_http_info(price_plan_id, opts)
|
397
|
+
data
|
398
|
+
end
|
399
|
+
|
400
|
+
# Get list of errors of a price plan
|
401
|
+
# Get list of errors of a price plan
|
402
|
+
# @param price_plan_id [String]
|
403
|
+
# @param [Hash] opts the optional parameters
|
404
|
+
# @return [Array<(ValidatedEntityErrorsPaginatedResponse, Integer, Hash)>] ValidatedEntityErrorsPaginatedResponse data, response status code and response headers
|
405
|
+
def list_price_plan_errors_with_http_info(price_plan_id, opts = {})
|
406
|
+
if @api_client.config.debugging
|
407
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_errors ...'
|
408
|
+
end
|
409
|
+
# verify the required parameter 'price_plan_id' is set
|
410
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
411
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_errors"
|
412
|
+
end
|
413
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
414
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_errors, the character length must be smaller than or equal to 50.'
|
415
|
+
end
|
416
|
+
|
417
|
+
# resource path
|
418
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/errors'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
419
|
+
|
420
|
+
# query parameters
|
421
|
+
query_params = opts[:query_params] || {}
|
422
|
+
|
423
|
+
# header parameters
|
424
|
+
header_params = opts[:header_params] || {}
|
425
|
+
# HTTP header 'Accept' (if needed)
|
426
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
427
|
+
|
428
|
+
# form parameters
|
429
|
+
form_params = opts[:form_params] || {}
|
430
|
+
|
431
|
+
# http body (model)
|
432
|
+
post_body = opts[:debug_body]
|
433
|
+
|
434
|
+
# return_type
|
435
|
+
return_type = opts[:debug_return_type] || 'ValidatedEntityErrorsPaginatedResponse'
|
436
|
+
|
437
|
+
# auth_names
|
438
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
439
|
+
|
440
|
+
new_options = opts.merge(
|
441
|
+
:operation => :"PricePlanV2Api.list_price_plan_errors",
|
442
|
+
:header_params => header_params,
|
443
|
+
:query_params => query_params,
|
444
|
+
:form_params => form_params,
|
445
|
+
:body => post_body,
|
446
|
+
:auth_names => auth_names,
|
447
|
+
:return_type => return_type
|
448
|
+
)
|
449
|
+
|
450
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
451
|
+
if @api_client.config.debugging
|
452
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_errors\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
453
|
+
end
|
454
|
+
return data, status_code, headers
|
455
|
+
end
|
456
|
+
|
457
|
+
# List pricing rules of a price plan
|
458
|
+
# List pricing rules of a price plan
|
459
|
+
# @param price_plan_id [String]
|
460
|
+
# @param [Hash] opts the optional parameters
|
461
|
+
# @option opts [String] :version Optional version to get a specific version. Gets latest version if it is not provided. Possible values: 1. LATEST - Get the latest version of the price plan, can be draft 2. ACTIVE - Get the latest active version of the price plan 3. NUMBER - Get the specific version of the price plans
|
462
|
+
# @return [PricingRulesPaginatedResponse]
|
463
|
+
def list_price_plan_pricing_rules(price_plan_id, opts = {})
|
464
|
+
data, _status_code, _headers = list_price_plan_pricing_rules_with_http_info(price_plan_id, opts)
|
465
|
+
data
|
466
|
+
end
|
467
|
+
|
468
|
+
# List pricing rules of a price plan
|
469
|
+
# List pricing rules of a price plan
|
470
|
+
# @param price_plan_id [String]
|
471
|
+
# @param [Hash] opts the optional parameters
|
472
|
+
# @option opts [String] :version Optional version to get a specific version. Gets latest version if it is not provided. Possible values: 1. LATEST - Get the latest version of the price plan, can be draft 2. ACTIVE - Get the latest active version of the price plan 3. NUMBER - Get the specific version of the price plans
|
473
|
+
# @return [Array<(PricingRulesPaginatedResponse, Integer, Hash)>] PricingRulesPaginatedResponse data, response status code and response headers
|
474
|
+
def list_price_plan_pricing_rules_with_http_info(price_plan_id, opts = {})
|
475
|
+
if @api_client.config.debugging
|
476
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_pricing_rules ...'
|
477
|
+
end
|
478
|
+
# verify the required parameter 'price_plan_id' is set
|
479
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
480
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_pricing_rules"
|
481
|
+
end
|
482
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
483
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_pricing_rules, the character length must be smaller than or equal to 50.'
|
484
|
+
end
|
485
|
+
|
486
|
+
# resource path
|
487
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/pricing_rules'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
488
|
+
|
489
|
+
# query parameters
|
490
|
+
query_params = opts[:query_params] || {}
|
491
|
+
query_params[:'version'] = opts[:'version'] if !opts[:'version'].nil?
|
492
|
+
|
493
|
+
# header parameters
|
494
|
+
header_params = opts[:header_params] || {}
|
495
|
+
# HTTP header 'Accept' (if needed)
|
496
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
497
|
+
|
498
|
+
# form parameters
|
499
|
+
form_params = opts[:form_params] || {}
|
500
|
+
|
501
|
+
# http body (model)
|
502
|
+
post_body = opts[:debug_body]
|
503
|
+
|
504
|
+
# return_type
|
505
|
+
return_type = opts[:debug_return_type] || 'PricingRulesPaginatedResponse'
|
506
|
+
|
507
|
+
# auth_names
|
508
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
509
|
+
|
510
|
+
new_options = opts.merge(
|
511
|
+
:operation => :"PricePlanV2Api.list_price_plan_pricing_rules",
|
512
|
+
:header_params => header_params,
|
513
|
+
:query_params => query_params,
|
514
|
+
:form_params => form_params,
|
515
|
+
:body => post_body,
|
516
|
+
:auth_names => auth_names,
|
517
|
+
:return_type => return_type
|
518
|
+
)
|
519
|
+
|
520
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
521
|
+
if @api_client.config.debugging
|
522
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_pricing_rules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
523
|
+
end
|
524
|
+
return data, status_code, headers
|
525
|
+
end
|
526
|
+
|
527
|
+
# List rate cards of a price plan
|
528
|
+
# List rate cards of a price plan
|
529
|
+
# @param price_plan_id [String]
|
530
|
+
# @param [Hash] opts the optional parameters
|
531
|
+
# @option opts [String] :next_token
|
532
|
+
# @option opts [Float] :page_size
|
533
|
+
# @return [RateCardPaginatedResponse]
|
534
|
+
def list_price_plan_rate_cards(price_plan_id, opts = {})
|
535
|
+
data, _status_code, _headers = list_price_plan_rate_cards_with_http_info(price_plan_id, opts)
|
536
|
+
data
|
537
|
+
end
|
538
|
+
|
539
|
+
# List rate cards of a price plan
|
540
|
+
# List rate cards of a price plan
|
541
|
+
# @param price_plan_id [String]
|
542
|
+
# @param [Hash] opts the optional parameters
|
543
|
+
# @option opts [String] :next_token
|
544
|
+
# @option opts [Float] :page_size
|
545
|
+
# @return [Array<(RateCardPaginatedResponse, Integer, Hash)>] RateCardPaginatedResponse data, response status code and response headers
|
546
|
+
def list_price_plan_rate_cards_with_http_info(price_plan_id, opts = {})
|
547
|
+
if @api_client.config.debugging
|
548
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_rate_cards ...'
|
549
|
+
end
|
550
|
+
# verify the required parameter 'price_plan_id' is set
|
551
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
552
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_rate_cards"
|
553
|
+
end
|
554
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
555
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_rate_cards, the character length must be smaller than or equal to 50.'
|
556
|
+
end
|
557
|
+
|
558
|
+
# resource path
|
559
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/rate_cards'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
560
|
+
|
561
|
+
# query parameters
|
562
|
+
query_params = opts[:query_params] || {}
|
563
|
+
query_params[:'nextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil?
|
564
|
+
query_params[:'pageSize'] = opts[:'page_size'] if !opts[:'page_size'].nil?
|
565
|
+
|
566
|
+
# header parameters
|
567
|
+
header_params = opts[:header_params] || {}
|
568
|
+
# HTTP header 'Accept' (if needed)
|
569
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
570
|
+
|
571
|
+
# form parameters
|
572
|
+
form_params = opts[:form_params] || {}
|
573
|
+
|
574
|
+
# http body (model)
|
575
|
+
post_body = opts[:debug_body]
|
576
|
+
|
577
|
+
# return_type
|
578
|
+
return_type = opts[:debug_return_type] || 'RateCardPaginatedResponse'
|
579
|
+
|
580
|
+
# auth_names
|
581
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
582
|
+
|
583
|
+
new_options = opts.merge(
|
584
|
+
:operation => :"PricePlanV2Api.list_price_plan_rate_cards",
|
585
|
+
:header_params => header_params,
|
586
|
+
:query_params => query_params,
|
587
|
+
:form_params => form_params,
|
588
|
+
:body => post_body,
|
589
|
+
:auth_names => auth_names,
|
590
|
+
:return_type => return_type
|
591
|
+
)
|
592
|
+
|
593
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
594
|
+
if @api_client.config.debugging
|
595
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_rate_cards\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
596
|
+
end
|
597
|
+
return data, status_code, headers
|
598
|
+
end
|
599
|
+
|
600
|
+
# List price plan versions
|
601
|
+
# List price plan versions
|
602
|
+
# @param price_plan_id [String]
|
603
|
+
# @param [Hash] opts the optional parameters
|
604
|
+
# @option opts [String] :next_token
|
605
|
+
# @option opts [Float] :page_size
|
606
|
+
# @return [PricePlanV2PaginatedResponse]
|
607
|
+
def list_price_plan_versions(price_plan_id, opts = {})
|
608
|
+
data, _status_code, _headers = list_price_plan_versions_with_http_info(price_plan_id, opts)
|
609
|
+
data
|
610
|
+
end
|
611
|
+
|
612
|
+
# List price plan versions
|
613
|
+
# List price plan versions
|
614
|
+
# @param price_plan_id [String]
|
615
|
+
# @param [Hash] opts the optional parameters
|
616
|
+
# @option opts [String] :next_token
|
617
|
+
# @option opts [Float] :page_size
|
618
|
+
# @return [Array<(PricePlanV2PaginatedResponse, Integer, Hash)>] PricePlanV2PaginatedResponse data, response status code and response headers
|
619
|
+
def list_price_plan_versions_with_http_info(price_plan_id, opts = {})
|
620
|
+
if @api_client.config.debugging
|
621
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_versions ...'
|
622
|
+
end
|
623
|
+
# verify the required parameter 'price_plan_id' is set
|
624
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
625
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_versions"
|
626
|
+
end
|
627
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
628
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_versions, the character length must be smaller than or equal to 50.'
|
629
|
+
end
|
630
|
+
|
631
|
+
# resource path
|
632
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/versions'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
633
|
+
|
634
|
+
# query parameters
|
635
|
+
query_params = opts[:query_params] || {}
|
636
|
+
query_params[:'nextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil?
|
637
|
+
query_params[:'pageSize'] = opts[:'page_size'] if !opts[:'page_size'].nil?
|
638
|
+
|
639
|
+
# header parameters
|
640
|
+
header_params = opts[:header_params] || {}
|
641
|
+
# HTTP header 'Accept' (if needed)
|
642
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
643
|
+
|
644
|
+
# form parameters
|
645
|
+
form_params = opts[:form_params] || {}
|
646
|
+
|
647
|
+
# http body (model)
|
648
|
+
post_body = opts[:debug_body]
|
649
|
+
|
650
|
+
# return_type
|
651
|
+
return_type = opts[:debug_return_type] || 'PricePlanV2PaginatedResponse'
|
652
|
+
|
653
|
+
# auth_names
|
654
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
655
|
+
|
656
|
+
new_options = opts.merge(
|
657
|
+
:operation => :"PricePlanV2Api.list_price_plan_versions",
|
658
|
+
:header_params => header_params,
|
659
|
+
:query_params => query_params,
|
660
|
+
:form_params => form_params,
|
661
|
+
:body => post_body,
|
662
|
+
:auth_names => auth_names,
|
663
|
+
:return_type => return_type
|
664
|
+
)
|
665
|
+
|
666
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
667
|
+
if @api_client.config.debugging
|
668
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_versions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
669
|
+
end
|
670
|
+
return data, status_code, headers
|
671
|
+
end
|
672
|
+
|
673
|
+
# List price plans
|
674
|
+
# List price plans
|
675
|
+
# @param [Hash] opts the optional parameters
|
676
|
+
# @option opts [String] :next_token
|
677
|
+
# @option opts [Float] :page_size
|
678
|
+
# @return [PricePlanV2PaginatedResponse]
|
679
|
+
def list_price_plans_v2(opts = {})
|
680
|
+
data, _status_code, _headers = list_price_plans_v2_with_http_info(opts)
|
681
|
+
data
|
682
|
+
end
|
683
|
+
|
684
|
+
# List price plans
|
685
|
+
# List price plans
|
686
|
+
# @param [Hash] opts the optional parameters
|
687
|
+
# @option opts [String] :next_token
|
688
|
+
# @option opts [Float] :page_size
|
689
|
+
# @return [Array<(PricePlanV2PaginatedResponse, Integer, Hash)>] PricePlanV2PaginatedResponse data, response status code and response headers
|
690
|
+
def list_price_plans_v2_with_http_info(opts = {})
|
691
|
+
if @api_client.config.debugging
|
692
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plans_v2 ...'
|
693
|
+
end
|
694
|
+
# resource path
|
695
|
+
local_var_path = '/v2/price_plans'
|
696
|
+
|
697
|
+
# query parameters
|
698
|
+
query_params = opts[:query_params] || {}
|
699
|
+
query_params[:'nextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil?
|
700
|
+
query_params[:'pageSize'] = opts[:'page_size'] if !opts[:'page_size'].nil?
|
701
|
+
|
702
|
+
# header parameters
|
703
|
+
header_params = opts[:header_params] || {}
|
704
|
+
# HTTP header 'Accept' (if needed)
|
705
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
706
|
+
|
707
|
+
# form parameters
|
708
|
+
form_params = opts[:form_params] || {}
|
709
|
+
|
710
|
+
# http body (model)
|
711
|
+
post_body = opts[:debug_body]
|
712
|
+
|
713
|
+
# return_type
|
714
|
+
return_type = opts[:debug_return_type] || 'PricePlanV2PaginatedResponse'
|
715
|
+
|
716
|
+
# auth_names
|
717
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
718
|
+
|
719
|
+
new_options = opts.merge(
|
720
|
+
:operation => :"PricePlanV2Api.list_price_plans_v2",
|
721
|
+
:header_params => header_params,
|
722
|
+
:query_params => query_params,
|
723
|
+
:form_params => form_params,
|
724
|
+
:body => post_body,
|
725
|
+
:auth_names => auth_names,
|
726
|
+
:return_type => return_type
|
727
|
+
)
|
728
|
+
|
729
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
730
|
+
if @api_client.config.debugging
|
731
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plans_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
732
|
+
end
|
733
|
+
return data, status_code, headers
|
734
|
+
end
|
735
|
+
|
736
|
+
# Create a price plan v2 migration
|
737
|
+
# Migrates accounts across price plans. This is an asynchronous process functioning on top of Togai's Jobs framework. Status of the created migrations can be obtained using the [Jobs APIs](https://docs.togai.com/api-reference/jobs/get-the-status-of-a-job)
|
738
|
+
# @param create_price_plan_migration_request [CreatePricePlanMigrationRequest] Payload to create price plan migration request
|
739
|
+
# @param [Hash] opts the optional parameters
|
740
|
+
# @return [BaseSuccessResponse]
|
741
|
+
def price_plan_migration_v2(create_price_plan_migration_request, opts = {})
|
742
|
+
data, _status_code, _headers = price_plan_migration_v2_with_http_info(create_price_plan_migration_request, opts)
|
743
|
+
data
|
744
|
+
end
|
745
|
+
|
746
|
+
# Create a price plan v2 migration
|
747
|
+
# Migrates accounts across price plans. This is an asynchronous process functioning on top of Togai's Jobs framework. Status of the created migrations can be obtained using the [Jobs APIs](https://docs.togai.com/api-reference/jobs/get-the-status-of-a-job)
|
748
|
+
# @param create_price_plan_migration_request [CreatePricePlanMigrationRequest] Payload to create price plan migration request
|
749
|
+
# @param [Hash] opts the optional parameters
|
750
|
+
# @return [Array<(BaseSuccessResponse, Integer, Hash)>] BaseSuccessResponse data, response status code and response headers
|
751
|
+
def price_plan_migration_v2_with_http_info(create_price_plan_migration_request, opts = {})
|
752
|
+
if @api_client.config.debugging
|
753
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.price_plan_migration_v2 ...'
|
754
|
+
end
|
755
|
+
# verify the required parameter 'create_price_plan_migration_request' is set
|
756
|
+
if @api_client.config.client_side_validation && create_price_plan_migration_request.nil?
|
757
|
+
fail ArgumentError, "Missing the required parameter 'create_price_plan_migration_request' when calling PricePlanV2Api.price_plan_migration_v2"
|
758
|
+
end
|
759
|
+
# resource path
|
760
|
+
local_var_path = '/v2/price_plans/migration'
|
761
|
+
|
762
|
+
# query parameters
|
763
|
+
query_params = opts[:query_params] || {}
|
764
|
+
|
765
|
+
# header parameters
|
766
|
+
header_params = opts[:header_params] || {}
|
767
|
+
# HTTP header 'Accept' (if needed)
|
768
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
769
|
+
# HTTP header 'Content-Type'
|
770
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
771
|
+
if !content_type.nil?
|
772
|
+
header_params['Content-Type'] = content_type
|
773
|
+
end
|
774
|
+
|
775
|
+
# form parameters
|
776
|
+
form_params = opts[:form_params] || {}
|
777
|
+
|
778
|
+
# http body (model)
|
779
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(create_price_plan_migration_request)
|
780
|
+
|
781
|
+
# return_type
|
782
|
+
return_type = opts[:debug_return_type] || 'BaseSuccessResponse'
|
783
|
+
|
784
|
+
# auth_names
|
785
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
786
|
+
|
787
|
+
new_options = opts.merge(
|
788
|
+
:operation => :"PricePlanV2Api.price_plan_migration_v2",
|
789
|
+
:header_params => header_params,
|
790
|
+
:query_params => query_params,
|
791
|
+
:form_params => form_params,
|
792
|
+
:body => post_body,
|
793
|
+
:auth_names => auth_names,
|
794
|
+
:return_type => return_type
|
795
|
+
)
|
796
|
+
|
797
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
798
|
+
if @api_client.config.debugging
|
799
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#price_plan_migration_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
800
|
+
end
|
801
|
+
return data, status_code, headers
|
802
|
+
end
|
803
|
+
|
804
|
+
# Update pricing rules of a price plan
|
805
|
+
# Update pricing rules of a price plan
|
806
|
+
# @param price_plan_id [String]
|
807
|
+
# @param update_pricing_rules_request [UpdatePricingRulesRequest] Payload to update pricing rules
|
808
|
+
# @param [Hash] opts the optional parameters
|
809
|
+
# @return [PricingRulesPaginatedResponse]
|
810
|
+
def update_price_plan_pricing_rules(price_plan_id, update_pricing_rules_request, opts = {})
|
811
|
+
data, _status_code, _headers = update_price_plan_pricing_rules_with_http_info(price_plan_id, update_pricing_rules_request, opts)
|
812
|
+
data
|
813
|
+
end
|
814
|
+
|
815
|
+
# Update pricing rules of a price plan
|
816
|
+
# Update pricing rules of a price plan
|
817
|
+
# @param price_plan_id [String]
|
818
|
+
# @param update_pricing_rules_request [UpdatePricingRulesRequest] Payload to update pricing rules
|
819
|
+
# @param [Hash] opts the optional parameters
|
820
|
+
# @return [Array<(PricingRulesPaginatedResponse, Integer, Hash)>] PricingRulesPaginatedResponse data, response status code and response headers
|
821
|
+
def update_price_plan_pricing_rules_with_http_info(price_plan_id, update_pricing_rules_request, opts = {})
|
822
|
+
if @api_client.config.debugging
|
823
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.update_price_plan_pricing_rules ...'
|
824
|
+
end
|
825
|
+
# verify the required parameter 'price_plan_id' is set
|
826
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
827
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.update_price_plan_pricing_rules"
|
828
|
+
end
|
829
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
830
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.update_price_plan_pricing_rules, the character length must be smaller than or equal to 50.'
|
831
|
+
end
|
832
|
+
|
833
|
+
# verify the required parameter 'update_pricing_rules_request' is set
|
834
|
+
if @api_client.config.client_side_validation && update_pricing_rules_request.nil?
|
835
|
+
fail ArgumentError, "Missing the required parameter 'update_pricing_rules_request' when calling PricePlanV2Api.update_price_plan_pricing_rules"
|
836
|
+
end
|
837
|
+
# resource path
|
838
|
+
local_var_path = '/v2/price_plans/{price_plan_id}/pricing_rules'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
839
|
+
|
840
|
+
# query parameters
|
841
|
+
query_params = opts[:query_params] || {}
|
842
|
+
|
843
|
+
# header parameters
|
844
|
+
header_params = opts[:header_params] || {}
|
845
|
+
# HTTP header 'Accept' (if needed)
|
846
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
847
|
+
# HTTP header 'Content-Type'
|
848
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
849
|
+
if !content_type.nil?
|
850
|
+
header_params['Content-Type'] = content_type
|
851
|
+
end
|
852
|
+
|
853
|
+
# form parameters
|
854
|
+
form_params = opts[:form_params] || {}
|
855
|
+
|
856
|
+
# http body (model)
|
857
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(update_pricing_rules_request)
|
858
|
+
|
859
|
+
# return_type
|
860
|
+
return_type = opts[:debug_return_type] || 'PricingRulesPaginatedResponse'
|
861
|
+
|
862
|
+
# auth_names
|
863
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
864
|
+
|
865
|
+
new_options = opts.merge(
|
866
|
+
:operation => :"PricePlanV2Api.update_price_plan_pricing_rules",
|
867
|
+
:header_params => header_params,
|
868
|
+
:query_params => query_params,
|
869
|
+
:form_params => form_params,
|
870
|
+
:body => post_body,
|
871
|
+
:auth_names => auth_names,
|
872
|
+
:return_type => return_type
|
873
|
+
)
|
874
|
+
|
875
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
876
|
+
if @api_client.config.debugging
|
877
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#update_price_plan_pricing_rules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
878
|
+
end
|
879
|
+
return data, status_code, headers
|
880
|
+
end
|
881
|
+
|
882
|
+
# Update a price plan
|
883
|
+
# Update a price plan
|
884
|
+
# @param price_plan_id [String]
|
885
|
+
# @param update_price_plan_v2_request [UpdatePricePlanV2Request] Payload to update price plan
|
886
|
+
# @param [Hash] opts the optional parameters
|
887
|
+
# @return [PricePlanV2]
|
888
|
+
def update_price_plan_v2(price_plan_id, update_price_plan_v2_request, opts = {})
|
889
|
+
data, _status_code, _headers = update_price_plan_v2_with_http_info(price_plan_id, update_price_plan_v2_request, opts)
|
890
|
+
data
|
891
|
+
end
|
892
|
+
|
893
|
+
# Update a price plan
|
894
|
+
# Update a price plan
|
895
|
+
# @param price_plan_id [String]
|
896
|
+
# @param update_price_plan_v2_request [UpdatePricePlanV2Request] Payload to update price plan
|
897
|
+
# @param [Hash] opts the optional parameters
|
898
|
+
# @return [Array<(PricePlanV2, Integer, Hash)>] PricePlanV2 data, response status code and response headers
|
899
|
+
def update_price_plan_v2_with_http_info(price_plan_id, update_price_plan_v2_request, opts = {})
|
900
|
+
if @api_client.config.debugging
|
901
|
+
@api_client.config.logger.debug 'Calling API: PricePlanV2Api.update_price_plan_v2 ...'
|
902
|
+
end
|
903
|
+
# verify the required parameter 'price_plan_id' is set
|
904
|
+
if @api_client.config.client_side_validation && price_plan_id.nil?
|
905
|
+
fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.update_price_plan_v2"
|
906
|
+
end
|
907
|
+
if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50
|
908
|
+
fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.update_price_plan_v2, the character length must be smaller than or equal to 50.'
|
909
|
+
end
|
910
|
+
|
911
|
+
# verify the required parameter 'update_price_plan_v2_request' is set
|
912
|
+
if @api_client.config.client_side_validation && update_price_plan_v2_request.nil?
|
913
|
+
fail ArgumentError, "Missing the required parameter 'update_price_plan_v2_request' when calling PricePlanV2Api.update_price_plan_v2"
|
914
|
+
end
|
915
|
+
# resource path
|
916
|
+
local_var_path = '/v2/price_plans/{price_plan_id}'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s))
|
917
|
+
|
918
|
+
# query parameters
|
919
|
+
query_params = opts[:query_params] || {}
|
920
|
+
|
921
|
+
# header parameters
|
922
|
+
header_params = opts[:header_params] || {}
|
923
|
+
# HTTP header 'Accept' (if needed)
|
924
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
925
|
+
# HTTP header 'Content-Type'
|
926
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
927
|
+
if !content_type.nil?
|
928
|
+
header_params['Content-Type'] = content_type
|
929
|
+
end
|
930
|
+
|
931
|
+
# form parameters
|
932
|
+
form_params = opts[:form_params] || {}
|
933
|
+
|
934
|
+
# http body (model)
|
935
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(update_price_plan_v2_request)
|
936
|
+
|
937
|
+
# return_type
|
938
|
+
return_type = opts[:debug_return_type] || 'PricePlanV2'
|
939
|
+
|
940
|
+
# auth_names
|
941
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
942
|
+
|
943
|
+
new_options = opts.merge(
|
944
|
+
:operation => :"PricePlanV2Api.update_price_plan_v2",
|
945
|
+
:header_params => header_params,
|
946
|
+
:query_params => query_params,
|
947
|
+
:form_params => form_params,
|
948
|
+
:body => post_body,
|
949
|
+
:auth_names => auth_names,
|
950
|
+
:return_type => return_type
|
951
|
+
)
|
952
|
+
|
953
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
954
|
+
if @api_client.config.debugging
|
955
|
+
@api_client.config.logger.debug "API called: PricePlanV2Api#update_price_plan_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
956
|
+
end
|
957
|
+
return data, status_code, headers
|
958
|
+
end
|
959
|
+
end
|
960
|
+
end
|