moolabs 0.3.0__py3-none-any.whl

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.
Files changed (1417) hide show
  1. moolabs/__init__.py +1487 -0
  2. moolabs/_dx_attribution_context.py +213 -0
  3. moolabs/_dx_attribution_db_time.py +2126 -0
  4. moolabs/_dx_attribution_db_time_transport.py +173 -0
  5. moolabs/_dx_attribution_delta.py +142 -0
  6. moolabs/_dx_attribution_deposits.py +552 -0
  7. moolabs/_dx_attribution_instrument.py +416 -0
  8. moolabs/_dx_attribution_middleware.py +541 -0
  9. moolabs/_dx_attribution_propagate.py +509 -0
  10. moolabs/_dx_attribution_signal_transport.py +232 -0
  11. moolabs/_dx_attribution_signals.py +927 -0
  12. moolabs/_dx_buffer.py +429 -0
  13. moolabs/_dx_client.py +726 -0
  14. moolabs/_dx_exceptions.py +84 -0
  15. moolabs/_dx_namespaces.py +1780 -0
  16. moolabs/_dx_pagination.py +131 -0
  17. moolabs/_dx_routing.py +276 -0
  18. moolabs/_dx_urls.py +629 -0
  19. moolabs/_dx_webhooks.py +82 -0
  20. moolabs/api/__init__.py +121 -0
  21. moolabs/api/account_team_api.py +1444 -0
  22. moolabs/api/accounts_api.py +4950 -0
  23. moolabs/api/acute_analytics_api.py +5750 -0
  24. moolabs/api/acute_integrations_api.py +3449 -0
  25. moolabs/api/admin_api.py +3347 -0
  26. moolabs/api/alerts_api.py +1626 -0
  27. moolabs/api/allocation_rules_api.py +1720 -0
  28. moolabs/api/analytics_api.py +3204 -0
  29. moolabs/api/app_custom_invoicing_api.py +952 -0
  30. moolabs/api/app_stripe_api.py +958 -0
  31. moolabs/api/apps_api.py +3064 -0
  32. moolabs/api/arc_admin_api.py +8773 -0
  33. moolabs/api/arc_communications_api.py +1991 -0
  34. moolabs/api/arc_portal_api.py +1737 -0
  35. moolabs/api/arc_webhooks_api.py +2087 -0
  36. moolabs/api/attribution_allocation_api.py +2345 -0
  37. moolabs/api/attribution_api.py +1717 -0
  38. moolabs/api/attribution_customer_keys_api.py +600 -0
  39. moolabs/api/attribution_db_time_api.py +918 -0
  40. moolabs/api/attribution_opencost_api.py +1372 -0
  41. moolabs/api/attribution_readouts_api.py +393 -0
  42. moolabs/api/attribution_signals_api.py +315 -0
  43. moolabs/api/auto_topup_api.py +3095 -0
  44. moolabs/api/batch_api.py +6714 -0
  45. moolabs/api/billing_api.py +300 -0
  46. moolabs/api/bom_api.py +2769 -0
  47. moolabs/api/budgets_api.py +2112 -0
  48. moolabs/api/buyer_quotes_api.py +2007 -0
  49. moolabs/api/cases_api.py +5075 -0
  50. moolabs/api/cash_credits_api.py +1548 -0
  51. moolabs/api/chat_api.py +3101 -0
  52. moolabs/api/clause_packs_api.py +2785 -0
  53. moolabs/api/cloud_billing_api.py +1747 -0
  54. moolabs/api/contract_editor_api.py +3384 -0
  55. moolabs/api/cost_events_api.py +1732 -0
  56. moolabs/api/credit_memos_api.py +3478 -0
  57. moolabs/api/customers_api.py +3931 -0
  58. moolabs/api/dashboard_api.py +771 -0
  59. moolabs/api/debug_api.py +300 -0
  60. moolabs/api/default_api.py +526 -0
  61. moolabs/api/disputes_api.py +3586 -0
  62. moolabs/api/dunning_templates_api.py +8737 -0
  63. moolabs/api/email_provider_api.py +526 -0
  64. moolabs/api/entitlements_api.py +9846 -0
  65. moolabs/api/escalations_api.py +2541 -0
  66. moolabs/api/events_api.py +1125 -0
  67. moolabs/api/fx_rates_api.py +1452 -0
  68. moolabs/api/governance_api.py +4402 -0
  69. moolabs/api/grants_api.py +1370 -0
  70. moolabs/api/handoffs_api.py +2138 -0
  71. moolabs/api/health_api.py +281 -0
  72. moolabs/api/homepage_api.py +305 -0
  73. moolabs/api/integrations_api.py +3374 -0
  74. moolabs/api/internal_api.py +7145 -0
  75. moolabs/api/internal_credit_memos_api.py +914 -0
  76. moolabs/api/internal_grants_api.py +1000 -0
  77. moolabs/api/internal_period_settlements_api.py +657 -0
  78. moolabs/api/internal_plan_pricing_api.py +326 -0
  79. moolabs/api/internal_subscriptions_api.py +326 -0
  80. moolabs/api/ledger_api.py +1483 -0
  81. moolabs/api/lookup_information_api.py +587 -0
  82. moolabs/api/mapping_rules_api.py +1782 -0
  83. moolabs/api/mappings_api.py +632 -0
  84. moolabs/api/margin_simulation_api.py +595 -0
  85. moolabs/api/margins_api.py +2301 -0
  86. moolabs/api/meter_billing_api.py +7419 -0
  87. moolabs/api/meter_portal_api.py +1368 -0
  88. moolabs/api/meter_subscriptions_api.py +4358 -0
  89. moolabs/api/meters_api.py +3707 -0
  90. moolabs/api/monitoring_api.py +561 -0
  91. moolabs/api/moolabs_api.py +1182 -0
  92. moolabs/api/moometer_proxy_api.py +1357 -0
  93. moolabs/api/netsuite_sync_api.py +2180 -0
  94. moolabs/api/notes_api.py +1425 -0
  95. moolabs/api/notifications_api.py +4490 -0
  96. moolabs/api/ops_api.py +315 -0
  97. moolabs/api/outbox_api.py +653 -0
  98. moolabs/api/payments_api.py +2889 -0
  99. moolabs/api/performance_api.py +2471 -0
  100. moolabs/api/plan_pricing_api.py +3409 -0
  101. moolabs/api/plans_api.py +2197 -0
  102. moolabs/api/pools_api.py +2358 -0
  103. moolabs/api/portal_api.py +1103 -0
  104. moolabs/api/product_catalog_api.py +7644 -0
  105. moolabs/api/promises_api.py +2814 -0
  106. moolabs/api/quote_agents_api.py +2036 -0
  107. moolabs/api/quote_contract_webhooks_api.py +327 -0
  108. moolabs/api/quote_contracts_api.py +2551 -0
  109. moolabs/api/quote_sessions_api.py +881 -0
  110. moolabs/api/quotes_api.py +12880 -0
  111. moolabs/api/rate_cards_api.py +578 -0
  112. moolabs/api/rate_catalog_api.py +2120 -0
  113. moolabs/api/rate_schedules_api.py +1224 -0
  114. moolabs/api/rating_api.py +617 -0
  115. moolabs/api/reconstruction_api.py +1281 -0
  116. moolabs/api/remittances_api.py +1521 -0
  117. moolabs/api/reports_api.py +722 -0
  118. moolabs/api/rollover_api.py +313 -0
  119. moolabs/api/sdk_ingest_api.py +312 -0
  120. moolabs/api/snapshots_api.py +1218 -0
  121. moolabs/api/state_projection_api.py +961 -0
  122. moolabs/api/steering_api.py +1862 -0
  123. moolabs/api/subjects_api.py +1160 -0
  124. moolabs/api/subscription_overrides_api.py +579 -0
  125. moolabs/api/subscriptions_api.py +1200 -0
  126. moolabs/api/tasks_api.py +1509 -0
  127. moolabs/api/tenant_api.py +22395 -0
  128. moolabs/api/tenant_config_api.py +282 -0
  129. moolabs/api/topup_api.py +632 -0
  130. moolabs/api/unpriced_api.py +933 -0
  131. moolabs/api/usage_api.py +999 -0
  132. moolabs/api/variance_api.py +1327 -0
  133. moolabs/api/wallets_api.py +3787 -0
  134. moolabs/api/webhooks_api.py +281 -0
  135. moolabs/api/well_known_api.py +278 -0
  136. moolabs/api/word_addin_api.py +623 -0
  137. moolabs/api_client.py +797 -0
  138. moolabs/api_response.py +21 -0
  139. moolabs/configuration.py +620 -0
  140. moolabs/exceptions.py +199 -0
  141. moolabs/models/__init__.py +1286 -0
  142. moolabs/models/account_create.py +114 -0
  143. moolabs/models/account_filter_options_response.py +97 -0
  144. moolabs/models/account_invoice_list_response.py +95 -0
  145. moolabs/models/account_list_item_response.py +152 -0
  146. moolabs/models/account_list_item_response_subsidiaries_inner.py +152 -0
  147. moolabs/models/account_list_response.py +101 -0
  148. moolabs/models/account_overview_bucket_response.py +91 -0
  149. moolabs/models/account_overview_response.py +106 -0
  150. moolabs/models/account_response.py +132 -0
  151. moolabs/models/account_segment_row.py +91 -0
  152. moolabs/models/account_subsidiary_option.py +89 -0
  153. moolabs/models/account_summary.py +97 -0
  154. moolabs/models/account_team_member_in.py +97 -0
  155. moolabs/models/account_team_member_out.py +101 -0
  156. moolabs/models/account_team_member_patch.py +97 -0
  157. moolabs/models/account_team_role.py +39 -0
  158. moolabs/models/account_update.py +106 -0
  159. moolabs/models/action_kind.py +45 -0
  160. moolabs/models/acute_approve_request.py +87 -0
  161. moolabs/models/acute_demo_seed_lifecycle_request.py +103 -0
  162. moolabs/models/acute_http_validation_error.py +95 -0
  163. moolabs/models/acute_validation_error.py +99 -0
  164. moolabs/models/add_contract_participant_request.py +107 -0
  165. moolabs/models/addon.py +178 -0
  166. moolabs/models/addon1.py +115 -0
  167. moolabs/models/addon2.py +95 -0
  168. moolabs/models/addon_create.py +123 -0
  169. moolabs/models/addon_instance_type.py +37 -0
  170. moolabs/models/addon_order_by.py +40 -0
  171. moolabs/models/addon_paginated_response.py +101 -0
  172. moolabs/models/addon_replace_update.py +105 -0
  173. moolabs/models/addon_status.py +38 -0
  174. moolabs/models/address.py +110 -0
  175. moolabs/models/adjusted_total.py +152 -0
  176. moolabs/models/adjustment_amount.py +152 -0
  177. moolabs/models/aging_bucket_detail.py +93 -0
  178. moolabs/models/aging_report_response.py +106 -0
  179. moolabs/models/alb_bootstrap_response.py +89 -0
  180. moolabs/models/alb_connector_config.py +128 -0
  181. moolabs/models/alb_connector_health_response.py +112 -0
  182. moolabs/models/alb_connector_list_response.py +138 -0
  183. moolabs/models/alb_load_balancer_config.py +111 -0
  184. moolabs/models/alb_route_rule.py +107 -0
  185. moolabs/models/alb_source_config.py +123 -0
  186. moolabs/models/alb_source_health_response.py +93 -0
  187. moolabs/models/alb_status_patch_request.py +94 -0
  188. moolabs/models/alb_status_patch_response.py +94 -0
  189. moolabs/models/alb_target_group_config.py +103 -0
  190. moolabs/models/algorithm_breakdown_item.py +89 -0
  191. moolabs/models/algorithm_info.py +93 -0
  192. moolabs/models/alignment.py +87 -0
  193. moolabs/models/allocate_credits_request.py +95 -0
  194. moolabs/models/allocation_coverage_response.py +157 -0
  195. moolabs/models/allocation_fact_page_response.py +97 -0
  196. moolabs/models/allocation_fact_response.py +146 -0
  197. moolabs/models/allocation_key.py +91 -0
  198. moolabs/models/allocation_rule_create.py +114 -0
  199. moolabs/models/allocation_rule_response.py +113 -0
  200. moolabs/models/allocation_rule_update.py +111 -0
  201. moolabs/models/allocation_run_create_request.py +100 -0
  202. moolabs/models/allocation_run_create_response.py +142 -0
  203. moolabs/models/allocation_run_open_cost_snapshot_response.py +120 -0
  204. moolabs/models/allocation_run_readout_response.py +110 -0
  205. moolabs/models/allocation_run_response.py +133 -0
  206. moolabs/models/allocations_list_response.py +97 -0
  207. moolabs/models/amount.py +152 -0
  208. moolabs/models/amount1.py +152 -0
  209. moolabs/models/api_key_item.py +103 -0
  210. moolabs/models/app.py +164 -0
  211. moolabs/models/app_api_v1_auto_topup_router_trigger_response.py +108 -0
  212. moolabs/models/app_api_v1_fx_rates_router_fx_rate_response.py +104 -0
  213. moolabs/models/app_api_v1_integrations_netsuite_sync_router_trigger_response.py +89 -0
  214. moolabs/models/app_api_v1_internal_subscription_sync_schemas_subscription_sync_request.py +123 -0
  215. moolabs/models/app_api_v1_portal_router_create_portal_token_request.py +92 -0
  216. moolabs/models/app_api_v1_quotes_schemas_quote_settings_response.py +91 -0
  217. moolabs/models/app_api_v1_quotes_schemas_update_quote_settings_request.py +89 -0
  218. moolabs/models/app_api_v1_subscriptions_router_subscription_sync_request.py +125 -0
  219. moolabs/models/app_api_v1_tenant_access_router_create_portal_token_request.py +101 -0
  220. moolabs/models/app_api_v1_tenant_fx_rates_router_fx_rate_response.py +93 -0
  221. moolabs/models/app_api_v1_tenant_quote_settings_router_quote_settings_response.py +89 -0
  222. moolabs/models/app_api_v1_tenant_quote_settings_router_update_quote_settings_request.py +87 -0
  223. moolabs/models/app_capability.py +102 -0
  224. moolabs/models/app_capability_type.py +40 -0
  225. moolabs/models/app_paginated_response.py +101 -0
  226. moolabs/models/app_reference.py +95 -0
  227. moolabs/models/app_replace_update.py +164 -0
  228. moolabs/models/app_status.py +37 -0
  229. moolabs/models/app_type.py +38 -0
  230. moolabs/models/apply_credit_request.py +92 -0
  231. moolabs/models/approval_action_request.py +88 -0
  232. moolabs/models/approval_action_response.py +95 -0
  233. moolabs/models/approval_policy_response.py +91 -0
  234. moolabs/models/approve_request.py +88 -0
  235. moolabs/models/approve_response.py +91 -0
  236. moolabs/models/approver_in.py +95 -0
  237. moolabs/models/arc_demo_seed_lifecycle_request.py +103 -0
  238. moolabs/models/arc_dunning_permission_grant_request.py +96 -0
  239. moolabs/models/arc_dunning_permission_revoke_request.py +90 -0
  240. moolabs/models/arc_dunning_template_admin_grant_request.py +90 -0
  241. moolabs/models/arc_dunning_template_admin_grant_response.py +115 -0
  242. moolabs/models/arc_dunning_template_admin_revoke_request.py +88 -0
  243. moolabs/models/arc_dunning_template_admin_user_dto.py +107 -0
  244. moolabs/models/arc_dunning_template_admin_user_grant_dto.py +105 -0
  245. moolabs/models/arc_dunning_template_admin_users_response.py +110 -0
  246. moolabs/models/arc_http_validation_error.py +95 -0
  247. moolabs/models/arc_transaction_request.py +110 -0
  248. moolabs/models/arc_validation_error.py +99 -0
  249. moolabs/models/ask_customer_request.py +97 -0
  250. moolabs/models/ask_customer_response.py +91 -0
  251. moolabs/models/ask_moo_redline_request.py +98 -0
  252. moolabs/models/attribution_allocation_error_detail.py +94 -0
  253. moolabs/models/attribution_allocation_error_response.py +91 -0
  254. moolabs/models/attribution_completeness_response.py +97 -0
  255. moolabs/models/attribution_signal_conflict_detail.py +94 -0
  256. moolabs/models/attribution_signal_conflict_response.py +91 -0
  257. moolabs/models/attribution_signal_delta.py +98 -0
  258. moolabs/models/attribution_signal_request.py +123 -0
  259. moolabs/models/attribution_signal_response.py +96 -0
  260. moolabs/models/audit_request.py +91 -0
  261. moolabs/models/auto_topup_activity_item.py +104 -0
  262. moolabs/models/auto_topup_activity_response.py +97 -0
  263. moolabs/models/auto_topup_rule_response.py +114 -0
  264. moolabs/models/availability.py +43 -0
  265. moolabs/models/backfill_candidate.py +97 -0
  266. moolabs/models/backfill_malformed_disputes_request.py +87 -0
  267. moolabs/models/backfill_malformed_disputes_response.py +101 -0
  268. moolabs/models/balance_history_window.py +99 -0
  269. moolabs/models/basis.py +37 -0
  270. moolabs/models/batch_ingest_request.py +96 -0
  271. moolabs/models/batch_wallet_state_request.py +105 -0
  272. moolabs/models/batch_wallet_state_request_item.py +91 -0
  273. moolabs/models/batch_wallet_state_response.py +97 -0
  274. moolabs/models/batch_wallets_by_subjects_request.py +88 -0
  275. moolabs/models/billing_customer_profile.py +109 -0
  276. moolabs/models/billing_discount_percentage.py +100 -0
  277. moolabs/models/billing_discount_reason.py +164 -0
  278. moolabs/models/billing_discount_usage.py +107 -0
  279. moolabs/models/billing_discounts.py +97 -0
  280. moolabs/models/billing_import_request.py +105 -0
  281. moolabs/models/billing_import_response.py +104 -0
  282. moolabs/models/billing_invoice_customer_extended_details.py +116 -0
  283. moolabs/models/billing_party.py +110 -0
  284. moolabs/models/billing_party_replace_update.py +106 -0
  285. moolabs/models/billing_party_tax_identity.py +88 -0
  286. moolabs/models/billing_profile.py +140 -0
  287. moolabs/models/billing_profile_app_references.py +107 -0
  288. moolabs/models/billing_profile_apps.py +107 -0
  289. moolabs/models/billing_profile_apps_create.py +113 -0
  290. moolabs/models/billing_profile_apps_or_reference.py +148 -0
  291. moolabs/models/billing_profile_create.py +112 -0
  292. moolabs/models/billing_profile_customer_override.py +116 -0
  293. moolabs/models/billing_profile_customer_override_create.py +98 -0
  294. moolabs/models/billing_profile_customer_override_expand.py +37 -0
  295. moolabs/models/billing_profile_customer_override_order_by.py +40 -0
  296. moolabs/models/billing_profile_customer_override_with_details.py +113 -0
  297. moolabs/models/billing_profile_customer_override_with_details_paginated_response.py +101 -0
  298. moolabs/models/billing_profile_expand.py +36 -0
  299. moolabs/models/billing_profile_order_by.py +39 -0
  300. moolabs/models/billing_profile_paginated_response.py +101 -0
  301. moolabs/models/billing_profile_replace_update_with_workflow.py +106 -0
  302. moolabs/models/billing_tenant_settings_out.py +89 -0
  303. moolabs/models/billing_tenant_settings_update.py +88 -0
  304. moolabs/models/billing_workflow.py +109 -0
  305. moolabs/models/billing_workflow_collection_alignment.py +150 -0
  306. moolabs/models/billing_workflow_collection_alignment_anchored.py +100 -0
  307. moolabs/models/billing_workflow_collection_alignment_subscription.py +94 -0
  308. moolabs/models/billing_workflow_collection_settings.py +93 -0
  309. moolabs/models/billing_workflow_create.py +109 -0
  310. moolabs/models/billing_workflow_invoicing_settings.py +99 -0
  311. moolabs/models/billing_workflow_payment_settings.py +88 -0
  312. moolabs/models/billing_workflow_tax_settings.py +89 -0
  313. moolabs/models/bom_component_in.py +105 -0
  314. moolabs/models/bom_component_out.py +109 -0
  315. moolabs/models/bom_create_request.py +107 -0
  316. moolabs/models/bom_out.py +127 -0
  317. moolabs/models/bom_update_request.py +103 -0
  318. moolabs/models/bom_variance_out.py +115 -0
  319. moolabs/models/breakdown_response.py +124 -0
  320. moolabs/models/breakdown_row.py +121 -0
  321. moolabs/models/breakdown_row_kind.py +39 -0
  322. moolabs/models/budget_alert_response.py +107 -0
  323. moolabs/models/budget_amount.py +152 -0
  324. moolabs/models/budget_amount1.py +152 -0
  325. moolabs/models/budget_create.py +110 -0
  326. moolabs/models/budget_pace_status.py +38 -0
  327. moolabs/models/budget_response.py +113 -0
  328. moolabs/models/budget_status_item.py +105 -0
  329. moolabs/models/budget_update.py +107 -0
  330. moolabs/models/budget_with_utilization.py +119 -0
  331. moolabs/models/bulk_action_request.py +92 -0
  332. moolabs/models/bulk_replay_request.py +92 -0
  333. moolabs/models/buyer_accept_request.py +95 -0
  334. moolabs/models/buyer_otp_request_response.py +91 -0
  335. moolabs/models/buyer_otp_verify_request.py +95 -0
  336. moolabs/models/buyer_otp_verify_response.py +89 -0
  337. moolabs/models/buyer_quote_line_item.py +103 -0
  338. moolabs/models/buyer_quote_pricing.py +93 -0
  339. moolabs/models/buyer_quote_projection.py +133 -0
  340. moolabs/models/buyer_reject_request.py +88 -0
  341. moolabs/models/buyer_request_changes_request.py +94 -0
  342. moolabs/models/buyer_request_changes_response.py +93 -0
  343. moolabs/models/buyer_requested_changes.py +90 -0
  344. moolabs/models/cancel_subscription_request.py +91 -0
  345. moolabs/models/card_type.py +37 -0
  346. moolabs/models/case_create.py +112 -0
  347. moolabs/models/case_escalate_request.py +90 -0
  348. moolabs/models/case_invoice_create.py +127 -0
  349. moolabs/models/case_invoice_response.py +150 -0
  350. moolabs/models/case_list_item_response.py +171 -0
  351. moolabs/models/case_list_response.py +101 -0
  352. moolabs/models/case_pause_request.py +91 -0
  353. moolabs/models/case_response.py +169 -0
  354. moolabs/models/case_update.py +102 -0
  355. moolabs/models/case_write_off_request.py +90 -0
  356. moolabs/models/cash_app_config_update_request.py +96 -0
  357. moolabs/models/cei_response.py +102 -0
  358. moolabs/models/change_item.py +101 -0
  359. moolabs/models/channel_policy_schema.py +112 -0
  360. moolabs/models/channel_preference_create.py +99 -0
  361. moolabs/models/channel_preference_response.py +106 -0
  362. moolabs/models/channel_preference_update.py +95 -0
  363. moolabs/models/channel_preferences_response.py +95 -0
  364. moolabs/models/chat_feedback_in.py +91 -0
  365. moolabs/models/chat_message_in.py +89 -0
  366. moolabs/models/chat_request.py +101 -0
  367. moolabs/models/check_trigger_request.py +88 -0
  368. moolabs/models/checkout_session_custom_text_after_submit_params.py +109 -0
  369. moolabs/models/checkout_session_custom_text_after_submit_params_after_submit.py +88 -0
  370. moolabs/models/checkout_session_custom_text_after_submit_params_shipping_address.py +88 -0
  371. moolabs/models/checkout_session_custom_text_after_submit_params_submit.py +88 -0
  372. moolabs/models/checkout_session_custom_text_after_submit_params_terms_of_service_acceptance.py +88 -0
  373. moolabs/models/checkout_session_ui_mode.py +37 -0
  374. moolabs/models/clause_citations.py +91 -0
  375. moolabs/models/clause_family.py +129 -0
  376. moolabs/models/clause_finding.py +110 -0
  377. moolabs/models/clause_pack.py +118 -0
  378. moolabs/models/clause_position.py +91 -0
  379. moolabs/models/client_app_start_response.py +87 -0
  380. moolabs/models/cloud_cost_row_input.py +105 -0
  381. moolabs/models/cloud_provider.py +38 -0
  382. moolabs/models/cloud_provider_data_through.py +116 -0
  383. moolabs/models/cloud_provider_quality_axis.py +107 -0
  384. moolabs/models/cloud_temporal_coverage_summary.py +114 -0
  385. moolabs/models/collection_method.py +37 -0
  386. moolabs/models/commercial_basis.py +39 -0
  387. moolabs/models/commercial_overrides.py +113 -0
  388. moolabs/models/commercial_overrides_input.py +115 -0
  389. moolabs/models/commercial_overrides_payload.py +113 -0
  390. moolabs/models/communication_create.py +110 -0
  391. moolabs/models/communication_list_response.py +101 -0
  392. moolabs/models/communication_response.py +138 -0
  393. moolabs/models/comparison_mode.py +37 -0
  394. moolabs/models/completeness_response.py +105 -0
  395. moolabs/models/component_coverage_response.py +123 -0
  396. moolabs/models/compute_variance_request.py +96 -0
  397. moolabs/models/compute_variance_response.py +105 -0
  398. moolabs/models/config_upload_gap_out.py +89 -0
  399. moolabs/models/config_upload_response.py +109 -0
  400. moolabs/models/config_upload_summary_out.py +95 -0
  401. moolabs/models/connector_config_response.py +93 -0
  402. moolabs/models/connector_health_response.py +102 -0
  403. moolabs/models/connector_item.py +105 -0
  404. moolabs/models/contact_create.py +100 -0
  405. moolabs/models/contact_list_response.py +101 -0
  406. moolabs/models/contact_response.py +134 -0
  407. moolabs/models/contact_update.py +102 -0
  408. moolabs/models/contract_document_response.py +104 -0
  409. moolabs/models/contract_event_response.py +108 -0
  410. moolabs/models/contract_inbound_message_response.py +106 -0
  411. moolabs/models/contract_participant_response.py +131 -0
  412. moolabs/models/contract_segment_response.py +95 -0
  413. moolabs/models/contract_thread_response.py +115 -0
  414. moolabs/models/contract_thread_snapshot_response.py +121 -0
  415. moolabs/models/contract_upload_detail_response.py +103 -0
  416. moolabs/models/contract_version_response.py +128 -0
  417. moolabs/models/contributor_item.py +123 -0
  418. moolabs/models/contributor_kind.py +38 -0
  419. moolabs/models/contributor_query_request.py +146 -0
  420. moolabs/models/contributor_response.py +174 -0
  421. moolabs/models/cost.py +152 -0
  422. moolabs/models/cost_adjustment_create.py +131 -0
  423. moolabs/models/cost_adjustment_response.py +102 -0
  424. moolabs/models/cost_driver_rule_create_request.py +158 -0
  425. moolabs/models/cost_driver_rule_response.py +126 -0
  426. moolabs/models/cost_driver_rule_update_request.py +100 -0
  427. moolabs/models/cost_event_detail_response.py +132 -0
  428. moolabs/models/cost_event_ingest.py +177 -0
  429. moolabs/models/cost_event_response.py +122 -0
  430. moolabs/models/cost_event_summary_item.py +103 -0
  431. moolabs/models/cost_event_summary_request.py +88 -0
  432. moolabs/models/cost_event_summary_response.py +95 -0
  433. moolabs/models/cost_explorer_response.py +155 -0
  434. moolabs/models/cost_scope.py +37 -0
  435. moolabs/models/coverage_snapshot_response.py +114 -0
  436. moolabs/models/cpu_core_hours.py +152 -0
  437. moolabs/models/cpu_cost_weight.py +152 -0
  438. moolabs/models/create_allocation_run_api422_response.py +147 -0
  439. moolabs/models/create_api_key_request.py +89 -0
  440. moolabs/models/create_api_key_response.py +105 -0
  441. moolabs/models/create_auto_topup_rule_request.py +106 -0
  442. moolabs/models/create_checkout_session_tax_id_collection.py +90 -0
  443. moolabs/models/create_checkout_session_tax_id_collection_required.py +37 -0
  444. moolabs/models/create_contract_thread_request.py +87 -0
  445. moolabs/models/create_credit_request.py +97 -0
  446. moolabs/models/create_fx_rate_request.py +103 -0
  447. moolabs/models/create_grant_request.py +136 -0
  448. moolabs/models/create_mapping_request.py +91 -0
  449. moolabs/models/create_matrix_price_row_request.py +91 -0
  450. moolabs/models/create_matrix_price_row_response.py +89 -0
  451. moolabs/models/create_portal_token_response.py +91 -0
  452. moolabs/models/create_quote_redline_request.py +103 -0
  453. moolabs/models/create_quote_request.py +119 -0
  454. moolabs/models/create_quote_template_request.py +102 -0
  455. moolabs/models/create_rate_card_request.py +105 -0
  456. moolabs/models/create_reconstruction_run_request.py +101 -0
  457. moolabs/models/create_session_response.py +97 -0
  458. moolabs/models/create_snapshot_request.py +98 -0
  459. moolabs/models/create_stripe_checkout_session_billing_address_collection.py +37 -0
  460. moolabs/models/create_stripe_checkout_session_consent_collection.py +97 -0
  461. moolabs/models/create_stripe_checkout_session_consent_collection_payment_method_reuse_agreement.py +88 -0
  462. moolabs/models/create_stripe_checkout_session_consent_collection_payment_method_reuse_agreement_position.py +37 -0
  463. moolabs/models/create_stripe_checkout_session_consent_collection_promotions.py +37 -0
  464. moolabs/models/create_stripe_checkout_session_consent_collection_terms_of_service.py +37 -0
  465. moolabs/models/create_stripe_checkout_session_customer_update.py +92 -0
  466. moolabs/models/create_stripe_checkout_session_customer_update_behavior.py +37 -0
  467. moolabs/models/create_stripe_checkout_session_redirect_on_completion.py +38 -0
  468. moolabs/models/create_stripe_checkout_session_request.py +112 -0
  469. moolabs/models/create_stripe_checkout_session_request_customer.py +163 -0
  470. moolabs/models/create_stripe_checkout_session_request_options.py +147 -0
  471. moolabs/models/create_stripe_checkout_session_result.py +139 -0
  472. moolabs/models/create_stripe_customer_portal_session_params.py +91 -0
  473. moolabs/models/create_threshold_request.py +99 -0
  474. moolabs/models/create_value_recognition_request.py +100 -0
  475. moolabs/models/create_wallet_request.py +106 -0
  476. moolabs/models/credit_config.py +119 -0
  477. moolabs/models/credit_config_payload.py +135 -0
  478. moolabs/models/credit_cost_ratio_item.py +93 -0
  479. moolabs/models/credit_cost_ratio_response.py +101 -0
  480. moolabs/models/credit_memo_apply_request.py +90 -0
  481. moolabs/models/credit_memo_create.py +104 -0
  482. moolabs/models/credit_memo_create_internal.py +114 -0
  483. moolabs/models/credit_memo_create_public.py +108 -0
  484. moolabs/models/credit_memo_item.py +102 -0
  485. moolabs/models/credit_memo_line_in.py +90 -0
  486. moolabs/models/credit_memo_list_response.py +101 -0
  487. moolabs/models/credit_memo_out.py +138 -0
  488. moolabs/models/credit_memo_response.py +124 -0
  489. moolabs/models/credit_memo_update.py +94 -0
  490. moolabs/models/credit_note_original_invoice_ref.py +114 -0
  491. moolabs/models/credit_override.py +87 -0
  492. moolabs/models/credit_override_input.py +101 -0
  493. moolabs/models/credit_override_payload.py +100 -0
  494. moolabs/models/crm_quote_context_request.py +94 -0
  495. moolabs/models/crm_quote_context_response.py +101 -0
  496. moolabs/models/crm_quote_draft_request.py +98 -0
  497. moolabs/models/crm_quote_draft_response.py +107 -0
  498. moolabs/models/crm_quote_record_card_response.py +97 -0
  499. moolabs/models/crm_surface_response.py +97 -0
  500. moolabs/models/currency.py +101 -0
  501. moolabs/models/current.py +152 -0
  502. moolabs/models/custom_invoicing_app.py +142 -0
  503. moolabs/models/custom_invoicing_app_replace_update.py +105 -0
  504. moolabs/models/custom_invoicing_customer_app_data.py +117 -0
  505. moolabs/models/custom_invoicing_draft_synchronized_request.py +91 -0
  506. moolabs/models/custom_invoicing_finalized_invoicing_request.py +91 -0
  507. moolabs/models/custom_invoicing_finalized_payment_request.py +87 -0
  508. moolabs/models/custom_invoicing_finalized_request.py +97 -0
  509. moolabs/models/custom_invoicing_line_discount_external_id_mapping.py +97 -0
  510. moolabs/models/custom_invoicing_line_external_id_mapping.py +97 -0
  511. moolabs/models/custom_invoicing_payment_trigger.py +41 -0
  512. moolabs/models/custom_invoicing_sync_result.py +110 -0
  513. moolabs/models/custom_invoicing_tax_config.py +87 -0
  514. moolabs/models/custom_invoicing_update_payment_status_request.py +92 -0
  515. moolabs/models/custom_plan_input.py +136 -0
  516. moolabs/models/custom_subscription_change.py +119 -0
  517. moolabs/models/custom_subscription_create.py +153 -0
  518. moolabs/models/customer.py +172 -0
  519. moolabs/models/customer_access.py +102 -0
  520. moolabs/models/customer_app_data.py +164 -0
  521. moolabs/models/customer_app_data_create_or_update_item.py +164 -0
  522. moolabs/models/customer_app_data_paginated_response.py +101 -0
  523. moolabs/models/customer_cost_item.py +95 -0
  524. moolabs/models/customer_create.py +120 -0
  525. moolabs/models/customer_expand.py +36 -0
  526. moolabs/models/customer_id.py +95 -0
  527. moolabs/models/customer_item.py +114 -0
  528. moolabs/models/customer_key.py +87 -0
  529. moolabs/models/customer_key_page_response.py +101 -0
  530. moolabs/models/customer_key_put_request.py +103 -0
  531. moolabs/models/customer_key_response.py +94 -0
  532. moolabs/models/customer_margin_item.py +99 -0
  533. moolabs/models/customer_margin_response.py +101 -0
  534. moolabs/models/customer_order_by.py +38 -0
  535. moolabs/models/customer_paginated_response.py +101 -0
  536. moolabs/models/customer_replace_update.py +120 -0
  537. moolabs/models/customer_subscription_order_by.py +37 -0
  538. moolabs/models/customer_upsert_request.py +102 -0
  539. moolabs/models/customer_usage_attribution.py +88 -0
  540. moolabs/models/danger_request.py +89 -0
  541. moolabs/models/dashboard_meta.py +172 -0
  542. moolabs/models/dashboard_overview_response.py +115 -0
  543. moolabs/models/data_through.py +115 -0
  544. moolabs/models/db_time_coverage_response.py +154 -0
  545. moolabs/models/db_time_evidence_batch_readback_response.py +135 -0
  546. moolabs/models/db_time_evidence_batch_request.py +147 -0
  547. moolabs/models/db_time_evidence_batch_response.py +100 -0
  548. moolabs/models/db_time_evidence_conflict_detail.py +94 -0
  549. moolabs/models/db_time_evidence_conflict_response.py +91 -0
  550. moolabs/models/db_time_evidence_not_found_detail.py +94 -0
  551. moolabs/models/db_time_evidence_not_found_response.py +91 -0
  552. moolabs/models/db_time_observation_request.py +131 -0
  553. moolabs/models/db_time_readout_quality_response.py +103 -0
  554. moolabs/models/deal_context.py +97 -0
  555. moolabs/models/deal_context_rule.py +105 -0
  556. moolabs/models/decision_item.py +131 -0
  557. moolabs/models/decision_kind.py +46 -0
  558. moolabs/models/decision_overview_response.py +172 -0
  559. moolabs/models/decision_queue_response.py +115 -0
  560. moolabs/models/decision_reason_code.py +53 -0
  561. moolabs/models/delta.py +152 -0
  562. moolabs/models/delta_pct.py +152 -0
  563. moolabs/models/demo_seed_acute_history_baseline_request.py +106 -0
  564. moolabs/models/demo_seed_acute_tenant_registration_request.py +114 -0
  565. moolabs/models/demo_seed_agent_report_baseline_request.py +106 -0
  566. moolabs/models/demo_seed_arc_invoice_ref.py +107 -0
  567. moolabs/models/demo_seed_arc_portfolio_baseline_request.py +121 -0
  568. moolabs/models/demo_seed_catalog_baseline_request.py +108 -0
  569. moolabs/models/demo_seed_customer_portfolio_baseline_request.py +103 -0
  570. moolabs/models/demo_seed_integration_crm_baseline_request.py +106 -0
  571. moolabs/models/demo_seed_integration_finance_baseline_request.py +106 -0
  572. moolabs/models/demo_seed_integration_netsuite_baseline_request.py +106 -0
  573. moolabs/models/demo_seed_integration_webhook_baseline_request.py +106 -0
  574. moolabs/models/demo_seed_invoice_payment_baseline_request.py +106 -0
  575. moolabs/models/demo_seed_isolation_canary_baseline_request.py +106 -0
  576. moolabs/models/demo_seed_lifecycle_request.py +103 -0
  577. moolabs/models/demo_seed_quote_contract_baseline_request.py +106 -0
  578. moolabs/models/demo_seed_security_credentials_baseline_request.py +106 -0
  579. moolabs/models/demo_seed_settings_baseline_request.py +106 -0
  580. moolabs/models/demo_seed_subscription_baseline_request.py +106 -0
  581. moolabs/models/demo_seed_tenant_config_baseline_request.py +119 -0
  582. moolabs/models/demo_seed_usage_baseline_request.py +106 -0
  583. moolabs/models/derive_request.py +94 -0
  584. moolabs/models/dimension.py +39 -0
  585. moolabs/models/dimension_coverage_response.py +102 -0
  586. moolabs/models/disclosure_policy_response.py +93 -0
  587. moolabs/models/disclosure_policy_update_request.py +102 -0
  588. moolabs/models/discount_percentage.py +87 -0
  589. moolabs/models/discount_reason_maximum_spend.py +94 -0
  590. moolabs/models/discount_reason_ratecard_percentage.py +109 -0
  591. moolabs/models/discount_reason_ratecard_usage.py +116 -0
  592. moolabs/models/discount_usage.py +95 -0
  593. moolabs/models/discounts.py +97 -0
  594. moolabs/models/dismiss_refinement_request.py +87 -0
  595. moolabs/models/dispute_approval_request.py +88 -0
  596. moolabs/models/dispute_list_response.py +101 -0
  597. moolabs/models/dispute_resolve_request.py +92 -0
  598. moolabs/models/dispute_response.py +134 -0
  599. moolabs/models/dispute_summary_response.py +104 -0
  600. moolabs/models/dispute_update_request.py +102 -0
  601. moolabs/models/dns_record.py +119 -0
  602. moolabs/models/domain_response.py +95 -0
  603. moolabs/models/domain_update.py +87 -0
  604. moolabs/models/draft_lock_request.py +88 -0
  605. moolabs/models/draft_lock_response.py +97 -0
  606. moolabs/models/draft_save_request.py +114 -0
  607. moolabs/models/draft_unlock_request.py +90 -0
  608. moolabs/models/driver_item.py +122 -0
  609. moolabs/models/dry_run_request.py +89 -0
  610. moolabs/models/dry_run_response.py +97 -0
  611. moolabs/models/dso_response.py +100 -0
  612. moolabs/models/dynamic_price_with_commitments.py +131 -0
  613. moolabs/models/economics_summary.py +114 -0
  614. moolabs/models/edit_subscription_add_item.py +102 -0
  615. moolabs/models/edit_subscription_add_phase.py +100 -0
  616. moolabs/models/edit_subscription_remove_item.py +98 -0
  617. moolabs/models/edit_subscription_remove_phase.py +99 -0
  618. moolabs/models/edit_subscription_stretch_phase.py +98 -0
  619. moolabs/models/edit_subscription_unschedule_edit.py +94 -0
  620. moolabs/models/effective_permission_grant_dto.py +105 -0
  621. moolabs/models/effective_permissions_response.py +129 -0
  622. moolabs/models/email_config_out.py +188 -0
  623. moolabs/models/email_config_upsert.py +111 -0
  624. moolabs/models/email_context.py +44 -0
  625. moolabs/models/email_message_status.py +42 -0
  626. moolabs/models/email_provider.py +37 -0
  627. moolabs/models/email_provider_identity.py +157 -0
  628. moolabs/models/email_provider_identity_list.py +108 -0
  629. moolabs/models/email_provider_operator_upsert.py +131 -0
  630. moolabs/models/email_provider_route.py +128 -0
  631. moolabs/models/email_provider_route_list.py +108 -0
  632. moolabs/models/enable_tier3_response.py +93 -0
  633. moolabs/models/endpoints_response.py +89 -0
  634. moolabs/models/entitlement.py +164 -0
  635. moolabs/models/entitlement_boolean.py +168 -0
  636. moolabs/models/entitlement_boolean_create_inputs.py +127 -0
  637. moolabs/models/entitlement_boolean_v2.py +170 -0
  638. moolabs/models/entitlement_create_inputs.py +164 -0
  639. moolabs/models/entitlement_grant.py +148 -0
  640. moolabs/models/entitlement_grant_create_input.py +111 -0
  641. moolabs/models/entitlement_grant_create_input_v2.py +113 -0
  642. moolabs/models/entitlement_grant_v2.py +148 -0
  643. moolabs/models/entitlement_metered.py +190 -0
  644. moolabs/models/entitlement_metered_create_inputs.py +143 -0
  645. moolabs/models/entitlement_metered_v2.py +196 -0
  646. moolabs/models/entitlement_metered_v2_create_inputs.py +157 -0
  647. moolabs/models/entitlement_order_by.py +37 -0
  648. moolabs/models/entitlement_override.py +89 -0
  649. moolabs/models/entitlement_override_input.py +95 -0
  650. moolabs/models/entitlement_override_payload.py +93 -0
  651. moolabs/models/entitlement_paginated_response.py +101 -0
  652. moolabs/models/entitlement_payload.py +103 -0
  653. moolabs/models/entitlement_static.py +170 -0
  654. moolabs/models/entitlement_static_create_inputs.py +129 -0
  655. moolabs/models/entitlement_static_v2.py +172 -0
  656. moolabs/models/entitlement_type.py +38 -0
  657. moolabs/models/entitlement_v2.py +164 -0
  658. moolabs/models/entitlement_v2_create_inputs.py +164 -0
  659. moolabs/models/entitlement_v2_paginated_response.py +101 -0
  660. moolabs/models/entitlement_value.py +109 -0
  661. moolabs/models/error_extension.py +110 -0
  662. moolabs/models/escalate_request.py +90 -0
  663. moolabs/models/escalate_response.py +91 -0
  664. moolabs/models/escalation_action_request.py +90 -0
  665. moolabs/models/escalation_action_response.py +91 -0
  666. moolabs/models/escalation_create.py +97 -0
  667. moolabs/models/escalation_dismiss_request.py +90 -0
  668. moolabs/models/escalation_list_response.py +101 -0
  669. moolabs/models/escalation_resolve_request.py +87 -0
  670. moolabs/models/escalation_response.py +112 -0
  671. moolabs/models/escalation_update.py +93 -0
  672. moolabs/models/event.py +115 -0
  673. moolabs/models/event_delivery_attempt_response.py +101 -0
  674. moolabs/models/evidence_create_request.py +96 -0
  675. moolabs/models/evidence_kind.py +39 -0
  676. moolabs/models/evidence_list_response.py +97 -0
  677. moolabs/models/evidence_response.py +106 -0
  678. moolabs/models/evidence_review_request.py +90 -0
  679. moolabs/models/evidence_window.py +37 -0
  680. moolabs/models/exchange_rate.py +152 -0
  681. moolabs/models/expiration_duration.py +40 -0
  682. moolabs/models/expiration_period.py +91 -0
  683. moolabs/models/explorer_alias_hint.py +104 -0
  684. moolabs/models/explorer_alias_hint1.py +110 -0
  685. moolabs/models/explorer_alias_kind.py +39 -0
  686. moolabs/models/explorer_breakdown_page.py +166 -0
  687. moolabs/models/explorer_breakdown_row.py +200 -0
  688. moolabs/models/explorer_cloud_provider_quality_axis.py +107 -0
  689. moolabs/models/explorer_cloud_temporal_coverage_summary.py +115 -0
  690. moolabs/models/explorer_contributor_kind.py +40 -0
  691. moolabs/models/explorer_contributor_query_request.py +190 -0
  692. moolabs/models/explorer_contributor_response.py +201 -0
  693. moolabs/models/explorer_contributor_row.py +177 -0
  694. moolabs/models/explorer_cost_event_status.py +39 -0
  695. moolabs/models/explorer_dimension.py +40 -0
  696. moolabs/models/explorer_effective_sort.py +107 -0
  697. moolabs/models/explorer_effective_sort_field.py +41 -0
  698. moolabs/models/explorer_evidence_kind.py +41 -0
  699. moolabs/models/explorer_evidence_role.py +37 -0
  700. moolabs/models/explorer_excluded_event_count.py +104 -0
  701. moolabs/models/explorer_excluded_event_reason.py +38 -0
  702. moolabs/models/explorer_exposure_summary.py +124 -0
  703. moolabs/models/explorer_measure_source.py +40 -0
  704. moolabs/models/explorer_meta.py +196 -0
  705. moolabs/models/explorer_quality_axis.py +117 -0
  706. moolabs/models/explorer_quality_caveat_code.py +45 -0
  707. moolabs/models/explorer_quality_summary.py +151 -0
  708. moolabs/models/explorer_query_request.py +184 -0
  709. moolabs/models/explorer_request_detail_event.py +134 -0
  710. moolabs/models/explorer_request_detail_line.py +133 -0
  711. moolabs/models/explorer_request_detail_query_request.py +201 -0
  712. moolabs/models/explorer_request_detail_response.py +205 -0
  713. moolabs/models/explorer_request_detail_result_cap.py +125 -0
  714. moolabs/models/explorer_request_distribution.py +109 -0
  715. moolabs/models/explorer_request_query_request.py +190 -0
  716. moolabs/models/explorer_search.py +111 -0
  717. moolabs/models/explorer_selection_result.py +107 -0
  718. moolabs/models/explorer_selection_row.py +185 -0
  719. moolabs/models/explorer_selection_status.py +39 -0
  720. moolabs/models/explorer_sort.py +104 -0
  721. moolabs/models/explorer_sort1.py +116 -0
  722. moolabs/models/explorer_sort_fallback_reason.py +39 -0
  723. moolabs/models/explorer_sort_field.py +40 -0
  724. moolabs/models/explorer_source_scope.py +38 -0
  725. moolabs/models/explorer_summary.py +134 -0
  726. moolabs/models/explorer_trend_point.py +124 -0
  727. moolabs/models/explorer_usage_history_evidence.py +110 -0
  728. moolabs/models/explorer_usage_history_source.py +38 -0
  729. moolabs/models/feature.py +156 -0
  730. moolabs/models/feature_contributor_customer.py +91 -0
  731. moolabs/models/feature_contributor_model.py +93 -0
  732. moolabs/models/feature_contributor_request.py +91 -0
  733. moolabs/models/feature_contributors_response.py +121 -0
  734. moolabs/models/feature_cost_item.py +97 -0
  735. moolabs/models/feature_create_inputs.py +128 -0
  736. moolabs/models/feature_flag_item.py +97 -0
  737. moolabs/models/feature_flag_update.py +87 -0
  738. moolabs/models/feature_margin_item.py +101 -0
  739. moolabs/models/feature_margin_response.py +101 -0
  740. moolabs/models/feature_meta.py +97 -0
  741. moolabs/models/feature_order_by.py +40 -0
  742. moolabs/models/feature_override_request.py +93 -0
  743. moolabs/models/feature_paginated_response.py +101 -0
  744. moolabs/models/feature_pool.py +99 -0
  745. moolabs/models/feature_pool_payload.py +107 -0
  746. moolabs/models/feature_price_request.py +93 -0
  747. moolabs/models/feature_pricing_input.py +120 -0
  748. moolabs/models/filter_id_exact.py +88 -0
  749. moolabs/models/filter_string.py +129 -0
  750. moolabs/models/filter_time.py +114 -0
  751. moolabs/models/finance_summary.py +143 -0
  752. moolabs/models/first_pass_redline_request.py +88 -0
  753. moolabs/models/first_pass_redline_response.py +89 -0
  754. moolabs/models/flag_disputed_request.py +92 -0
  755. moolabs/models/flag_disputed_response.py +97 -0
  756. moolabs/models/flat_price.py +104 -0
  757. moolabs/models/flat_price_with_payment_term.py +107 -0
  758. moolabs/models/flatamount.py +152 -0
  759. moolabs/models/freshness_axis.py +121 -0
  760. moolabs/models/freshness_source.py +40 -0
  761. moolabs/models/fx_rate_to_reporting.py +153 -0
  762. moolabs/models/fx_rates_list_response.py +97 -0
  763. moolabs/models/gate_status_response.py +105 -0
  764. moolabs/models/get_fx_rate_request.py +92 -0
  765. moolabs/models/get_matrix_price_rows_response.py +107 -0
  766. moolabs/models/google_chat_quote_response.py +89 -0
  767. moolabs/models/grant_activation_request.py +122 -0
  768. moolabs/models/grant_burn_down_history_segment.py +125 -0
  769. moolabs/models/grant_order_by.py +38 -0
  770. moolabs/models/grant_paginated_response.py +101 -0
  771. moolabs/models/grant_plan_change_request.py +126 -0
  772. moolabs/models/grant_renewal_request.py +122 -0
  773. moolabs/models/grant_response.py +128 -0
  774. moolabs/models/grant_source_type.py +40 -0
  775. moolabs/models/grant_usage_record.py +97 -0
  776. moolabs/models/grant_v2_paginated_response.py +101 -0
  777. moolabs/models/grants_list_response.py +99 -0
  778. moolabs/models/handoff_create_request.py +92 -0
  779. moolabs/models/helicone_config_request.py +92 -0
  780. moolabs/models/homepage_response.py +107 -0
  781. moolabs/models/hosted_checkout_settlement_ptp_response.py +100 -0
  782. moolabs/models/hosted_checkout_settlement_request.py +109 -0
  783. moolabs/models/hosted_checkout_settlement_response.py +97 -0
  784. moolabs/models/http_validation_error.py +95 -0
  785. moolabs/models/hub_spot_connect_request.py +91 -0
  786. moolabs/models/id_resource.py +97 -0
  787. moolabs/models/identity_scope.py +39 -0
  788. moolabs/models/identity_scope_coverage_response.py +96 -0
  789. moolabs/models/import_batch_detail_response.py +105 -0
  790. moolabs/models/import_batch_detail_row.py +111 -0
  791. moolabs/models/import_batch_request.py +112 -0
  792. moolabs/models/import_batch_response.py +101 -0
  793. moolabs/models/import_batch_summary.py +111 -0
  794. moolabs/models/import_dispute_item.py +122 -0
  795. moolabs/models/import_disputes_request.py +96 -0
  796. moolabs/models/import_invoice_item.py +133 -0
  797. moolabs/models/import_invoices_request.py +96 -0
  798. moolabs/models/import_promise_item.py +155 -0
  799. moolabs/models/import_promises_request.py +96 -0
  800. moolabs/models/inbound_email_attachment.py +91 -0
  801. moolabs/models/inbound_email_payload.py +103 -0
  802. moolabs/models/inbound_email_process_response.py +97 -0
  803. moolabs/models/ingest_events_body.py +150 -0
  804. moolabs/models/ingest_health.py +97 -0
  805. moolabs/models/ingested_event.py +111 -0
  806. moolabs/models/ingested_event_cursor_paginated_response.py +98 -0
  807. moolabs/models/initialamount.py +152 -0
  808. moolabs/models/insight_card.py +111 -0
  809. moolabs/models/install_method.py +38 -0
  810. moolabs/models/integration_update.py +89 -0
  811. moolabs/models/invalidate_portal_token_request.py +89 -0
  812. moolabs/models/invalidate_portal_tokens_request.py +89 -0
  813. moolabs/models/invoice.py +249 -0
  814. moolabs/models/invoice_allocation_out.py +103 -0
  815. moolabs/models/invoice_app_external_ids.py +97 -0
  816. moolabs/models/invoice_available_action_details.py +89 -0
  817. moolabs/models/invoice_available_actions.py +132 -0
  818. moolabs/models/invoice_detailed_line.py +244 -0
  819. moolabs/models/invoice_detailed_line_cost_category.py +37 -0
  820. moolabs/models/invoice_detailed_line_rate_card.py +116 -0
  821. moolabs/models/invoice_document_ref_type.py +36 -0
  822. moolabs/models/invoice_expand.py +38 -0
  823. moolabs/models/invoice_generic_document_ref.py +98 -0
  824. moolabs/models/invoice_item.py +112 -0
  825. moolabs/models/invoice_line.py +296 -0
  826. moolabs/models/invoice_line_amount_discount.py +141 -0
  827. moolabs/models/invoice_line_app_external_ids.py +93 -0
  828. moolabs/models/invoice_line_discounts.py +105 -0
  829. moolabs/models/invoice_line_managed_by.py +38 -0
  830. moolabs/models/invoice_line_out.py +99 -0
  831. moolabs/models/invoice_line_replace_update.py +143 -0
  832. moolabs/models/invoice_line_status.py +38 -0
  833. moolabs/models/invoice_line_subscription_reference.py +115 -0
  834. moolabs/models/invoice_line_tax_behavior.py +37 -0
  835. moolabs/models/invoice_line_tax_item.py +117 -0
  836. moolabs/models/invoice_line_usage_discount.py +155 -0
  837. moolabs/models/invoice_order_by.py +41 -0
  838. moolabs/models/invoice_paginated_response.py +101 -0
  839. moolabs/models/invoice_payment_terms.py +91 -0
  840. moolabs/models/invoice_pending_line_create.py +131 -0
  841. moolabs/models/invoice_pending_line_create_input.py +105 -0
  842. moolabs/models/invoice_pending_line_create_response.py +107 -0
  843. moolabs/models/invoice_pending_lines_action_filters_input.py +88 -0
  844. moolabs/models/invoice_pending_lines_action_input.py +106 -0
  845. moolabs/models/invoice_reference.py +101 -0
  846. moolabs/models/invoice_replace_update.py +117 -0
  847. moolabs/models/invoice_simulation_input.py +107 -0
  848. moolabs/models/invoice_simulation_line.py +164 -0
  849. moolabs/models/invoice_status.py +44 -0
  850. moolabs/models/invoice_status_details.py +103 -0
  851. moolabs/models/invoice_totals.py +163 -0
  852. moolabs/models/invoice_type.py +37 -0
  853. moolabs/models/invoice_upsert_request.py +112 -0
  854. moolabs/models/invoice_usage_based_rate_card.py +116 -0
  855. moolabs/models/invoice_workflow_invoicing_settings_replace_update.py +97 -0
  856. moolabs/models/invoice_workflow_replace_update.py +91 -0
  857. moolabs/models/invoice_workflow_settings.py +111 -0
  858. moolabs/models/invoice_workflow_settings_replace_update.py +97 -0
  859. moolabs/models/issue_after_reset.py +90 -0
  860. moolabs/models/jurisdiction_profile_response.py +102 -0
  861. moolabs/models/jurisdiction_resolution_request.py +92 -0
  862. moolabs/models/kill_switch_request.py +87 -0
  863. moolabs/models/langfuse_config_request.py +92 -0
  864. moolabs/models/lesson_action_request.py +89 -0
  865. moolabs/models/level_in.py +91 -0
  866. moolabs/models/lifecycle_event_request.py +97 -0
  867. moolabs/models/line_item_create.py +118 -0
  868. moolabs/models/line_total.py +153 -0
  869. moolabs/models/link_net_suite_account_request.py +89 -0
  870. moolabs/models/list_auto_topup_rules_response.py +97 -0
  871. moolabs/models/list_connectors200_response_inner.py +148 -0
  872. moolabs/models/list_entitlements_result.py +151 -0
  873. moolabs/models/list_events_v2_filter_param.py +123 -0
  874. moolabs/models/list_features_result.py +151 -0
  875. moolabs/models/list_grants_get200_response.py +151 -0
  876. moolabs/models/mapping_response.py +97 -0
  877. moolabs/models/mapping_rule_create.py +105 -0
  878. moolabs/models/mapping_rule_response.py +118 -0
  879. moolabs/models/mapping_rule_update.py +103 -0
  880. moolabs/models/margin_snapshot_response.py +131 -0
  881. moolabs/models/marketplace_app_api_key_install_request.py +91 -0
  882. moolabs/models/marketplace_install_request_payload.py +89 -0
  883. moolabs/models/marketplace_install_response.py +94 -0
  884. moolabs/models/marketplace_listing.py +105 -0
  885. moolabs/models/marketplace_listing_paginated_response.py +101 -0
  886. moolabs/models/matrix_price_row.py +91 -0
  887. moolabs/models/measure.py +146 -0
  888. moolabs/models/measure_kind.py +41 -0
  889. moolabs/models/measure_usage_from.py +151 -0
  890. moolabs/models/measure_usage_from_preset.py +37 -0
  891. moolabs/models/merge_remittances_request.py +89 -0
  892. moolabs/models/meter.py +176 -0
  893. moolabs/models/meter_aggregation.py +42 -0
  894. moolabs/models/meter_create.py +113 -0
  895. moolabs/models/meter_mapping_item.py +95 -0
  896. moolabs/models/meter_order_by.py +40 -0
  897. moolabs/models/meter_query_request.py +121 -0
  898. moolabs/models/meter_query_result.py +103 -0
  899. moolabs/models/meter_query_row.py +98 -0
  900. moolabs/models/meter_test_event_request.py +87 -0
  901. moolabs/models/meter_test_event_response.py +93 -0
  902. moolabs/models/meter_update.py +94 -0
  903. moolabs/models/meter_usage_summary_item.py +103 -0
  904. moolabs/models/meter_usage_summary_response.py +95 -0
  905. moolabs/models/meter_validation_error.py +101 -0
  906. moolabs/models/migrate_subscription_request.py +105 -0
  907. moolabs/models/model_cost_item.py +95 -0
  908. moolabs/models/net_suite_connect_request.py +103 -0
  909. moolabs/models/net_suite_cutover_guard_request.py +87 -0
  910. moolabs/models/net_suite_m2_m_finalize_request.py +87 -0
  911. moolabs/models/net_suite_m2_m_setup_request.py +101 -0
  912. moolabs/models/net_suite_managed_portal_backfill_cancel_request.py +87 -0
  913. moolabs/models/net_suite_managed_portal_backfill_request.py +89 -0
  914. moolabs/models/net_suite_managed_portal_backfill_run_request.py +90 -0
  915. moolabs/models/net_suite_managed_portal_mapping_delete_request.py +91 -0
  916. moolabs/models/net_suite_managed_portal_mapping_request.py +97 -0
  917. moolabs/models/net_suite_managed_portal_protection_ack_request.py +89 -0
  918. moolabs/models/next_action_type.py +41 -0
  919. moolabs/models/note_create.py +94 -0
  920. moolabs/models/note_list_response.py +101 -0
  921. moolabs/models/note_response.py +104 -0
  922. moolabs/models/notification_channel_meta.py +100 -0
  923. moolabs/models/notification_channel_order_by.py +39 -0
  924. moolabs/models/notification_channel_paginated_response.py +101 -0
  925. moolabs/models/notification_channel_type.py +36 -0
  926. moolabs/models/notification_channel_webhook.py +145 -0
  927. moolabs/models/notification_channel_webhook_create_request.py +117 -0
  928. moolabs/models/notification_event.py +137 -0
  929. moolabs/models/notification_event_balance_threshold_payload.py +121 -0
  930. moolabs/models/notification_event_balance_threshold_payload_data.py +133 -0
  931. moolabs/models/notification_event_delivery_attempt.py +103 -0
  932. moolabs/models/notification_event_delivery_status.py +125 -0
  933. moolabs/models/notification_event_delivery_status_state.py +40 -0
  934. moolabs/models/notification_event_entitlement_value_payload_base.py +125 -0
  935. moolabs/models/notification_event_invoice_created_payload.py +121 -0
  936. moolabs/models/notification_event_invoice_updated_payload.py +121 -0
  937. moolabs/models/notification_event_order_by.py +37 -0
  938. moolabs/models/notification_event_paginated_response.py +101 -0
  939. moolabs/models/notification_event_payload.py +178 -0
  940. moolabs/models/notification_event_resend_request.py +88 -0
  941. moolabs/models/notification_event_reset_payload.py +121 -0
  942. moolabs/models/notification_event_type.py +39 -0
  943. moolabs/models/notification_rule.py +178 -0
  944. moolabs/models/notification_rule_balance_threshold.py +159 -0
  945. moolabs/models/notification_rule_balance_threshold_create_request.py +115 -0
  946. moolabs/models/notification_rule_balance_threshold_value.py +90 -0
  947. moolabs/models/notification_rule_balance_threshold_value_type.py +40 -0
  948. moolabs/models/notification_rule_create_request.py +178 -0
  949. moolabs/models/notification_rule_entitlement_reset.py +149 -0
  950. moolabs/models/notification_rule_entitlement_reset_create_request.py +105 -0
  951. moolabs/models/notification_rule_invoice_created.py +139 -0
  952. moolabs/models/notification_rule_invoice_created_create_request.py +103 -0
  953. moolabs/models/notification_rule_invoice_updated.py +139 -0
  954. moolabs/models/notification_rule_invoice_updated_create_request.py +103 -0
  955. moolabs/models/notification_rule_order_by.py +39 -0
  956. moolabs/models/notification_rule_paginated_response.py +101 -0
  957. moolabs/models/notify_channel.py +89 -0
  958. moolabs/models/o_auth2_authorization_code_grant_error_type.py +42 -0
  959. moolabs/models/observation_out.py +103 -0
  960. moolabs/models/observed_total_cost.py +153 -0
  961. moolabs/models/open_cost_cluster_binding.py +115 -0
  962. moolabs/models/open_cost_dedicated_namespace.py +104 -0
  963. moolabs/models/open_cost_installation_create_request.py +122 -0
  964. moolabs/models/open_cost_installation_create_response.py +116 -0
  965. moolabs/models/open_cost_installation_response.py +114 -0
  966. moolabs/models/open_cost_snapshot_request.py +139 -0
  967. moolabs/models/open_cost_snapshot_response.py +125 -0
  968. moolabs/models/open_cost_trust_policy.py +145 -0
  969. moolabs/models/open_cost_wire_row.py +140 -0
  970. moolabs/models/open_from_scope_request.py +98 -0
  971. moolabs/models/operations_summary.py +120 -0
  972. moolabs/models/opt_out_request.py +90 -0
  973. moolabs/models/opt_out_response.py +93 -0
  974. moolabs/models/org_role.py +152 -0
  975. moolabs/models/original_total.py +152 -0
  976. moolabs/models/otlp_ingest_response.py +91 -0
  977. moolabs/models/overall_freshness.py +116 -0
  978. moolabs/models/overdraft_settings.py +93 -0
  979. moolabs/models/overdraft_settings_payload.py +93 -0
  980. moolabs/models/override_first_ingress_request.py +94 -0
  981. moolabs/models/override_request.py +90 -0
  982. moolabs/models/override_response.py +91 -0
  983. moolabs/models/overview_response.py +109 -0
  984. moolabs/models/pack_provenance.py +101 -0
  985. moolabs/models/package_price_with_commitments.py +137 -0
  986. moolabs/models/paginated_credit_memos.py +97 -0
  987. moolabs/models/paginated_customers.py +99 -0
  988. moolabs/models/paginated_invoices.py +97 -0
  989. moolabs/models/paginated_payments.py +97 -0
  990. moolabs/models/paginated_sync_runs.py +97 -0
  991. moolabs/models/patch_quote_agent_policy_request.py +98 -0
  992. moolabs/models/patch_rows_request.py +95 -0
  993. moolabs/models/patch_session_request.py +107 -0
  994. moolabs/models/payment_allocation_response.py +104 -0
  995. moolabs/models/payment_create.py +109 -0
  996. moolabs/models/payment_due_date.py +124 -0
  997. moolabs/models/payment_failed_request.py +101 -0
  998. moolabs/models/payment_failed_response.py +93 -0
  999. moolabs/models/payment_instructions_response.py +95 -0
  1000. moolabs/models/payment_instructions_update_request.py +90 -0
  1001. moolabs/models/payment_item.py +104 -0
  1002. moolabs/models/payment_link_request.py +105 -0
  1003. moolabs/models/payment_link_response.py +89 -0
  1004. moolabs/models/payment_list_response.py +101 -0
  1005. moolabs/models/payment_match_request.py +90 -0
  1006. moolabs/models/payment_response.py +136 -0
  1007. moolabs/models/payment_reversal_request.py +90 -0
  1008. moolabs/models/payment_succeeded_request.py +103 -0
  1009. moolabs/models/payment_succeeded_response.py +97 -0
  1010. moolabs/models/payment_term_due_date.py +113 -0
  1011. moolabs/models/payment_term_instant.py +102 -0
  1012. moolabs/models/payment_terms.py +148 -0
  1013. moolabs/models/pending_provider_confirmation_reconcile_request.py +88 -0
  1014. moolabs/models/pending_sns_confirmation_out.py +102 -0
  1015. moolabs/models/period.py +90 -0
  1016. moolabs/models/period_settlement_out.py +143 -0
  1017. moolabs/models/period_window.py +103 -0
  1018. moolabs/models/persona.py +39 -0
  1019. moolabs/models/plan.py +191 -0
  1020. moolabs/models/plan_addon.py +126 -0
  1021. moolabs/models/plan_addon_create.py +101 -0
  1022. moolabs/models/plan_addon_order_by.py +40 -0
  1023. moolabs/models/plan_addon_paginated_response.py +101 -0
  1024. moolabs/models/plan_addon_replace_update.py +91 -0
  1025. moolabs/models/plan_amend_request.py +103 -0
  1026. moolabs/models/plan_cost_item.py +97 -0
  1027. moolabs/models/plan_create.py +140 -0
  1028. moolabs/models/plan_create_request.py +103 -0
  1029. moolabs/models/plan_order_by.py +40 -0
  1030. moolabs/models/plan_paginated_response.py +101 -0
  1031. moolabs/models/plan_phase.py +113 -0
  1032. moolabs/models/plan_pricing_input.py +103 -0
  1033. moolabs/models/plan_pricing_sync_request.py +105 -0
  1034. moolabs/models/plan_pricing_view.py +107 -0
  1035. moolabs/models/plan_ref_payload.py +91 -0
  1036. moolabs/models/plan_reference.py +106 -0
  1037. moolabs/models/plan_reference_input.py +97 -0
  1038. moolabs/models/plan_replace_update.py +122 -0
  1039. moolabs/models/plan_status.py +39 -0
  1040. moolabs/models/plan_subscription_change.py +153 -0
  1041. moolabs/models/plan_subscription_create.py +167 -0
  1042. moolabs/models/policy_update_request.py +94 -0
  1043. moolabs/models/pool_notification_config_request.py +87 -0
  1044. moolabs/models/pooloverrides_value.py +152 -0
  1045. moolabs/models/portal_case_response.py +108 -0
  1046. moolabs/models/portal_channel_preference_request.py +100 -0
  1047. moolabs/models/portal_dispute_request.py +94 -0
  1048. moolabs/models/portal_dispute_response.py +102 -0
  1049. moolabs/models/portal_invoice_response.py +124 -0
  1050. moolabs/models/portal_payment_intent_response.py +91 -0
  1051. moolabs/models/portal_payment_request.py +102 -0
  1052. moolabs/models/portal_preferences_request.py +113 -0
  1053. moolabs/models/portal_preferences_response.py +87 -0
  1054. moolabs/models/portal_promise_to_pay_response.py +106 -0
  1055. moolabs/models/portal_ptp_request.py +95 -0
  1056. moolabs/models/portal_token.py +121 -0
  1057. moolabs/models/portal_token_item.py +97 -0
  1058. moolabs/models/preview_resolution_request.py +89 -0
  1059. moolabs/models/preview_resolution_response.py +101 -0
  1060. moolabs/models/preview_template_request.py +102 -0
  1061. moolabs/models/preview_template_response.py +95 -0
  1062. moolabs/models/preview_trace_entry.py +97 -0
  1063. moolabs/models/previous.py +152 -0
  1064. moolabs/models/price_payment_term.py +37 -0
  1065. moolabs/models/price_session_response.py +109 -0
  1066. moolabs/models/price_tier.py +110 -0
  1067. moolabs/models/price_tier_payload.py +103 -0
  1068. moolabs/models/pricing_override_input.py +100 -0
  1069. moolabs/models/pricing_result.py +100 -0
  1070. moolabs/models/pricing_snapshot_response.py +109 -0
  1071. moolabs/models/pricing_tier_input.py +90 -0
  1072. moolabs/models/priority.py +38 -0
  1073. moolabs/models/pro_rating_config.py +90 -0
  1074. moolabs/models/pro_rating_mode.py +36 -0
  1075. moolabs/models/process_value_recognition_request.py +94 -0
  1076. moolabs/models/progress.py +94 -0
  1077. moolabs/models/projection_link_in.py +91 -0
  1078. moolabs/models/projection_links_request.py +98 -0
  1079. moolabs/models/projection_links_response.py +89 -0
  1080. moolabs/models/promise_response.py +112 -0
  1081. moolabs/models/promote_response.py +89 -0
  1082. moolabs/models/provider_billing_reference.py +146 -0
  1083. moolabs/models/provider_billing_reference_kind.py +37 -0
  1084. moolabs/models/provider_blocking_reason.py +115 -0
  1085. moolabs/models/provider_confirmation_repair_request.py +99 -0
  1086. moolabs/models/provider_connection_status.py +42 -0
  1087. moolabs/models/provider_identity_details.py +110 -0
  1088. moolabs/models/provider_identity_purpose.py +38 -0
  1089. moolabs/models/provider_kind.py +37 -0
  1090. moolabs/models/provider_readiness_response.py +97 -0
  1091. moolabs/models/provider_readiness_summary.py +123 -0
  1092. moolabs/models/provider_route_status.py +39 -0
  1093. moolabs/models/provider_safe_test_send_request.py +107 -0
  1094. moolabs/models/provider_safe_test_send_response.py +109 -0
  1095. moolabs/models/provider_summary.py +89 -0
  1096. moolabs/models/provider_warning.py +115 -0
  1097. moolabs/models/ptp_approval_request.py +88 -0
  1098. moolabs/models/ptp_create_request.py +103 -0
  1099. moolabs/models/ptp_fulfill_request.py +90 -0
  1100. moolabs/models/ptp_payment_link_response.py +89 -0
  1101. moolabs/models/ptp_summary_response.py +104 -0
  1102. moolabs/models/publish_plan_request.py +93 -0
  1103. moolabs/models/publish_plan_result.py +93 -0
  1104. moolabs/models/publish_template_request.py +96 -0
  1105. moolabs/models/put_account_segment_request.py +89 -0
  1106. moolabs/models/put_sku_eligibility_request.py +89 -0
  1107. moolabs/models/put_tenant_segments_request.py +89 -0
  1108. moolabs/models/quality_axis.py +116 -0
  1109. moolabs/models/quality_caveat_code.py +40 -0
  1110. moolabs/models/quality_status.py +40 -0
  1111. moolabs/models/quality_summary.py +135 -0
  1112. moolabs/models/quantity.py +153 -0
  1113. moolabs/models/quick_action.py +99 -0
  1114. moolabs/models/quick_books_connect_request.py +93 -0
  1115. moolabs/models/quick_redline_response.py +123 -0
  1116. moolabs/models/quote_agent_evaluation_response.py +106 -0
  1117. moolabs/models/quote_agent_policy_response.py +112 -0
  1118. moolabs/models/quote_agent_provenance_run_response.py +114 -0
  1119. moolabs/models/quote_agent_run_response.py +122 -0
  1120. moolabs/models/quote_approval_decision_request.py +88 -0
  1121. moolabs/models/quote_approval_response.py +107 -0
  1122. moolabs/models/quote_line_item_input.py +144 -0
  1123. moolabs/models/quote_list_response.py +101 -0
  1124. moolabs/models/quote_metrics_response.py +105 -0
  1125. moolabs/models/quote_redline_decision_request.py +88 -0
  1126. moolabs/models/quote_redline_response.py +125 -0
  1127. moolabs/models/quote_response.py +125 -0
  1128. moolabs/models/quote_template_list_response.py +95 -0
  1129. moolabs/models/quote_template_response.py +109 -0
  1130. moolabs/models/quote_version_response.py +129 -0
  1131. moolabs/models/ram_cost_weight.py +152 -0
  1132. moolabs/models/ram_gib_hours.py +152 -0
  1133. moolabs/models/rate_bulk_import_request.py +97 -0
  1134. moolabs/models/rate_bulk_import_response.py +91 -0
  1135. moolabs/models/rate_card.py +150 -0
  1136. moolabs/models/rate_card_boolean_entitlement.py +96 -0
  1137. moolabs/models/rate_card_cost_list_response.py +95 -0
  1138. moolabs/models/rate_card_cost_row.py +103 -0
  1139. moolabs/models/rate_card_discount.py +87 -0
  1140. moolabs/models/rate_card_discount_input.py +103 -0
  1141. moolabs/models/rate_card_discount_payload.py +87 -0
  1142. moolabs/models/rate_card_entitlement.py +164 -0
  1143. moolabs/models/rate_card_flat_fee.py +148 -0
  1144. moolabs/models/rate_card_metered_entitlement.py +107 -0
  1145. moolabs/models/rate_card_payload.py +103 -0
  1146. moolabs/models/rate_card_response.py +106 -0
  1147. moolabs/models/rate_card_static_entitlement.py +98 -0
  1148. moolabs/models/rate_card_usage_based.py +148 -0
  1149. moolabs/models/rate_card_usage_based_price.py +192 -0
  1150. moolabs/models/rate_catalog_create.py +117 -0
  1151. moolabs/models/rate_catalog_response.py +118 -0
  1152. moolabs/models/rate_catalog_update.py +107 -0
  1153. moolabs/models/rate_generation_list_view.py +97 -0
  1154. moolabs/models/rate_generation_view.py +98 -0
  1155. moolabs/models/rate_per_unit.py +153 -0
  1156. moolabs/models/rate_per_unit1.py +153 -0
  1157. moolabs/models/rate_schedule_list_response.py +95 -0
  1158. moolabs/models/rate_schedule_preview_response.py +105 -0
  1159. moolabs/models/rate_schedule_version_out.py +101 -0
  1160. moolabs/models/ratify_family_request.py +91 -0
  1161. moolabs/models/ratify_refinement_request.py +93 -0
  1162. moolabs/models/re_scope_request.py +89 -0
  1163. moolabs/models/readiness_summary.py +89 -0
  1164. moolabs/models/readout_page_response.py +119 -0
  1165. moolabs/models/readout_row_response.py +104 -0
  1166. moolabs/models/readout_snapshot_response.py +116 -0
  1167. moolabs/models/reallocate_request.py +90 -0
  1168. moolabs/models/reallocate_response.py +97 -0
  1169. moolabs/models/reattempt_request.py +88 -0
  1170. moolabs/models/reattempt_response.py +89 -0
  1171. moolabs/models/recall_request.py +87 -0
  1172. moolabs/models/reconcile_request.py +89 -0
  1173. moolabs/models/reconcile_response.py +95 -0
  1174. moolabs/models/reconciliation_basis.py +99 -0
  1175. moolabs/models/reconciliation_basis_out.py +95 -0
  1176. moolabs/models/reconstruction_run_response.py +95 -0
  1177. moolabs/models/record_usage_request.py +115 -0
  1178. moolabs/models/recurring_period.py +96 -0
  1179. moolabs/models/recurring_period_create_input.py +94 -0
  1180. moolabs/models/recurring_period_interval.py +151 -0
  1181. moolabs/models/recurring_period_interval_enum.py +39 -0
  1182. moolabs/models/recurring_period_v2.py +94 -0
  1183. moolabs/models/recurringamount.py +152 -0
  1184. moolabs/models/redline_summary.py +89 -0
  1185. moolabs/models/refund_credit_request.py +90 -0
  1186. moolabs/models/reject_rate_generation_request.py +87 -0
  1187. moolabs/models/remittance_create_request.py +103 -0
  1188. moolabs/models/remittance_list_response.py +101 -0
  1189. moolabs/models/remittance_response.py +120 -0
  1190. moolabs/models/remove_contract_participant_response.py +131 -0
  1191. moolabs/models/remove_phase_shifting.py +37 -0
  1192. moolabs/models/replace_levels_request.py +95 -0
  1193. moolabs/models/replay_dead_letter_request.py +89 -0
  1194. moolabs/models/report_create_request.py +105 -0
  1195. moolabs/models/report_create_response.py +139 -0
  1196. moolabs/models/reporting_line_total.py +153 -0
  1197. moolabs/models/reporting_total_cost.py +153 -0
  1198. moolabs/models/request_cost_distribution.py +127 -0
  1199. moolabs/models/request_evidence_response.py +197 -0
  1200. moolabs/models/request_evidence_row.py +154 -0
  1201. moolabs/models/request_pricing_state.py +40 -0
  1202. moolabs/models/reschedule_request.py +88 -0
  1203. moolabs/models/resend_identity_details.py +104 -0
  1204. moolabs/models/reset_entitlement_usage_input.py +92 -0
  1205. moolabs/models/resolve_unapplied_request.py +87 -0
  1206. moolabs/models/resource_map_create_request.py +103 -0
  1207. moolabs/models/resource_map_response.py +113 -0
  1208. moolabs/models/retry_unpriced_request.py +91 -0
  1209. moolabs/models/retry_unpriced_response.py +91 -0
  1210. moolabs/models/revenue_recognition_request.py +89 -0
  1211. moolabs/models/reversed_settlement_ref.py +93 -0
  1212. moolabs/models/review_quarantined_request.py +95 -0
  1213. moolabs/models/review_quarantined_response.py +95 -0
  1214. moolabs/models/revoke_api_key_request.py +87 -0
  1215. moolabs/models/revoke_portal_token_request.py +87 -0
  1216. moolabs/models/rollover_mode.py +38 -0
  1217. moolabs/models/rollover_request.py +95 -0
  1218. moolabs/models/rollover_response.py +98 -0
  1219. moolabs/models/rollovercapamount.py +152 -0
  1220. moolabs/models/rolloverpercent.py +152 -0
  1221. moolabs/models/rotate_key_request.py +88 -0
  1222. moolabs/models/rotate_key_response.py +92 -0
  1223. moolabs/models/route_update_request.py +110 -0
  1224. moolabs/models/salesforce_connect_request.py +93 -0
  1225. moolabs/models/sample_rate.py +153 -0
  1226. moolabs/models/sandbox_app.py +138 -0
  1227. moolabs/models/sandbox_app_replace_update.py +101 -0
  1228. moolabs/models/sandbox_customer_app_data.py +115 -0
  1229. moolabs/models/save_redline_edit_request.py +95 -0
  1230. moolabs/models/scenario_compare_response.py +97 -0
  1231. moolabs/models/scenario_item.py +117 -0
  1232. moolabs/models/scenario_request.py +96 -0
  1233. moolabs/models/scope_type.py +38 -0
  1234. moolabs/models/sdk_batch_ingest_request.py +96 -0
  1235. moolabs/models/sdk_batch_ingest_response.py +91 -0
  1236. moolabs/models/sdk_event.py +111 -0
  1237. moolabs/models/sdk_span.py +106 -0
  1238. moolabs/models/segment_out.py +95 -0
  1239. moolabs/models/sender_response.py +93 -0
  1240. moolabs/models/sender_update.py +93 -0
  1241. moolabs/models/ses_identity_details.py +127 -0
  1242. moolabs/models/ses_provider_scope_status.py +89 -0
  1243. moolabs/models/set_rate_card_cost_request.py +89 -0
  1244. moolabs/models/severity.py +38 -0
  1245. moolabs/models/shadow_mode_request.py +87 -0
  1246. moolabs/models/shadow_run_list_item.py +101 -0
  1247. moolabs/models/shadow_run_metrics.py +114 -0
  1248. moolabs/models/shadow_run_request.py +92 -0
  1249. moolabs/models/shadow_run_summary.py +95 -0
  1250. moolabs/models/simulate_margin_request.py +100 -0
  1251. moolabs/models/simulate_margin_response.py +115 -0
  1252. moolabs/models/simulate_out.py +103 -0
  1253. moolabs/models/sku_eligibility_list_response.py +95 -0
  1254. moolabs/models/sku_eligibility_row.py +91 -0
  1255. moolabs/models/slack_quote_command_response.py +93 -0
  1256. moolabs/models/snapshot_compute_request.py +104 -0
  1257. moolabs/models/snapshot_compute_response.py +99 -0
  1258. moolabs/models/snapshot_response.py +104 -0
  1259. moolabs/models/sns_confirmation_command_out.py +98 -0
  1260. moolabs/models/sns_confirmation_confirmed_out.py +94 -0
  1261. moolabs/models/sns_confirmation_confirmed_request.py +101 -0
  1262. moolabs/models/sns_confirmation_list_out.py +95 -0
  1263. moolabs/models/sort_direction.py +37 -0
  1264. moolabs/models/sort_order.py +37 -0
  1265. moolabs/models/spend_summary.py +114 -0
  1266. moolabs/models/stage_schema.py +117 -0
  1267. moolabs/models/strategy_create_request.py +130 -0
  1268. moolabs/models/strategy_preview_request.py +87 -0
  1269. moolabs/models/strategy_update_request.py +133 -0
  1270. moolabs/models/stripe_api_key_input.py +87 -0
  1271. moolabs/models/stripe_app.py +150 -0
  1272. moolabs/models/stripe_app_replace_update.py +103 -0
  1273. moolabs/models/stripe_checkout_session_mode.py +36 -0
  1274. moolabs/models/stripe_customer_app_data.py +119 -0
  1275. moolabs/models/stripe_customer_app_data_base.py +89 -0
  1276. moolabs/models/stripe_customer_app_data_create_or_update_item.py +111 -0
  1277. moolabs/models/stripe_customer_portal_session.py +102 -0
  1278. moolabs/models/stripe_tax_config.py +95 -0
  1279. moolabs/models/stripe_webhook_event.py +99 -0
  1280. moolabs/models/stripe_webhook_event_data.py +92 -0
  1281. moolabs/models/stripe_webhook_response.py +118 -0
  1282. moolabs/models/subject.py +122 -0
  1283. moolabs/models/subject_upsert.py +98 -0
  1284. moolabs/models/subscription.py +201 -0
  1285. moolabs/models/subscription_activate_request.py +101 -0
  1286. moolabs/models/subscription_addon.py +167 -0
  1287. moolabs/models/subscription_addon_create.py +106 -0
  1288. moolabs/models/subscription_addon_rate_card.py +94 -0
  1289. moolabs/models/subscription_addon_timeline_segment.py +95 -0
  1290. moolabs/models/subscription_addon_update.py +100 -0
  1291. moolabs/models/subscription_alignment.py +93 -0
  1292. moolabs/models/subscription_bad_request_error_response.py +102 -0
  1293. moolabs/models/subscription_change.py +147 -0
  1294. moolabs/models/subscription_change_response_body.py +97 -0
  1295. moolabs/models/subscription_conflict_error_response.py +102 -0
  1296. moolabs/models/subscription_create.py +147 -0
  1297. moolabs/models/subscription_edit.py +102 -0
  1298. moolabs/models/subscription_edit_operation.py +206 -0
  1299. moolabs/models/subscription_error_extensions.py +95 -0
  1300. moolabs/models/subscription_expanded.py +211 -0
  1301. moolabs/models/subscription_item.py +167 -0
  1302. moolabs/models/subscription_item_included.py +97 -0
  1303. moolabs/models/subscription_item_price_override.py +111 -0
  1304. moolabs/models/subscription_item_price_override_type.py +37 -0
  1305. moolabs/models/subscription_paginated_response.py +101 -0
  1306. moolabs/models/subscription_phase_create.py +109 -0
  1307. moolabs/models/subscription_phase_expanded.py +163 -0
  1308. moolabs/models/subscription_ramp_phase.py +91 -0
  1309. moolabs/models/subscription_status.py +39 -0
  1310. moolabs/models/subscription_timing.py +151 -0
  1311. moolabs/models/subscription_timing_enum.py +37 -0
  1312. moolabs/models/sync_config_request.py +109 -0
  1313. moolabs/models/sync_config_response.py +111 -0
  1314. moolabs/models/sync_invoices_request.py +87 -0
  1315. moolabs/models/sync_run_item.py +102 -0
  1316. moolabs/models/synthetic_request_evidence_row.py +118 -0
  1317. moolabs/models/task_complete_request.py +92 -0
  1318. moolabs/models/task_list_response.py +101 -0
  1319. moolabs/models/task_response.py +130 -0
  1320. moolabs/models/task_update.py +93 -0
  1321. moolabs/models/tax_behavior.py +37 -0
  1322. moolabs/models/tax_config.py +100 -0
  1323. moolabs/models/template_archive_request.py +88 -0
  1324. moolabs/models/template_card_action_request.py +99 -0
  1325. moolabs/models/template_item.py +97 -0
  1326. moolabs/models/template_key_create_request.py +92 -0
  1327. moolabs/models/template_key_list_response.py +116 -0
  1328. moolabs/models/template_key_response.py +126 -0
  1329. moolabs/models/template_meta_response.py +93 -0
  1330. moolabs/models/template_preview_request.py +87 -0
  1331. moolabs/models/template_preview_response.py +101 -0
  1332. moolabs/models/template_test_send_request.py +87 -0
  1333. moolabs/models/template_test_send_response.py +93 -0
  1334. moolabs/models/template_update.py +91 -0
  1335. moolabs/models/template_version_list_response.py +95 -0
  1336. moolabs/models/template_version_response.py +143 -0
  1337. moolabs/models/tenant_config_response.py +95 -0
  1338. moolabs/models/tenant_escalation_config_out.py +97 -0
  1339. moolabs/models/tenant_escalation_config_patch.py +92 -0
  1340. moolabs/models/tenant_provision_request.py +89 -0
  1341. moolabs/models/tenant_segment_entry.py +89 -0
  1342. moolabs/models/tenant_segments_response.py +97 -0
  1343. moolabs/models/tenant_unit_economics.py +97 -0
  1344. moolabs/models/territory_in.py +89 -0
  1345. moolabs/models/test_send_request.py +104 -0
  1346. moolabs/models/test_send_response.py +93 -0
  1347. moolabs/models/tiered_price_mode.py +37 -0
  1348. moolabs/models/tiered_price_with_commitments.py +132 -0
  1349. moolabs/models/tiered_pricing_payload.py +97 -0
  1350. moolabs/models/timestamp_window.py +103 -0
  1351. moolabs/models/top_consumer.py +93 -0
  1352. moolabs/models/topup_defaults_request.py +93 -0
  1353. moolabs/models/total_cost.py +153 -0
  1354. moolabs/models/traces_response.py +95 -0
  1355. moolabs/models/trend_data_point.py +91 -0
  1356. moolabs/models/trend_point.py +116 -0
  1357. moolabs/models/trigger_request.py +87 -0
  1358. moolabs/models/ulidor_external_key.py +153 -0
  1359. moolabs/models/unapplied_cash_response.py +106 -0
  1360. moolabs/models/unavailable_reason.py +66 -0
  1361. moolabs/models/unexpected_problem_response.py +111 -0
  1362. moolabs/models/unified_price_row_input.py +99 -0
  1363. moolabs/models/unified_price_row_out.py +109 -0
  1364. moolabs/models/unit_cost.py +153 -0
  1365. moolabs/models/unit_economics.py +97 -0
  1366. moolabs/models/unit_price.py +104 -0
  1367. moolabs/models/unit_price_with_commitments.py +128 -0
  1368. moolabs/models/unitamount.py +152 -0
  1369. moolabs/models/update_approval_policy_request.py +87 -0
  1370. moolabs/models/update_auto_topup_rule_request.py +102 -0
  1371. moolabs/models/update_credit_pool_request.py +98 -0
  1372. moolabs/models/update_quote_template_request.py +102 -0
  1373. moolabs/models/update_threshold_request.py +97 -0
  1374. moolabs/models/update_wallet_settings_request.py +95 -0
  1375. moolabs/models/update_wallet_thresholds_request.py +92 -0
  1376. moolabs/models/upsert_fx_rate_request.py +92 -0
  1377. moolabs/models/upsert_provider_identity_request.py +115 -0
  1378. moolabs/models/upto.py +152 -0
  1379. moolabs/models/usage_summary_window_size.py +37 -0
  1380. moolabs/models/validate_template_request.py +116 -0
  1381. moolabs/models/validate_template_response.py +89 -0
  1382. moolabs/models/validation_error.py +99 -0
  1383. moolabs/models/validation_error_loc_inner.py +152 -0
  1384. moolabs/models/validation_issue.py +135 -0
  1385. moolabs/models/validation_issue_severity.py +37 -0
  1386. moolabs/models/validation_response.py +105 -0
  1387. moolabs/models/value_recognition_response.py +93 -0
  1388. moolabs/models/variance_decomposition_out.py +117 -0
  1389. moolabs/models/variance_summary_response.py +101 -0
  1390. moolabs/models/verification_status.py +39 -0
  1391. moolabs/models/void_grant_request.py +88 -0
  1392. moolabs/models/void_invoice_action_create.py +93 -0
  1393. moolabs/models/void_invoice_action_create_item.py +93 -0
  1394. moolabs/models/void_invoice_action_input.py +103 -0
  1395. moolabs/models/void_invoice_action_line_override.py +101 -0
  1396. moolabs/models/void_invoice_line_action_create.py +150 -0
  1397. moolabs/models/void_invoice_line_action_create_item.py +150 -0
  1398. moolabs/models/void_invoice_line_discard_action.py +94 -0
  1399. moolabs/models/void_invoice_line_pending_action_create.py +97 -0
  1400. moolabs/models/void_invoice_line_pending_action_create_item.py +97 -0
  1401. moolabs/models/volume_summary.py +114 -0
  1402. moolabs/models/wallet_owner_type.py +43 -0
  1403. moolabs/models/wallet_policy.py +38 -0
  1404. moolabs/models/wallet_response.py +112 -0
  1405. moolabs/models/wallet_state_response.py +105 -0
  1406. moolabs/models/warning_item.py +93 -0
  1407. moolabs/models/webhook_response.py +95 -0
  1408. moolabs/models/webhook_update.py +95 -0
  1409. moolabs/models/window_size.py +39 -0
  1410. moolabs/models/windowed_balance_history.py +105 -0
  1411. moolabs/models/xero_connect_request.py +91 -0
  1412. moolabs/py.typed +0 -0
  1413. moolabs/rest.py +257 -0
  1414. moolabs-0.3.0.dist-info/METADATA +31 -0
  1415. moolabs-0.3.0.dist-info/RECORD +1417 -0
  1416. moolabs-0.3.0.dist-info/WHEEL +5 -0
  1417. moolabs-0.3.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,4358 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ Moolabs API
5
+
6
+ Unified Moolabs SDK. Capability-based public surface stitched from internal service specs: bff, meter, arc, acute. Customers see capability namespaces (usage, billing, collections, etc.); the SDK routes per-operation internally.
7
+
8
+ The version of the OpenAPI document: 0.3.0
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """ # noqa: E501
13
+
14
+ import warnings
15
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
+ from typing import Any, Dict, List, Optional, Tuple, Union
17
+ from typing_extensions import Annotated
18
+
19
+ from datetime import datetime
20
+ from pydantic import Field, field_validator
21
+ from typing import List, Optional
22
+ from typing_extensions import Annotated
23
+ from moolabs.models.cancel_subscription_request import CancelSubscriptionRequest
24
+ from moolabs.models.customer_subscription_order_by import CustomerSubscriptionOrderBy
25
+ from moolabs.models.migrate_subscription_request import MigrateSubscriptionRequest
26
+ from moolabs.models.sort_order import SortOrder
27
+ from moolabs.models.subscription import Subscription
28
+ from moolabs.models.subscription_addon import SubscriptionAddon
29
+ from moolabs.models.subscription_addon_create import SubscriptionAddonCreate
30
+ from moolabs.models.subscription_addon_update import SubscriptionAddonUpdate
31
+ from moolabs.models.subscription_change import SubscriptionChange
32
+ from moolabs.models.subscription_change_response_body import SubscriptionChangeResponseBody
33
+ from moolabs.models.subscription_create import SubscriptionCreate
34
+ from moolabs.models.subscription_edit import SubscriptionEdit
35
+ from moolabs.models.subscription_expanded import SubscriptionExpanded
36
+ from moolabs.models.subscription_paginated_response import SubscriptionPaginatedResponse
37
+ from moolabs.models.subscription_status import SubscriptionStatus
38
+
39
+ from moolabs.api_client import ApiClient, RequestSerialized
40
+ from moolabs.api_response import ApiResponse
41
+ from moolabs.rest import RESTResponseType
42
+
43
+
44
+ class MeterSubscriptionsApi:
45
+ """NOTE: This class is auto generated by OpenAPI Generator
46
+ Ref: https://openapi-generator.tech
47
+
48
+ Do not edit the class manually.
49
+ """
50
+
51
+ def __init__(self, api_client=None) -> None:
52
+ if api_client is None:
53
+ api_client = ApiClient.get_default()
54
+ self.api_client = api_client
55
+
56
+
57
+ @validate_call
58
+ def cancel_subscription(
59
+ self,
60
+ subscription_id: Annotated[str, Field(strict=True)],
61
+ cancel_subscription_request: CancelSubscriptionRequest,
62
+ _request_timeout: Union[
63
+ None,
64
+ Annotated[StrictFloat, Field(gt=0)],
65
+ Tuple[
66
+ Annotated[StrictFloat, Field(gt=0)],
67
+ Annotated[StrictFloat, Field(gt=0)]
68
+ ]
69
+ ] = None,
70
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
71
+ _content_type: Optional[StrictStr] = None,
72
+ _headers: Optional[Dict[StrictStr, Any]] = None,
73
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
74
+ ) -> Subscription:
75
+ """Cancel subscription
76
+
77
+ Cancels the subscription. Will result in a scheduling conflict if there are other subscriptions scheduled to start after the cancellation time.
78
+
79
+ :param subscription_id: (required)
80
+ :type subscription_id: str
81
+ :param cancel_subscription_request: (required)
82
+ :type cancel_subscription_request: CancelSubscriptionRequest
83
+ :param _request_timeout: timeout setting for this request. If one
84
+ number provided, it will be total request
85
+ timeout. It can also be a pair (tuple) of
86
+ (connection, read) timeouts.
87
+ :type _request_timeout: int, tuple(int, int), optional
88
+ :param _request_auth: set to override the auth_settings for an a single
89
+ request; this effectively ignores the
90
+ authentication in the spec for a single request.
91
+ :type _request_auth: dict, optional
92
+ :param _content_type: force content-type for the request.
93
+ :type _content_type: str, Optional
94
+ :param _headers: set to override the headers for a single
95
+ request; this effectively ignores the headers
96
+ in the spec for a single request.
97
+ :type _headers: dict, optional
98
+ :param _host_index: set to override the host_index for a single
99
+ request; this effectively ignores the host_index
100
+ in the spec for a single request.
101
+ :type _host_index: int, optional
102
+ :return: Returns the result object.
103
+ """ # noqa: E501
104
+
105
+ _param = self._cancel_subscription_serialize(
106
+ subscription_id=subscription_id,
107
+ cancel_subscription_request=cancel_subscription_request,
108
+ _request_auth=_request_auth,
109
+ _content_type=_content_type,
110
+ _headers=_headers,
111
+ _host_index=_host_index
112
+ )
113
+
114
+ _response_types_map: Dict[str, Optional[str]] = {
115
+ '200': "Subscription",
116
+ '400': "SubscriptionBadRequestErrorResponse",
117
+ '401': "UnexpectedProblemResponse",
118
+ '403': "UnexpectedProblemResponse",
119
+ '404': "UnexpectedProblemResponse",
120
+ '409': "SubscriptionConflictErrorResponse",
121
+ '412': "UnexpectedProblemResponse",
122
+ '500': "UnexpectedProblemResponse",
123
+ '503': "UnexpectedProblemResponse",
124
+ }
125
+ response_data = self.api_client.call_api(
126
+ *_param,
127
+ _request_timeout=_request_timeout
128
+ )
129
+ response_data.read()
130
+ return self.api_client.response_deserialize(
131
+ response_data=response_data,
132
+ response_types_map=_response_types_map,
133
+ ).data
134
+
135
+
136
+ @validate_call
137
+ def cancel_subscription_with_http_info(
138
+ self,
139
+ subscription_id: Annotated[str, Field(strict=True)],
140
+ cancel_subscription_request: CancelSubscriptionRequest,
141
+ _request_timeout: Union[
142
+ None,
143
+ Annotated[StrictFloat, Field(gt=0)],
144
+ Tuple[
145
+ Annotated[StrictFloat, Field(gt=0)],
146
+ Annotated[StrictFloat, Field(gt=0)]
147
+ ]
148
+ ] = None,
149
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
150
+ _content_type: Optional[StrictStr] = None,
151
+ _headers: Optional[Dict[StrictStr, Any]] = None,
152
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
153
+ ) -> ApiResponse[Subscription]:
154
+ """Cancel subscription
155
+
156
+ Cancels the subscription. Will result in a scheduling conflict if there are other subscriptions scheduled to start after the cancellation time.
157
+
158
+ :param subscription_id: (required)
159
+ :type subscription_id: str
160
+ :param cancel_subscription_request: (required)
161
+ :type cancel_subscription_request: CancelSubscriptionRequest
162
+ :param _request_timeout: timeout setting for this request. If one
163
+ number provided, it will be total request
164
+ timeout. It can also be a pair (tuple) of
165
+ (connection, read) timeouts.
166
+ :type _request_timeout: int, tuple(int, int), optional
167
+ :param _request_auth: set to override the auth_settings for an a single
168
+ request; this effectively ignores the
169
+ authentication in the spec for a single request.
170
+ :type _request_auth: dict, optional
171
+ :param _content_type: force content-type for the request.
172
+ :type _content_type: str, Optional
173
+ :param _headers: set to override the headers for a single
174
+ request; this effectively ignores the headers
175
+ in the spec for a single request.
176
+ :type _headers: dict, optional
177
+ :param _host_index: set to override the host_index for a single
178
+ request; this effectively ignores the host_index
179
+ in the spec for a single request.
180
+ :type _host_index: int, optional
181
+ :return: Returns the result object.
182
+ """ # noqa: E501
183
+
184
+ _param = self._cancel_subscription_serialize(
185
+ subscription_id=subscription_id,
186
+ cancel_subscription_request=cancel_subscription_request,
187
+ _request_auth=_request_auth,
188
+ _content_type=_content_type,
189
+ _headers=_headers,
190
+ _host_index=_host_index
191
+ )
192
+
193
+ _response_types_map: Dict[str, Optional[str]] = {
194
+ '200': "Subscription",
195
+ '400': "SubscriptionBadRequestErrorResponse",
196
+ '401': "UnexpectedProblemResponse",
197
+ '403': "UnexpectedProblemResponse",
198
+ '404': "UnexpectedProblemResponse",
199
+ '409': "SubscriptionConflictErrorResponse",
200
+ '412': "UnexpectedProblemResponse",
201
+ '500': "UnexpectedProblemResponse",
202
+ '503': "UnexpectedProblemResponse",
203
+ }
204
+ response_data = self.api_client.call_api(
205
+ *_param,
206
+ _request_timeout=_request_timeout
207
+ )
208
+ response_data.read()
209
+ return self.api_client.response_deserialize(
210
+ response_data=response_data,
211
+ response_types_map=_response_types_map,
212
+ )
213
+
214
+
215
+ @validate_call
216
+ def cancel_subscription_without_preload_content(
217
+ self,
218
+ subscription_id: Annotated[str, Field(strict=True)],
219
+ cancel_subscription_request: CancelSubscriptionRequest,
220
+ _request_timeout: Union[
221
+ None,
222
+ Annotated[StrictFloat, Field(gt=0)],
223
+ Tuple[
224
+ Annotated[StrictFloat, Field(gt=0)],
225
+ Annotated[StrictFloat, Field(gt=0)]
226
+ ]
227
+ ] = None,
228
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
229
+ _content_type: Optional[StrictStr] = None,
230
+ _headers: Optional[Dict[StrictStr, Any]] = None,
231
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
232
+ ) -> RESTResponseType:
233
+ """Cancel subscription
234
+
235
+ Cancels the subscription. Will result in a scheduling conflict if there are other subscriptions scheduled to start after the cancellation time.
236
+
237
+ :param subscription_id: (required)
238
+ :type subscription_id: str
239
+ :param cancel_subscription_request: (required)
240
+ :type cancel_subscription_request: CancelSubscriptionRequest
241
+ :param _request_timeout: timeout setting for this request. If one
242
+ number provided, it will be total request
243
+ timeout. It can also be a pair (tuple) of
244
+ (connection, read) timeouts.
245
+ :type _request_timeout: int, tuple(int, int), optional
246
+ :param _request_auth: set to override the auth_settings for an a single
247
+ request; this effectively ignores the
248
+ authentication in the spec for a single request.
249
+ :type _request_auth: dict, optional
250
+ :param _content_type: force content-type for the request.
251
+ :type _content_type: str, Optional
252
+ :param _headers: set to override the headers for a single
253
+ request; this effectively ignores the headers
254
+ in the spec for a single request.
255
+ :type _headers: dict, optional
256
+ :param _host_index: set to override the host_index for a single
257
+ request; this effectively ignores the host_index
258
+ in the spec for a single request.
259
+ :type _host_index: int, optional
260
+ :return: Returns the result object.
261
+ """ # noqa: E501
262
+
263
+ _param = self._cancel_subscription_serialize(
264
+ subscription_id=subscription_id,
265
+ cancel_subscription_request=cancel_subscription_request,
266
+ _request_auth=_request_auth,
267
+ _content_type=_content_type,
268
+ _headers=_headers,
269
+ _host_index=_host_index
270
+ )
271
+
272
+ _response_types_map: Dict[str, Optional[str]] = {
273
+ '200': "Subscription",
274
+ '400': "SubscriptionBadRequestErrorResponse",
275
+ '401': "UnexpectedProblemResponse",
276
+ '403': "UnexpectedProblemResponse",
277
+ '404': "UnexpectedProblemResponse",
278
+ '409': "SubscriptionConflictErrorResponse",
279
+ '412': "UnexpectedProblemResponse",
280
+ '500': "UnexpectedProblemResponse",
281
+ '503': "UnexpectedProblemResponse",
282
+ }
283
+ response_data = self.api_client.call_api(
284
+ *_param,
285
+ _request_timeout=_request_timeout
286
+ )
287
+ return response_data.response
288
+
289
+
290
+ def _cancel_subscription_serialize(
291
+ self,
292
+ subscription_id,
293
+ cancel_subscription_request,
294
+ _request_auth,
295
+ _content_type,
296
+ _headers,
297
+ _host_index,
298
+ ) -> RequestSerialized:
299
+
300
+ _host = None
301
+
302
+ _collection_formats: Dict[str, str] = {
303
+ }
304
+
305
+ _path_params: Dict[str, str] = {}
306
+ _query_params: List[Tuple[str, str]] = []
307
+ _header_params: Dict[str, Optional[str]] = _headers or {}
308
+ _form_params: List[Tuple[str, str]] = []
309
+ _files: Dict[
310
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
311
+ ] = {}
312
+ _body_params: Optional[bytes] = None
313
+
314
+ # process the path parameters
315
+ if subscription_id is not None:
316
+ _path_params['subscriptionId'] = subscription_id
317
+ # process the query parameters
318
+ # process the header parameters
319
+ # process the form parameters
320
+ # process the body parameter
321
+ if cancel_subscription_request is not None:
322
+ _body_params = cancel_subscription_request
323
+
324
+
325
+ # set the HTTP header `Accept`
326
+ if 'Accept' not in _header_params:
327
+ _header_params['Accept'] = self.api_client.select_header_accept(
328
+ [
329
+ 'application/json',
330
+ 'application/problem+json'
331
+ ]
332
+ )
333
+
334
+ # set the HTTP header `Content-Type`
335
+ if _content_type:
336
+ _header_params['Content-Type'] = _content_type
337
+ else:
338
+ _default_content_type = (
339
+ self.api_client.select_header_content_type(
340
+ [
341
+ 'application/json'
342
+ ]
343
+ )
344
+ )
345
+ if _default_content_type is not None:
346
+ _header_params['Content-Type'] = _default_content_type
347
+
348
+ # authentication setting
349
+ _auth_settings: List[str] = [
350
+ 'CloudTokenAuth'
351
+ ]
352
+
353
+ return self.api_client.param_serialize(
354
+ method='POST',
355
+ resource_path='/api/v1/subscriptions/{subscriptionId}/cancel',
356
+ path_params=_path_params,
357
+ query_params=_query_params,
358
+ header_params=_header_params,
359
+ body=_body_params,
360
+ post_params=_form_params,
361
+ files=_files,
362
+ auth_settings=_auth_settings,
363
+ collection_formats=_collection_formats,
364
+ _host=_host,
365
+ _request_auth=_request_auth
366
+ )
367
+
368
+
369
+
370
+
371
+ @validate_call
372
+ def change_subscription(
373
+ self,
374
+ subscription_id: Annotated[str, Field(strict=True)],
375
+ subscription_change: SubscriptionChange,
376
+ _request_timeout: Union[
377
+ None,
378
+ Annotated[StrictFloat, Field(gt=0)],
379
+ Tuple[
380
+ Annotated[StrictFloat, Field(gt=0)],
381
+ Annotated[StrictFloat, Field(gt=0)]
382
+ ]
383
+ ] = None,
384
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
385
+ _content_type: Optional[StrictStr] = None,
386
+ _headers: Optional[Dict[StrictStr, Any]] = None,
387
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
388
+ ) -> SubscriptionChangeResponseBody:
389
+ """Change subscription
390
+
391
+ Closes a running subscription and starts a new one according to the specification. Can be used for upgrades, downgrades, and plan changes.
392
+
393
+ :param subscription_id: (required)
394
+ :type subscription_id: str
395
+ :param subscription_change: (required)
396
+ :type subscription_change: SubscriptionChange
397
+ :param _request_timeout: timeout setting for this request. If one
398
+ number provided, it will be total request
399
+ timeout. It can also be a pair (tuple) of
400
+ (connection, read) timeouts.
401
+ :type _request_timeout: int, tuple(int, int), optional
402
+ :param _request_auth: set to override the auth_settings for an a single
403
+ request; this effectively ignores the
404
+ authentication in the spec for a single request.
405
+ :type _request_auth: dict, optional
406
+ :param _content_type: force content-type for the request.
407
+ :type _content_type: str, Optional
408
+ :param _headers: set to override the headers for a single
409
+ request; this effectively ignores the headers
410
+ in the spec for a single request.
411
+ :type _headers: dict, optional
412
+ :param _host_index: set to override the host_index for a single
413
+ request; this effectively ignores the host_index
414
+ in the spec for a single request.
415
+ :type _host_index: int, optional
416
+ :return: Returns the result object.
417
+ """ # noqa: E501
418
+
419
+ _param = self._change_subscription_serialize(
420
+ subscription_id=subscription_id,
421
+ subscription_change=subscription_change,
422
+ _request_auth=_request_auth,
423
+ _content_type=_content_type,
424
+ _headers=_headers,
425
+ _host_index=_host_index
426
+ )
427
+
428
+ _response_types_map: Dict[str, Optional[str]] = {
429
+ '200': "SubscriptionChangeResponseBody",
430
+ '400': "SubscriptionBadRequestErrorResponse",
431
+ '401': "UnexpectedProblemResponse",
432
+ '403': "UnexpectedProblemResponse",
433
+ '404': "UnexpectedProblemResponse",
434
+ '409': "SubscriptionConflictErrorResponse",
435
+ '412': "UnexpectedProblemResponse",
436
+ '500': "UnexpectedProblemResponse",
437
+ '503': "UnexpectedProblemResponse",
438
+ }
439
+ response_data = self.api_client.call_api(
440
+ *_param,
441
+ _request_timeout=_request_timeout
442
+ )
443
+ response_data.read()
444
+ return self.api_client.response_deserialize(
445
+ response_data=response_data,
446
+ response_types_map=_response_types_map,
447
+ ).data
448
+
449
+
450
+ @validate_call
451
+ def change_subscription_with_http_info(
452
+ self,
453
+ subscription_id: Annotated[str, Field(strict=True)],
454
+ subscription_change: SubscriptionChange,
455
+ _request_timeout: Union[
456
+ None,
457
+ Annotated[StrictFloat, Field(gt=0)],
458
+ Tuple[
459
+ Annotated[StrictFloat, Field(gt=0)],
460
+ Annotated[StrictFloat, Field(gt=0)]
461
+ ]
462
+ ] = None,
463
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
464
+ _content_type: Optional[StrictStr] = None,
465
+ _headers: Optional[Dict[StrictStr, Any]] = None,
466
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
467
+ ) -> ApiResponse[SubscriptionChangeResponseBody]:
468
+ """Change subscription
469
+
470
+ Closes a running subscription and starts a new one according to the specification. Can be used for upgrades, downgrades, and plan changes.
471
+
472
+ :param subscription_id: (required)
473
+ :type subscription_id: str
474
+ :param subscription_change: (required)
475
+ :type subscription_change: SubscriptionChange
476
+ :param _request_timeout: timeout setting for this request. If one
477
+ number provided, it will be total request
478
+ timeout. It can also be a pair (tuple) of
479
+ (connection, read) timeouts.
480
+ :type _request_timeout: int, tuple(int, int), optional
481
+ :param _request_auth: set to override the auth_settings for an a single
482
+ request; this effectively ignores the
483
+ authentication in the spec for a single request.
484
+ :type _request_auth: dict, optional
485
+ :param _content_type: force content-type for the request.
486
+ :type _content_type: str, Optional
487
+ :param _headers: set to override the headers for a single
488
+ request; this effectively ignores the headers
489
+ in the spec for a single request.
490
+ :type _headers: dict, optional
491
+ :param _host_index: set to override the host_index for a single
492
+ request; this effectively ignores the host_index
493
+ in the spec for a single request.
494
+ :type _host_index: int, optional
495
+ :return: Returns the result object.
496
+ """ # noqa: E501
497
+
498
+ _param = self._change_subscription_serialize(
499
+ subscription_id=subscription_id,
500
+ subscription_change=subscription_change,
501
+ _request_auth=_request_auth,
502
+ _content_type=_content_type,
503
+ _headers=_headers,
504
+ _host_index=_host_index
505
+ )
506
+
507
+ _response_types_map: Dict[str, Optional[str]] = {
508
+ '200': "SubscriptionChangeResponseBody",
509
+ '400': "SubscriptionBadRequestErrorResponse",
510
+ '401': "UnexpectedProblemResponse",
511
+ '403': "UnexpectedProblemResponse",
512
+ '404': "UnexpectedProblemResponse",
513
+ '409': "SubscriptionConflictErrorResponse",
514
+ '412': "UnexpectedProblemResponse",
515
+ '500': "UnexpectedProblemResponse",
516
+ '503': "UnexpectedProblemResponse",
517
+ }
518
+ response_data = self.api_client.call_api(
519
+ *_param,
520
+ _request_timeout=_request_timeout
521
+ )
522
+ response_data.read()
523
+ return self.api_client.response_deserialize(
524
+ response_data=response_data,
525
+ response_types_map=_response_types_map,
526
+ )
527
+
528
+
529
+ @validate_call
530
+ def change_subscription_without_preload_content(
531
+ self,
532
+ subscription_id: Annotated[str, Field(strict=True)],
533
+ subscription_change: SubscriptionChange,
534
+ _request_timeout: Union[
535
+ None,
536
+ Annotated[StrictFloat, Field(gt=0)],
537
+ Tuple[
538
+ Annotated[StrictFloat, Field(gt=0)],
539
+ Annotated[StrictFloat, Field(gt=0)]
540
+ ]
541
+ ] = None,
542
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
543
+ _content_type: Optional[StrictStr] = None,
544
+ _headers: Optional[Dict[StrictStr, Any]] = None,
545
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
546
+ ) -> RESTResponseType:
547
+ """Change subscription
548
+
549
+ Closes a running subscription and starts a new one according to the specification. Can be used for upgrades, downgrades, and plan changes.
550
+
551
+ :param subscription_id: (required)
552
+ :type subscription_id: str
553
+ :param subscription_change: (required)
554
+ :type subscription_change: SubscriptionChange
555
+ :param _request_timeout: timeout setting for this request. If one
556
+ number provided, it will be total request
557
+ timeout. It can also be a pair (tuple) of
558
+ (connection, read) timeouts.
559
+ :type _request_timeout: int, tuple(int, int), optional
560
+ :param _request_auth: set to override the auth_settings for an a single
561
+ request; this effectively ignores the
562
+ authentication in the spec for a single request.
563
+ :type _request_auth: dict, optional
564
+ :param _content_type: force content-type for the request.
565
+ :type _content_type: str, Optional
566
+ :param _headers: set to override the headers for a single
567
+ request; this effectively ignores the headers
568
+ in the spec for a single request.
569
+ :type _headers: dict, optional
570
+ :param _host_index: set to override the host_index for a single
571
+ request; this effectively ignores the host_index
572
+ in the spec for a single request.
573
+ :type _host_index: int, optional
574
+ :return: Returns the result object.
575
+ """ # noqa: E501
576
+
577
+ _param = self._change_subscription_serialize(
578
+ subscription_id=subscription_id,
579
+ subscription_change=subscription_change,
580
+ _request_auth=_request_auth,
581
+ _content_type=_content_type,
582
+ _headers=_headers,
583
+ _host_index=_host_index
584
+ )
585
+
586
+ _response_types_map: Dict[str, Optional[str]] = {
587
+ '200': "SubscriptionChangeResponseBody",
588
+ '400': "SubscriptionBadRequestErrorResponse",
589
+ '401': "UnexpectedProblemResponse",
590
+ '403': "UnexpectedProblemResponse",
591
+ '404': "UnexpectedProblemResponse",
592
+ '409': "SubscriptionConflictErrorResponse",
593
+ '412': "UnexpectedProblemResponse",
594
+ '500': "UnexpectedProblemResponse",
595
+ '503': "UnexpectedProblemResponse",
596
+ }
597
+ response_data = self.api_client.call_api(
598
+ *_param,
599
+ _request_timeout=_request_timeout
600
+ )
601
+ return response_data.response
602
+
603
+
604
+ def _change_subscription_serialize(
605
+ self,
606
+ subscription_id,
607
+ subscription_change,
608
+ _request_auth,
609
+ _content_type,
610
+ _headers,
611
+ _host_index,
612
+ ) -> RequestSerialized:
613
+
614
+ _host = None
615
+
616
+ _collection_formats: Dict[str, str] = {
617
+ }
618
+
619
+ _path_params: Dict[str, str] = {}
620
+ _query_params: List[Tuple[str, str]] = []
621
+ _header_params: Dict[str, Optional[str]] = _headers or {}
622
+ _form_params: List[Tuple[str, str]] = []
623
+ _files: Dict[
624
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
625
+ ] = {}
626
+ _body_params: Optional[bytes] = None
627
+
628
+ # process the path parameters
629
+ if subscription_id is not None:
630
+ _path_params['subscriptionId'] = subscription_id
631
+ # process the query parameters
632
+ # process the header parameters
633
+ # process the form parameters
634
+ # process the body parameter
635
+ if subscription_change is not None:
636
+ _body_params = subscription_change
637
+
638
+
639
+ # set the HTTP header `Accept`
640
+ if 'Accept' not in _header_params:
641
+ _header_params['Accept'] = self.api_client.select_header_accept(
642
+ [
643
+ 'application/json',
644
+ 'application/problem+json'
645
+ ]
646
+ )
647
+
648
+ # set the HTTP header `Content-Type`
649
+ if _content_type:
650
+ _header_params['Content-Type'] = _content_type
651
+ else:
652
+ _default_content_type = (
653
+ self.api_client.select_header_content_type(
654
+ [
655
+ 'application/json'
656
+ ]
657
+ )
658
+ )
659
+ if _default_content_type is not None:
660
+ _header_params['Content-Type'] = _default_content_type
661
+
662
+ # authentication setting
663
+ _auth_settings: List[str] = [
664
+ 'CloudTokenAuth'
665
+ ]
666
+
667
+ return self.api_client.param_serialize(
668
+ method='POST',
669
+ resource_path='/api/v1/subscriptions/{subscriptionId}/change',
670
+ path_params=_path_params,
671
+ query_params=_query_params,
672
+ header_params=_header_params,
673
+ body=_body_params,
674
+ post_params=_form_params,
675
+ files=_files,
676
+ auth_settings=_auth_settings,
677
+ collection_formats=_collection_formats,
678
+ _host=_host,
679
+ _request_auth=_request_auth
680
+ )
681
+
682
+
683
+
684
+
685
+ @validate_call
686
+ def create_subscription(
687
+ self,
688
+ subscription_create: SubscriptionCreate,
689
+ _request_timeout: Union[
690
+ None,
691
+ Annotated[StrictFloat, Field(gt=0)],
692
+ Tuple[
693
+ Annotated[StrictFloat, Field(gt=0)],
694
+ Annotated[StrictFloat, Field(gt=0)]
695
+ ]
696
+ ] = None,
697
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
698
+ _content_type: Optional[StrictStr] = None,
699
+ _headers: Optional[Dict[StrictStr, Any]] = None,
700
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
701
+ ) -> Subscription:
702
+ """Create subscription
703
+
704
+
705
+ :param subscription_create: (required)
706
+ :type subscription_create: SubscriptionCreate
707
+ :param _request_timeout: timeout setting for this request. If one
708
+ number provided, it will be total request
709
+ timeout. It can also be a pair (tuple) of
710
+ (connection, read) timeouts.
711
+ :type _request_timeout: int, tuple(int, int), optional
712
+ :param _request_auth: set to override the auth_settings for an a single
713
+ request; this effectively ignores the
714
+ authentication in the spec for a single request.
715
+ :type _request_auth: dict, optional
716
+ :param _content_type: force content-type for the request.
717
+ :type _content_type: str, Optional
718
+ :param _headers: set to override the headers for a single
719
+ request; this effectively ignores the headers
720
+ in the spec for a single request.
721
+ :type _headers: dict, optional
722
+ :param _host_index: set to override the host_index for a single
723
+ request; this effectively ignores the host_index
724
+ in the spec for a single request.
725
+ :type _host_index: int, optional
726
+ :return: Returns the result object.
727
+ """ # noqa: E501
728
+
729
+ _param = self._create_subscription_serialize(
730
+ subscription_create=subscription_create,
731
+ _request_auth=_request_auth,
732
+ _content_type=_content_type,
733
+ _headers=_headers,
734
+ _host_index=_host_index
735
+ )
736
+
737
+ _response_types_map: Dict[str, Optional[str]] = {
738
+ '200': "Subscription",
739
+ '201': "Subscription",
740
+ '400': "SubscriptionBadRequestErrorResponse",
741
+ '401': "UnexpectedProblemResponse",
742
+ '403': "UnexpectedProblemResponse",
743
+ '409': "SubscriptionConflictErrorResponse",
744
+ '412': "UnexpectedProblemResponse",
745
+ '500': "UnexpectedProblemResponse",
746
+ '503': "UnexpectedProblemResponse",
747
+ }
748
+ response_data = self.api_client.call_api(
749
+ *_param,
750
+ _request_timeout=_request_timeout
751
+ )
752
+ response_data.read()
753
+ return self.api_client.response_deserialize(
754
+ response_data=response_data,
755
+ response_types_map=_response_types_map,
756
+ ).data
757
+
758
+
759
+ @validate_call
760
+ def create_subscription_with_http_info(
761
+ self,
762
+ subscription_create: SubscriptionCreate,
763
+ _request_timeout: Union[
764
+ None,
765
+ Annotated[StrictFloat, Field(gt=0)],
766
+ Tuple[
767
+ Annotated[StrictFloat, Field(gt=0)],
768
+ Annotated[StrictFloat, Field(gt=0)]
769
+ ]
770
+ ] = None,
771
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
772
+ _content_type: Optional[StrictStr] = None,
773
+ _headers: Optional[Dict[StrictStr, Any]] = None,
774
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
775
+ ) -> ApiResponse[Subscription]:
776
+ """Create subscription
777
+
778
+
779
+ :param subscription_create: (required)
780
+ :type subscription_create: SubscriptionCreate
781
+ :param _request_timeout: timeout setting for this request. If one
782
+ number provided, it will be total request
783
+ timeout. It can also be a pair (tuple) of
784
+ (connection, read) timeouts.
785
+ :type _request_timeout: int, tuple(int, int), optional
786
+ :param _request_auth: set to override the auth_settings for an a single
787
+ request; this effectively ignores the
788
+ authentication in the spec for a single request.
789
+ :type _request_auth: dict, optional
790
+ :param _content_type: force content-type for the request.
791
+ :type _content_type: str, Optional
792
+ :param _headers: set to override the headers for a single
793
+ request; this effectively ignores the headers
794
+ in the spec for a single request.
795
+ :type _headers: dict, optional
796
+ :param _host_index: set to override the host_index for a single
797
+ request; this effectively ignores the host_index
798
+ in the spec for a single request.
799
+ :type _host_index: int, optional
800
+ :return: Returns the result object.
801
+ """ # noqa: E501
802
+
803
+ _param = self._create_subscription_serialize(
804
+ subscription_create=subscription_create,
805
+ _request_auth=_request_auth,
806
+ _content_type=_content_type,
807
+ _headers=_headers,
808
+ _host_index=_host_index
809
+ )
810
+
811
+ _response_types_map: Dict[str, Optional[str]] = {
812
+ '200': "Subscription",
813
+ '201': "Subscription",
814
+ '400': "SubscriptionBadRequestErrorResponse",
815
+ '401': "UnexpectedProblemResponse",
816
+ '403': "UnexpectedProblemResponse",
817
+ '409': "SubscriptionConflictErrorResponse",
818
+ '412': "UnexpectedProblemResponse",
819
+ '500': "UnexpectedProblemResponse",
820
+ '503': "UnexpectedProblemResponse",
821
+ }
822
+ response_data = self.api_client.call_api(
823
+ *_param,
824
+ _request_timeout=_request_timeout
825
+ )
826
+ response_data.read()
827
+ return self.api_client.response_deserialize(
828
+ response_data=response_data,
829
+ response_types_map=_response_types_map,
830
+ )
831
+
832
+
833
+ @validate_call
834
+ def create_subscription_without_preload_content(
835
+ self,
836
+ subscription_create: SubscriptionCreate,
837
+ _request_timeout: Union[
838
+ None,
839
+ Annotated[StrictFloat, Field(gt=0)],
840
+ Tuple[
841
+ Annotated[StrictFloat, Field(gt=0)],
842
+ Annotated[StrictFloat, Field(gt=0)]
843
+ ]
844
+ ] = None,
845
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
846
+ _content_type: Optional[StrictStr] = None,
847
+ _headers: Optional[Dict[StrictStr, Any]] = None,
848
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
849
+ ) -> RESTResponseType:
850
+ """Create subscription
851
+
852
+
853
+ :param subscription_create: (required)
854
+ :type subscription_create: SubscriptionCreate
855
+ :param _request_timeout: timeout setting for this request. If one
856
+ number provided, it will be total request
857
+ timeout. It can also be a pair (tuple) of
858
+ (connection, read) timeouts.
859
+ :type _request_timeout: int, tuple(int, int), optional
860
+ :param _request_auth: set to override the auth_settings for an a single
861
+ request; this effectively ignores the
862
+ authentication in the spec for a single request.
863
+ :type _request_auth: dict, optional
864
+ :param _content_type: force content-type for the request.
865
+ :type _content_type: str, Optional
866
+ :param _headers: set to override the headers for a single
867
+ request; this effectively ignores the headers
868
+ in the spec for a single request.
869
+ :type _headers: dict, optional
870
+ :param _host_index: set to override the host_index for a single
871
+ request; this effectively ignores the host_index
872
+ in the spec for a single request.
873
+ :type _host_index: int, optional
874
+ :return: Returns the result object.
875
+ """ # noqa: E501
876
+
877
+ _param = self._create_subscription_serialize(
878
+ subscription_create=subscription_create,
879
+ _request_auth=_request_auth,
880
+ _content_type=_content_type,
881
+ _headers=_headers,
882
+ _host_index=_host_index
883
+ )
884
+
885
+ _response_types_map: Dict[str, Optional[str]] = {
886
+ '200': "Subscription",
887
+ '201': "Subscription",
888
+ '400': "SubscriptionBadRequestErrorResponse",
889
+ '401': "UnexpectedProblemResponse",
890
+ '403': "UnexpectedProblemResponse",
891
+ '409': "SubscriptionConflictErrorResponse",
892
+ '412': "UnexpectedProblemResponse",
893
+ '500': "UnexpectedProblemResponse",
894
+ '503': "UnexpectedProblemResponse",
895
+ }
896
+ response_data = self.api_client.call_api(
897
+ *_param,
898
+ _request_timeout=_request_timeout
899
+ )
900
+ return response_data.response
901
+
902
+
903
+ def _create_subscription_serialize(
904
+ self,
905
+ subscription_create,
906
+ _request_auth,
907
+ _content_type,
908
+ _headers,
909
+ _host_index,
910
+ ) -> RequestSerialized:
911
+
912
+ _host = None
913
+
914
+ _collection_formats: Dict[str, str] = {
915
+ }
916
+
917
+ _path_params: Dict[str, str] = {}
918
+ _query_params: List[Tuple[str, str]] = []
919
+ _header_params: Dict[str, Optional[str]] = _headers or {}
920
+ _form_params: List[Tuple[str, str]] = []
921
+ _files: Dict[
922
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
923
+ ] = {}
924
+ _body_params: Optional[bytes] = None
925
+
926
+ # process the path parameters
927
+ # process the query parameters
928
+ # process the header parameters
929
+ # process the form parameters
930
+ # process the body parameter
931
+ if subscription_create is not None:
932
+ _body_params = subscription_create
933
+
934
+
935
+ # set the HTTP header `Accept`
936
+ if 'Accept' not in _header_params:
937
+ _header_params['Accept'] = self.api_client.select_header_accept(
938
+ [
939
+ 'application/json',
940
+ 'application/problem+json'
941
+ ]
942
+ )
943
+
944
+ # set the HTTP header `Content-Type`
945
+ if _content_type:
946
+ _header_params['Content-Type'] = _content_type
947
+ else:
948
+ _default_content_type = (
949
+ self.api_client.select_header_content_type(
950
+ [
951
+ 'application/json'
952
+ ]
953
+ )
954
+ )
955
+ if _default_content_type is not None:
956
+ _header_params['Content-Type'] = _default_content_type
957
+
958
+ # authentication setting
959
+ _auth_settings: List[str] = [
960
+ 'CloudTokenAuth'
961
+ ]
962
+
963
+ return self.api_client.param_serialize(
964
+ method='POST',
965
+ resource_path='/api/v1/subscriptions',
966
+ path_params=_path_params,
967
+ query_params=_query_params,
968
+ header_params=_header_params,
969
+ body=_body_params,
970
+ post_params=_form_params,
971
+ files=_files,
972
+ auth_settings=_auth_settings,
973
+ collection_formats=_collection_formats,
974
+ _host=_host,
975
+ _request_auth=_request_auth
976
+ )
977
+
978
+
979
+
980
+
981
+ @validate_call
982
+ def create_subscription_addon(
983
+ self,
984
+ subscription_id: Annotated[str, Field(strict=True)],
985
+ subscription_addon_create: SubscriptionAddonCreate,
986
+ _request_timeout: Union[
987
+ None,
988
+ Annotated[StrictFloat, Field(gt=0)],
989
+ Tuple[
990
+ Annotated[StrictFloat, Field(gt=0)],
991
+ Annotated[StrictFloat, Field(gt=0)]
992
+ ]
993
+ ] = None,
994
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
995
+ _content_type: Optional[StrictStr] = None,
996
+ _headers: Optional[Dict[StrictStr, Any]] = None,
997
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
998
+ ) -> SubscriptionAddon:
999
+ """Create subscription addon
1000
+
1001
+ Create a new subscription addon, either providing the key or the id of the addon.
1002
+
1003
+ :param subscription_id: (required)
1004
+ :type subscription_id: str
1005
+ :param subscription_addon_create: (required)
1006
+ :type subscription_addon_create: SubscriptionAddonCreate
1007
+ :param _request_timeout: timeout setting for this request. If one
1008
+ number provided, it will be total request
1009
+ timeout. It can also be a pair (tuple) of
1010
+ (connection, read) timeouts.
1011
+ :type _request_timeout: int, tuple(int, int), optional
1012
+ :param _request_auth: set to override the auth_settings for an a single
1013
+ request; this effectively ignores the
1014
+ authentication in the spec for a single request.
1015
+ :type _request_auth: dict, optional
1016
+ :param _content_type: force content-type for the request.
1017
+ :type _content_type: str, Optional
1018
+ :param _headers: set to override the headers for a single
1019
+ request; this effectively ignores the headers
1020
+ in the spec for a single request.
1021
+ :type _headers: dict, optional
1022
+ :param _host_index: set to override the host_index for a single
1023
+ request; this effectively ignores the host_index
1024
+ in the spec for a single request.
1025
+ :type _host_index: int, optional
1026
+ :return: Returns the result object.
1027
+ """ # noqa: E501
1028
+
1029
+ _param = self._create_subscription_addon_serialize(
1030
+ subscription_id=subscription_id,
1031
+ subscription_addon_create=subscription_addon_create,
1032
+ _request_auth=_request_auth,
1033
+ _content_type=_content_type,
1034
+ _headers=_headers,
1035
+ _host_index=_host_index
1036
+ )
1037
+
1038
+ _response_types_map: Dict[str, Optional[str]] = {
1039
+ '201': "SubscriptionAddon",
1040
+ '400': "UnexpectedProblemResponse",
1041
+ '401': "UnexpectedProblemResponse",
1042
+ '403': "UnexpectedProblemResponse",
1043
+ '404': "UnexpectedProblemResponse",
1044
+ '409': "UnexpectedProblemResponse",
1045
+ '412': "UnexpectedProblemResponse",
1046
+ '500': "UnexpectedProblemResponse",
1047
+ '503': "UnexpectedProblemResponse",
1048
+ }
1049
+ response_data = self.api_client.call_api(
1050
+ *_param,
1051
+ _request_timeout=_request_timeout
1052
+ )
1053
+ response_data.read()
1054
+ return self.api_client.response_deserialize(
1055
+ response_data=response_data,
1056
+ response_types_map=_response_types_map,
1057
+ ).data
1058
+
1059
+
1060
+ @validate_call
1061
+ def create_subscription_addon_with_http_info(
1062
+ self,
1063
+ subscription_id: Annotated[str, Field(strict=True)],
1064
+ subscription_addon_create: SubscriptionAddonCreate,
1065
+ _request_timeout: Union[
1066
+ None,
1067
+ Annotated[StrictFloat, Field(gt=0)],
1068
+ Tuple[
1069
+ Annotated[StrictFloat, Field(gt=0)],
1070
+ Annotated[StrictFloat, Field(gt=0)]
1071
+ ]
1072
+ ] = None,
1073
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1074
+ _content_type: Optional[StrictStr] = None,
1075
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1076
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1077
+ ) -> ApiResponse[SubscriptionAddon]:
1078
+ """Create subscription addon
1079
+
1080
+ Create a new subscription addon, either providing the key or the id of the addon.
1081
+
1082
+ :param subscription_id: (required)
1083
+ :type subscription_id: str
1084
+ :param subscription_addon_create: (required)
1085
+ :type subscription_addon_create: SubscriptionAddonCreate
1086
+ :param _request_timeout: timeout setting for this request. If one
1087
+ number provided, it will be total request
1088
+ timeout. It can also be a pair (tuple) of
1089
+ (connection, read) timeouts.
1090
+ :type _request_timeout: int, tuple(int, int), optional
1091
+ :param _request_auth: set to override the auth_settings for an a single
1092
+ request; this effectively ignores the
1093
+ authentication in the spec for a single request.
1094
+ :type _request_auth: dict, optional
1095
+ :param _content_type: force content-type for the request.
1096
+ :type _content_type: str, Optional
1097
+ :param _headers: set to override the headers for a single
1098
+ request; this effectively ignores the headers
1099
+ in the spec for a single request.
1100
+ :type _headers: dict, optional
1101
+ :param _host_index: set to override the host_index for a single
1102
+ request; this effectively ignores the host_index
1103
+ in the spec for a single request.
1104
+ :type _host_index: int, optional
1105
+ :return: Returns the result object.
1106
+ """ # noqa: E501
1107
+
1108
+ _param = self._create_subscription_addon_serialize(
1109
+ subscription_id=subscription_id,
1110
+ subscription_addon_create=subscription_addon_create,
1111
+ _request_auth=_request_auth,
1112
+ _content_type=_content_type,
1113
+ _headers=_headers,
1114
+ _host_index=_host_index
1115
+ )
1116
+
1117
+ _response_types_map: Dict[str, Optional[str]] = {
1118
+ '201': "SubscriptionAddon",
1119
+ '400': "UnexpectedProblemResponse",
1120
+ '401': "UnexpectedProblemResponse",
1121
+ '403': "UnexpectedProblemResponse",
1122
+ '404': "UnexpectedProblemResponse",
1123
+ '409': "UnexpectedProblemResponse",
1124
+ '412': "UnexpectedProblemResponse",
1125
+ '500': "UnexpectedProblemResponse",
1126
+ '503': "UnexpectedProblemResponse",
1127
+ }
1128
+ response_data = self.api_client.call_api(
1129
+ *_param,
1130
+ _request_timeout=_request_timeout
1131
+ )
1132
+ response_data.read()
1133
+ return self.api_client.response_deserialize(
1134
+ response_data=response_data,
1135
+ response_types_map=_response_types_map,
1136
+ )
1137
+
1138
+
1139
+ @validate_call
1140
+ def create_subscription_addon_without_preload_content(
1141
+ self,
1142
+ subscription_id: Annotated[str, Field(strict=True)],
1143
+ subscription_addon_create: SubscriptionAddonCreate,
1144
+ _request_timeout: Union[
1145
+ None,
1146
+ Annotated[StrictFloat, Field(gt=0)],
1147
+ Tuple[
1148
+ Annotated[StrictFloat, Field(gt=0)],
1149
+ Annotated[StrictFloat, Field(gt=0)]
1150
+ ]
1151
+ ] = None,
1152
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1153
+ _content_type: Optional[StrictStr] = None,
1154
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1155
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1156
+ ) -> RESTResponseType:
1157
+ """Create subscription addon
1158
+
1159
+ Create a new subscription addon, either providing the key or the id of the addon.
1160
+
1161
+ :param subscription_id: (required)
1162
+ :type subscription_id: str
1163
+ :param subscription_addon_create: (required)
1164
+ :type subscription_addon_create: SubscriptionAddonCreate
1165
+ :param _request_timeout: timeout setting for this request. If one
1166
+ number provided, it will be total request
1167
+ timeout. It can also be a pair (tuple) of
1168
+ (connection, read) timeouts.
1169
+ :type _request_timeout: int, tuple(int, int), optional
1170
+ :param _request_auth: set to override the auth_settings for an a single
1171
+ request; this effectively ignores the
1172
+ authentication in the spec for a single request.
1173
+ :type _request_auth: dict, optional
1174
+ :param _content_type: force content-type for the request.
1175
+ :type _content_type: str, Optional
1176
+ :param _headers: set to override the headers for a single
1177
+ request; this effectively ignores the headers
1178
+ in the spec for a single request.
1179
+ :type _headers: dict, optional
1180
+ :param _host_index: set to override the host_index for a single
1181
+ request; this effectively ignores the host_index
1182
+ in the spec for a single request.
1183
+ :type _host_index: int, optional
1184
+ :return: Returns the result object.
1185
+ """ # noqa: E501
1186
+
1187
+ _param = self._create_subscription_addon_serialize(
1188
+ subscription_id=subscription_id,
1189
+ subscription_addon_create=subscription_addon_create,
1190
+ _request_auth=_request_auth,
1191
+ _content_type=_content_type,
1192
+ _headers=_headers,
1193
+ _host_index=_host_index
1194
+ )
1195
+
1196
+ _response_types_map: Dict[str, Optional[str]] = {
1197
+ '201': "SubscriptionAddon",
1198
+ '400': "UnexpectedProblemResponse",
1199
+ '401': "UnexpectedProblemResponse",
1200
+ '403': "UnexpectedProblemResponse",
1201
+ '404': "UnexpectedProblemResponse",
1202
+ '409': "UnexpectedProblemResponse",
1203
+ '412': "UnexpectedProblemResponse",
1204
+ '500': "UnexpectedProblemResponse",
1205
+ '503': "UnexpectedProblemResponse",
1206
+ }
1207
+ response_data = self.api_client.call_api(
1208
+ *_param,
1209
+ _request_timeout=_request_timeout
1210
+ )
1211
+ return response_data.response
1212
+
1213
+
1214
+ def _create_subscription_addon_serialize(
1215
+ self,
1216
+ subscription_id,
1217
+ subscription_addon_create,
1218
+ _request_auth,
1219
+ _content_type,
1220
+ _headers,
1221
+ _host_index,
1222
+ ) -> RequestSerialized:
1223
+
1224
+ _host = None
1225
+
1226
+ _collection_formats: Dict[str, str] = {
1227
+ }
1228
+
1229
+ _path_params: Dict[str, str] = {}
1230
+ _query_params: List[Tuple[str, str]] = []
1231
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1232
+ _form_params: List[Tuple[str, str]] = []
1233
+ _files: Dict[
1234
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1235
+ ] = {}
1236
+ _body_params: Optional[bytes] = None
1237
+
1238
+ # process the path parameters
1239
+ if subscription_id is not None:
1240
+ _path_params['subscriptionId'] = subscription_id
1241
+ # process the query parameters
1242
+ # process the header parameters
1243
+ # process the form parameters
1244
+ # process the body parameter
1245
+ if subscription_addon_create is not None:
1246
+ _body_params = subscription_addon_create
1247
+
1248
+
1249
+ # set the HTTP header `Accept`
1250
+ if 'Accept' not in _header_params:
1251
+ _header_params['Accept'] = self.api_client.select_header_accept(
1252
+ [
1253
+ 'application/json',
1254
+ 'application/problem+json'
1255
+ ]
1256
+ )
1257
+
1258
+ # set the HTTP header `Content-Type`
1259
+ if _content_type:
1260
+ _header_params['Content-Type'] = _content_type
1261
+ else:
1262
+ _default_content_type = (
1263
+ self.api_client.select_header_content_type(
1264
+ [
1265
+ 'application/json'
1266
+ ]
1267
+ )
1268
+ )
1269
+ if _default_content_type is not None:
1270
+ _header_params['Content-Type'] = _default_content_type
1271
+
1272
+ # authentication setting
1273
+ _auth_settings: List[str] = [
1274
+ 'CloudTokenAuth'
1275
+ ]
1276
+
1277
+ return self.api_client.param_serialize(
1278
+ method='POST',
1279
+ resource_path='/api/v1/subscriptions/{subscriptionId}/addons',
1280
+ path_params=_path_params,
1281
+ query_params=_query_params,
1282
+ header_params=_header_params,
1283
+ body=_body_params,
1284
+ post_params=_form_params,
1285
+ files=_files,
1286
+ auth_settings=_auth_settings,
1287
+ collection_formats=_collection_formats,
1288
+ _host=_host,
1289
+ _request_auth=_request_auth
1290
+ )
1291
+
1292
+
1293
+
1294
+
1295
+ @validate_call
1296
+ def delete_subscription(
1297
+ self,
1298
+ subscription_id: Annotated[str, Field(strict=True)],
1299
+ _request_timeout: Union[
1300
+ None,
1301
+ Annotated[StrictFloat, Field(gt=0)],
1302
+ Tuple[
1303
+ Annotated[StrictFloat, Field(gt=0)],
1304
+ Annotated[StrictFloat, Field(gt=0)]
1305
+ ]
1306
+ ] = None,
1307
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1308
+ _content_type: Optional[StrictStr] = None,
1309
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1310
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1311
+ ) -> None:
1312
+ """Delete subscription
1313
+
1314
+ Deletes a subscription. Only scheduled subscriptions can be deleted.
1315
+
1316
+ :param subscription_id: (required)
1317
+ :type subscription_id: str
1318
+ :param _request_timeout: timeout setting for this request. If one
1319
+ number provided, it will be total request
1320
+ timeout. It can also be a pair (tuple) of
1321
+ (connection, read) timeouts.
1322
+ :type _request_timeout: int, tuple(int, int), optional
1323
+ :param _request_auth: set to override the auth_settings for an a single
1324
+ request; this effectively ignores the
1325
+ authentication in the spec for a single request.
1326
+ :type _request_auth: dict, optional
1327
+ :param _content_type: force content-type for the request.
1328
+ :type _content_type: str, Optional
1329
+ :param _headers: set to override the headers for a single
1330
+ request; this effectively ignores the headers
1331
+ in the spec for a single request.
1332
+ :type _headers: dict, optional
1333
+ :param _host_index: set to override the host_index for a single
1334
+ request; this effectively ignores the host_index
1335
+ in the spec for a single request.
1336
+ :type _host_index: int, optional
1337
+ :return: Returns the result object.
1338
+ """ # noqa: E501
1339
+
1340
+ _param = self._delete_subscription_serialize(
1341
+ subscription_id=subscription_id,
1342
+ _request_auth=_request_auth,
1343
+ _content_type=_content_type,
1344
+ _headers=_headers,
1345
+ _host_index=_host_index
1346
+ )
1347
+
1348
+ _response_types_map: Dict[str, Optional[str]] = {
1349
+ '204': None,
1350
+ '400': "SubscriptionBadRequestErrorResponse",
1351
+ '401': "UnexpectedProblemResponse",
1352
+ '403': "UnexpectedProblemResponse",
1353
+ '404': "UnexpectedProblemResponse",
1354
+ '409': "SubscriptionConflictErrorResponse",
1355
+ '412': "UnexpectedProblemResponse",
1356
+ '500': "UnexpectedProblemResponse",
1357
+ '503': "UnexpectedProblemResponse",
1358
+ }
1359
+ response_data = self.api_client.call_api(
1360
+ *_param,
1361
+ _request_timeout=_request_timeout
1362
+ )
1363
+ response_data.read()
1364
+ return self.api_client.response_deserialize(
1365
+ response_data=response_data,
1366
+ response_types_map=_response_types_map,
1367
+ ).data
1368
+
1369
+
1370
+ @validate_call
1371
+ def delete_subscription_with_http_info(
1372
+ self,
1373
+ subscription_id: Annotated[str, Field(strict=True)],
1374
+ _request_timeout: Union[
1375
+ None,
1376
+ Annotated[StrictFloat, Field(gt=0)],
1377
+ Tuple[
1378
+ Annotated[StrictFloat, Field(gt=0)],
1379
+ Annotated[StrictFloat, Field(gt=0)]
1380
+ ]
1381
+ ] = None,
1382
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1383
+ _content_type: Optional[StrictStr] = None,
1384
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1385
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1386
+ ) -> ApiResponse[None]:
1387
+ """Delete subscription
1388
+
1389
+ Deletes a subscription. Only scheduled subscriptions can be deleted.
1390
+
1391
+ :param subscription_id: (required)
1392
+ :type subscription_id: str
1393
+ :param _request_timeout: timeout setting for this request. If one
1394
+ number provided, it will be total request
1395
+ timeout. It can also be a pair (tuple) of
1396
+ (connection, read) timeouts.
1397
+ :type _request_timeout: int, tuple(int, int), optional
1398
+ :param _request_auth: set to override the auth_settings for an a single
1399
+ request; this effectively ignores the
1400
+ authentication in the spec for a single request.
1401
+ :type _request_auth: dict, optional
1402
+ :param _content_type: force content-type for the request.
1403
+ :type _content_type: str, Optional
1404
+ :param _headers: set to override the headers for a single
1405
+ request; this effectively ignores the headers
1406
+ in the spec for a single request.
1407
+ :type _headers: dict, optional
1408
+ :param _host_index: set to override the host_index for a single
1409
+ request; this effectively ignores the host_index
1410
+ in the spec for a single request.
1411
+ :type _host_index: int, optional
1412
+ :return: Returns the result object.
1413
+ """ # noqa: E501
1414
+
1415
+ _param = self._delete_subscription_serialize(
1416
+ subscription_id=subscription_id,
1417
+ _request_auth=_request_auth,
1418
+ _content_type=_content_type,
1419
+ _headers=_headers,
1420
+ _host_index=_host_index
1421
+ )
1422
+
1423
+ _response_types_map: Dict[str, Optional[str]] = {
1424
+ '204': None,
1425
+ '400': "SubscriptionBadRequestErrorResponse",
1426
+ '401': "UnexpectedProblemResponse",
1427
+ '403': "UnexpectedProblemResponse",
1428
+ '404': "UnexpectedProblemResponse",
1429
+ '409': "SubscriptionConflictErrorResponse",
1430
+ '412': "UnexpectedProblemResponse",
1431
+ '500': "UnexpectedProblemResponse",
1432
+ '503': "UnexpectedProblemResponse",
1433
+ }
1434
+ response_data = self.api_client.call_api(
1435
+ *_param,
1436
+ _request_timeout=_request_timeout
1437
+ )
1438
+ response_data.read()
1439
+ return self.api_client.response_deserialize(
1440
+ response_data=response_data,
1441
+ response_types_map=_response_types_map,
1442
+ )
1443
+
1444
+
1445
+ @validate_call
1446
+ def delete_subscription_without_preload_content(
1447
+ self,
1448
+ subscription_id: Annotated[str, Field(strict=True)],
1449
+ _request_timeout: Union[
1450
+ None,
1451
+ Annotated[StrictFloat, Field(gt=0)],
1452
+ Tuple[
1453
+ Annotated[StrictFloat, Field(gt=0)],
1454
+ Annotated[StrictFloat, Field(gt=0)]
1455
+ ]
1456
+ ] = None,
1457
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1458
+ _content_type: Optional[StrictStr] = None,
1459
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1460
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1461
+ ) -> RESTResponseType:
1462
+ """Delete subscription
1463
+
1464
+ Deletes a subscription. Only scheduled subscriptions can be deleted.
1465
+
1466
+ :param subscription_id: (required)
1467
+ :type subscription_id: str
1468
+ :param _request_timeout: timeout setting for this request. If one
1469
+ number provided, it will be total request
1470
+ timeout. It can also be a pair (tuple) of
1471
+ (connection, read) timeouts.
1472
+ :type _request_timeout: int, tuple(int, int), optional
1473
+ :param _request_auth: set to override the auth_settings for an a single
1474
+ request; this effectively ignores the
1475
+ authentication in the spec for a single request.
1476
+ :type _request_auth: dict, optional
1477
+ :param _content_type: force content-type for the request.
1478
+ :type _content_type: str, Optional
1479
+ :param _headers: set to override the headers for a single
1480
+ request; this effectively ignores the headers
1481
+ in the spec for a single request.
1482
+ :type _headers: dict, optional
1483
+ :param _host_index: set to override the host_index for a single
1484
+ request; this effectively ignores the host_index
1485
+ in the spec for a single request.
1486
+ :type _host_index: int, optional
1487
+ :return: Returns the result object.
1488
+ """ # noqa: E501
1489
+
1490
+ _param = self._delete_subscription_serialize(
1491
+ subscription_id=subscription_id,
1492
+ _request_auth=_request_auth,
1493
+ _content_type=_content_type,
1494
+ _headers=_headers,
1495
+ _host_index=_host_index
1496
+ )
1497
+
1498
+ _response_types_map: Dict[str, Optional[str]] = {
1499
+ '204': None,
1500
+ '400': "SubscriptionBadRequestErrorResponse",
1501
+ '401': "UnexpectedProblemResponse",
1502
+ '403': "UnexpectedProblemResponse",
1503
+ '404': "UnexpectedProblemResponse",
1504
+ '409': "SubscriptionConflictErrorResponse",
1505
+ '412': "UnexpectedProblemResponse",
1506
+ '500': "UnexpectedProblemResponse",
1507
+ '503': "UnexpectedProblemResponse",
1508
+ }
1509
+ response_data = self.api_client.call_api(
1510
+ *_param,
1511
+ _request_timeout=_request_timeout
1512
+ )
1513
+ return response_data.response
1514
+
1515
+
1516
+ def _delete_subscription_serialize(
1517
+ self,
1518
+ subscription_id,
1519
+ _request_auth,
1520
+ _content_type,
1521
+ _headers,
1522
+ _host_index,
1523
+ ) -> RequestSerialized:
1524
+
1525
+ _host = None
1526
+
1527
+ _collection_formats: Dict[str, str] = {
1528
+ }
1529
+
1530
+ _path_params: Dict[str, str] = {}
1531
+ _query_params: List[Tuple[str, str]] = []
1532
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1533
+ _form_params: List[Tuple[str, str]] = []
1534
+ _files: Dict[
1535
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1536
+ ] = {}
1537
+ _body_params: Optional[bytes] = None
1538
+
1539
+ # process the path parameters
1540
+ if subscription_id is not None:
1541
+ _path_params['subscriptionId'] = subscription_id
1542
+ # process the query parameters
1543
+ # process the header parameters
1544
+ # process the form parameters
1545
+ # process the body parameter
1546
+
1547
+
1548
+ # set the HTTP header `Accept`
1549
+ if 'Accept' not in _header_params:
1550
+ _header_params['Accept'] = self.api_client.select_header_accept(
1551
+ [
1552
+ 'application/problem+json'
1553
+ ]
1554
+ )
1555
+
1556
+
1557
+ # authentication setting
1558
+ _auth_settings: List[str] = [
1559
+ 'CloudTokenAuth'
1560
+ ]
1561
+
1562
+ return self.api_client.param_serialize(
1563
+ method='DELETE',
1564
+ resource_path='/api/v1/subscriptions/{subscriptionId}',
1565
+ path_params=_path_params,
1566
+ query_params=_query_params,
1567
+ header_params=_header_params,
1568
+ body=_body_params,
1569
+ post_params=_form_params,
1570
+ files=_files,
1571
+ auth_settings=_auth_settings,
1572
+ collection_formats=_collection_formats,
1573
+ _host=_host,
1574
+ _request_auth=_request_auth
1575
+ )
1576
+
1577
+
1578
+
1579
+
1580
+ @validate_call
1581
+ def edit_subscription(
1582
+ self,
1583
+ subscription_id: Annotated[str, Field(strict=True)],
1584
+ subscription_edit: SubscriptionEdit,
1585
+ _request_timeout: Union[
1586
+ None,
1587
+ Annotated[StrictFloat, Field(gt=0)],
1588
+ Tuple[
1589
+ Annotated[StrictFloat, Field(gt=0)],
1590
+ Annotated[StrictFloat, Field(gt=0)]
1591
+ ]
1592
+ ] = None,
1593
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1594
+ _content_type: Optional[StrictStr] = None,
1595
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1596
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1597
+ ) -> Subscription:
1598
+ """Edit subscription
1599
+
1600
+ Batch processing commands for manipulating running subscriptions. The key format is `/phases/{phaseKey}` or `/phases/{phaseKey}/items/{itemKey}`.
1601
+
1602
+ :param subscription_id: (required)
1603
+ :type subscription_id: str
1604
+ :param subscription_edit: (required)
1605
+ :type subscription_edit: SubscriptionEdit
1606
+ :param _request_timeout: timeout setting for this request. If one
1607
+ number provided, it will be total request
1608
+ timeout. It can also be a pair (tuple) of
1609
+ (connection, read) timeouts.
1610
+ :type _request_timeout: int, tuple(int, int), optional
1611
+ :param _request_auth: set to override the auth_settings for an a single
1612
+ request; this effectively ignores the
1613
+ authentication in the spec for a single request.
1614
+ :type _request_auth: dict, optional
1615
+ :param _content_type: force content-type for the request.
1616
+ :type _content_type: str, Optional
1617
+ :param _headers: set to override the headers for a single
1618
+ request; this effectively ignores the headers
1619
+ in the spec for a single request.
1620
+ :type _headers: dict, optional
1621
+ :param _host_index: set to override the host_index for a single
1622
+ request; this effectively ignores the host_index
1623
+ in the spec for a single request.
1624
+ :type _host_index: int, optional
1625
+ :return: Returns the result object.
1626
+ """ # noqa: E501
1627
+
1628
+ _param = self._edit_subscription_serialize(
1629
+ subscription_id=subscription_id,
1630
+ subscription_edit=subscription_edit,
1631
+ _request_auth=_request_auth,
1632
+ _content_type=_content_type,
1633
+ _headers=_headers,
1634
+ _host_index=_host_index
1635
+ )
1636
+
1637
+ _response_types_map: Dict[str, Optional[str]] = {
1638
+ '200': "Subscription",
1639
+ '400': "SubscriptionBadRequestErrorResponse",
1640
+ '401': "UnexpectedProblemResponse",
1641
+ '403': "UnexpectedProblemResponse",
1642
+ '404': "UnexpectedProblemResponse",
1643
+ '409': "SubscriptionConflictErrorResponse",
1644
+ '412': "UnexpectedProblemResponse",
1645
+ '500': "UnexpectedProblemResponse",
1646
+ '503': "UnexpectedProblemResponse",
1647
+ }
1648
+ response_data = self.api_client.call_api(
1649
+ *_param,
1650
+ _request_timeout=_request_timeout
1651
+ )
1652
+ response_data.read()
1653
+ return self.api_client.response_deserialize(
1654
+ response_data=response_data,
1655
+ response_types_map=_response_types_map,
1656
+ ).data
1657
+
1658
+
1659
+ @validate_call
1660
+ def edit_subscription_with_http_info(
1661
+ self,
1662
+ subscription_id: Annotated[str, Field(strict=True)],
1663
+ subscription_edit: SubscriptionEdit,
1664
+ _request_timeout: Union[
1665
+ None,
1666
+ Annotated[StrictFloat, Field(gt=0)],
1667
+ Tuple[
1668
+ Annotated[StrictFloat, Field(gt=0)],
1669
+ Annotated[StrictFloat, Field(gt=0)]
1670
+ ]
1671
+ ] = None,
1672
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1673
+ _content_type: Optional[StrictStr] = None,
1674
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1675
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1676
+ ) -> ApiResponse[Subscription]:
1677
+ """Edit subscription
1678
+
1679
+ Batch processing commands for manipulating running subscriptions. The key format is `/phases/{phaseKey}` or `/phases/{phaseKey}/items/{itemKey}`.
1680
+
1681
+ :param subscription_id: (required)
1682
+ :type subscription_id: str
1683
+ :param subscription_edit: (required)
1684
+ :type subscription_edit: SubscriptionEdit
1685
+ :param _request_timeout: timeout setting for this request. If one
1686
+ number provided, it will be total request
1687
+ timeout. It can also be a pair (tuple) of
1688
+ (connection, read) timeouts.
1689
+ :type _request_timeout: int, tuple(int, int), optional
1690
+ :param _request_auth: set to override the auth_settings for an a single
1691
+ request; this effectively ignores the
1692
+ authentication in the spec for a single request.
1693
+ :type _request_auth: dict, optional
1694
+ :param _content_type: force content-type for the request.
1695
+ :type _content_type: str, Optional
1696
+ :param _headers: set to override the headers for a single
1697
+ request; this effectively ignores the headers
1698
+ in the spec for a single request.
1699
+ :type _headers: dict, optional
1700
+ :param _host_index: set to override the host_index for a single
1701
+ request; this effectively ignores the host_index
1702
+ in the spec for a single request.
1703
+ :type _host_index: int, optional
1704
+ :return: Returns the result object.
1705
+ """ # noqa: E501
1706
+
1707
+ _param = self._edit_subscription_serialize(
1708
+ subscription_id=subscription_id,
1709
+ subscription_edit=subscription_edit,
1710
+ _request_auth=_request_auth,
1711
+ _content_type=_content_type,
1712
+ _headers=_headers,
1713
+ _host_index=_host_index
1714
+ )
1715
+
1716
+ _response_types_map: Dict[str, Optional[str]] = {
1717
+ '200': "Subscription",
1718
+ '400': "SubscriptionBadRequestErrorResponse",
1719
+ '401': "UnexpectedProblemResponse",
1720
+ '403': "UnexpectedProblemResponse",
1721
+ '404': "UnexpectedProblemResponse",
1722
+ '409': "SubscriptionConflictErrorResponse",
1723
+ '412': "UnexpectedProblemResponse",
1724
+ '500': "UnexpectedProblemResponse",
1725
+ '503': "UnexpectedProblemResponse",
1726
+ }
1727
+ response_data = self.api_client.call_api(
1728
+ *_param,
1729
+ _request_timeout=_request_timeout
1730
+ )
1731
+ response_data.read()
1732
+ return self.api_client.response_deserialize(
1733
+ response_data=response_data,
1734
+ response_types_map=_response_types_map,
1735
+ )
1736
+
1737
+
1738
+ @validate_call
1739
+ def edit_subscription_without_preload_content(
1740
+ self,
1741
+ subscription_id: Annotated[str, Field(strict=True)],
1742
+ subscription_edit: SubscriptionEdit,
1743
+ _request_timeout: Union[
1744
+ None,
1745
+ Annotated[StrictFloat, Field(gt=0)],
1746
+ Tuple[
1747
+ Annotated[StrictFloat, Field(gt=0)],
1748
+ Annotated[StrictFloat, Field(gt=0)]
1749
+ ]
1750
+ ] = None,
1751
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1752
+ _content_type: Optional[StrictStr] = None,
1753
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1754
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1755
+ ) -> RESTResponseType:
1756
+ """Edit subscription
1757
+
1758
+ Batch processing commands for manipulating running subscriptions. The key format is `/phases/{phaseKey}` or `/phases/{phaseKey}/items/{itemKey}`.
1759
+
1760
+ :param subscription_id: (required)
1761
+ :type subscription_id: str
1762
+ :param subscription_edit: (required)
1763
+ :type subscription_edit: SubscriptionEdit
1764
+ :param _request_timeout: timeout setting for this request. If one
1765
+ number provided, it will be total request
1766
+ timeout. It can also be a pair (tuple) of
1767
+ (connection, read) timeouts.
1768
+ :type _request_timeout: int, tuple(int, int), optional
1769
+ :param _request_auth: set to override the auth_settings for an a single
1770
+ request; this effectively ignores the
1771
+ authentication in the spec for a single request.
1772
+ :type _request_auth: dict, optional
1773
+ :param _content_type: force content-type for the request.
1774
+ :type _content_type: str, Optional
1775
+ :param _headers: set to override the headers for a single
1776
+ request; this effectively ignores the headers
1777
+ in the spec for a single request.
1778
+ :type _headers: dict, optional
1779
+ :param _host_index: set to override the host_index for a single
1780
+ request; this effectively ignores the host_index
1781
+ in the spec for a single request.
1782
+ :type _host_index: int, optional
1783
+ :return: Returns the result object.
1784
+ """ # noqa: E501
1785
+
1786
+ _param = self._edit_subscription_serialize(
1787
+ subscription_id=subscription_id,
1788
+ subscription_edit=subscription_edit,
1789
+ _request_auth=_request_auth,
1790
+ _content_type=_content_type,
1791
+ _headers=_headers,
1792
+ _host_index=_host_index
1793
+ )
1794
+
1795
+ _response_types_map: Dict[str, Optional[str]] = {
1796
+ '200': "Subscription",
1797
+ '400': "SubscriptionBadRequestErrorResponse",
1798
+ '401': "UnexpectedProblemResponse",
1799
+ '403': "UnexpectedProblemResponse",
1800
+ '404': "UnexpectedProblemResponse",
1801
+ '409': "SubscriptionConflictErrorResponse",
1802
+ '412': "UnexpectedProblemResponse",
1803
+ '500': "UnexpectedProblemResponse",
1804
+ '503': "UnexpectedProblemResponse",
1805
+ }
1806
+ response_data = self.api_client.call_api(
1807
+ *_param,
1808
+ _request_timeout=_request_timeout
1809
+ )
1810
+ return response_data.response
1811
+
1812
+
1813
+ def _edit_subscription_serialize(
1814
+ self,
1815
+ subscription_id,
1816
+ subscription_edit,
1817
+ _request_auth,
1818
+ _content_type,
1819
+ _headers,
1820
+ _host_index,
1821
+ ) -> RequestSerialized:
1822
+
1823
+ _host = None
1824
+
1825
+ _collection_formats: Dict[str, str] = {
1826
+ }
1827
+
1828
+ _path_params: Dict[str, str] = {}
1829
+ _query_params: List[Tuple[str, str]] = []
1830
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1831
+ _form_params: List[Tuple[str, str]] = []
1832
+ _files: Dict[
1833
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1834
+ ] = {}
1835
+ _body_params: Optional[bytes] = None
1836
+
1837
+ # process the path parameters
1838
+ if subscription_id is not None:
1839
+ _path_params['subscriptionId'] = subscription_id
1840
+ # process the query parameters
1841
+ # process the header parameters
1842
+ # process the form parameters
1843
+ # process the body parameter
1844
+ if subscription_edit is not None:
1845
+ _body_params = subscription_edit
1846
+
1847
+
1848
+ # set the HTTP header `Accept`
1849
+ if 'Accept' not in _header_params:
1850
+ _header_params['Accept'] = self.api_client.select_header_accept(
1851
+ [
1852
+ 'application/json',
1853
+ 'application/problem+json'
1854
+ ]
1855
+ )
1856
+
1857
+ # set the HTTP header `Content-Type`
1858
+ if _content_type:
1859
+ _header_params['Content-Type'] = _content_type
1860
+ else:
1861
+ _default_content_type = (
1862
+ self.api_client.select_header_content_type(
1863
+ [
1864
+ 'application/json'
1865
+ ]
1866
+ )
1867
+ )
1868
+ if _default_content_type is not None:
1869
+ _header_params['Content-Type'] = _default_content_type
1870
+
1871
+ # authentication setting
1872
+ _auth_settings: List[str] = [
1873
+ 'CloudTokenAuth'
1874
+ ]
1875
+
1876
+ return self.api_client.param_serialize(
1877
+ method='PATCH',
1878
+ resource_path='/api/v1/subscriptions/{subscriptionId}',
1879
+ path_params=_path_params,
1880
+ query_params=_query_params,
1881
+ header_params=_header_params,
1882
+ body=_body_params,
1883
+ post_params=_form_params,
1884
+ files=_files,
1885
+ auth_settings=_auth_settings,
1886
+ collection_formats=_collection_formats,
1887
+ _host=_host,
1888
+ _request_auth=_request_auth
1889
+ )
1890
+
1891
+
1892
+
1893
+
1894
+ @validate_call
1895
+ def get_subscription_addon(
1896
+ self,
1897
+ subscription_id: Annotated[str, Field(strict=True)],
1898
+ subscription_addon_id: Annotated[str, Field(strict=True)],
1899
+ _request_timeout: Union[
1900
+ None,
1901
+ Annotated[StrictFloat, Field(gt=0)],
1902
+ Tuple[
1903
+ Annotated[StrictFloat, Field(gt=0)],
1904
+ Annotated[StrictFloat, Field(gt=0)]
1905
+ ]
1906
+ ] = None,
1907
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1908
+ _content_type: Optional[StrictStr] = None,
1909
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1910
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1911
+ ) -> SubscriptionAddon:
1912
+ """Get subscription addon
1913
+
1914
+ Get a subscription addon by id.
1915
+
1916
+ :param subscription_id: (required)
1917
+ :type subscription_id: str
1918
+ :param subscription_addon_id: (required)
1919
+ :type subscription_addon_id: str
1920
+ :param _request_timeout: timeout setting for this request. If one
1921
+ number provided, it will be total request
1922
+ timeout. It can also be a pair (tuple) of
1923
+ (connection, read) timeouts.
1924
+ :type _request_timeout: int, tuple(int, int), optional
1925
+ :param _request_auth: set to override the auth_settings for an a single
1926
+ request; this effectively ignores the
1927
+ authentication in the spec for a single request.
1928
+ :type _request_auth: dict, optional
1929
+ :param _content_type: force content-type for the request.
1930
+ :type _content_type: str, Optional
1931
+ :param _headers: set to override the headers for a single
1932
+ request; this effectively ignores the headers
1933
+ in the spec for a single request.
1934
+ :type _headers: dict, optional
1935
+ :param _host_index: set to override the host_index for a single
1936
+ request; this effectively ignores the host_index
1937
+ in the spec for a single request.
1938
+ :type _host_index: int, optional
1939
+ :return: Returns the result object.
1940
+ """ # noqa: E501
1941
+
1942
+ _param = self._get_subscription_addon_serialize(
1943
+ subscription_id=subscription_id,
1944
+ subscription_addon_id=subscription_addon_id,
1945
+ _request_auth=_request_auth,
1946
+ _content_type=_content_type,
1947
+ _headers=_headers,
1948
+ _host_index=_host_index
1949
+ )
1950
+
1951
+ _response_types_map: Dict[str, Optional[str]] = {
1952
+ '200': "SubscriptionAddon",
1953
+ '400': "UnexpectedProblemResponse",
1954
+ '401': "UnexpectedProblemResponse",
1955
+ '403': "UnexpectedProblemResponse",
1956
+ '404': "UnexpectedProblemResponse",
1957
+ '412': "UnexpectedProblemResponse",
1958
+ '500': "UnexpectedProblemResponse",
1959
+ '503': "UnexpectedProblemResponse",
1960
+ }
1961
+ response_data = self.api_client.call_api(
1962
+ *_param,
1963
+ _request_timeout=_request_timeout
1964
+ )
1965
+ response_data.read()
1966
+ return self.api_client.response_deserialize(
1967
+ response_data=response_data,
1968
+ response_types_map=_response_types_map,
1969
+ ).data
1970
+
1971
+
1972
+ @validate_call
1973
+ def get_subscription_addon_with_http_info(
1974
+ self,
1975
+ subscription_id: Annotated[str, Field(strict=True)],
1976
+ subscription_addon_id: Annotated[str, Field(strict=True)],
1977
+ _request_timeout: Union[
1978
+ None,
1979
+ Annotated[StrictFloat, Field(gt=0)],
1980
+ Tuple[
1981
+ Annotated[StrictFloat, Field(gt=0)],
1982
+ Annotated[StrictFloat, Field(gt=0)]
1983
+ ]
1984
+ ] = None,
1985
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1986
+ _content_type: Optional[StrictStr] = None,
1987
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1988
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1989
+ ) -> ApiResponse[SubscriptionAddon]:
1990
+ """Get subscription addon
1991
+
1992
+ Get a subscription addon by id.
1993
+
1994
+ :param subscription_id: (required)
1995
+ :type subscription_id: str
1996
+ :param subscription_addon_id: (required)
1997
+ :type subscription_addon_id: str
1998
+ :param _request_timeout: timeout setting for this request. If one
1999
+ number provided, it will be total request
2000
+ timeout. It can also be a pair (tuple) of
2001
+ (connection, read) timeouts.
2002
+ :type _request_timeout: int, tuple(int, int), optional
2003
+ :param _request_auth: set to override the auth_settings for an a single
2004
+ request; this effectively ignores the
2005
+ authentication in the spec for a single request.
2006
+ :type _request_auth: dict, optional
2007
+ :param _content_type: force content-type for the request.
2008
+ :type _content_type: str, Optional
2009
+ :param _headers: set to override the headers for a single
2010
+ request; this effectively ignores the headers
2011
+ in the spec for a single request.
2012
+ :type _headers: dict, optional
2013
+ :param _host_index: set to override the host_index for a single
2014
+ request; this effectively ignores the host_index
2015
+ in the spec for a single request.
2016
+ :type _host_index: int, optional
2017
+ :return: Returns the result object.
2018
+ """ # noqa: E501
2019
+
2020
+ _param = self._get_subscription_addon_serialize(
2021
+ subscription_id=subscription_id,
2022
+ subscription_addon_id=subscription_addon_id,
2023
+ _request_auth=_request_auth,
2024
+ _content_type=_content_type,
2025
+ _headers=_headers,
2026
+ _host_index=_host_index
2027
+ )
2028
+
2029
+ _response_types_map: Dict[str, Optional[str]] = {
2030
+ '200': "SubscriptionAddon",
2031
+ '400': "UnexpectedProblemResponse",
2032
+ '401': "UnexpectedProblemResponse",
2033
+ '403': "UnexpectedProblemResponse",
2034
+ '404': "UnexpectedProblemResponse",
2035
+ '412': "UnexpectedProblemResponse",
2036
+ '500': "UnexpectedProblemResponse",
2037
+ '503': "UnexpectedProblemResponse",
2038
+ }
2039
+ response_data = self.api_client.call_api(
2040
+ *_param,
2041
+ _request_timeout=_request_timeout
2042
+ )
2043
+ response_data.read()
2044
+ return self.api_client.response_deserialize(
2045
+ response_data=response_data,
2046
+ response_types_map=_response_types_map,
2047
+ )
2048
+
2049
+
2050
+ @validate_call
2051
+ def get_subscription_addon_without_preload_content(
2052
+ self,
2053
+ subscription_id: Annotated[str, Field(strict=True)],
2054
+ subscription_addon_id: Annotated[str, Field(strict=True)],
2055
+ _request_timeout: Union[
2056
+ None,
2057
+ Annotated[StrictFloat, Field(gt=0)],
2058
+ Tuple[
2059
+ Annotated[StrictFloat, Field(gt=0)],
2060
+ Annotated[StrictFloat, Field(gt=0)]
2061
+ ]
2062
+ ] = None,
2063
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2064
+ _content_type: Optional[StrictStr] = None,
2065
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2066
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2067
+ ) -> RESTResponseType:
2068
+ """Get subscription addon
2069
+
2070
+ Get a subscription addon by id.
2071
+
2072
+ :param subscription_id: (required)
2073
+ :type subscription_id: str
2074
+ :param subscription_addon_id: (required)
2075
+ :type subscription_addon_id: str
2076
+ :param _request_timeout: timeout setting for this request. If one
2077
+ number provided, it will be total request
2078
+ timeout. It can also be a pair (tuple) of
2079
+ (connection, read) timeouts.
2080
+ :type _request_timeout: int, tuple(int, int), optional
2081
+ :param _request_auth: set to override the auth_settings for an a single
2082
+ request; this effectively ignores the
2083
+ authentication in the spec for a single request.
2084
+ :type _request_auth: dict, optional
2085
+ :param _content_type: force content-type for the request.
2086
+ :type _content_type: str, Optional
2087
+ :param _headers: set to override the headers for a single
2088
+ request; this effectively ignores the headers
2089
+ in the spec for a single request.
2090
+ :type _headers: dict, optional
2091
+ :param _host_index: set to override the host_index for a single
2092
+ request; this effectively ignores the host_index
2093
+ in the spec for a single request.
2094
+ :type _host_index: int, optional
2095
+ :return: Returns the result object.
2096
+ """ # noqa: E501
2097
+
2098
+ _param = self._get_subscription_addon_serialize(
2099
+ subscription_id=subscription_id,
2100
+ subscription_addon_id=subscription_addon_id,
2101
+ _request_auth=_request_auth,
2102
+ _content_type=_content_type,
2103
+ _headers=_headers,
2104
+ _host_index=_host_index
2105
+ )
2106
+
2107
+ _response_types_map: Dict[str, Optional[str]] = {
2108
+ '200': "SubscriptionAddon",
2109
+ '400': "UnexpectedProblemResponse",
2110
+ '401': "UnexpectedProblemResponse",
2111
+ '403': "UnexpectedProblemResponse",
2112
+ '404': "UnexpectedProblemResponse",
2113
+ '412': "UnexpectedProblemResponse",
2114
+ '500': "UnexpectedProblemResponse",
2115
+ '503': "UnexpectedProblemResponse",
2116
+ }
2117
+ response_data = self.api_client.call_api(
2118
+ *_param,
2119
+ _request_timeout=_request_timeout
2120
+ )
2121
+ return response_data.response
2122
+
2123
+
2124
+ def _get_subscription_addon_serialize(
2125
+ self,
2126
+ subscription_id,
2127
+ subscription_addon_id,
2128
+ _request_auth,
2129
+ _content_type,
2130
+ _headers,
2131
+ _host_index,
2132
+ ) -> RequestSerialized:
2133
+
2134
+ _host = None
2135
+
2136
+ _collection_formats: Dict[str, str] = {
2137
+ }
2138
+
2139
+ _path_params: Dict[str, str] = {}
2140
+ _query_params: List[Tuple[str, str]] = []
2141
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2142
+ _form_params: List[Tuple[str, str]] = []
2143
+ _files: Dict[
2144
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2145
+ ] = {}
2146
+ _body_params: Optional[bytes] = None
2147
+
2148
+ # process the path parameters
2149
+ if subscription_id is not None:
2150
+ _path_params['subscriptionId'] = subscription_id
2151
+ if subscription_addon_id is not None:
2152
+ _path_params['subscriptionAddonId'] = subscription_addon_id
2153
+ # process the query parameters
2154
+ # process the header parameters
2155
+ # process the form parameters
2156
+ # process the body parameter
2157
+
2158
+
2159
+ # set the HTTP header `Accept`
2160
+ if 'Accept' not in _header_params:
2161
+ _header_params['Accept'] = self.api_client.select_header_accept(
2162
+ [
2163
+ 'application/json',
2164
+ 'application/problem+json'
2165
+ ]
2166
+ )
2167
+
2168
+
2169
+ # authentication setting
2170
+ _auth_settings: List[str] = [
2171
+ 'CloudTokenAuth'
2172
+ ]
2173
+
2174
+ return self.api_client.param_serialize(
2175
+ method='GET',
2176
+ resource_path='/api/v1/subscriptions/{subscriptionId}/addons/{subscriptionAddonId}',
2177
+ path_params=_path_params,
2178
+ query_params=_query_params,
2179
+ header_params=_header_params,
2180
+ body=_body_params,
2181
+ post_params=_form_params,
2182
+ files=_files,
2183
+ auth_settings=_auth_settings,
2184
+ collection_formats=_collection_formats,
2185
+ _host=_host,
2186
+ _request_auth=_request_auth
2187
+ )
2188
+
2189
+
2190
+
2191
+
2192
+ @validate_call
2193
+ def get_subscription_get(
2194
+ self,
2195
+ subscription_id: Annotated[str, Field(strict=True)],
2196
+ at: Annotated[Optional[datetime], Field(description="The time at which the subscription should be queried. If not provided the current time is used.")] = None,
2197
+ _request_timeout: Union[
2198
+ None,
2199
+ Annotated[StrictFloat, Field(gt=0)],
2200
+ Tuple[
2201
+ Annotated[StrictFloat, Field(gt=0)],
2202
+ Annotated[StrictFloat, Field(gt=0)]
2203
+ ]
2204
+ ] = None,
2205
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2206
+ _content_type: Optional[StrictStr] = None,
2207
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2208
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2209
+ ) -> SubscriptionExpanded:
2210
+ """Get subscription
2211
+
2212
+
2213
+ :param subscription_id: (required)
2214
+ :type subscription_id: str
2215
+ :param at: The time at which the subscription should be queried. If not provided the current time is used.
2216
+ :type at: datetime
2217
+ :param _request_timeout: timeout setting for this request. If one
2218
+ number provided, it will be total request
2219
+ timeout. It can also be a pair (tuple) of
2220
+ (connection, read) timeouts.
2221
+ :type _request_timeout: int, tuple(int, int), optional
2222
+ :param _request_auth: set to override the auth_settings for an a single
2223
+ request; this effectively ignores the
2224
+ authentication in the spec for a single request.
2225
+ :type _request_auth: dict, optional
2226
+ :param _content_type: force content-type for the request.
2227
+ :type _content_type: str, Optional
2228
+ :param _headers: set to override the headers for a single
2229
+ request; this effectively ignores the headers
2230
+ in the spec for a single request.
2231
+ :type _headers: dict, optional
2232
+ :param _host_index: set to override the host_index for a single
2233
+ request; this effectively ignores the host_index
2234
+ in the spec for a single request.
2235
+ :type _host_index: int, optional
2236
+ :return: Returns the result object.
2237
+ """ # noqa: E501
2238
+
2239
+ _param = self._get_subscription_get_serialize(
2240
+ subscription_id=subscription_id,
2241
+ at=at,
2242
+ _request_auth=_request_auth,
2243
+ _content_type=_content_type,
2244
+ _headers=_headers,
2245
+ _host_index=_host_index
2246
+ )
2247
+
2248
+ _response_types_map: Dict[str, Optional[str]] = {
2249
+ '200': "SubscriptionExpanded",
2250
+ '400': "UnexpectedProblemResponse",
2251
+ '401': "UnexpectedProblemResponse",
2252
+ '403': "UnexpectedProblemResponse",
2253
+ '404': "UnexpectedProblemResponse",
2254
+ '412': "UnexpectedProblemResponse",
2255
+ '500': "UnexpectedProblemResponse",
2256
+ '503': "UnexpectedProblemResponse",
2257
+ }
2258
+ response_data = self.api_client.call_api(
2259
+ *_param,
2260
+ _request_timeout=_request_timeout
2261
+ )
2262
+ response_data.read()
2263
+ return self.api_client.response_deserialize(
2264
+ response_data=response_data,
2265
+ response_types_map=_response_types_map,
2266
+ ).data
2267
+
2268
+
2269
+ @validate_call
2270
+ def get_subscription_get_with_http_info(
2271
+ self,
2272
+ subscription_id: Annotated[str, Field(strict=True)],
2273
+ at: Annotated[Optional[datetime], Field(description="The time at which the subscription should be queried. If not provided the current time is used.")] = None,
2274
+ _request_timeout: Union[
2275
+ None,
2276
+ Annotated[StrictFloat, Field(gt=0)],
2277
+ Tuple[
2278
+ Annotated[StrictFloat, Field(gt=0)],
2279
+ Annotated[StrictFloat, Field(gt=0)]
2280
+ ]
2281
+ ] = None,
2282
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2283
+ _content_type: Optional[StrictStr] = None,
2284
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2285
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2286
+ ) -> ApiResponse[SubscriptionExpanded]:
2287
+ """Get subscription
2288
+
2289
+
2290
+ :param subscription_id: (required)
2291
+ :type subscription_id: str
2292
+ :param at: The time at which the subscription should be queried. If not provided the current time is used.
2293
+ :type at: datetime
2294
+ :param _request_timeout: timeout setting for this request. If one
2295
+ number provided, it will be total request
2296
+ timeout. It can also be a pair (tuple) of
2297
+ (connection, read) timeouts.
2298
+ :type _request_timeout: int, tuple(int, int), optional
2299
+ :param _request_auth: set to override the auth_settings for an a single
2300
+ request; this effectively ignores the
2301
+ authentication in the spec for a single request.
2302
+ :type _request_auth: dict, optional
2303
+ :param _content_type: force content-type for the request.
2304
+ :type _content_type: str, Optional
2305
+ :param _headers: set to override the headers for a single
2306
+ request; this effectively ignores the headers
2307
+ in the spec for a single request.
2308
+ :type _headers: dict, optional
2309
+ :param _host_index: set to override the host_index for a single
2310
+ request; this effectively ignores the host_index
2311
+ in the spec for a single request.
2312
+ :type _host_index: int, optional
2313
+ :return: Returns the result object.
2314
+ """ # noqa: E501
2315
+
2316
+ _param = self._get_subscription_get_serialize(
2317
+ subscription_id=subscription_id,
2318
+ at=at,
2319
+ _request_auth=_request_auth,
2320
+ _content_type=_content_type,
2321
+ _headers=_headers,
2322
+ _host_index=_host_index
2323
+ )
2324
+
2325
+ _response_types_map: Dict[str, Optional[str]] = {
2326
+ '200': "SubscriptionExpanded",
2327
+ '400': "UnexpectedProblemResponse",
2328
+ '401': "UnexpectedProblemResponse",
2329
+ '403': "UnexpectedProblemResponse",
2330
+ '404': "UnexpectedProblemResponse",
2331
+ '412': "UnexpectedProblemResponse",
2332
+ '500': "UnexpectedProblemResponse",
2333
+ '503': "UnexpectedProblemResponse",
2334
+ }
2335
+ response_data = self.api_client.call_api(
2336
+ *_param,
2337
+ _request_timeout=_request_timeout
2338
+ )
2339
+ response_data.read()
2340
+ return self.api_client.response_deserialize(
2341
+ response_data=response_data,
2342
+ response_types_map=_response_types_map,
2343
+ )
2344
+
2345
+
2346
+ @validate_call
2347
+ def get_subscription_get_without_preload_content(
2348
+ self,
2349
+ subscription_id: Annotated[str, Field(strict=True)],
2350
+ at: Annotated[Optional[datetime], Field(description="The time at which the subscription should be queried. If not provided the current time is used.")] = None,
2351
+ _request_timeout: Union[
2352
+ None,
2353
+ Annotated[StrictFloat, Field(gt=0)],
2354
+ Tuple[
2355
+ Annotated[StrictFloat, Field(gt=0)],
2356
+ Annotated[StrictFloat, Field(gt=0)]
2357
+ ]
2358
+ ] = None,
2359
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2360
+ _content_type: Optional[StrictStr] = None,
2361
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2362
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2363
+ ) -> RESTResponseType:
2364
+ """Get subscription
2365
+
2366
+
2367
+ :param subscription_id: (required)
2368
+ :type subscription_id: str
2369
+ :param at: The time at which the subscription should be queried. If not provided the current time is used.
2370
+ :type at: datetime
2371
+ :param _request_timeout: timeout setting for this request. If one
2372
+ number provided, it will be total request
2373
+ timeout. It can also be a pair (tuple) of
2374
+ (connection, read) timeouts.
2375
+ :type _request_timeout: int, tuple(int, int), optional
2376
+ :param _request_auth: set to override the auth_settings for an a single
2377
+ request; this effectively ignores the
2378
+ authentication in the spec for a single request.
2379
+ :type _request_auth: dict, optional
2380
+ :param _content_type: force content-type for the request.
2381
+ :type _content_type: str, Optional
2382
+ :param _headers: set to override the headers for a single
2383
+ request; this effectively ignores the headers
2384
+ in the spec for a single request.
2385
+ :type _headers: dict, optional
2386
+ :param _host_index: set to override the host_index for a single
2387
+ request; this effectively ignores the host_index
2388
+ in the spec for a single request.
2389
+ :type _host_index: int, optional
2390
+ :return: Returns the result object.
2391
+ """ # noqa: E501
2392
+
2393
+ _param = self._get_subscription_get_serialize(
2394
+ subscription_id=subscription_id,
2395
+ at=at,
2396
+ _request_auth=_request_auth,
2397
+ _content_type=_content_type,
2398
+ _headers=_headers,
2399
+ _host_index=_host_index
2400
+ )
2401
+
2402
+ _response_types_map: Dict[str, Optional[str]] = {
2403
+ '200': "SubscriptionExpanded",
2404
+ '400': "UnexpectedProblemResponse",
2405
+ '401': "UnexpectedProblemResponse",
2406
+ '403': "UnexpectedProblemResponse",
2407
+ '404': "UnexpectedProblemResponse",
2408
+ '412': "UnexpectedProblemResponse",
2409
+ '500': "UnexpectedProblemResponse",
2410
+ '503': "UnexpectedProblemResponse",
2411
+ }
2412
+ response_data = self.api_client.call_api(
2413
+ *_param,
2414
+ _request_timeout=_request_timeout
2415
+ )
2416
+ return response_data.response
2417
+
2418
+
2419
+ def _get_subscription_get_serialize(
2420
+ self,
2421
+ subscription_id,
2422
+ at,
2423
+ _request_auth,
2424
+ _content_type,
2425
+ _headers,
2426
+ _host_index,
2427
+ ) -> RequestSerialized:
2428
+
2429
+ _host = None
2430
+
2431
+ _collection_formats: Dict[str, str] = {
2432
+ }
2433
+
2434
+ _path_params: Dict[str, str] = {}
2435
+ _query_params: List[Tuple[str, str]] = []
2436
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2437
+ _form_params: List[Tuple[str, str]] = []
2438
+ _files: Dict[
2439
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2440
+ ] = {}
2441
+ _body_params: Optional[bytes] = None
2442
+
2443
+ # process the path parameters
2444
+ if subscription_id is not None:
2445
+ _path_params['subscriptionId'] = subscription_id
2446
+ # process the query parameters
2447
+ if at is not None:
2448
+ if isinstance(at, datetime):
2449
+ _query_params.append(
2450
+ (
2451
+ 'at',
2452
+ at.strftime(
2453
+ self.api_client.configuration.datetime_format
2454
+ )
2455
+ )
2456
+ )
2457
+ else:
2458
+ _query_params.append(('at', at))
2459
+
2460
+ # process the header parameters
2461
+ # process the form parameters
2462
+ # process the body parameter
2463
+
2464
+
2465
+ # set the HTTP header `Accept`
2466
+ if 'Accept' not in _header_params:
2467
+ _header_params['Accept'] = self.api_client.select_header_accept(
2468
+ [
2469
+ 'application/json',
2470
+ 'application/problem+json'
2471
+ ]
2472
+ )
2473
+
2474
+
2475
+ # authentication setting
2476
+ _auth_settings: List[str] = [
2477
+ 'CloudTokenAuth'
2478
+ ]
2479
+
2480
+ return self.api_client.param_serialize(
2481
+ method='GET',
2482
+ resource_path='/api/v1/subscriptions/{subscriptionId}',
2483
+ path_params=_path_params,
2484
+ query_params=_query_params,
2485
+ header_params=_header_params,
2486
+ body=_body_params,
2487
+ post_params=_form_params,
2488
+ files=_files,
2489
+ auth_settings=_auth_settings,
2490
+ collection_formats=_collection_formats,
2491
+ _host=_host,
2492
+ _request_auth=_request_auth
2493
+ )
2494
+
2495
+
2496
+
2497
+
2498
+ @validate_call
2499
+ def list_subscription_addons(
2500
+ self,
2501
+ subscription_id: Annotated[str, Field(strict=True)],
2502
+ _request_timeout: Union[
2503
+ None,
2504
+ Annotated[StrictFloat, Field(gt=0)],
2505
+ Tuple[
2506
+ Annotated[StrictFloat, Field(gt=0)],
2507
+ Annotated[StrictFloat, Field(gt=0)]
2508
+ ]
2509
+ ] = None,
2510
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2511
+ _content_type: Optional[StrictStr] = None,
2512
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2513
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2514
+ ) -> List[SubscriptionAddon]:
2515
+ """List subscription addons
2516
+
2517
+ List all addons of a subscription. In the returned list will match to a set unique by addonId.
2518
+
2519
+ :param subscription_id: (required)
2520
+ :type subscription_id: str
2521
+ :param _request_timeout: timeout setting for this request. If one
2522
+ number provided, it will be total request
2523
+ timeout. It can also be a pair (tuple) of
2524
+ (connection, read) timeouts.
2525
+ :type _request_timeout: int, tuple(int, int), optional
2526
+ :param _request_auth: set to override the auth_settings for an a single
2527
+ request; this effectively ignores the
2528
+ authentication in the spec for a single request.
2529
+ :type _request_auth: dict, optional
2530
+ :param _content_type: force content-type for the request.
2531
+ :type _content_type: str, Optional
2532
+ :param _headers: set to override the headers for a single
2533
+ request; this effectively ignores the headers
2534
+ in the spec for a single request.
2535
+ :type _headers: dict, optional
2536
+ :param _host_index: set to override the host_index for a single
2537
+ request; this effectively ignores the host_index
2538
+ in the spec for a single request.
2539
+ :type _host_index: int, optional
2540
+ :return: Returns the result object.
2541
+ """ # noqa: E501
2542
+
2543
+ _param = self._list_subscription_addons_serialize(
2544
+ subscription_id=subscription_id,
2545
+ _request_auth=_request_auth,
2546
+ _content_type=_content_type,
2547
+ _headers=_headers,
2548
+ _host_index=_host_index
2549
+ )
2550
+
2551
+ _response_types_map: Dict[str, Optional[str]] = {
2552
+ '200': "List[SubscriptionAddon]",
2553
+ '400': "UnexpectedProblemResponse",
2554
+ '401': "UnexpectedProblemResponse",
2555
+ '403': "UnexpectedProblemResponse",
2556
+ '404': "UnexpectedProblemResponse",
2557
+ '412': "UnexpectedProblemResponse",
2558
+ '500': "UnexpectedProblemResponse",
2559
+ '503': "UnexpectedProblemResponse",
2560
+ }
2561
+ response_data = self.api_client.call_api(
2562
+ *_param,
2563
+ _request_timeout=_request_timeout
2564
+ )
2565
+ response_data.read()
2566
+ return self.api_client.response_deserialize(
2567
+ response_data=response_data,
2568
+ response_types_map=_response_types_map,
2569
+ ).data
2570
+
2571
+
2572
+ @validate_call
2573
+ def list_subscription_addons_with_http_info(
2574
+ self,
2575
+ subscription_id: Annotated[str, Field(strict=True)],
2576
+ _request_timeout: Union[
2577
+ None,
2578
+ Annotated[StrictFloat, Field(gt=0)],
2579
+ Tuple[
2580
+ Annotated[StrictFloat, Field(gt=0)],
2581
+ Annotated[StrictFloat, Field(gt=0)]
2582
+ ]
2583
+ ] = None,
2584
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2585
+ _content_type: Optional[StrictStr] = None,
2586
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2587
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2588
+ ) -> ApiResponse[List[SubscriptionAddon]]:
2589
+ """List subscription addons
2590
+
2591
+ List all addons of a subscription. In the returned list will match to a set unique by addonId.
2592
+
2593
+ :param subscription_id: (required)
2594
+ :type subscription_id: str
2595
+ :param _request_timeout: timeout setting for this request. If one
2596
+ number provided, it will be total request
2597
+ timeout. It can also be a pair (tuple) of
2598
+ (connection, read) timeouts.
2599
+ :type _request_timeout: int, tuple(int, int), optional
2600
+ :param _request_auth: set to override the auth_settings for an a single
2601
+ request; this effectively ignores the
2602
+ authentication in the spec for a single request.
2603
+ :type _request_auth: dict, optional
2604
+ :param _content_type: force content-type for the request.
2605
+ :type _content_type: str, Optional
2606
+ :param _headers: set to override the headers for a single
2607
+ request; this effectively ignores the headers
2608
+ in the spec for a single request.
2609
+ :type _headers: dict, optional
2610
+ :param _host_index: set to override the host_index for a single
2611
+ request; this effectively ignores the host_index
2612
+ in the spec for a single request.
2613
+ :type _host_index: int, optional
2614
+ :return: Returns the result object.
2615
+ """ # noqa: E501
2616
+
2617
+ _param = self._list_subscription_addons_serialize(
2618
+ subscription_id=subscription_id,
2619
+ _request_auth=_request_auth,
2620
+ _content_type=_content_type,
2621
+ _headers=_headers,
2622
+ _host_index=_host_index
2623
+ )
2624
+
2625
+ _response_types_map: Dict[str, Optional[str]] = {
2626
+ '200': "List[SubscriptionAddon]",
2627
+ '400': "UnexpectedProblemResponse",
2628
+ '401': "UnexpectedProblemResponse",
2629
+ '403': "UnexpectedProblemResponse",
2630
+ '404': "UnexpectedProblemResponse",
2631
+ '412': "UnexpectedProblemResponse",
2632
+ '500': "UnexpectedProblemResponse",
2633
+ '503': "UnexpectedProblemResponse",
2634
+ }
2635
+ response_data = self.api_client.call_api(
2636
+ *_param,
2637
+ _request_timeout=_request_timeout
2638
+ )
2639
+ response_data.read()
2640
+ return self.api_client.response_deserialize(
2641
+ response_data=response_data,
2642
+ response_types_map=_response_types_map,
2643
+ )
2644
+
2645
+
2646
+ @validate_call
2647
+ def list_subscription_addons_without_preload_content(
2648
+ self,
2649
+ subscription_id: Annotated[str, Field(strict=True)],
2650
+ _request_timeout: Union[
2651
+ None,
2652
+ Annotated[StrictFloat, Field(gt=0)],
2653
+ Tuple[
2654
+ Annotated[StrictFloat, Field(gt=0)],
2655
+ Annotated[StrictFloat, Field(gt=0)]
2656
+ ]
2657
+ ] = None,
2658
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2659
+ _content_type: Optional[StrictStr] = None,
2660
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2661
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2662
+ ) -> RESTResponseType:
2663
+ """List subscription addons
2664
+
2665
+ List all addons of a subscription. In the returned list will match to a set unique by addonId.
2666
+
2667
+ :param subscription_id: (required)
2668
+ :type subscription_id: str
2669
+ :param _request_timeout: timeout setting for this request. If one
2670
+ number provided, it will be total request
2671
+ timeout. It can also be a pair (tuple) of
2672
+ (connection, read) timeouts.
2673
+ :type _request_timeout: int, tuple(int, int), optional
2674
+ :param _request_auth: set to override the auth_settings for an a single
2675
+ request; this effectively ignores the
2676
+ authentication in the spec for a single request.
2677
+ :type _request_auth: dict, optional
2678
+ :param _content_type: force content-type for the request.
2679
+ :type _content_type: str, Optional
2680
+ :param _headers: set to override the headers for a single
2681
+ request; this effectively ignores the headers
2682
+ in the spec for a single request.
2683
+ :type _headers: dict, optional
2684
+ :param _host_index: set to override the host_index for a single
2685
+ request; this effectively ignores the host_index
2686
+ in the spec for a single request.
2687
+ :type _host_index: int, optional
2688
+ :return: Returns the result object.
2689
+ """ # noqa: E501
2690
+
2691
+ _param = self._list_subscription_addons_serialize(
2692
+ subscription_id=subscription_id,
2693
+ _request_auth=_request_auth,
2694
+ _content_type=_content_type,
2695
+ _headers=_headers,
2696
+ _host_index=_host_index
2697
+ )
2698
+
2699
+ _response_types_map: Dict[str, Optional[str]] = {
2700
+ '200': "List[SubscriptionAddon]",
2701
+ '400': "UnexpectedProblemResponse",
2702
+ '401': "UnexpectedProblemResponse",
2703
+ '403': "UnexpectedProblemResponse",
2704
+ '404': "UnexpectedProblemResponse",
2705
+ '412': "UnexpectedProblemResponse",
2706
+ '500': "UnexpectedProblemResponse",
2707
+ '503': "UnexpectedProblemResponse",
2708
+ }
2709
+ response_data = self.api_client.call_api(
2710
+ *_param,
2711
+ _request_timeout=_request_timeout
2712
+ )
2713
+ return response_data.response
2714
+
2715
+
2716
+ def _list_subscription_addons_serialize(
2717
+ self,
2718
+ subscription_id,
2719
+ _request_auth,
2720
+ _content_type,
2721
+ _headers,
2722
+ _host_index,
2723
+ ) -> RequestSerialized:
2724
+
2725
+ _host = None
2726
+
2727
+ _collection_formats: Dict[str, str] = {
2728
+ }
2729
+
2730
+ _path_params: Dict[str, str] = {}
2731
+ _query_params: List[Tuple[str, str]] = []
2732
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2733
+ _form_params: List[Tuple[str, str]] = []
2734
+ _files: Dict[
2735
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2736
+ ] = {}
2737
+ _body_params: Optional[bytes] = None
2738
+
2739
+ # process the path parameters
2740
+ if subscription_id is not None:
2741
+ _path_params['subscriptionId'] = subscription_id
2742
+ # process the query parameters
2743
+ # process the header parameters
2744
+ # process the form parameters
2745
+ # process the body parameter
2746
+
2747
+
2748
+ # set the HTTP header `Accept`
2749
+ if 'Accept' not in _header_params:
2750
+ _header_params['Accept'] = self.api_client.select_header_accept(
2751
+ [
2752
+ 'application/json',
2753
+ 'application/problem+json'
2754
+ ]
2755
+ )
2756
+
2757
+
2758
+ # authentication setting
2759
+ _auth_settings: List[str] = [
2760
+ 'CloudTokenAuth'
2761
+ ]
2762
+
2763
+ return self.api_client.param_serialize(
2764
+ method='GET',
2765
+ resource_path='/api/v1/subscriptions/{subscriptionId}/addons',
2766
+ path_params=_path_params,
2767
+ query_params=_query_params,
2768
+ header_params=_header_params,
2769
+ body=_body_params,
2770
+ post_params=_form_params,
2771
+ files=_files,
2772
+ auth_settings=_auth_settings,
2773
+ collection_formats=_collection_formats,
2774
+ _host=_host,
2775
+ _request_auth=_request_auth
2776
+ )
2777
+
2778
+
2779
+
2780
+
2781
+ @validate_call
2782
+ def list_subscriptions(
2783
+ self,
2784
+ customer_id: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="Filter by customer ID.")] = None,
2785
+ status: Optional[List[SubscriptionStatus]] = None,
2786
+ order: Annotated[Optional[SortOrder], Field(description="The order direction.")] = None,
2787
+ order_by: Annotated[Optional[CustomerSubscriptionOrderBy], Field(description="The order by field.")] = None,
2788
+ page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page index. Default is 1.")] = None,
2789
+ page_size: Annotated[Optional[Annotated[int, Field(le=1000, strict=True, ge=1)]], Field(description="The maximum number of items per page. Default is 100.")] = None,
2790
+ _request_timeout: Union[
2791
+ None,
2792
+ Annotated[StrictFloat, Field(gt=0)],
2793
+ Tuple[
2794
+ Annotated[StrictFloat, Field(gt=0)],
2795
+ Annotated[StrictFloat, Field(gt=0)]
2796
+ ]
2797
+ ] = None,
2798
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2799
+ _content_type: Optional[StrictStr] = None,
2800
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2801
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2802
+ ) -> SubscriptionPaginatedResponse:
2803
+ """List subscriptions
2804
+
2805
+ Lists all subscriptions for the current namespace. Optionally filter by customer or status.
2806
+
2807
+ :param customer_id: Filter by customer ID.
2808
+ :type customer_id: str
2809
+ :param status:
2810
+ :type status: List[SubscriptionStatus]
2811
+ :param order: The order direction.
2812
+ :type order: SortOrder
2813
+ :param order_by: The order by field.
2814
+ :type order_by: CustomerSubscriptionOrderBy
2815
+ :param page: Page index. Default is 1.
2816
+ :type page: int
2817
+ :param page_size: The maximum number of items per page. Default is 100.
2818
+ :type page_size: int
2819
+ :param _request_timeout: timeout setting for this request. If one
2820
+ number provided, it will be total request
2821
+ timeout. It can also be a pair (tuple) of
2822
+ (connection, read) timeouts.
2823
+ :type _request_timeout: int, tuple(int, int), optional
2824
+ :param _request_auth: set to override the auth_settings for an a single
2825
+ request; this effectively ignores the
2826
+ authentication in the spec for a single request.
2827
+ :type _request_auth: dict, optional
2828
+ :param _content_type: force content-type for the request.
2829
+ :type _content_type: str, Optional
2830
+ :param _headers: set to override the headers for a single
2831
+ request; this effectively ignores the headers
2832
+ in the spec for a single request.
2833
+ :type _headers: dict, optional
2834
+ :param _host_index: set to override the host_index for a single
2835
+ request; this effectively ignores the host_index
2836
+ in the spec for a single request.
2837
+ :type _host_index: int, optional
2838
+ :return: Returns the result object.
2839
+ """ # noqa: E501
2840
+
2841
+ _param = self._list_subscriptions_serialize(
2842
+ customer_id=customer_id,
2843
+ status=status,
2844
+ order=order,
2845
+ order_by=order_by,
2846
+ page=page,
2847
+ page_size=page_size,
2848
+ _request_auth=_request_auth,
2849
+ _content_type=_content_type,
2850
+ _headers=_headers,
2851
+ _host_index=_host_index
2852
+ )
2853
+
2854
+ _response_types_map: Dict[str, Optional[str]] = {
2855
+ '200': "SubscriptionPaginatedResponse",
2856
+ '400': "UnexpectedProblemResponse",
2857
+ '401': "UnexpectedProblemResponse",
2858
+ '403': "UnexpectedProblemResponse",
2859
+ '412': "UnexpectedProblemResponse",
2860
+ '500': "UnexpectedProblemResponse",
2861
+ '503': "UnexpectedProblemResponse",
2862
+ }
2863
+ response_data = self.api_client.call_api(
2864
+ *_param,
2865
+ _request_timeout=_request_timeout
2866
+ )
2867
+ response_data.read()
2868
+ return self.api_client.response_deserialize(
2869
+ response_data=response_data,
2870
+ response_types_map=_response_types_map,
2871
+ ).data
2872
+
2873
+
2874
+ @validate_call
2875
+ def list_subscriptions_with_http_info(
2876
+ self,
2877
+ customer_id: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="Filter by customer ID.")] = None,
2878
+ status: Optional[List[SubscriptionStatus]] = None,
2879
+ order: Annotated[Optional[SortOrder], Field(description="The order direction.")] = None,
2880
+ order_by: Annotated[Optional[CustomerSubscriptionOrderBy], Field(description="The order by field.")] = None,
2881
+ page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page index. Default is 1.")] = None,
2882
+ page_size: Annotated[Optional[Annotated[int, Field(le=1000, strict=True, ge=1)]], Field(description="The maximum number of items per page. Default is 100.")] = None,
2883
+ _request_timeout: Union[
2884
+ None,
2885
+ Annotated[StrictFloat, Field(gt=0)],
2886
+ Tuple[
2887
+ Annotated[StrictFloat, Field(gt=0)],
2888
+ Annotated[StrictFloat, Field(gt=0)]
2889
+ ]
2890
+ ] = None,
2891
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2892
+ _content_type: Optional[StrictStr] = None,
2893
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2894
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2895
+ ) -> ApiResponse[SubscriptionPaginatedResponse]:
2896
+ """List subscriptions
2897
+
2898
+ Lists all subscriptions for the current namespace. Optionally filter by customer or status.
2899
+
2900
+ :param customer_id: Filter by customer ID.
2901
+ :type customer_id: str
2902
+ :param status:
2903
+ :type status: List[SubscriptionStatus]
2904
+ :param order: The order direction.
2905
+ :type order: SortOrder
2906
+ :param order_by: The order by field.
2907
+ :type order_by: CustomerSubscriptionOrderBy
2908
+ :param page: Page index. Default is 1.
2909
+ :type page: int
2910
+ :param page_size: The maximum number of items per page. Default is 100.
2911
+ :type page_size: int
2912
+ :param _request_timeout: timeout setting for this request. If one
2913
+ number provided, it will be total request
2914
+ timeout. It can also be a pair (tuple) of
2915
+ (connection, read) timeouts.
2916
+ :type _request_timeout: int, tuple(int, int), optional
2917
+ :param _request_auth: set to override the auth_settings for an a single
2918
+ request; this effectively ignores the
2919
+ authentication in the spec for a single request.
2920
+ :type _request_auth: dict, optional
2921
+ :param _content_type: force content-type for the request.
2922
+ :type _content_type: str, Optional
2923
+ :param _headers: set to override the headers for a single
2924
+ request; this effectively ignores the headers
2925
+ in the spec for a single request.
2926
+ :type _headers: dict, optional
2927
+ :param _host_index: set to override the host_index for a single
2928
+ request; this effectively ignores the host_index
2929
+ in the spec for a single request.
2930
+ :type _host_index: int, optional
2931
+ :return: Returns the result object.
2932
+ """ # noqa: E501
2933
+
2934
+ _param = self._list_subscriptions_serialize(
2935
+ customer_id=customer_id,
2936
+ status=status,
2937
+ order=order,
2938
+ order_by=order_by,
2939
+ page=page,
2940
+ page_size=page_size,
2941
+ _request_auth=_request_auth,
2942
+ _content_type=_content_type,
2943
+ _headers=_headers,
2944
+ _host_index=_host_index
2945
+ )
2946
+
2947
+ _response_types_map: Dict[str, Optional[str]] = {
2948
+ '200': "SubscriptionPaginatedResponse",
2949
+ '400': "UnexpectedProblemResponse",
2950
+ '401': "UnexpectedProblemResponse",
2951
+ '403': "UnexpectedProblemResponse",
2952
+ '412': "UnexpectedProblemResponse",
2953
+ '500': "UnexpectedProblemResponse",
2954
+ '503': "UnexpectedProblemResponse",
2955
+ }
2956
+ response_data = self.api_client.call_api(
2957
+ *_param,
2958
+ _request_timeout=_request_timeout
2959
+ )
2960
+ response_data.read()
2961
+ return self.api_client.response_deserialize(
2962
+ response_data=response_data,
2963
+ response_types_map=_response_types_map,
2964
+ )
2965
+
2966
+
2967
+ @validate_call
2968
+ def list_subscriptions_without_preload_content(
2969
+ self,
2970
+ customer_id: Annotated[Optional[Annotated[str, Field(strict=True)]], Field(description="Filter by customer ID.")] = None,
2971
+ status: Optional[List[SubscriptionStatus]] = None,
2972
+ order: Annotated[Optional[SortOrder], Field(description="The order direction.")] = None,
2973
+ order_by: Annotated[Optional[CustomerSubscriptionOrderBy], Field(description="The order by field.")] = None,
2974
+ page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page index. Default is 1.")] = None,
2975
+ page_size: Annotated[Optional[Annotated[int, Field(le=1000, strict=True, ge=1)]], Field(description="The maximum number of items per page. Default is 100.")] = None,
2976
+ _request_timeout: Union[
2977
+ None,
2978
+ Annotated[StrictFloat, Field(gt=0)],
2979
+ Tuple[
2980
+ Annotated[StrictFloat, Field(gt=0)],
2981
+ Annotated[StrictFloat, Field(gt=0)]
2982
+ ]
2983
+ ] = None,
2984
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2985
+ _content_type: Optional[StrictStr] = None,
2986
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2987
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2988
+ ) -> RESTResponseType:
2989
+ """List subscriptions
2990
+
2991
+ Lists all subscriptions for the current namespace. Optionally filter by customer or status.
2992
+
2993
+ :param customer_id: Filter by customer ID.
2994
+ :type customer_id: str
2995
+ :param status:
2996
+ :type status: List[SubscriptionStatus]
2997
+ :param order: The order direction.
2998
+ :type order: SortOrder
2999
+ :param order_by: The order by field.
3000
+ :type order_by: CustomerSubscriptionOrderBy
3001
+ :param page: Page index. Default is 1.
3002
+ :type page: int
3003
+ :param page_size: The maximum number of items per page. Default is 100.
3004
+ :type page_size: int
3005
+ :param _request_timeout: timeout setting for this request. If one
3006
+ number provided, it will be total request
3007
+ timeout. It can also be a pair (tuple) of
3008
+ (connection, read) timeouts.
3009
+ :type _request_timeout: int, tuple(int, int), optional
3010
+ :param _request_auth: set to override the auth_settings for an a single
3011
+ request; this effectively ignores the
3012
+ authentication in the spec for a single request.
3013
+ :type _request_auth: dict, optional
3014
+ :param _content_type: force content-type for the request.
3015
+ :type _content_type: str, Optional
3016
+ :param _headers: set to override the headers for a single
3017
+ request; this effectively ignores the headers
3018
+ in the spec for a single request.
3019
+ :type _headers: dict, optional
3020
+ :param _host_index: set to override the host_index for a single
3021
+ request; this effectively ignores the host_index
3022
+ in the spec for a single request.
3023
+ :type _host_index: int, optional
3024
+ :return: Returns the result object.
3025
+ """ # noqa: E501
3026
+
3027
+ _param = self._list_subscriptions_serialize(
3028
+ customer_id=customer_id,
3029
+ status=status,
3030
+ order=order,
3031
+ order_by=order_by,
3032
+ page=page,
3033
+ page_size=page_size,
3034
+ _request_auth=_request_auth,
3035
+ _content_type=_content_type,
3036
+ _headers=_headers,
3037
+ _host_index=_host_index
3038
+ )
3039
+
3040
+ _response_types_map: Dict[str, Optional[str]] = {
3041
+ '200': "SubscriptionPaginatedResponse",
3042
+ '400': "UnexpectedProblemResponse",
3043
+ '401': "UnexpectedProblemResponse",
3044
+ '403': "UnexpectedProblemResponse",
3045
+ '412': "UnexpectedProblemResponse",
3046
+ '500': "UnexpectedProblemResponse",
3047
+ '503': "UnexpectedProblemResponse",
3048
+ }
3049
+ response_data = self.api_client.call_api(
3050
+ *_param,
3051
+ _request_timeout=_request_timeout
3052
+ )
3053
+ return response_data.response
3054
+
3055
+
3056
+ def _list_subscriptions_serialize(
3057
+ self,
3058
+ customer_id,
3059
+ status,
3060
+ order,
3061
+ order_by,
3062
+ page,
3063
+ page_size,
3064
+ _request_auth,
3065
+ _content_type,
3066
+ _headers,
3067
+ _host_index,
3068
+ ) -> RequestSerialized:
3069
+
3070
+ _host = None
3071
+
3072
+ _collection_formats: Dict[str, str] = {
3073
+ 'status': 'multi',
3074
+ }
3075
+
3076
+ _path_params: Dict[str, str] = {}
3077
+ _query_params: List[Tuple[str, str]] = []
3078
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3079
+ _form_params: List[Tuple[str, str]] = []
3080
+ _files: Dict[
3081
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3082
+ ] = {}
3083
+ _body_params: Optional[bytes] = None
3084
+
3085
+ # process the path parameters
3086
+ # process the query parameters
3087
+ if customer_id is not None:
3088
+
3089
+ _query_params.append(('customerId', customer_id))
3090
+
3091
+ if status is not None:
3092
+
3093
+ _query_params.append(('status', status))
3094
+
3095
+ if order is not None:
3096
+
3097
+ _query_params.append(('order', order.value))
3098
+
3099
+ if order_by is not None:
3100
+
3101
+ _query_params.append(('orderBy', order_by.value))
3102
+
3103
+ if page is not None:
3104
+
3105
+ _query_params.append(('page', page))
3106
+
3107
+ if page_size is not None:
3108
+
3109
+ _query_params.append(('pageSize', page_size))
3110
+
3111
+ # process the header parameters
3112
+ # process the form parameters
3113
+ # process the body parameter
3114
+
3115
+
3116
+ # set the HTTP header `Accept`
3117
+ if 'Accept' not in _header_params:
3118
+ _header_params['Accept'] = self.api_client.select_header_accept(
3119
+ [
3120
+ 'application/json',
3121
+ 'application/problem+json'
3122
+ ]
3123
+ )
3124
+
3125
+
3126
+ # authentication setting
3127
+ _auth_settings: List[str] = [
3128
+ 'CloudTokenAuth'
3129
+ ]
3130
+
3131
+ return self.api_client.param_serialize(
3132
+ method='GET',
3133
+ resource_path='/api/v1/subscriptions',
3134
+ path_params=_path_params,
3135
+ query_params=_query_params,
3136
+ header_params=_header_params,
3137
+ body=_body_params,
3138
+ post_params=_form_params,
3139
+ files=_files,
3140
+ auth_settings=_auth_settings,
3141
+ collection_formats=_collection_formats,
3142
+ _host=_host,
3143
+ _request_auth=_request_auth
3144
+ )
3145
+
3146
+
3147
+
3148
+
3149
+ @validate_call
3150
+ def migrate_subscription(
3151
+ self,
3152
+ subscription_id: Annotated[str, Field(strict=True)],
3153
+ migrate_subscription_request: MigrateSubscriptionRequest,
3154
+ _request_timeout: Union[
3155
+ None,
3156
+ Annotated[StrictFloat, Field(gt=0)],
3157
+ Tuple[
3158
+ Annotated[StrictFloat, Field(gt=0)],
3159
+ Annotated[StrictFloat, Field(gt=0)]
3160
+ ]
3161
+ ] = None,
3162
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3163
+ _content_type: Optional[StrictStr] = None,
3164
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3165
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3166
+ ) -> SubscriptionChangeResponseBody:
3167
+ """Migrate subscription
3168
+
3169
+ Migrates the subscripiton to the provided version of the current plan. If possible, the migration will be done immediately. If not, the migration will be scheduled to the end of the current billing period.
3170
+
3171
+ :param subscription_id: (required)
3172
+ :type subscription_id: str
3173
+ :param migrate_subscription_request: (required)
3174
+ :type migrate_subscription_request: MigrateSubscriptionRequest
3175
+ :param _request_timeout: timeout setting for this request. If one
3176
+ number provided, it will be total request
3177
+ timeout. It can also be a pair (tuple) of
3178
+ (connection, read) timeouts.
3179
+ :type _request_timeout: int, tuple(int, int), optional
3180
+ :param _request_auth: set to override the auth_settings for an a single
3181
+ request; this effectively ignores the
3182
+ authentication in the spec for a single request.
3183
+ :type _request_auth: dict, optional
3184
+ :param _content_type: force content-type for the request.
3185
+ :type _content_type: str, Optional
3186
+ :param _headers: set to override the headers for a single
3187
+ request; this effectively ignores the headers
3188
+ in the spec for a single request.
3189
+ :type _headers: dict, optional
3190
+ :param _host_index: set to override the host_index for a single
3191
+ request; this effectively ignores the host_index
3192
+ in the spec for a single request.
3193
+ :type _host_index: int, optional
3194
+ :return: Returns the result object.
3195
+ """ # noqa: E501
3196
+
3197
+ _param = self._migrate_subscription_serialize(
3198
+ subscription_id=subscription_id,
3199
+ migrate_subscription_request=migrate_subscription_request,
3200
+ _request_auth=_request_auth,
3201
+ _content_type=_content_type,
3202
+ _headers=_headers,
3203
+ _host_index=_host_index
3204
+ )
3205
+
3206
+ _response_types_map: Dict[str, Optional[str]] = {
3207
+ '200': "SubscriptionChangeResponseBody",
3208
+ '400': "SubscriptionBadRequestErrorResponse",
3209
+ '401': "UnexpectedProblemResponse",
3210
+ '403': "UnexpectedProblemResponse",
3211
+ '404': "UnexpectedProblemResponse",
3212
+ '409': "SubscriptionConflictErrorResponse",
3213
+ '412': "UnexpectedProblemResponse",
3214
+ '500': "UnexpectedProblemResponse",
3215
+ '503': "UnexpectedProblemResponse",
3216
+ }
3217
+ response_data = self.api_client.call_api(
3218
+ *_param,
3219
+ _request_timeout=_request_timeout
3220
+ )
3221
+ response_data.read()
3222
+ return self.api_client.response_deserialize(
3223
+ response_data=response_data,
3224
+ response_types_map=_response_types_map,
3225
+ ).data
3226
+
3227
+
3228
+ @validate_call
3229
+ def migrate_subscription_with_http_info(
3230
+ self,
3231
+ subscription_id: Annotated[str, Field(strict=True)],
3232
+ migrate_subscription_request: MigrateSubscriptionRequest,
3233
+ _request_timeout: Union[
3234
+ None,
3235
+ Annotated[StrictFloat, Field(gt=0)],
3236
+ Tuple[
3237
+ Annotated[StrictFloat, Field(gt=0)],
3238
+ Annotated[StrictFloat, Field(gt=0)]
3239
+ ]
3240
+ ] = None,
3241
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3242
+ _content_type: Optional[StrictStr] = None,
3243
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3244
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3245
+ ) -> ApiResponse[SubscriptionChangeResponseBody]:
3246
+ """Migrate subscription
3247
+
3248
+ Migrates the subscripiton to the provided version of the current plan. If possible, the migration will be done immediately. If not, the migration will be scheduled to the end of the current billing period.
3249
+
3250
+ :param subscription_id: (required)
3251
+ :type subscription_id: str
3252
+ :param migrate_subscription_request: (required)
3253
+ :type migrate_subscription_request: MigrateSubscriptionRequest
3254
+ :param _request_timeout: timeout setting for this request. If one
3255
+ number provided, it will be total request
3256
+ timeout. It can also be a pair (tuple) of
3257
+ (connection, read) timeouts.
3258
+ :type _request_timeout: int, tuple(int, int), optional
3259
+ :param _request_auth: set to override the auth_settings for an a single
3260
+ request; this effectively ignores the
3261
+ authentication in the spec for a single request.
3262
+ :type _request_auth: dict, optional
3263
+ :param _content_type: force content-type for the request.
3264
+ :type _content_type: str, Optional
3265
+ :param _headers: set to override the headers for a single
3266
+ request; this effectively ignores the headers
3267
+ in the spec for a single request.
3268
+ :type _headers: dict, optional
3269
+ :param _host_index: set to override the host_index for a single
3270
+ request; this effectively ignores the host_index
3271
+ in the spec for a single request.
3272
+ :type _host_index: int, optional
3273
+ :return: Returns the result object.
3274
+ """ # noqa: E501
3275
+
3276
+ _param = self._migrate_subscription_serialize(
3277
+ subscription_id=subscription_id,
3278
+ migrate_subscription_request=migrate_subscription_request,
3279
+ _request_auth=_request_auth,
3280
+ _content_type=_content_type,
3281
+ _headers=_headers,
3282
+ _host_index=_host_index
3283
+ )
3284
+
3285
+ _response_types_map: Dict[str, Optional[str]] = {
3286
+ '200': "SubscriptionChangeResponseBody",
3287
+ '400': "SubscriptionBadRequestErrorResponse",
3288
+ '401': "UnexpectedProblemResponse",
3289
+ '403': "UnexpectedProblemResponse",
3290
+ '404': "UnexpectedProblemResponse",
3291
+ '409': "SubscriptionConflictErrorResponse",
3292
+ '412': "UnexpectedProblemResponse",
3293
+ '500': "UnexpectedProblemResponse",
3294
+ '503': "UnexpectedProblemResponse",
3295
+ }
3296
+ response_data = self.api_client.call_api(
3297
+ *_param,
3298
+ _request_timeout=_request_timeout
3299
+ )
3300
+ response_data.read()
3301
+ return self.api_client.response_deserialize(
3302
+ response_data=response_data,
3303
+ response_types_map=_response_types_map,
3304
+ )
3305
+
3306
+
3307
+ @validate_call
3308
+ def migrate_subscription_without_preload_content(
3309
+ self,
3310
+ subscription_id: Annotated[str, Field(strict=True)],
3311
+ migrate_subscription_request: MigrateSubscriptionRequest,
3312
+ _request_timeout: Union[
3313
+ None,
3314
+ Annotated[StrictFloat, Field(gt=0)],
3315
+ Tuple[
3316
+ Annotated[StrictFloat, Field(gt=0)],
3317
+ Annotated[StrictFloat, Field(gt=0)]
3318
+ ]
3319
+ ] = None,
3320
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3321
+ _content_type: Optional[StrictStr] = None,
3322
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3323
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3324
+ ) -> RESTResponseType:
3325
+ """Migrate subscription
3326
+
3327
+ Migrates the subscripiton to the provided version of the current plan. If possible, the migration will be done immediately. If not, the migration will be scheduled to the end of the current billing period.
3328
+
3329
+ :param subscription_id: (required)
3330
+ :type subscription_id: str
3331
+ :param migrate_subscription_request: (required)
3332
+ :type migrate_subscription_request: MigrateSubscriptionRequest
3333
+ :param _request_timeout: timeout setting for this request. If one
3334
+ number provided, it will be total request
3335
+ timeout. It can also be a pair (tuple) of
3336
+ (connection, read) timeouts.
3337
+ :type _request_timeout: int, tuple(int, int), optional
3338
+ :param _request_auth: set to override the auth_settings for an a single
3339
+ request; this effectively ignores the
3340
+ authentication in the spec for a single request.
3341
+ :type _request_auth: dict, optional
3342
+ :param _content_type: force content-type for the request.
3343
+ :type _content_type: str, Optional
3344
+ :param _headers: set to override the headers for a single
3345
+ request; this effectively ignores the headers
3346
+ in the spec for a single request.
3347
+ :type _headers: dict, optional
3348
+ :param _host_index: set to override the host_index for a single
3349
+ request; this effectively ignores the host_index
3350
+ in the spec for a single request.
3351
+ :type _host_index: int, optional
3352
+ :return: Returns the result object.
3353
+ """ # noqa: E501
3354
+
3355
+ _param = self._migrate_subscription_serialize(
3356
+ subscription_id=subscription_id,
3357
+ migrate_subscription_request=migrate_subscription_request,
3358
+ _request_auth=_request_auth,
3359
+ _content_type=_content_type,
3360
+ _headers=_headers,
3361
+ _host_index=_host_index
3362
+ )
3363
+
3364
+ _response_types_map: Dict[str, Optional[str]] = {
3365
+ '200': "SubscriptionChangeResponseBody",
3366
+ '400': "SubscriptionBadRequestErrorResponse",
3367
+ '401': "UnexpectedProblemResponse",
3368
+ '403': "UnexpectedProblemResponse",
3369
+ '404': "UnexpectedProblemResponse",
3370
+ '409': "SubscriptionConflictErrorResponse",
3371
+ '412': "UnexpectedProblemResponse",
3372
+ '500': "UnexpectedProblemResponse",
3373
+ '503': "UnexpectedProblemResponse",
3374
+ }
3375
+ response_data = self.api_client.call_api(
3376
+ *_param,
3377
+ _request_timeout=_request_timeout
3378
+ )
3379
+ return response_data.response
3380
+
3381
+
3382
+ def _migrate_subscription_serialize(
3383
+ self,
3384
+ subscription_id,
3385
+ migrate_subscription_request,
3386
+ _request_auth,
3387
+ _content_type,
3388
+ _headers,
3389
+ _host_index,
3390
+ ) -> RequestSerialized:
3391
+
3392
+ _host = None
3393
+
3394
+ _collection_formats: Dict[str, str] = {
3395
+ }
3396
+
3397
+ _path_params: Dict[str, str] = {}
3398
+ _query_params: List[Tuple[str, str]] = []
3399
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3400
+ _form_params: List[Tuple[str, str]] = []
3401
+ _files: Dict[
3402
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3403
+ ] = {}
3404
+ _body_params: Optional[bytes] = None
3405
+
3406
+ # process the path parameters
3407
+ if subscription_id is not None:
3408
+ _path_params['subscriptionId'] = subscription_id
3409
+ # process the query parameters
3410
+ # process the header parameters
3411
+ # process the form parameters
3412
+ # process the body parameter
3413
+ if migrate_subscription_request is not None:
3414
+ _body_params = migrate_subscription_request
3415
+
3416
+
3417
+ # set the HTTP header `Accept`
3418
+ if 'Accept' not in _header_params:
3419
+ _header_params['Accept'] = self.api_client.select_header_accept(
3420
+ [
3421
+ 'application/json',
3422
+ 'application/problem+json'
3423
+ ]
3424
+ )
3425
+
3426
+ # set the HTTP header `Content-Type`
3427
+ if _content_type:
3428
+ _header_params['Content-Type'] = _content_type
3429
+ else:
3430
+ _default_content_type = (
3431
+ self.api_client.select_header_content_type(
3432
+ [
3433
+ 'application/json'
3434
+ ]
3435
+ )
3436
+ )
3437
+ if _default_content_type is not None:
3438
+ _header_params['Content-Type'] = _default_content_type
3439
+
3440
+ # authentication setting
3441
+ _auth_settings: List[str] = [
3442
+ 'CloudTokenAuth'
3443
+ ]
3444
+
3445
+ return self.api_client.param_serialize(
3446
+ method='POST',
3447
+ resource_path='/api/v1/subscriptions/{subscriptionId}/migrate',
3448
+ path_params=_path_params,
3449
+ query_params=_query_params,
3450
+ header_params=_header_params,
3451
+ body=_body_params,
3452
+ post_params=_form_params,
3453
+ files=_files,
3454
+ auth_settings=_auth_settings,
3455
+ collection_formats=_collection_formats,
3456
+ _host=_host,
3457
+ _request_auth=_request_auth
3458
+ )
3459
+
3460
+
3461
+
3462
+
3463
+ @validate_call
3464
+ def restore_subscription(
3465
+ self,
3466
+ subscription_id: Annotated[str, Field(strict=True)],
3467
+ _request_timeout: Union[
3468
+ None,
3469
+ Annotated[StrictFloat, Field(gt=0)],
3470
+ Tuple[
3471
+ Annotated[StrictFloat, Field(gt=0)],
3472
+ Annotated[StrictFloat, Field(gt=0)]
3473
+ ]
3474
+ ] = None,
3475
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3476
+ _content_type: Optional[StrictStr] = None,
3477
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3478
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3479
+ ) -> Subscription:
3480
+ """(Deprecated) Restore subscription
3481
+
3482
+ Restores a canceled subscription. Any subscription scheduled to start later will be deleted and this subscription will be continued indefinitely.
3483
+
3484
+ :param subscription_id: (required)
3485
+ :type subscription_id: str
3486
+ :param _request_timeout: timeout setting for this request. If one
3487
+ number provided, it will be total request
3488
+ timeout. It can also be a pair (tuple) of
3489
+ (connection, read) timeouts.
3490
+ :type _request_timeout: int, tuple(int, int), optional
3491
+ :param _request_auth: set to override the auth_settings for an a single
3492
+ request; this effectively ignores the
3493
+ authentication in the spec for a single request.
3494
+ :type _request_auth: dict, optional
3495
+ :param _content_type: force content-type for the request.
3496
+ :type _content_type: str, Optional
3497
+ :param _headers: set to override the headers for a single
3498
+ request; this effectively ignores the headers
3499
+ in the spec for a single request.
3500
+ :type _headers: dict, optional
3501
+ :param _host_index: set to override the host_index for a single
3502
+ request; this effectively ignores the host_index
3503
+ in the spec for a single request.
3504
+ :type _host_index: int, optional
3505
+ :return: Returns the result object.
3506
+ """ # noqa: E501
3507
+ warnings.warn("POST /api/v1/subscriptions/{subscriptionId}/restore is deprecated.", DeprecationWarning)
3508
+
3509
+ _param = self._restore_subscription_serialize(
3510
+ subscription_id=subscription_id,
3511
+ _request_auth=_request_auth,
3512
+ _content_type=_content_type,
3513
+ _headers=_headers,
3514
+ _host_index=_host_index
3515
+ )
3516
+
3517
+ _response_types_map: Dict[str, Optional[str]] = {
3518
+ '200': "Subscription",
3519
+ '400': "UnexpectedProblemResponse",
3520
+ '401': "UnexpectedProblemResponse",
3521
+ '403': "UnexpectedProblemResponse",
3522
+ '404': "UnexpectedProblemResponse",
3523
+ '412': "UnexpectedProblemResponse",
3524
+ '500': "UnexpectedProblemResponse",
3525
+ '503': "UnexpectedProblemResponse",
3526
+ }
3527
+ response_data = self.api_client.call_api(
3528
+ *_param,
3529
+ _request_timeout=_request_timeout
3530
+ )
3531
+ response_data.read()
3532
+ return self.api_client.response_deserialize(
3533
+ response_data=response_data,
3534
+ response_types_map=_response_types_map,
3535
+ ).data
3536
+
3537
+
3538
+ @validate_call
3539
+ def restore_subscription_with_http_info(
3540
+ self,
3541
+ subscription_id: Annotated[str, Field(strict=True)],
3542
+ _request_timeout: Union[
3543
+ None,
3544
+ Annotated[StrictFloat, Field(gt=0)],
3545
+ Tuple[
3546
+ Annotated[StrictFloat, Field(gt=0)],
3547
+ Annotated[StrictFloat, Field(gt=0)]
3548
+ ]
3549
+ ] = None,
3550
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3551
+ _content_type: Optional[StrictStr] = None,
3552
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3553
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3554
+ ) -> ApiResponse[Subscription]:
3555
+ """(Deprecated) Restore subscription
3556
+
3557
+ Restores a canceled subscription. Any subscription scheduled to start later will be deleted and this subscription will be continued indefinitely.
3558
+
3559
+ :param subscription_id: (required)
3560
+ :type subscription_id: str
3561
+ :param _request_timeout: timeout setting for this request. If one
3562
+ number provided, it will be total request
3563
+ timeout. It can also be a pair (tuple) of
3564
+ (connection, read) timeouts.
3565
+ :type _request_timeout: int, tuple(int, int), optional
3566
+ :param _request_auth: set to override the auth_settings for an a single
3567
+ request; this effectively ignores the
3568
+ authentication in the spec for a single request.
3569
+ :type _request_auth: dict, optional
3570
+ :param _content_type: force content-type for the request.
3571
+ :type _content_type: str, Optional
3572
+ :param _headers: set to override the headers for a single
3573
+ request; this effectively ignores the headers
3574
+ in the spec for a single request.
3575
+ :type _headers: dict, optional
3576
+ :param _host_index: set to override the host_index for a single
3577
+ request; this effectively ignores the host_index
3578
+ in the spec for a single request.
3579
+ :type _host_index: int, optional
3580
+ :return: Returns the result object.
3581
+ """ # noqa: E501
3582
+ warnings.warn("POST /api/v1/subscriptions/{subscriptionId}/restore is deprecated.", DeprecationWarning)
3583
+
3584
+ _param = self._restore_subscription_serialize(
3585
+ subscription_id=subscription_id,
3586
+ _request_auth=_request_auth,
3587
+ _content_type=_content_type,
3588
+ _headers=_headers,
3589
+ _host_index=_host_index
3590
+ )
3591
+
3592
+ _response_types_map: Dict[str, Optional[str]] = {
3593
+ '200': "Subscription",
3594
+ '400': "UnexpectedProblemResponse",
3595
+ '401': "UnexpectedProblemResponse",
3596
+ '403': "UnexpectedProblemResponse",
3597
+ '404': "UnexpectedProblemResponse",
3598
+ '412': "UnexpectedProblemResponse",
3599
+ '500': "UnexpectedProblemResponse",
3600
+ '503': "UnexpectedProblemResponse",
3601
+ }
3602
+ response_data = self.api_client.call_api(
3603
+ *_param,
3604
+ _request_timeout=_request_timeout
3605
+ )
3606
+ response_data.read()
3607
+ return self.api_client.response_deserialize(
3608
+ response_data=response_data,
3609
+ response_types_map=_response_types_map,
3610
+ )
3611
+
3612
+
3613
+ @validate_call
3614
+ def restore_subscription_without_preload_content(
3615
+ self,
3616
+ subscription_id: Annotated[str, Field(strict=True)],
3617
+ _request_timeout: Union[
3618
+ None,
3619
+ Annotated[StrictFloat, Field(gt=0)],
3620
+ Tuple[
3621
+ Annotated[StrictFloat, Field(gt=0)],
3622
+ Annotated[StrictFloat, Field(gt=0)]
3623
+ ]
3624
+ ] = None,
3625
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3626
+ _content_type: Optional[StrictStr] = None,
3627
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3628
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3629
+ ) -> RESTResponseType:
3630
+ """(Deprecated) Restore subscription
3631
+
3632
+ Restores a canceled subscription. Any subscription scheduled to start later will be deleted and this subscription will be continued indefinitely.
3633
+
3634
+ :param subscription_id: (required)
3635
+ :type subscription_id: str
3636
+ :param _request_timeout: timeout setting for this request. If one
3637
+ number provided, it will be total request
3638
+ timeout. It can also be a pair (tuple) of
3639
+ (connection, read) timeouts.
3640
+ :type _request_timeout: int, tuple(int, int), optional
3641
+ :param _request_auth: set to override the auth_settings for an a single
3642
+ request; this effectively ignores the
3643
+ authentication in the spec for a single request.
3644
+ :type _request_auth: dict, optional
3645
+ :param _content_type: force content-type for the request.
3646
+ :type _content_type: str, Optional
3647
+ :param _headers: set to override the headers for a single
3648
+ request; this effectively ignores the headers
3649
+ in the spec for a single request.
3650
+ :type _headers: dict, optional
3651
+ :param _host_index: set to override the host_index for a single
3652
+ request; this effectively ignores the host_index
3653
+ in the spec for a single request.
3654
+ :type _host_index: int, optional
3655
+ :return: Returns the result object.
3656
+ """ # noqa: E501
3657
+ warnings.warn("POST /api/v1/subscriptions/{subscriptionId}/restore is deprecated.", DeprecationWarning)
3658
+
3659
+ _param = self._restore_subscription_serialize(
3660
+ subscription_id=subscription_id,
3661
+ _request_auth=_request_auth,
3662
+ _content_type=_content_type,
3663
+ _headers=_headers,
3664
+ _host_index=_host_index
3665
+ )
3666
+
3667
+ _response_types_map: Dict[str, Optional[str]] = {
3668
+ '200': "Subscription",
3669
+ '400': "UnexpectedProblemResponse",
3670
+ '401': "UnexpectedProblemResponse",
3671
+ '403': "UnexpectedProblemResponse",
3672
+ '404': "UnexpectedProblemResponse",
3673
+ '412': "UnexpectedProblemResponse",
3674
+ '500': "UnexpectedProblemResponse",
3675
+ '503': "UnexpectedProblemResponse",
3676
+ }
3677
+ response_data = self.api_client.call_api(
3678
+ *_param,
3679
+ _request_timeout=_request_timeout
3680
+ )
3681
+ return response_data.response
3682
+
3683
+
3684
+ def _restore_subscription_serialize(
3685
+ self,
3686
+ subscription_id,
3687
+ _request_auth,
3688
+ _content_type,
3689
+ _headers,
3690
+ _host_index,
3691
+ ) -> RequestSerialized:
3692
+
3693
+ _host = None
3694
+
3695
+ _collection_formats: Dict[str, str] = {
3696
+ }
3697
+
3698
+ _path_params: Dict[str, str] = {}
3699
+ _query_params: List[Tuple[str, str]] = []
3700
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3701
+ _form_params: List[Tuple[str, str]] = []
3702
+ _files: Dict[
3703
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3704
+ ] = {}
3705
+ _body_params: Optional[bytes] = None
3706
+
3707
+ # process the path parameters
3708
+ if subscription_id is not None:
3709
+ _path_params['subscriptionId'] = subscription_id
3710
+ # process the query parameters
3711
+ # process the header parameters
3712
+ # process the form parameters
3713
+ # process the body parameter
3714
+
3715
+
3716
+ # set the HTTP header `Accept`
3717
+ if 'Accept' not in _header_params:
3718
+ _header_params['Accept'] = self.api_client.select_header_accept(
3719
+ [
3720
+ 'application/json',
3721
+ 'application/problem+json'
3722
+ ]
3723
+ )
3724
+
3725
+
3726
+ # authentication setting
3727
+ _auth_settings: List[str] = [
3728
+ 'CloudTokenAuth'
3729
+ ]
3730
+
3731
+ return self.api_client.param_serialize(
3732
+ method='POST',
3733
+ resource_path='/api/v1/subscriptions/{subscriptionId}/restore',
3734
+ path_params=_path_params,
3735
+ query_params=_query_params,
3736
+ header_params=_header_params,
3737
+ body=_body_params,
3738
+ post_params=_form_params,
3739
+ files=_files,
3740
+ auth_settings=_auth_settings,
3741
+ collection_formats=_collection_formats,
3742
+ _host=_host,
3743
+ _request_auth=_request_auth
3744
+ )
3745
+
3746
+
3747
+
3748
+
3749
+ @validate_call
3750
+ def unschedule_cancelation(
3751
+ self,
3752
+ subscription_id: Annotated[str, Field(strict=True)],
3753
+ _request_timeout: Union[
3754
+ None,
3755
+ Annotated[StrictFloat, Field(gt=0)],
3756
+ Tuple[
3757
+ Annotated[StrictFloat, Field(gt=0)],
3758
+ Annotated[StrictFloat, Field(gt=0)]
3759
+ ]
3760
+ ] = None,
3761
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3762
+ _content_type: Optional[StrictStr] = None,
3763
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3764
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3765
+ ) -> Subscription:
3766
+ """Unschedule cancelation
3767
+
3768
+ Cancels the scheduled cancelation.
3769
+
3770
+ :param subscription_id: (required)
3771
+ :type subscription_id: str
3772
+ :param _request_timeout: timeout setting for this request. If one
3773
+ number provided, it will be total request
3774
+ timeout. It can also be a pair (tuple) of
3775
+ (connection, read) timeouts.
3776
+ :type _request_timeout: int, tuple(int, int), optional
3777
+ :param _request_auth: set to override the auth_settings for an a single
3778
+ request; this effectively ignores the
3779
+ authentication in the spec for a single request.
3780
+ :type _request_auth: dict, optional
3781
+ :param _content_type: force content-type for the request.
3782
+ :type _content_type: str, Optional
3783
+ :param _headers: set to override the headers for a single
3784
+ request; this effectively ignores the headers
3785
+ in the spec for a single request.
3786
+ :type _headers: dict, optional
3787
+ :param _host_index: set to override the host_index for a single
3788
+ request; this effectively ignores the host_index
3789
+ in the spec for a single request.
3790
+ :type _host_index: int, optional
3791
+ :return: Returns the result object.
3792
+ """ # noqa: E501
3793
+
3794
+ _param = self._unschedule_cancelation_serialize(
3795
+ subscription_id=subscription_id,
3796
+ _request_auth=_request_auth,
3797
+ _content_type=_content_type,
3798
+ _headers=_headers,
3799
+ _host_index=_host_index
3800
+ )
3801
+
3802
+ _response_types_map: Dict[str, Optional[str]] = {
3803
+ '200': "Subscription",
3804
+ '400': "SubscriptionBadRequestErrorResponse",
3805
+ '401': "UnexpectedProblemResponse",
3806
+ '403': "UnexpectedProblemResponse",
3807
+ '404': "UnexpectedProblemResponse",
3808
+ '409': "SubscriptionConflictErrorResponse",
3809
+ '412': "UnexpectedProblemResponse",
3810
+ '500': "UnexpectedProblemResponse",
3811
+ '503': "UnexpectedProblemResponse",
3812
+ }
3813
+ response_data = self.api_client.call_api(
3814
+ *_param,
3815
+ _request_timeout=_request_timeout
3816
+ )
3817
+ response_data.read()
3818
+ return self.api_client.response_deserialize(
3819
+ response_data=response_data,
3820
+ response_types_map=_response_types_map,
3821
+ ).data
3822
+
3823
+
3824
+ @validate_call
3825
+ def unschedule_cancelation_with_http_info(
3826
+ self,
3827
+ subscription_id: Annotated[str, Field(strict=True)],
3828
+ _request_timeout: Union[
3829
+ None,
3830
+ Annotated[StrictFloat, Field(gt=0)],
3831
+ Tuple[
3832
+ Annotated[StrictFloat, Field(gt=0)],
3833
+ Annotated[StrictFloat, Field(gt=0)]
3834
+ ]
3835
+ ] = None,
3836
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3837
+ _content_type: Optional[StrictStr] = None,
3838
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3839
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3840
+ ) -> ApiResponse[Subscription]:
3841
+ """Unschedule cancelation
3842
+
3843
+ Cancels the scheduled cancelation.
3844
+
3845
+ :param subscription_id: (required)
3846
+ :type subscription_id: str
3847
+ :param _request_timeout: timeout setting for this request. If one
3848
+ number provided, it will be total request
3849
+ timeout. It can also be a pair (tuple) of
3850
+ (connection, read) timeouts.
3851
+ :type _request_timeout: int, tuple(int, int), optional
3852
+ :param _request_auth: set to override the auth_settings for an a single
3853
+ request; this effectively ignores the
3854
+ authentication in the spec for a single request.
3855
+ :type _request_auth: dict, optional
3856
+ :param _content_type: force content-type for the request.
3857
+ :type _content_type: str, Optional
3858
+ :param _headers: set to override the headers for a single
3859
+ request; this effectively ignores the headers
3860
+ in the spec for a single request.
3861
+ :type _headers: dict, optional
3862
+ :param _host_index: set to override the host_index for a single
3863
+ request; this effectively ignores the host_index
3864
+ in the spec for a single request.
3865
+ :type _host_index: int, optional
3866
+ :return: Returns the result object.
3867
+ """ # noqa: E501
3868
+
3869
+ _param = self._unschedule_cancelation_serialize(
3870
+ subscription_id=subscription_id,
3871
+ _request_auth=_request_auth,
3872
+ _content_type=_content_type,
3873
+ _headers=_headers,
3874
+ _host_index=_host_index
3875
+ )
3876
+
3877
+ _response_types_map: Dict[str, Optional[str]] = {
3878
+ '200': "Subscription",
3879
+ '400': "SubscriptionBadRequestErrorResponse",
3880
+ '401': "UnexpectedProblemResponse",
3881
+ '403': "UnexpectedProblemResponse",
3882
+ '404': "UnexpectedProblemResponse",
3883
+ '409': "SubscriptionConflictErrorResponse",
3884
+ '412': "UnexpectedProblemResponse",
3885
+ '500': "UnexpectedProblemResponse",
3886
+ '503': "UnexpectedProblemResponse",
3887
+ }
3888
+ response_data = self.api_client.call_api(
3889
+ *_param,
3890
+ _request_timeout=_request_timeout
3891
+ )
3892
+ response_data.read()
3893
+ return self.api_client.response_deserialize(
3894
+ response_data=response_data,
3895
+ response_types_map=_response_types_map,
3896
+ )
3897
+
3898
+
3899
+ @validate_call
3900
+ def unschedule_cancelation_without_preload_content(
3901
+ self,
3902
+ subscription_id: Annotated[str, Field(strict=True)],
3903
+ _request_timeout: Union[
3904
+ None,
3905
+ Annotated[StrictFloat, Field(gt=0)],
3906
+ Tuple[
3907
+ Annotated[StrictFloat, Field(gt=0)],
3908
+ Annotated[StrictFloat, Field(gt=0)]
3909
+ ]
3910
+ ] = None,
3911
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3912
+ _content_type: Optional[StrictStr] = None,
3913
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3914
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3915
+ ) -> RESTResponseType:
3916
+ """Unschedule cancelation
3917
+
3918
+ Cancels the scheduled cancelation.
3919
+
3920
+ :param subscription_id: (required)
3921
+ :type subscription_id: str
3922
+ :param _request_timeout: timeout setting for this request. If one
3923
+ number provided, it will be total request
3924
+ timeout. It can also be a pair (tuple) of
3925
+ (connection, read) timeouts.
3926
+ :type _request_timeout: int, tuple(int, int), optional
3927
+ :param _request_auth: set to override the auth_settings for an a single
3928
+ request; this effectively ignores the
3929
+ authentication in the spec for a single request.
3930
+ :type _request_auth: dict, optional
3931
+ :param _content_type: force content-type for the request.
3932
+ :type _content_type: str, Optional
3933
+ :param _headers: set to override the headers for a single
3934
+ request; this effectively ignores the headers
3935
+ in the spec for a single request.
3936
+ :type _headers: dict, optional
3937
+ :param _host_index: set to override the host_index for a single
3938
+ request; this effectively ignores the host_index
3939
+ in the spec for a single request.
3940
+ :type _host_index: int, optional
3941
+ :return: Returns the result object.
3942
+ """ # noqa: E501
3943
+
3944
+ _param = self._unschedule_cancelation_serialize(
3945
+ subscription_id=subscription_id,
3946
+ _request_auth=_request_auth,
3947
+ _content_type=_content_type,
3948
+ _headers=_headers,
3949
+ _host_index=_host_index
3950
+ )
3951
+
3952
+ _response_types_map: Dict[str, Optional[str]] = {
3953
+ '200': "Subscription",
3954
+ '400': "SubscriptionBadRequestErrorResponse",
3955
+ '401': "UnexpectedProblemResponse",
3956
+ '403': "UnexpectedProblemResponse",
3957
+ '404': "UnexpectedProblemResponse",
3958
+ '409': "SubscriptionConflictErrorResponse",
3959
+ '412': "UnexpectedProblemResponse",
3960
+ '500': "UnexpectedProblemResponse",
3961
+ '503': "UnexpectedProblemResponse",
3962
+ }
3963
+ response_data = self.api_client.call_api(
3964
+ *_param,
3965
+ _request_timeout=_request_timeout
3966
+ )
3967
+ return response_data.response
3968
+
3969
+
3970
+ def _unschedule_cancelation_serialize(
3971
+ self,
3972
+ subscription_id,
3973
+ _request_auth,
3974
+ _content_type,
3975
+ _headers,
3976
+ _host_index,
3977
+ ) -> RequestSerialized:
3978
+
3979
+ _host = None
3980
+
3981
+ _collection_formats: Dict[str, str] = {
3982
+ }
3983
+
3984
+ _path_params: Dict[str, str] = {}
3985
+ _query_params: List[Tuple[str, str]] = []
3986
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3987
+ _form_params: List[Tuple[str, str]] = []
3988
+ _files: Dict[
3989
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3990
+ ] = {}
3991
+ _body_params: Optional[bytes] = None
3992
+
3993
+ # process the path parameters
3994
+ if subscription_id is not None:
3995
+ _path_params['subscriptionId'] = subscription_id
3996
+ # process the query parameters
3997
+ # process the header parameters
3998
+ # process the form parameters
3999
+ # process the body parameter
4000
+
4001
+
4002
+ # set the HTTP header `Accept`
4003
+ if 'Accept' not in _header_params:
4004
+ _header_params['Accept'] = self.api_client.select_header_accept(
4005
+ [
4006
+ 'application/json',
4007
+ 'application/problem+json'
4008
+ ]
4009
+ )
4010
+
4011
+
4012
+ # authentication setting
4013
+ _auth_settings: List[str] = [
4014
+ 'CloudTokenAuth'
4015
+ ]
4016
+
4017
+ return self.api_client.param_serialize(
4018
+ method='POST',
4019
+ resource_path='/api/v1/subscriptions/{subscriptionId}/unschedule-cancelation',
4020
+ path_params=_path_params,
4021
+ query_params=_query_params,
4022
+ header_params=_header_params,
4023
+ body=_body_params,
4024
+ post_params=_form_params,
4025
+ files=_files,
4026
+ auth_settings=_auth_settings,
4027
+ collection_formats=_collection_formats,
4028
+ _host=_host,
4029
+ _request_auth=_request_auth
4030
+ )
4031
+
4032
+
4033
+
4034
+
4035
+ @validate_call
4036
+ def update_subscription_addon(
4037
+ self,
4038
+ subscription_id: Annotated[str, Field(strict=True)],
4039
+ subscription_addon_id: Annotated[str, Field(strict=True)],
4040
+ subscription_addon_update: SubscriptionAddonUpdate,
4041
+ _request_timeout: Union[
4042
+ None,
4043
+ Annotated[StrictFloat, Field(gt=0)],
4044
+ Tuple[
4045
+ Annotated[StrictFloat, Field(gt=0)],
4046
+ Annotated[StrictFloat, Field(gt=0)]
4047
+ ]
4048
+ ] = None,
4049
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
4050
+ _content_type: Optional[StrictStr] = None,
4051
+ _headers: Optional[Dict[StrictStr, Any]] = None,
4052
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
4053
+ ) -> SubscriptionAddon:
4054
+ """Update subscription addon
4055
+
4056
+ Updates a subscription addon (allows changing the quantity: purchasing more instances or cancelling the current instances)
4057
+
4058
+ :param subscription_id: (required)
4059
+ :type subscription_id: str
4060
+ :param subscription_addon_id: (required)
4061
+ :type subscription_addon_id: str
4062
+ :param subscription_addon_update: (required)
4063
+ :type subscription_addon_update: SubscriptionAddonUpdate
4064
+ :param _request_timeout: timeout setting for this request. If one
4065
+ number provided, it will be total request
4066
+ timeout. It can also be a pair (tuple) of
4067
+ (connection, read) timeouts.
4068
+ :type _request_timeout: int, tuple(int, int), optional
4069
+ :param _request_auth: set to override the auth_settings for an a single
4070
+ request; this effectively ignores the
4071
+ authentication in the spec for a single request.
4072
+ :type _request_auth: dict, optional
4073
+ :param _content_type: force content-type for the request.
4074
+ :type _content_type: str, Optional
4075
+ :param _headers: set to override the headers for a single
4076
+ request; this effectively ignores the headers
4077
+ in the spec for a single request.
4078
+ :type _headers: dict, optional
4079
+ :param _host_index: set to override the host_index for a single
4080
+ request; this effectively ignores the host_index
4081
+ in the spec for a single request.
4082
+ :type _host_index: int, optional
4083
+ :return: Returns the result object.
4084
+ """ # noqa: E501
4085
+
4086
+ _param = self._update_subscription_addon_serialize(
4087
+ subscription_id=subscription_id,
4088
+ subscription_addon_id=subscription_addon_id,
4089
+ subscription_addon_update=subscription_addon_update,
4090
+ _request_auth=_request_auth,
4091
+ _content_type=_content_type,
4092
+ _headers=_headers,
4093
+ _host_index=_host_index
4094
+ )
4095
+
4096
+ _response_types_map: Dict[str, Optional[str]] = {
4097
+ '200': "SubscriptionAddon",
4098
+ '400': "UnexpectedProblemResponse",
4099
+ '401': "UnexpectedProblemResponse",
4100
+ '403': "UnexpectedProblemResponse",
4101
+ '404': "UnexpectedProblemResponse",
4102
+ '412': "UnexpectedProblemResponse",
4103
+ '500': "UnexpectedProblemResponse",
4104
+ '503': "UnexpectedProblemResponse",
4105
+ }
4106
+ response_data = self.api_client.call_api(
4107
+ *_param,
4108
+ _request_timeout=_request_timeout
4109
+ )
4110
+ response_data.read()
4111
+ return self.api_client.response_deserialize(
4112
+ response_data=response_data,
4113
+ response_types_map=_response_types_map,
4114
+ ).data
4115
+
4116
+
4117
+ @validate_call
4118
+ def update_subscription_addon_with_http_info(
4119
+ self,
4120
+ subscription_id: Annotated[str, Field(strict=True)],
4121
+ subscription_addon_id: Annotated[str, Field(strict=True)],
4122
+ subscription_addon_update: SubscriptionAddonUpdate,
4123
+ _request_timeout: Union[
4124
+ None,
4125
+ Annotated[StrictFloat, Field(gt=0)],
4126
+ Tuple[
4127
+ Annotated[StrictFloat, Field(gt=0)],
4128
+ Annotated[StrictFloat, Field(gt=0)]
4129
+ ]
4130
+ ] = None,
4131
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
4132
+ _content_type: Optional[StrictStr] = None,
4133
+ _headers: Optional[Dict[StrictStr, Any]] = None,
4134
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
4135
+ ) -> ApiResponse[SubscriptionAddon]:
4136
+ """Update subscription addon
4137
+
4138
+ Updates a subscription addon (allows changing the quantity: purchasing more instances or cancelling the current instances)
4139
+
4140
+ :param subscription_id: (required)
4141
+ :type subscription_id: str
4142
+ :param subscription_addon_id: (required)
4143
+ :type subscription_addon_id: str
4144
+ :param subscription_addon_update: (required)
4145
+ :type subscription_addon_update: SubscriptionAddonUpdate
4146
+ :param _request_timeout: timeout setting for this request. If one
4147
+ number provided, it will be total request
4148
+ timeout. It can also be a pair (tuple) of
4149
+ (connection, read) timeouts.
4150
+ :type _request_timeout: int, tuple(int, int), optional
4151
+ :param _request_auth: set to override the auth_settings for an a single
4152
+ request; this effectively ignores the
4153
+ authentication in the spec for a single request.
4154
+ :type _request_auth: dict, optional
4155
+ :param _content_type: force content-type for the request.
4156
+ :type _content_type: str, Optional
4157
+ :param _headers: set to override the headers for a single
4158
+ request; this effectively ignores the headers
4159
+ in the spec for a single request.
4160
+ :type _headers: dict, optional
4161
+ :param _host_index: set to override the host_index for a single
4162
+ request; this effectively ignores the host_index
4163
+ in the spec for a single request.
4164
+ :type _host_index: int, optional
4165
+ :return: Returns the result object.
4166
+ """ # noqa: E501
4167
+
4168
+ _param = self._update_subscription_addon_serialize(
4169
+ subscription_id=subscription_id,
4170
+ subscription_addon_id=subscription_addon_id,
4171
+ subscription_addon_update=subscription_addon_update,
4172
+ _request_auth=_request_auth,
4173
+ _content_type=_content_type,
4174
+ _headers=_headers,
4175
+ _host_index=_host_index
4176
+ )
4177
+
4178
+ _response_types_map: Dict[str, Optional[str]] = {
4179
+ '200': "SubscriptionAddon",
4180
+ '400': "UnexpectedProblemResponse",
4181
+ '401': "UnexpectedProblemResponse",
4182
+ '403': "UnexpectedProblemResponse",
4183
+ '404': "UnexpectedProblemResponse",
4184
+ '412': "UnexpectedProblemResponse",
4185
+ '500': "UnexpectedProblemResponse",
4186
+ '503': "UnexpectedProblemResponse",
4187
+ }
4188
+ response_data = self.api_client.call_api(
4189
+ *_param,
4190
+ _request_timeout=_request_timeout
4191
+ )
4192
+ response_data.read()
4193
+ return self.api_client.response_deserialize(
4194
+ response_data=response_data,
4195
+ response_types_map=_response_types_map,
4196
+ )
4197
+
4198
+
4199
+ @validate_call
4200
+ def update_subscription_addon_without_preload_content(
4201
+ self,
4202
+ subscription_id: Annotated[str, Field(strict=True)],
4203
+ subscription_addon_id: Annotated[str, Field(strict=True)],
4204
+ subscription_addon_update: SubscriptionAddonUpdate,
4205
+ _request_timeout: Union[
4206
+ None,
4207
+ Annotated[StrictFloat, Field(gt=0)],
4208
+ Tuple[
4209
+ Annotated[StrictFloat, Field(gt=0)],
4210
+ Annotated[StrictFloat, Field(gt=0)]
4211
+ ]
4212
+ ] = None,
4213
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
4214
+ _content_type: Optional[StrictStr] = None,
4215
+ _headers: Optional[Dict[StrictStr, Any]] = None,
4216
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
4217
+ ) -> RESTResponseType:
4218
+ """Update subscription addon
4219
+
4220
+ Updates a subscription addon (allows changing the quantity: purchasing more instances or cancelling the current instances)
4221
+
4222
+ :param subscription_id: (required)
4223
+ :type subscription_id: str
4224
+ :param subscription_addon_id: (required)
4225
+ :type subscription_addon_id: str
4226
+ :param subscription_addon_update: (required)
4227
+ :type subscription_addon_update: SubscriptionAddonUpdate
4228
+ :param _request_timeout: timeout setting for this request. If one
4229
+ number provided, it will be total request
4230
+ timeout. It can also be a pair (tuple) of
4231
+ (connection, read) timeouts.
4232
+ :type _request_timeout: int, tuple(int, int), optional
4233
+ :param _request_auth: set to override the auth_settings for an a single
4234
+ request; this effectively ignores the
4235
+ authentication in the spec for a single request.
4236
+ :type _request_auth: dict, optional
4237
+ :param _content_type: force content-type for the request.
4238
+ :type _content_type: str, Optional
4239
+ :param _headers: set to override the headers for a single
4240
+ request; this effectively ignores the headers
4241
+ in the spec for a single request.
4242
+ :type _headers: dict, optional
4243
+ :param _host_index: set to override the host_index for a single
4244
+ request; this effectively ignores the host_index
4245
+ in the spec for a single request.
4246
+ :type _host_index: int, optional
4247
+ :return: Returns the result object.
4248
+ """ # noqa: E501
4249
+
4250
+ _param = self._update_subscription_addon_serialize(
4251
+ subscription_id=subscription_id,
4252
+ subscription_addon_id=subscription_addon_id,
4253
+ subscription_addon_update=subscription_addon_update,
4254
+ _request_auth=_request_auth,
4255
+ _content_type=_content_type,
4256
+ _headers=_headers,
4257
+ _host_index=_host_index
4258
+ )
4259
+
4260
+ _response_types_map: Dict[str, Optional[str]] = {
4261
+ '200': "SubscriptionAddon",
4262
+ '400': "UnexpectedProblemResponse",
4263
+ '401': "UnexpectedProblemResponse",
4264
+ '403': "UnexpectedProblemResponse",
4265
+ '404': "UnexpectedProblemResponse",
4266
+ '412': "UnexpectedProblemResponse",
4267
+ '500': "UnexpectedProblemResponse",
4268
+ '503': "UnexpectedProblemResponse",
4269
+ }
4270
+ response_data = self.api_client.call_api(
4271
+ *_param,
4272
+ _request_timeout=_request_timeout
4273
+ )
4274
+ return response_data.response
4275
+
4276
+
4277
+ def _update_subscription_addon_serialize(
4278
+ self,
4279
+ subscription_id,
4280
+ subscription_addon_id,
4281
+ subscription_addon_update,
4282
+ _request_auth,
4283
+ _content_type,
4284
+ _headers,
4285
+ _host_index,
4286
+ ) -> RequestSerialized:
4287
+
4288
+ _host = None
4289
+
4290
+ _collection_formats: Dict[str, str] = {
4291
+ }
4292
+
4293
+ _path_params: Dict[str, str] = {}
4294
+ _query_params: List[Tuple[str, str]] = []
4295
+ _header_params: Dict[str, Optional[str]] = _headers or {}
4296
+ _form_params: List[Tuple[str, str]] = []
4297
+ _files: Dict[
4298
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
4299
+ ] = {}
4300
+ _body_params: Optional[bytes] = None
4301
+
4302
+ # process the path parameters
4303
+ if subscription_id is not None:
4304
+ _path_params['subscriptionId'] = subscription_id
4305
+ if subscription_addon_id is not None:
4306
+ _path_params['subscriptionAddonId'] = subscription_addon_id
4307
+ # process the query parameters
4308
+ # process the header parameters
4309
+ # process the form parameters
4310
+ # process the body parameter
4311
+ if subscription_addon_update is not None:
4312
+ _body_params = subscription_addon_update
4313
+
4314
+
4315
+ # set the HTTP header `Accept`
4316
+ if 'Accept' not in _header_params:
4317
+ _header_params['Accept'] = self.api_client.select_header_accept(
4318
+ [
4319
+ 'application/json',
4320
+ 'application/problem+json'
4321
+ ]
4322
+ )
4323
+
4324
+ # set the HTTP header `Content-Type`
4325
+ if _content_type:
4326
+ _header_params['Content-Type'] = _content_type
4327
+ else:
4328
+ _default_content_type = (
4329
+ self.api_client.select_header_content_type(
4330
+ [
4331
+ 'application/json'
4332
+ ]
4333
+ )
4334
+ )
4335
+ if _default_content_type is not None:
4336
+ _header_params['Content-Type'] = _default_content_type
4337
+
4338
+ # authentication setting
4339
+ _auth_settings: List[str] = [
4340
+ 'CloudTokenAuth'
4341
+ ]
4342
+
4343
+ return self.api_client.param_serialize(
4344
+ method='PATCH',
4345
+ resource_path='/api/v1/subscriptions/{subscriptionId}/addons/{subscriptionAddonId}',
4346
+ path_params=_path_params,
4347
+ query_params=_query_params,
4348
+ header_params=_header_params,
4349
+ body=_body_params,
4350
+ post_params=_form_params,
4351
+ files=_files,
4352
+ auth_settings=_auth_settings,
4353
+ collection_formats=_collection_formats,
4354
+ _host=_host,
4355
+ _request_auth=_request_auth
4356
+ )
4357
+
4358
+