orb-billing 0.11.0 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (746) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +39 -0
  3. data/README.md +1 -1
  4. data/lib/orb/internal/type/base_model.rb +5 -5
  5. data/lib/orb/internal/type/union.rb +3 -8
  6. data/lib/orb/internal/util.rb +8 -9
  7. data/lib/orb/models/accounting_provider_config.rb +21 -0
  8. data/lib/orb/models/address.rb +45 -0
  9. data/lib/orb/models/address_input.rb +45 -0
  10. data/lib/orb/models/adjustment_interval.rb +66 -0
  11. data/lib/orb/models/aggregated_cost.rb +45 -0
  12. data/lib/orb/models/alert.rb +9 -60
  13. data/lib/orb/models/alert_create_for_customer_params.rb +3 -24
  14. data/lib/orb/models/alert_create_for_external_customer_params.rb +3 -24
  15. data/lib/orb/models/alert_create_for_subscription_params.rb +3 -23
  16. data/lib/orb/models/alert_update_params.rb +3 -22
  17. data/lib/orb/models/allocation.rb +27 -0
  18. data/lib/orb/models/amount_discount.rb +9 -1
  19. data/lib/orb/models/amount_discount_interval.rb +65 -0
  20. data/lib/orb/models/beta/external_plan_id_create_plan_version_params.rb +186 -17772
  21. data/lib/orb/models/beta_create_plan_version_params.rb +183 -17605
  22. data/lib/orb/models/billable_metric_tiny.rb +15 -0
  23. data/lib/orb/models/billing_cycle_anchor_configuration.rb +41 -0
  24. data/lib/orb/models/billing_cycle_configuration.rb +32 -0
  25. data/lib/orb/models/bps_config.rb +24 -0
  26. data/lib/orb/models/bps_tier.rb +40 -0
  27. data/lib/orb/models/bulk_bps_config.rb +20 -0
  28. data/lib/orb/models/bulk_bps_tier.rb +32 -0
  29. data/lib/orb/models/bulk_config.rb +16 -0
  30. data/lib/orb/models/bulk_tier.rb +24 -0
  31. data/lib/orb/models/changed_subscription_resources.rb +40 -0
  32. data/lib/orb/models/conversion_rate_tier.rb +32 -0
  33. data/lib/orb/models/conversion_rate_tiered_config.rb +16 -0
  34. data/lib/orb/models/conversion_rate_unit_config.rb +16 -0
  35. data/lib/orb/models/coupon_redemption.rb +27 -0
  36. data/lib/orb/models/credit_note.rb +6 -51
  37. data/lib/orb/models/credit_note_tiny.rb +16 -0
  38. data/lib/orb/models/custom_expiration.rb +32 -0
  39. data/lib/orb/models/customer.rb +15 -426
  40. data/lib/orb/models/customer_create_params.rb +24 -527
  41. data/lib/orb/models/customer_hierarchy_config.rb +29 -0
  42. data/lib/orb/models/customer_minified.rb +21 -0
  43. data/lib/orb/models/customer_tax_id.rb +300 -0
  44. data/lib/orb/models/customer_update_by_external_id_params.rb +24 -529
  45. data/lib/orb/models/customer_update_params.rb +24 -527
  46. data/lib/orb/models/customers/balance_transaction_create_response.rb +6 -32
  47. data/lib/orb/models/customers/balance_transaction_list_response.rb +6 -32
  48. data/lib/orb/models/customers/cost_list_by_external_id_response.rb +3 -88
  49. data/lib/orb/models/customers/cost_list_response.rb +3 -87
  50. data/lib/orb/models/customers/credits/affected_block.rb +31 -0
  51. data/lib/orb/models/customers/credits/amendment_ledger_entry.rb +131 -0
  52. data/lib/orb/models/customers/credits/credit_block_expiry_ledger_entry.rb +137 -0
  53. data/lib/orb/models/customers/credits/decrement_ledger_entry.rb +152 -0
  54. data/lib/orb/models/customers/credits/expiration_change_ledger_entry.rb +141 -0
  55. data/lib/orb/models/customers/credits/increment_ledger_entry.rb +139 -0
  56. data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rb +8 -1177
  57. data/lib/orb/models/customers/credits/ledger_create_entry_response.rb +8 -1169
  58. data/lib/orb/models/customers/credits/ledger_list_by_external_id_response.rb +8 -1173
  59. data/lib/orb/models/customers/credits/ledger_list_response.rb +8 -1161
  60. data/lib/orb/models/customers/credits/top_up_create_by_external_id_response.rb +3 -52
  61. data/lib/orb/models/customers/credits/top_up_create_response.rb +3 -51
  62. data/lib/orb/models/customers/credits/top_up_invoice_settings.rb +53 -0
  63. data/lib/orb/models/customers/credits/top_up_list_by_external_id_response.rb +3 -52
  64. data/lib/orb/models/customers/credits/top_up_list_response.rb +3 -51
  65. data/lib/orb/models/customers/credits/void_initiated_ledger_entry.rb +152 -0
  66. data/lib/orb/models/customers/credits/void_ledger_entry.rb +145 -0
  67. data/lib/orb/models/dimensional_price_configuration.rb +21 -0
  68. data/lib/orb/models/discount_override.rb +56 -0
  69. data/lib/orb/models/fixed_fee_quantity_schedule_entry.rb +33 -0
  70. data/lib/orb/models/fixed_fee_quantity_transition.rb +27 -0
  71. data/lib/orb/models/invoice.rb +56 -1777
  72. data/lib/orb/models/invoice_create_params.rb +3 -15
  73. data/lib/orb/models/invoice_fetch_upcoming_response.rb +56 -1794
  74. data/lib/orb/models/invoice_line_item_create_response.rb +25 -1142
  75. data/lib/orb/models/invoice_tiny.rb +16 -0
  76. data/lib/orb/models/item_slim.rb +21 -0
  77. data/lib/orb/models/matrix_config.rb +32 -0
  78. data/lib/orb/models/matrix_sub_line_item.rb +61 -0
  79. data/lib/orb/models/matrix_value.rb +29 -0
  80. data/lib/orb/models/matrix_with_allocation_config.rb +40 -0
  81. data/lib/orb/models/maximum.rb +38 -0
  82. data/lib/orb/models/maximum_interval.rb +52 -0
  83. data/lib/orb/models/minimum.rb +38 -0
  84. data/lib/orb/models/minimum_interval.rb +52 -0
  85. data/lib/orb/models/monetary_amount_discount_adjustment.rb +87 -0
  86. data/lib/orb/models/monetary_maximum_adjustment.rb +87 -0
  87. data/lib/orb/models/monetary_minimum_adjustment.rb +95 -0
  88. data/lib/orb/models/monetary_percentage_discount_adjustment.rb +87 -0
  89. data/lib/orb/models/monetary_usage_discount_adjustment.rb +87 -0
  90. data/lib/orb/models/mutated_subscription.rb +302 -0
  91. data/lib/orb/models/new_accounting_sync_configuration.rb +23 -0
  92. data/lib/orb/models/new_allocation_price.rb +70 -0
  93. data/lib/orb/models/new_amount_discount.rb +120 -0
  94. data/lib/orb/models/new_avalara_tax_configuration.rb +37 -0
  95. data/lib/orb/models/new_billing_cycle_configuration.rb +37 -0
  96. data/lib/orb/models/new_dimensional_price_configuration.rb +36 -0
  97. data/lib/orb/models/new_floating_bps_price.rb +199 -0
  98. data/lib/orb/models/new_floating_bulk_bps_price.rb +197 -0
  99. data/lib/orb/models/new_floating_bulk_price.rb +197 -0
  100. data/lib/orb/models/new_floating_bulk_with_proration_price.rb +197 -0
  101. data/lib/orb/models/new_floating_cumulative_grouped_bulk_price.rb +197 -0
  102. data/lib/orb/models/new_floating_grouped_allocation_price.rb +197 -0
  103. data/lib/orb/models/new_floating_grouped_tiered_package_price.rb +197 -0
  104. data/lib/orb/models/new_floating_grouped_tiered_price.rb +197 -0
  105. data/lib/orb/models/new_floating_grouped_with_metered_minimum_price.rb +197 -0
  106. data/lib/orb/models/new_floating_grouped_with_prorated_minimum_price.rb +198 -0
  107. data/lib/orb/models/new_floating_matrix_price.rb +197 -0
  108. data/lib/orb/models/new_floating_matrix_with_allocation_price.rb +197 -0
  109. data/lib/orb/models/new_floating_matrix_with_display_name_price.rb +197 -0
  110. data/lib/orb/models/new_floating_max_group_tiered_package_price.rb +197 -0
  111. data/lib/orb/models/new_floating_package_price.rb +197 -0
  112. data/lib/orb/models/new_floating_package_with_allocation_price.rb +197 -0
  113. data/lib/orb/models/new_floating_scalable_matrix_with_tiered_pricing_price.rb +198 -0
  114. data/lib/orb/models/new_floating_scalable_matrix_with_unit_pricing_price.rb +198 -0
  115. data/lib/orb/models/new_floating_threshold_total_amount_price.rb +197 -0
  116. data/lib/orb/models/new_floating_tiered_bps_price.rb +197 -0
  117. data/lib/orb/models/new_floating_tiered_package_price.rb +197 -0
  118. data/lib/orb/models/new_floating_tiered_package_with_minimum_price.rb +197 -0
  119. data/lib/orb/models/new_floating_tiered_price.rb +197 -0
  120. data/lib/orb/models/new_floating_tiered_with_minimum_price.rb +197 -0
  121. data/lib/orb/models/new_floating_tiered_with_proration_price.rb +197 -0
  122. data/lib/orb/models/new_floating_unit_price.rb +197 -0
  123. data/lib/orb/models/new_floating_unit_with_percent_price.rb +197 -0
  124. data/lib/orb/models/new_floating_unit_with_proration_price.rb +197 -0
  125. data/lib/orb/models/new_maximum.rb +120 -0
  126. data/lib/orb/models/new_minimum.rb +128 -0
  127. data/lib/orb/models/new_percentage_discount.rb +120 -0
  128. data/lib/orb/models/new_plan_bps_price.rb +196 -0
  129. data/lib/orb/models/new_plan_bulk_bps_price.rb +200 -0
  130. data/lib/orb/models/new_plan_bulk_price.rb +196 -0
  131. data/lib/orb/models/new_plan_bulk_with_proration_price.rb +198 -0
  132. data/lib/orb/models/new_plan_cumulative_grouped_bulk_price.rb +198 -0
  133. data/lib/orb/models/new_plan_grouped_allocation_price.rb +198 -0
  134. data/lib/orb/models/new_plan_grouped_tiered_package_price.rb +198 -0
  135. data/lib/orb/models/new_plan_grouped_tiered_price.rb +198 -0
  136. data/lib/orb/models/new_plan_grouped_with_metered_minimum_price.rb +198 -0
  137. data/lib/orb/models/new_plan_grouped_with_prorated_minimum_price.rb +199 -0
  138. data/lib/orb/models/new_plan_matrix_price.rb +200 -0
  139. data/lib/orb/models/new_plan_matrix_with_allocation_price.rb +198 -0
  140. data/lib/orb/models/new_plan_matrix_with_display_name_price.rb +198 -0
  141. data/lib/orb/models/new_plan_max_group_tiered_package_price.rb +198 -0
  142. data/lib/orb/models/new_plan_package_price.rb +200 -0
  143. data/lib/orb/models/new_plan_package_with_allocation_price.rb +198 -0
  144. data/lib/orb/models/new_plan_scalable_matrix_with_tiered_pricing_price.rb +199 -0
  145. data/lib/orb/models/new_plan_scalable_matrix_with_unit_pricing_price.rb +199 -0
  146. data/lib/orb/models/new_plan_threshold_total_amount_price.rb +198 -0
  147. data/lib/orb/models/new_plan_tier_with_proration_price.rb +198 -0
  148. data/lib/orb/models/new_plan_tiered_bps_price.rb +198 -0
  149. data/lib/orb/models/new_plan_tiered_package_price.rb +198 -0
  150. data/lib/orb/models/new_plan_tiered_package_with_minimum_price.rb +198 -0
  151. data/lib/orb/models/new_plan_tiered_price.rb +200 -0
  152. data/lib/orb/models/new_plan_tiered_with_minimum_price.rb +198 -0
  153. data/lib/orb/models/new_plan_unit_price.rb +196 -0
  154. data/lib/orb/models/new_plan_unit_with_percent_price.rb +198 -0
  155. data/lib/orb/models/new_plan_unit_with_proration_price.rb +198 -0
  156. data/lib/orb/models/new_reporting_configuration.rb +15 -0
  157. data/lib/orb/models/new_sphere_configuration.rb +31 -0
  158. data/lib/orb/models/new_subscription_bps_price.rb +207 -0
  159. data/lib/orb/models/new_subscription_bulk_bps_price.rb +207 -0
  160. data/lib/orb/models/new_subscription_bulk_price.rb +207 -0
  161. data/lib/orb/models/new_subscription_bulk_with_proration_price.rb +207 -0
  162. data/lib/orb/models/new_subscription_cumulative_grouped_bulk_price.rb +207 -0
  163. data/lib/orb/models/new_subscription_grouped_allocation_price.rb +207 -0
  164. data/lib/orb/models/new_subscription_grouped_tiered_package_price.rb +207 -0
  165. data/lib/orb/models/new_subscription_grouped_tiered_price.rb +207 -0
  166. data/lib/orb/models/new_subscription_grouped_with_metered_minimum_price.rb +207 -0
  167. data/lib/orb/models/new_subscription_grouped_with_prorated_minimum_price.rb +208 -0
  168. data/lib/orb/models/new_subscription_matrix_price.rb +207 -0
  169. data/lib/orb/models/new_subscription_matrix_with_allocation_price.rb +207 -0
  170. data/lib/orb/models/new_subscription_matrix_with_display_name_price.rb +207 -0
  171. data/lib/orb/models/new_subscription_max_group_tiered_package_price.rb +207 -0
  172. data/lib/orb/models/new_subscription_package_price.rb +207 -0
  173. data/lib/orb/models/new_subscription_package_with_allocation_price.rb +207 -0
  174. data/lib/orb/models/new_subscription_scalable_matrix_with_tiered_pricing_price.rb +209 -0
  175. data/lib/orb/models/new_subscription_scalable_matrix_with_unit_pricing_price.rb +209 -0
  176. data/lib/orb/models/new_subscription_threshold_total_amount_price.rb +207 -0
  177. data/lib/orb/models/new_subscription_tier_with_proration_price.rb +207 -0
  178. data/lib/orb/models/new_subscription_tiered_bps_price.rb +207 -0
  179. data/lib/orb/models/new_subscription_tiered_package_price.rb +207 -0
  180. data/lib/orb/models/new_subscription_tiered_package_with_minimum_price.rb +207 -0
  181. data/lib/orb/models/new_subscription_tiered_price.rb +207 -0
  182. data/lib/orb/models/new_subscription_tiered_with_minimum_price.rb +207 -0
  183. data/lib/orb/models/new_subscription_unit_price.rb +207 -0
  184. data/lib/orb/models/new_subscription_unit_with_percent_price.rb +207 -0
  185. data/lib/orb/models/new_subscription_unit_with_proration_price.rb +207 -0
  186. data/lib/orb/models/new_tax_jar_configuration.rb +31 -0
  187. data/lib/orb/models/new_usage_discount.rb +120 -0
  188. data/lib/orb/models/other_sub_line_item.rb +54 -0
  189. data/lib/orb/models/package_config.rb +28 -0
  190. data/lib/orb/models/per_price_cost.rb +48 -0
  191. data/lib/orb/models/percentage_discount.rb +9 -1
  192. data/lib/orb/models/percentage_discount_interval.rb +69 -0
  193. data/lib/orb/models/plan.rb +22 -1040
  194. data/lib/orb/models/plan_create_params.rb +31 -8145
  195. data/lib/orb/models/plan_phase_amount_discount_adjustment.rb +87 -0
  196. data/lib/orb/models/plan_phase_maximum_adjustment.rb +87 -0
  197. data/lib/orb/models/plan_phase_minimum_adjustment.rb +95 -0
  198. data/lib/orb/models/plan_phase_percentage_discount_adjustment.rb +87 -0
  199. data/lib/orb/models/plan_phase_usage_discount_adjustment.rb +87 -0
  200. data/lib/orb/models/plan_version.rb +10 -672
  201. data/lib/orb/models/price.rb +1225 -10817
  202. data/lib/orb/models/price_create_params.rb +53 -472
  203. data/lib/orb/models/price_evaluate_multiple_params.rb +32 -8479
  204. data/lib/orb/models/price_evaluate_preview_events_params.rb +236 -0
  205. data/lib/orb/models/price_evaluate_preview_events_response.rb +51 -0
  206. data/lib/orb/models/price_interval.rb +113 -0
  207. data/lib/orb/models/sub_line_item_grouping.rb +23 -0
  208. data/lib/orb/models/sub_line_item_matrix_config.rb +16 -0
  209. data/lib/orb/models/subscription.rb +33 -1581
  210. data/lib/orb/models/subscription_change_apply_response.rb +3 -1904
  211. data/lib/orb/models/subscription_change_cancel_response.rb +3 -1905
  212. data/lib/orb/models/subscription_change_minified.rb +15 -0
  213. data/lib/orb/models/subscription_change_retrieve_response.rb +3 -1906
  214. data/lib/orb/models/subscription_create_params.rb +232 -18278
  215. data/lib/orb/models/subscription_fetch_costs_response.rb +3 -87
  216. data/lib/orb/models/subscription_minified.rb +15 -0
  217. data/lib/orb/models/subscription_price_intervals_params.rb +86 -8758
  218. data/lib/orb/models/subscription_redeem_coupon_params.rb +17 -9
  219. data/lib/orb/models/subscription_schedule_plan_change_params.rb +238 -18372
  220. data/lib/orb/models/subscription_trial_info.rb +15 -0
  221. data/lib/orb/models/tax_amount.rb +32 -0
  222. data/lib/orb/models/threshold.rb +24 -0
  223. data/lib/orb/models/tier.rb +32 -0
  224. data/lib/orb/models/tier_config.rb +27 -0
  225. data/lib/orb/models/tier_sub_line_item.rb +61 -0
  226. data/lib/orb/models/tiered_bps_config.rb +20 -0
  227. data/lib/orb/models/tiered_config.rb +16 -0
  228. data/lib/orb/models/tiered_conversion_rate_config.rb +31 -0
  229. data/lib/orb/models/transform_price_filter.rb +61 -0
  230. data/lib/orb/models/trial_discount.rb +9 -1
  231. data/lib/orb/models/unit_config.rb +16 -0
  232. data/lib/orb/models/unit_conversion_rate_config.rb +31 -0
  233. data/lib/orb/models/usage_discount.rb +9 -1
  234. data/lib/orb/models/usage_discount_interval.rb +69 -0
  235. data/lib/orb/models.rb +348 -0
  236. data/lib/orb/resources/alerts.rb +4 -4
  237. data/lib/orb/resources/customers/credits/ledger.rb +4 -4
  238. data/lib/orb/resources/customers.rb +21 -21
  239. data/lib/orb/resources/plans.rb +1 -1
  240. data/lib/orb/resources/prices/external_price_id.rb +2 -2
  241. data/lib/orb/resources/prices.rb +82 -34
  242. data/lib/orb/resources/subscriptions.rb +29 -27
  243. data/lib/orb/version.rb +1 -1
  244. data/lib/orb.rb +181 -11
  245. data/rbi/orb/internal/util.rbi +2 -0
  246. data/rbi/orb/models/accounting_provider_config.rbi +34 -0
  247. data/rbi/orb/models/address.rbi +55 -0
  248. data/rbi/orb/models/address_input.rbi +62 -0
  249. data/rbi/orb/models/adjustment_interval.rbi +93 -0
  250. data/rbi/orb/models/aggregated_cost.rbi +61 -0
  251. data/rbi/orb/models/alert.rbi +11 -84
  252. data/rbi/orb/models/alert_create_for_customer_params.rbi +3 -42
  253. data/rbi/orb/models/alert_create_for_external_customer_params.rbi +3 -48
  254. data/rbi/orb/models/alert_create_for_subscription_params.rbi +3 -38
  255. data/rbi/orb/models/alert_update_params.rbi +3 -31
  256. data/rbi/orb/models/allocation.rbi +45 -0
  257. data/rbi/orb/models/amount_discount.rbi +8 -0
  258. data/rbi/orb/models/amount_discount_interval.rbi +100 -0
  259. data/rbi/orb/models/beta/external_plan_id_create_plan_version_params.rbi +482 -32442
  260. data/rbi/orb/models/beta_create_plan_version_params.rbi +484 -32436
  261. data/rbi/orb/models/billable_metric_tiny.rbi +21 -0
  262. data/rbi/orb/models/billing_cycle_anchor_configuration.rbi +61 -0
  263. data/rbi/orb/models/billing_cycle_configuration.rbi +70 -0
  264. data/rbi/orb/models/bps_config.rbi +36 -0
  265. data/rbi/orb/models/bps_tier.rbi +58 -0
  266. data/rbi/orb/models/bulk_bps_config.rbi +31 -0
  267. data/rbi/orb/models/bulk_bps_tier.rbi +50 -0
  268. data/rbi/orb/models/bulk_config.rbi +26 -0
  269. data/rbi/orb/models/bulk_tier.rbi +38 -0
  270. data/rbi/orb/models/changed_subscription_resources.rbi +61 -0
  271. data/rbi/orb/models/conversion_rate_tier.rbi +51 -0
  272. data/rbi/orb/models/conversion_rate_tiered_config.rbi +31 -0
  273. data/rbi/orb/models/conversion_rate_unit_config.rbi +27 -0
  274. data/rbi/orb/models/coupon_redemption.rbi +37 -0
  275. data/rbi/orb/models/credit_note.rbi +7 -87
  276. data/rbi/orb/models/credit_note_tiny.rbi +25 -0
  277. data/rbi/orb/models/custom_expiration.rbi +55 -0
  278. data/rbi/orb/models/customer.rbi +19 -522
  279. data/rbi/orb/models/customer_create_params.rbi +36 -957
  280. data/rbi/orb/models/customer_hierarchy_config.rbi +52 -0
  281. data/rbi/orb/models/customer_minified.rbi +32 -0
  282. data/rbi/orb/models/customer_tax_id.rbi +324 -0
  283. data/rbi/orb/models/customer_update_by_external_id_params.rbi +36 -1436
  284. data/rbi/orb/models/customer_update_params.rbi +36 -957
  285. data/rbi/orb/models/customers/balance_transaction_create_response.rbi +8 -96
  286. data/rbi/orb/models/customers/balance_transaction_list_response.rbi +8 -96
  287. data/rbi/orb/models/customers/cost_list_by_external_id_response.rbi +5 -191
  288. data/rbi/orb/models/customers/cost_list_response.rbi +5 -182
  289. data/rbi/orb/models/customers/credits/affected_block.rbi +50 -0
  290. data/rbi/orb/models/customers/credits/amendment_ledger_entry.rbi +207 -0
  291. data/rbi/orb/models/customers/credits/credit_block_expiry_ledger_entry.rbi +209 -0
  292. data/rbi/orb/models/customers/credits/decrement_ledger_entry.rbi +225 -0
  293. data/rbi/orb/models/customers/credits/expiration_change_ledger_entry.rbi +213 -0
  294. data/rbi/orb/models/customers/credits/increment_ledger_entry.rbi +215 -0
  295. data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbi +7 -1854
  296. data/rbi/orb/models/customers/credits/ledger_create_entry_response.rbi +7 -1854
  297. data/rbi/orb/models/customers/credits/ledger_list_by_external_id_response.rbi +7 -1854
  298. data/rbi/orb/models/customers/credits/ledger_list_response.rbi +7 -1854
  299. data/rbi/orb/models/customers/credits/top_up_create_by_external_id_response.rbi +4 -84
  300. data/rbi/orb/models/customers/credits/top_up_create_response.rbi +4 -84
  301. data/rbi/orb/models/customers/credits/top_up_invoice_settings.rbi +83 -0
  302. data/rbi/orb/models/customers/credits/top_up_list_by_external_id_response.rbi +4 -84
  303. data/rbi/orb/models/customers/credits/top_up_list_response.rbi +4 -84
  304. data/rbi/orb/models/customers/credits/void_initiated_ledger_entry.rbi +225 -0
  305. data/rbi/orb/models/customers/credits/void_ledger_entry.rbi +219 -0
  306. data/rbi/orb/models/dimensional_price_configuration.rbi +38 -0
  307. data/rbi/orb/models/discount_override.rbi +83 -0
  308. data/rbi/orb/models/fixed_fee_quantity_schedule_entry.rbi +48 -0
  309. data/rbi/orb/models/fixed_fee_quantity_transition.rbi +39 -0
  310. data/rbi/orb/models/invoice.rbi +212 -3345
  311. data/rbi/orb/models/invoice_create_params.rbi +4 -33
  312. data/rbi/orb/models/invoice_fetch_upcoming_response.rbi +355 -4329
  313. data/rbi/orb/models/invoice_line_item_create_response.rbi +30 -2260
  314. data/rbi/orb/models/invoice_tiny.rbi +24 -0
  315. data/rbi/orb/models/item_slim.rbi +23 -0
  316. data/rbi/orb/models/matrix_config.rbi +50 -0
  317. data/rbi/orb/models/matrix_sub_line_item.rbi +87 -0
  318. data/rbi/orb/models/matrix_value.rbi +43 -0
  319. data/rbi/orb/models/matrix_with_allocation_config.rbi +61 -0
  320. data/rbi/orb/models/maximum.rbi +52 -0
  321. data/rbi/orb/models/maximum_interval.rbi +69 -0
  322. data/rbi/orb/models/minimum.rbi +52 -0
  323. data/rbi/orb/models/minimum_interval.rbi +69 -0
  324. data/rbi/orb/models/monetary_amount_discount_adjustment.rbi +125 -0
  325. data/rbi/orb/models/monetary_maximum_adjustment.rbi +123 -0
  326. data/rbi/orb/models/monetary_minimum_adjustment.rbi +131 -0
  327. data/rbi/orb/models/monetary_percentage_discount_adjustment.rbi +131 -0
  328. data/rbi/orb/models/monetary_usage_discount_adjustment.rbi +125 -0
  329. data/rbi/orb/models/mutated_subscription.rbi +412 -0
  330. data/rbi/orb/models/new_accounting_sync_configuration.rbi +40 -0
  331. data/rbi/orb/models/new_allocation_price.rbi +104 -0
  332. data/rbi/orb/models/new_amount_discount.rbi +179 -0
  333. data/rbi/orb/models/new_avalara_tax_configuration.rbi +68 -0
  334. data/rbi/orb/models/new_billing_cycle_configuration.rbi +79 -0
  335. data/rbi/orb/models/new_dimensional_price_configuration.rbi +55 -0
  336. data/rbi/orb/models/new_floating_bps_price.rbi +294 -0
  337. data/rbi/orb/models/new_floating_bulk_bps_price.rbi +309 -0
  338. data/rbi/orb/models/new_floating_bulk_price.rbi +298 -0
  339. data/rbi/orb/models/new_floating_bulk_with_proration_price.rbi +331 -0
  340. data/rbi/orb/models/new_floating_cumulative_grouped_bulk_price.rbi +338 -0
  341. data/rbi/orb/models/new_floating_grouped_allocation_price.rbi +331 -0
  342. data/rbi/orb/models/new_floating_grouped_tiered_package_price.rbi +337 -0
  343. data/rbi/orb/models/new_floating_grouped_tiered_price.rbi +325 -0
  344. data/rbi/orb/models/new_floating_grouped_with_metered_minimum_price.rbi +348 -0
  345. data/rbi/orb/models/new_floating_grouped_with_prorated_minimum_price.rbi +348 -0
  346. data/rbi/orb/models/new_floating_matrix_price.rbi +304 -0
  347. data/rbi/orb/models/new_floating_matrix_with_allocation_price.rbi +345 -0
  348. data/rbi/orb/models/new_floating_matrix_with_display_name_price.rbi +338 -0
  349. data/rbi/orb/models/new_floating_max_group_tiered_package_price.rbi +338 -0
  350. data/rbi/orb/models/new_floating_package_price.rbi +306 -0
  351. data/rbi/orb/models/new_floating_package_with_allocation_price.rbi +338 -0
  352. data/rbi/orb/models/new_floating_scalable_matrix_with_tiered_pricing_price.rbi +350 -0
  353. data/rbi/orb/models/new_floating_scalable_matrix_with_unit_pricing_price.rbi +349 -0
  354. data/rbi/orb/models/new_floating_threshold_total_amount_price.rbi +337 -0
  355. data/rbi/orb/models/new_floating_tiered_bps_price.rbi +317 -0
  356. data/rbi/orb/models/new_floating_tiered_package_price.rbi +325 -0
  357. data/rbi/orb/models/new_floating_tiered_package_with_minimum_price.rbi +348 -0
  358. data/rbi/orb/models/new_floating_tiered_price.rbi +304 -0
  359. data/rbi/orb/models/new_floating_tiered_with_minimum_price.rbi +331 -0
  360. data/rbi/orb/models/new_floating_tiered_with_proration_price.rbi +337 -0
  361. data/rbi/orb/models/new_floating_unit_price.rbi +298 -0
  362. data/rbi/orb/models/new_floating_unit_with_percent_price.rbi +328 -0
  363. data/rbi/orb/models/new_floating_unit_with_proration_price.rbi +331 -0
  364. data/rbi/orb/models/new_maximum.rbi +160 -0
  365. data/rbi/orb/models/new_minimum.rbi +168 -0
  366. data/rbi/orb/models/new_percentage_discount.rbi +193 -0
  367. data/rbi/orb/models/new_plan_bps_price.rbi +294 -0
  368. data/rbi/orb/models/new_plan_bulk_bps_price.rbi +297 -0
  369. data/rbi/orb/models/new_plan_bulk_price.rbi +295 -0
  370. data/rbi/orb/models/new_plan_bulk_with_proration_price.rbi +327 -0
  371. data/rbi/orb/models/new_plan_cumulative_grouped_bulk_price.rbi +333 -0
  372. data/rbi/orb/models/new_plan_grouped_allocation_price.rbi +327 -0
  373. data/rbi/orb/models/new_plan_grouped_tiered_package_price.rbi +333 -0
  374. data/rbi/orb/models/new_plan_grouped_tiered_price.rbi +316 -0
  375. data/rbi/orb/models/new_plan_grouped_with_metered_minimum_price.rbi +340 -0
  376. data/rbi/orb/models/new_plan_grouped_with_prorated_minimum_price.rbi +345 -0
  377. data/rbi/orb/models/new_plan_matrix_price.rbi +297 -0
  378. data/rbi/orb/models/new_plan_matrix_with_allocation_price.rbi +341 -0
  379. data/rbi/orb/models/new_plan_matrix_with_display_name_price.rbi +333 -0
  380. data/rbi/orb/models/new_plan_max_group_tiered_package_price.rbi +333 -0
  381. data/rbi/orb/models/new_plan_package_price.rbi +297 -0
  382. data/rbi/orb/models/new_plan_package_with_allocation_price.rbi +333 -0
  383. data/rbi/orb/models/new_plan_scalable_matrix_with_tiered_pricing_price.rbi +352 -0
  384. data/rbi/orb/models/new_plan_scalable_matrix_with_unit_pricing_price.rbi +351 -0
  385. data/rbi/orb/models/new_plan_threshold_total_amount_price.rbi +333 -0
  386. data/rbi/orb/models/new_plan_tier_with_proration_price.rbi +327 -0
  387. data/rbi/orb/models/new_plan_tiered_bps_price.rbi +304 -0
  388. data/rbi/orb/models/new_plan_tiered_package_price.rbi +316 -0
  389. data/rbi/orb/models/new_plan_tiered_package_with_minimum_price.rbi +339 -0
  390. data/rbi/orb/models/new_plan_tiered_price.rbi +297 -0
  391. data/rbi/orb/models/new_plan_tiered_with_minimum_price.rbi +327 -0
  392. data/rbi/orb/models/new_plan_unit_price.rbi +295 -0
  393. data/rbi/orb/models/new_plan_unit_with_percent_price.rbi +325 -0
  394. data/rbi/orb/models/new_plan_unit_with_proration_price.rbi +327 -0
  395. data/rbi/orb/models/new_reporting_configuration.rbi +23 -0
  396. data/rbi/orb/models/new_sphere_configuration.rbi +59 -0
  397. data/rbi/orb/models/new_subscription_bps_price.rbi +317 -0
  398. data/rbi/orb/models/new_subscription_bulk_bps_price.rbi +338 -0
  399. data/rbi/orb/models/new_subscription_bulk_price.rbi +321 -0
  400. data/rbi/orb/models/new_subscription_bulk_with_proration_price.rbi +350 -0
  401. data/rbi/orb/models/new_subscription_cumulative_grouped_bulk_price.rbi +360 -0
  402. data/rbi/orb/models/new_subscription_grouped_allocation_price.rbi +350 -0
  403. data/rbi/orb/models/new_subscription_grouped_tiered_package_price.rbi +360 -0
  404. data/rbi/orb/models/new_subscription_grouped_tiered_price.rbi +343 -0
  405. data/rbi/orb/models/new_subscription_grouped_with_metered_minimum_price.rbi +360 -0
  406. data/rbi/orb/models/new_subscription_grouped_with_prorated_minimum_price.rbi +360 -0
  407. data/rbi/orb/models/new_subscription_matrix_price.rbi +332 -0
  408. data/rbi/orb/models/new_subscription_matrix_with_allocation_price.rbi +368 -0
  409. data/rbi/orb/models/new_subscription_matrix_with_display_name_price.rbi +360 -0
  410. data/rbi/orb/models/new_subscription_max_group_tiered_package_price.rbi +360 -0
  411. data/rbi/orb/models/new_subscription_package_price.rbi +338 -0
  412. data/rbi/orb/models/new_subscription_package_with_allocation_price.rbi +360 -0
  413. data/rbi/orb/models/new_subscription_scalable_matrix_with_tiered_pricing_price.rbi +362 -0
  414. data/rbi/orb/models/new_subscription_scalable_matrix_with_unit_pricing_price.rbi +361 -0
  415. data/rbi/orb/models/new_subscription_threshold_total_amount_price.rbi +360 -0
  416. data/rbi/orb/models/new_subscription_tier_with_proration_price.rbi +350 -0
  417. data/rbi/orb/models/new_subscription_tiered_bps_price.rbi +340 -0
  418. data/rbi/orb/models/new_subscription_tiered_package_price.rbi +343 -0
  419. data/rbi/orb/models/new_subscription_tiered_package_with_minimum_price.rbi +360 -0
  420. data/rbi/orb/models/new_subscription_tiered_price.rbi +332 -0
  421. data/rbi/orb/models/new_subscription_tiered_with_minimum_price.rbi +350 -0
  422. data/rbi/orb/models/new_subscription_unit_price.rbi +321 -0
  423. data/rbi/orb/models/new_subscription_unit_with_percent_price.rbi +349 -0
  424. data/rbi/orb/models/new_subscription_unit_with_proration_price.rbi +350 -0
  425. data/rbi/orb/models/new_tax_jar_configuration.rbi +59 -0
  426. data/rbi/orb/models/new_usage_discount.rbi +177 -0
  427. data/rbi/orb/models/other_sub_line_item.rbi +78 -0
  428. data/rbi/orb/models/package_config.rbi +39 -0
  429. data/rbi/orb/models/per_price_cost.rbi +96 -0
  430. data/rbi/orb/models/percentage_discount.rbi +8 -0
  431. data/rbi/orb/models/percentage_discount_interval.rbi +107 -0
  432. data/rbi/orb/models/plan.rbi +29 -1937
  433. data/rbi/orb/models/plan_create_params.rbi +112 -15428
  434. data/rbi/orb/models/plan_phase_amount_discount_adjustment.rbi +128 -0
  435. data/rbi/orb/models/plan_phase_maximum_adjustment.rbi +123 -0
  436. data/rbi/orb/models/plan_phase_minimum_adjustment.rbi +131 -0
  437. data/rbi/orb/models/plan_phase_percentage_discount_adjustment.rbi +131 -0
  438. data/rbi/orb/models/plan_phase_usage_discount_adjustment.rbi +125 -0
  439. data/rbi/orb/models/plan_version.rbi +13 -1252
  440. data/rbi/orb/models/price.rbi +3518 -26097
  441. data/rbi/orb/models/price_create_params.rbi +81 -937
  442. data/rbi/orb/models/price_evaluate_multiple_params.rbi +112 -15566
  443. data/rbi/orb/models/price_evaluate_preview_events_params.rbi +411 -0
  444. data/rbi/orb/models/price_evaluate_preview_events_response.rbi +101 -0
  445. data/rbi/orb/models/price_interval.rbi +174 -0
  446. data/rbi/orb/models/sub_line_item_grouping.rbi +31 -0
  447. data/rbi/orb/models/sub_line_item_matrix_config.rbi +33 -0
  448. data/rbi/orb/models/subscription.rbi +51 -2939
  449. data/rbi/orb/models/subscription_change_apply_response.rbi +4 -3580
  450. data/rbi/orb/models/subscription_change_cancel_response.rbi +4 -3580
  451. data/rbi/orb/models/subscription_change_minified.rbi +23 -0
  452. data/rbi/orb/models/subscription_change_retrieve_response.rbi +4 -3582
  453. data/rbi/orb/models/subscription_create_params.rbi +541 -33368
  454. data/rbi/orb/models/subscription_fetch_costs_response.rbi +5 -182
  455. data/rbi/orb/models/subscription_minified.rbi +23 -0
  456. data/rbi/orb/models/subscription_price_intervals_params.rbi +224 -16144
  457. data/rbi/orb/models/subscription_redeem_coupon_params.rbi +16 -8
  458. data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +549 -33384
  459. data/rbi/orb/models/subscription_trial_info.rbi +23 -0
  460. data/rbi/orb/models/tax_amount.rbi +50 -0
  461. data/rbi/orb/models/threshold.rbi +30 -0
  462. data/rbi/orb/models/tier.rbi +50 -0
  463. data/rbi/orb/models/tier_config.rbi +40 -0
  464. data/rbi/orb/models/tier_sub_line_item.rbi +87 -0
  465. data/rbi/orb/models/tiered_bps_config.rbi +29 -0
  466. data/rbi/orb/models/tiered_config.rbi +26 -0
  467. data/rbi/orb/models/tiered_conversion_rate_config.rbi +73 -0
  468. data/rbi/orb/models/transform_price_filter.rbi +106 -0
  469. data/rbi/orb/models/trial_discount.rbi +8 -0
  470. data/rbi/orb/models/unit_config.rbi +24 -0
  471. data/rbi/orb/models/unit_conversion_rate_config.rbi +71 -0
  472. data/rbi/orb/models/usage_discount.rbi +8 -0
  473. data/rbi/orb/models/usage_discount_interval.rbi +99 -0
  474. data/rbi/orb/models.rbi +398 -0
  475. data/rbi/orb/resources/alerts.rbi +4 -13
  476. data/rbi/orb/resources/customers.rbi +27 -51
  477. data/rbi/orb/resources/plans.rbi +28 -28
  478. data/rbi/orb/resources/prices.rbi +82 -36
  479. data/rbi/orb/resources/subscriptions.rbi +19 -22
  480. data/sig/orb/models/accounting_provider_config.rbs +19 -0
  481. data/sig/orb/models/address.rbs +45 -0
  482. data/sig/orb/models/address_input.rbs +45 -0
  483. data/sig/orb/models/adjustment_interval.rbs +53 -0
  484. data/sig/orb/models/aggregated_cost.rbs +40 -0
  485. data/sig/orb/models/alert.rbs +12 -44
  486. data/sig/orb/models/alert_create_for_customer_params.rbs +4 -14
  487. data/sig/orb/models/alert_create_for_external_customer_params.rbs +4 -14
  488. data/sig/orb/models/alert_create_for_subscription_params.rbs +4 -14
  489. data/sig/orb/models/alert_update_params.rbs +4 -14
  490. data/sig/orb/models/allocation.rbs +30 -0
  491. data/sig/orb/models/amount_discount.rbs +5 -0
  492. data/sig/orb/models/amount_discount_interval.rbs +55 -0
  493. data/sig/orb/models/beta/external_plan_id_create_plan_version_params.rbs +147 -12821
  494. data/sig/orb/models/beta_create_plan_version_params.rbs +144 -12802
  495. data/sig/orb/models/billable_metric_tiny.rbs +13 -0
  496. data/sig/orb/models/billing_cycle_anchor_configuration.rbs +18 -0
  497. data/sig/orb/models/billing_cycle_configuration.rbs +36 -0
  498. data/sig/orb/models/bps_config.rbs +15 -0
  499. data/sig/orb/models/bps_tier.rbs +35 -0
  500. data/sig/orb/models/bulk_bps_config.rbs +13 -0
  501. data/sig/orb/models/bulk_bps_tier.rbs +26 -0
  502. data/sig/orb/models/bulk_config.rbs +13 -0
  503. data/sig/orb/models/bulk_tier.rbs +15 -0
  504. data/sig/orb/models/changed_subscription_resources.rbs +35 -0
  505. data/sig/orb/models/conversion_rate_tier.rbs +26 -0
  506. data/sig/orb/models/conversion_rate_tiered_config.rbs +14 -0
  507. data/sig/orb/models/conversion_rate_unit_config.rbs +13 -0
  508. data/sig/orb/models/coupon_redemption.rbs +22 -0
  509. data/sig/orb/models/credit_note.rbs +8 -47
  510. data/sig/orb/models/credit_note_tiny.rbs +13 -0
  511. data/sig/orb/models/custom_expiration.rbs +36 -0
  512. data/sig/orb/models/customer.rbs +20 -471
  513. data/sig/orb/models/customer_create_params.rbs +27 -577
  514. data/sig/orb/models/customer_hierarchy_config.rbs +24 -0
  515. data/sig/orb/models/customer_minified.rbs +15 -0
  516. data/sig/orb/models/customer_tax_id.rbs +346 -0
  517. data/sig/orb/models/customer_update_by_external_id_params.rbs +27 -577
  518. data/sig/orb/models/customer_update_params.rbs +27 -577
  519. data/sig/orb/models/customers/balance_transaction_create_response.rbs +8 -28
  520. data/sig/orb/models/customers/balance_transaction_list_response.rbs +8 -28
  521. data/sig/orb/models/customers/cost_list_by_external_id_response.rbs +4 -84
  522. data/sig/orb/models/customers/cost_list_response.rbs +4 -83
  523. data/sig/orb/models/customers/credits/affected_block.rbs +30 -0
  524. data/sig/orb/models/customers/credits/amendment_ledger_entry.rbs +105 -0
  525. data/sig/orb/models/customers/credits/credit_block_expiry_ledger_entry.rbs +107 -0
  526. data/sig/orb/models/customers/credits/decrement_ledger_entry.rbs +120 -0
  527. data/sig/orb/models/customers/credits/expiration_change_ledger_entry.rbs +110 -0
  528. data/sig/orb/models/customers/credits/increment_ledger_entry.rbs +110 -0
  529. data/sig/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbs +7 -939
  530. data/sig/orb/models/customers/credits/ledger_create_entry_response.rbs +7 -939
  531. data/sig/orb/models/customers/credits/ledger_list_by_external_id_response.rbs +7 -939
  532. data/sig/orb/models/customers/credits/ledger_list_response.rbs +7 -939
  533. data/sig/orb/models/customers/credits/top_up_create_by_external_id_response.rbs +4 -38
  534. data/sig/orb/models/customers/credits/top_up_create_response.rbs +4 -38
  535. data/sig/orb/models/customers/credits/top_up_invoice_settings.rbs +41 -0
  536. data/sig/orb/models/customers/credits/top_up_list_by_external_id_response.rbs +4 -38
  537. data/sig/orb/models/customers/credits/top_up_list_response.rbs +4 -38
  538. data/sig/orb/models/customers/credits/void_initiated_ledger_entry.rbs +120 -0
  539. data/sig/orb/models/customers/credits/void_ledger_entry.rbs +115 -0
  540. data/sig/orb/models/dimensional_price_configuration.rbs +22 -0
  541. data/sig/orb/models/discount_override.rbs +47 -0
  542. data/sig/orb/models/fixed_fee_quantity_schedule_entry.rbs +30 -0
  543. data/sig/orb/models/fixed_fee_quantity_transition.rbs +26 -0
  544. data/sig/orb/models/invoice.rbs +54 -1612
  545. data/sig/orb/models/invoice_create_params.rbs +4 -14
  546. data/sig/orb/models/invoice_fetch_upcoming_response.rbs +54 -1612
  547. data/sig/orb/models/invoice_line_item_create_response.rbs +18 -927
  548. data/sig/orb/models/invoice_tiny.rbs +13 -0
  549. data/sig/orb/models/item_slim.rbs +15 -0
  550. data/sig/orb/models/matrix_config.rbs +30 -0
  551. data/sig/orb/models/matrix_sub_line_item.rbs +55 -0
  552. data/sig/orb/models/matrix_value.rbs +22 -0
  553. data/sig/orb/models/matrix_with_allocation_config.rbs +35 -0
  554. data/sig/orb/models/maximum.rbs +30 -0
  555. data/sig/orb/models/maximum_interval.rbs +40 -0
  556. data/sig/orb/models/minimum.rbs +30 -0
  557. data/sig/orb/models/minimum_interval.rbs +40 -0
  558. data/sig/orb/models/monetary_amount_discount_adjustment.rbs +65 -0
  559. data/sig/orb/models/monetary_maximum_adjustment.rbs +65 -0
  560. data/sig/orb/models/monetary_minimum_adjustment.rbs +70 -0
  561. data/sig/orb/models/monetary_percentage_discount_adjustment.rbs +65 -0
  562. data/sig/orb/models/monetary_usage_discount_adjustment.rbs +65 -0
  563. data/sig/orb/models/mutated_subscription.rbs +178 -0
  564. data/sig/orb/models/new_accounting_sync_configuration.rbs +25 -0
  565. data/sig/orb/models/new_allocation_price.rbs +56 -0
  566. data/sig/orb/models/new_amount_discount.rbs +97 -0
  567. data/sig/orb/models/new_avalara_tax_configuration.rbs +40 -0
  568. data/sig/orb/models/new_billing_cycle_configuration.rbs +36 -0
  569. data/sig/orb/models/new_dimensional_price_configuration.rbs +30 -0
  570. data/sig/orb/models/new_floating_bps_price.rbs +135 -0
  571. data/sig/orb/models/new_floating_bulk_bps_price.rbs +135 -0
  572. data/sig/orb/models/new_floating_bulk_price.rbs +135 -0
  573. data/sig/orb/models/new_floating_bulk_with_proration_price.rbs +135 -0
  574. data/sig/orb/models/new_floating_cumulative_grouped_bulk_price.rbs +135 -0
  575. data/sig/orb/models/new_floating_grouped_allocation_price.rbs +135 -0
  576. data/sig/orb/models/new_floating_grouped_tiered_package_price.rbs +135 -0
  577. data/sig/orb/models/new_floating_grouped_tiered_price.rbs +135 -0
  578. data/sig/orb/models/new_floating_grouped_with_metered_minimum_price.rbs +135 -0
  579. data/sig/orb/models/new_floating_grouped_with_prorated_minimum_price.rbs +135 -0
  580. data/sig/orb/models/new_floating_matrix_price.rbs +135 -0
  581. data/sig/orb/models/new_floating_matrix_with_allocation_price.rbs +135 -0
  582. data/sig/orb/models/new_floating_matrix_with_display_name_price.rbs +135 -0
  583. data/sig/orb/models/new_floating_max_group_tiered_package_price.rbs +135 -0
  584. data/sig/orb/models/new_floating_package_price.rbs +135 -0
  585. data/sig/orb/models/new_floating_package_with_allocation_price.rbs +135 -0
  586. data/sig/orb/models/new_floating_scalable_matrix_with_tiered_pricing_price.rbs +135 -0
  587. data/sig/orb/models/new_floating_scalable_matrix_with_unit_pricing_price.rbs +135 -0
  588. data/sig/orb/models/new_floating_threshold_total_amount_price.rbs +135 -0
  589. data/sig/orb/models/new_floating_tiered_bps_price.rbs +135 -0
  590. data/sig/orb/models/new_floating_tiered_package_price.rbs +135 -0
  591. data/sig/orb/models/new_floating_tiered_package_with_minimum_price.rbs +135 -0
  592. data/sig/orb/models/new_floating_tiered_price.rbs +135 -0
  593. data/sig/orb/models/new_floating_tiered_with_minimum_price.rbs +135 -0
  594. data/sig/orb/models/new_floating_tiered_with_proration_price.rbs +135 -0
  595. data/sig/orb/models/new_floating_unit_price.rbs +135 -0
  596. data/sig/orb/models/new_floating_unit_with_percent_price.rbs +135 -0
  597. data/sig/orb/models/new_floating_unit_with_proration_price.rbs +135 -0
  598. data/sig/orb/models/new_maximum.rbs +97 -0
  599. data/sig/orb/models/new_minimum.rbs +102 -0
  600. data/sig/orb/models/new_percentage_discount.rbs +97 -0
  601. data/sig/orb/models/new_plan_bps_price.rbs +135 -0
  602. data/sig/orb/models/new_plan_bulk_bps_price.rbs +135 -0
  603. data/sig/orb/models/new_plan_bulk_price.rbs +135 -0
  604. data/sig/orb/models/new_plan_bulk_with_proration_price.rbs +135 -0
  605. data/sig/orb/models/new_plan_cumulative_grouped_bulk_price.rbs +135 -0
  606. data/sig/orb/models/new_plan_grouped_allocation_price.rbs +135 -0
  607. data/sig/orb/models/new_plan_grouped_tiered_package_price.rbs +135 -0
  608. data/sig/orb/models/new_plan_grouped_tiered_price.rbs +135 -0
  609. data/sig/orb/models/new_plan_grouped_with_metered_minimum_price.rbs +135 -0
  610. data/sig/orb/models/new_plan_grouped_with_prorated_minimum_price.rbs +135 -0
  611. data/sig/orb/models/new_plan_matrix_price.rbs +135 -0
  612. data/sig/orb/models/new_plan_matrix_with_allocation_price.rbs +135 -0
  613. data/sig/orb/models/new_plan_matrix_with_display_name_price.rbs +135 -0
  614. data/sig/orb/models/new_plan_max_group_tiered_package_price.rbs +135 -0
  615. data/sig/orb/models/new_plan_package_price.rbs +135 -0
  616. data/sig/orb/models/new_plan_package_with_allocation_price.rbs +135 -0
  617. data/sig/orb/models/new_plan_scalable_matrix_with_tiered_pricing_price.rbs +135 -0
  618. data/sig/orb/models/new_plan_scalable_matrix_with_unit_pricing_price.rbs +135 -0
  619. data/sig/orb/models/new_plan_threshold_total_amount_price.rbs +135 -0
  620. data/sig/orb/models/new_plan_tier_with_proration_price.rbs +135 -0
  621. data/sig/orb/models/new_plan_tiered_bps_price.rbs +135 -0
  622. data/sig/orb/models/new_plan_tiered_package_price.rbs +135 -0
  623. data/sig/orb/models/new_plan_tiered_package_with_minimum_price.rbs +135 -0
  624. data/sig/orb/models/new_plan_tiered_price.rbs +135 -0
  625. data/sig/orb/models/new_plan_tiered_with_minimum_price.rbs +135 -0
  626. data/sig/orb/models/new_plan_unit_price.rbs +135 -0
  627. data/sig/orb/models/new_plan_unit_with_percent_price.rbs +135 -0
  628. data/sig/orb/models/new_plan_unit_with_proration_price.rbs +135 -0
  629. data/sig/orb/models/new_reporting_configuration.rbs +13 -0
  630. data/sig/orb/models/new_sphere_configuration.rbs +35 -0
  631. data/sig/orb/models/new_subscription_bps_price.rbs +140 -0
  632. data/sig/orb/models/new_subscription_bulk_bps_price.rbs +140 -0
  633. data/sig/orb/models/new_subscription_bulk_price.rbs +140 -0
  634. data/sig/orb/models/new_subscription_bulk_with_proration_price.rbs +140 -0
  635. data/sig/orb/models/new_subscription_cumulative_grouped_bulk_price.rbs +140 -0
  636. data/sig/orb/models/new_subscription_grouped_allocation_price.rbs +140 -0
  637. data/sig/orb/models/new_subscription_grouped_tiered_package_price.rbs +140 -0
  638. data/sig/orb/models/new_subscription_grouped_tiered_price.rbs +140 -0
  639. data/sig/orb/models/new_subscription_grouped_with_metered_minimum_price.rbs +140 -0
  640. data/sig/orb/models/new_subscription_grouped_with_prorated_minimum_price.rbs +140 -0
  641. data/sig/orb/models/new_subscription_matrix_price.rbs +140 -0
  642. data/sig/orb/models/new_subscription_matrix_with_allocation_price.rbs +140 -0
  643. data/sig/orb/models/new_subscription_matrix_with_display_name_price.rbs +140 -0
  644. data/sig/orb/models/new_subscription_max_group_tiered_package_price.rbs +140 -0
  645. data/sig/orb/models/new_subscription_package_price.rbs +140 -0
  646. data/sig/orb/models/new_subscription_package_with_allocation_price.rbs +140 -0
  647. data/sig/orb/models/new_subscription_scalable_matrix_with_tiered_pricing_price.rbs +140 -0
  648. data/sig/orb/models/new_subscription_scalable_matrix_with_unit_pricing_price.rbs +140 -0
  649. data/sig/orb/models/new_subscription_threshold_total_amount_price.rbs +140 -0
  650. data/sig/orb/models/new_subscription_tier_with_proration_price.rbs +140 -0
  651. data/sig/orb/models/new_subscription_tiered_bps_price.rbs +140 -0
  652. data/sig/orb/models/new_subscription_tiered_package_price.rbs +140 -0
  653. data/sig/orb/models/new_subscription_tiered_package_with_minimum_price.rbs +140 -0
  654. data/sig/orb/models/new_subscription_tiered_price.rbs +140 -0
  655. data/sig/orb/models/new_subscription_tiered_with_minimum_price.rbs +140 -0
  656. data/sig/orb/models/new_subscription_unit_price.rbs +140 -0
  657. data/sig/orb/models/new_subscription_unit_with_percent_price.rbs +140 -0
  658. data/sig/orb/models/new_subscription_unit_with_proration_price.rbs +140 -0
  659. data/sig/orb/models/new_tax_jar_configuration.rbs +35 -0
  660. data/sig/orb/models/new_usage_discount.rbs +97 -0
  661. data/sig/orb/models/other_sub_line_item.rbs +50 -0
  662. data/sig/orb/models/package_config.rbs +15 -0
  663. data/sig/orb/models/per_price_cost.rbs +40 -0
  664. data/sig/orb/models/percentage_discount.rbs +5 -0
  665. data/sig/orb/models/percentage_discount_interval.rbs +55 -0
  666. data/sig/orb/models/plan.rbs +21 -871
  667. data/sig/orb/models/plan_create_params.rbs +28 -5952
  668. data/sig/orb/models/plan_phase_amount_discount_adjustment.rbs +65 -0
  669. data/sig/orb/models/plan_phase_maximum_adjustment.rbs +65 -0
  670. data/sig/orb/models/plan_phase_minimum_adjustment.rbs +70 -0
  671. data/sig/orb/models/plan_phase_percentage_discount_adjustment.rbs +65 -0
  672. data/sig/orb/models/plan_phase_usage_discount_adjustment.rbs +65 -0
  673. data/sig/orb/models/plan_version.rbs +5 -535
  674. data/sig/orb/models/price.rbs +2164 -11297
  675. data/sig/orb/models/price_create_params.rbs +58 -418
  676. data/sig/orb/models/price_evaluate_multiple_params.rbs +28 -6138
  677. data/sig/orb/models/price_evaluate_preview_events_params.rbs +166 -0
  678. data/sig/orb/models/price_evaluate_preview_events_response.rbs +50 -0
  679. data/sig/orb/models/price_interval.rbs +65 -0
  680. data/sig/orb/models/sub_line_item_grouping.rbs +15 -0
  681. data/sig/orb/models/sub_line_item_matrix_config.rbs +13 -0
  682. data/sig/orb/models/subscription.rbs +39 -1274
  683. data/sig/orb/models/subscription_change_apply_response.rbs +4 -1467
  684. data/sig/orb/models/subscription_change_cancel_response.rbs +4 -1467
  685. data/sig/orb/models/subscription_change_minified.rbs +13 -0
  686. data/sig/orb/models/subscription_change_retrieve_response.rbs +4 -1467
  687. data/sig/orb/models/subscription_create_params.rbs +174 -13219
  688. data/sig/orb/models/subscription_fetch_costs_response.rbs +4 -82
  689. data/sig/orb/models/subscription_minified.rbs +13 -0
  690. data/sig/orb/models/subscription_price_intervals_params.rbs +61 -6390
  691. data/sig/orb/models/subscription_redeem_coupon_params.rbs +11 -6
  692. data/sig/orb/models/subscription_schedule_plan_change_params.rbs +175 -13220
  693. data/sig/orb/models/subscription_trial_info.rbs +13 -0
  694. data/sig/orb/models/tax_amount.rbs +30 -0
  695. data/sig/orb/models/threshold.rbs +13 -0
  696. data/sig/orb/models/tier.rbs +25 -0
  697. data/sig/orb/models/tier_config.rbs +26 -0
  698. data/sig/orb/models/tier_sub_line_item.rbs +55 -0
  699. data/sig/orb/models/tiered_bps_config.rbs +13 -0
  700. data/sig/orb/models/tiered_config.rbs +13 -0
  701. data/sig/orb/models/tiered_conversion_rate_config.rbs +35 -0
  702. data/sig/orb/models/transform_price_filter.rbs +56 -0
  703. data/sig/orb/models/trial_discount.rbs +5 -0
  704. data/sig/orb/models/unit_config.rbs +13 -0
  705. data/sig/orb/models/unit_conversion_rate_config.rbs +35 -0
  706. data/sig/orb/models/usage_discount.rbs +5 -0
  707. data/sig/orb/models/usage_discount_interval.rbs +55 -0
  708. data/sig/orb/models.rbs +342 -0
  709. data/sig/orb/resources/alerts.rbs +4 -4
  710. data/sig/orb/resources/customers.rbs +18 -18
  711. data/sig/orb/resources/prices.rbs +23 -13
  712. data/sig/orb/resources/subscriptions.rbs +15 -14
  713. metadata +545 -35
  714. data/lib/orb/models/subscription_cancel_response.rb +0 -1873
  715. data/lib/orb/models/subscription_create_response.rb +0 -1873
  716. data/lib/orb/models/subscription_price_intervals_response.rb +0 -1888
  717. data/lib/orb/models/subscription_redeem_coupon_response.rb +0 -1883
  718. data/lib/orb/models/subscription_schedule_plan_change_response.rb +0 -1893
  719. data/lib/orb/models/subscription_trigger_phase_response.rb +0 -1883
  720. data/lib/orb/models/subscription_unschedule_cancellation_response.rb +0 -1897
  721. data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rb +0 -1912
  722. data/lib/orb/models/subscription_unschedule_pending_plan_changes_response.rb +0 -1908
  723. data/lib/orb/models/subscription_update_fixed_fee_quantity_response.rb +0 -1897
  724. data/lib/orb/models/subscription_update_trial_response.rb +0 -1879
  725. data/rbi/orb/models/subscription_cancel_response.rbi +0 -3537
  726. data/rbi/orb/models/subscription_create_response.rbi +0 -3537
  727. data/rbi/orb/models/subscription_price_intervals_response.rbi +0 -3564
  728. data/rbi/orb/models/subscription_redeem_coupon_response.rbi +0 -3557
  729. data/rbi/orb/models/subscription_schedule_plan_change_response.rbi +0 -3564
  730. data/rbi/orb/models/subscription_trigger_phase_response.rbi +0 -3557
  731. data/rbi/orb/models/subscription_unschedule_cancellation_response.rbi +0 -3566
  732. data/rbi/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbi +0 -3566
  733. data/rbi/orb/models/subscription_unschedule_pending_plan_changes_response.rbi +0 -3566
  734. data/rbi/orb/models/subscription_update_fixed_fee_quantity_response.rbi +0 -3566
  735. data/rbi/orb/models/subscription_update_trial_response.rbi +0 -3556
  736. data/sig/orb/models/subscription_cancel_response.rbs +0 -1445
  737. data/sig/orb/models/subscription_create_response.rbs +0 -1445
  738. data/sig/orb/models/subscription_price_intervals_response.rbs +0 -1445
  739. data/sig/orb/models/subscription_redeem_coupon_response.rbs +0 -1445
  740. data/sig/orb/models/subscription_schedule_plan_change_response.rbs +0 -1445
  741. data/sig/orb/models/subscription_trigger_phase_response.rbs +0 -1445
  742. data/sig/orb/models/subscription_unschedule_cancellation_response.rbs +0 -1445
  743. data/sig/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbs +0 -1445
  744. data/sig/orb/models/subscription_unschedule_pending_plan_changes_response.rbs +0 -1445
  745. data/sig/orb/models/subscription_update_fixed_fee_quantity_response.rbs +0 -1445
  746. data/sig/orb/models/subscription_update_trial_response.rbs +0 -1445
@@ -1,3537 +0,0 @@
1
- # typed: strong
2
-
3
- module Orb
4
- module Models
5
- class SubscriptionCancelResponse < Orb::Internal::Type::BaseModel
6
- OrHash =
7
- T.type_alias do
8
- T.any(Orb::Models::SubscriptionCancelResponse, Orb::Internal::AnyHash)
9
- end
10
-
11
- sig { returns(String) }
12
- attr_accessor :id
13
-
14
- # The current plan phase that is active, only if the subscription's plan has
15
- # phases.
16
- sig { returns(T.nilable(Integer)) }
17
- attr_accessor :active_plan_phase_order
18
-
19
- # The adjustment intervals for this subscription sorted by the start_date of the
20
- # adjustment interval.
21
- sig do
22
- returns(
23
- T::Array[Orb::Models::SubscriptionCancelResponse::AdjustmentInterval]
24
- )
25
- end
26
- attr_accessor :adjustment_intervals
27
-
28
- # Determines whether issued invoices for this subscription will automatically be
29
- # charged with the saved payment method on the due date. This property defaults to
30
- # the plan's behavior. If null, defaults to the customer's setting.
31
- sig { returns(T.nilable(T::Boolean)) }
32
- attr_accessor :auto_collection
33
-
34
- sig do
35
- returns(
36
- Orb::Models::SubscriptionCancelResponse::BillingCycleAnchorConfiguration
37
- )
38
- end
39
- attr_reader :billing_cycle_anchor_configuration
40
-
41
- sig do
42
- params(
43
- billing_cycle_anchor_configuration:
44
- Orb::Models::SubscriptionCancelResponse::BillingCycleAnchorConfiguration::OrHash
45
- ).void
46
- end
47
- attr_writer :billing_cycle_anchor_configuration
48
-
49
- # The day of the month on which the billing cycle is anchored. If the maximum
50
- # number of days in a month is greater than this value, the last day of the month
51
- # is the billing cycle day (e.g. billing_cycle_day=31 for April means the billing
52
- # period begins on the 30th.
53
- sig { returns(Integer) }
54
- attr_accessor :billing_cycle_day
55
-
56
- sig { returns(Time) }
57
- attr_accessor :created_at
58
-
59
- # The end of the current billing period. This is an exclusive timestamp, such that
60
- # the instant returned is not part of the billing period. Set to null for
61
- # subscriptions that are not currently active.
62
- sig { returns(T.nilable(Time)) }
63
- attr_accessor :current_billing_period_end_date
64
-
65
- # The start date of the current billing period. This is an inclusive timestamp;
66
- # the instant returned is exactly the beginning of the billing period. Set to null
67
- # if the subscription is not currently active.
68
- sig { returns(T.nilable(Time)) }
69
- attr_accessor :current_billing_period_start_date
70
-
71
- # A customer is a buyer of your products, and the other party to the billing
72
- # relationship.
73
- #
74
- # In Orb, customers are assigned system generated identifiers automatically, but
75
- # it's often desirable to have these match existing identifiers in your system. To
76
- # avoid having to denormalize Orb ID information, you can pass in an
77
- # `external_customer_id` with your own identifier. See
78
- # [Customer ID Aliases](/events-and-metrics/customer-aliases) for further
79
- # information about how these aliases work in Orb.
80
- #
81
- # In addition to having an identifier in your system, a customer may exist in a
82
- # payment provider solution like Stripe. Use the `payment_provider_id` and the
83
- # `payment_provider` enum field to express this mapping.
84
- #
85
- # A customer also has a timezone (from the standard
86
- # [IANA timezone database](https://www.iana.org/time-zones)), which defaults to
87
- # your account's timezone. See [Timezone localization](/essentials/timezones) for
88
- # information on what this timezone parameter influences within Orb.
89
- sig { returns(Orb::Customer) }
90
- attr_reader :customer
91
-
92
- sig { params(customer: Orb::Customer::OrHash).void }
93
- attr_writer :customer
94
-
95
- # Determines the default memo on this subscriptions' invoices. Note that if this
96
- # is not provided, it is determined by the plan configuration.
97
- sig { returns(T.nilable(String)) }
98
- attr_accessor :default_invoice_memo
99
-
100
- # The discount intervals for this subscription sorted by the start_date.
101
- sig do
102
- returns(
103
- T::Array[
104
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Variants
105
- ]
106
- )
107
- end
108
- attr_accessor :discount_intervals
109
-
110
- # The date Orb stops billing for this subscription.
111
- sig { returns(T.nilable(Time)) }
112
- attr_accessor :end_date
113
-
114
- sig do
115
- returns(
116
- T::Array[
117
- Orb::Models::SubscriptionCancelResponse::FixedFeeQuantitySchedule
118
- ]
119
- )
120
- end
121
- attr_accessor :fixed_fee_quantity_schedule
122
-
123
- sig { returns(T.nilable(String)) }
124
- attr_accessor :invoicing_threshold
125
-
126
- # The maximum intervals for this subscription sorted by the start_date.
127
- sig do
128
- returns(
129
- T::Array[Orb::Models::SubscriptionCancelResponse::MaximumInterval]
130
- )
131
- end
132
- attr_accessor :maximum_intervals
133
-
134
- # User specified key-value pairs for the resource. If not present, this defaults
135
- # to an empty dictionary. Individual keys can be removed by setting the value to
136
- # `null`, and the entire metadata mapping can be cleared by setting `metadata` to
137
- # `null`.
138
- sig { returns(T::Hash[Symbol, String]) }
139
- attr_accessor :metadata
140
-
141
- # The minimum intervals for this subscription sorted by the start_date.
142
- sig do
143
- returns(
144
- T::Array[Orb::Models::SubscriptionCancelResponse::MinimumInterval]
145
- )
146
- end
147
- attr_accessor :minimum_intervals
148
-
149
- # The name of the subscription.
150
- sig { returns(String) }
151
- attr_accessor :name
152
-
153
- # Determines the difference between the invoice issue date for subscription
154
- # invoices as the date that they are due. A value of `0` here represents that the
155
- # invoice is due on issue, whereas a value of `30` represents that the customer
156
- # has a month to pay the invoice.
157
- sig { returns(Integer) }
158
- attr_accessor :net_terms
159
-
160
- # A pending subscription change if one exists on this subscription.
161
- sig do
162
- returns(
163
- T.nilable(
164
- Orb::Models::SubscriptionCancelResponse::PendingSubscriptionChange
165
- )
166
- )
167
- end
168
- attr_reader :pending_subscription_change
169
-
170
- sig do
171
- params(
172
- pending_subscription_change:
173
- T.nilable(
174
- Orb::Models::SubscriptionCancelResponse::PendingSubscriptionChange::OrHash
175
- )
176
- ).void
177
- end
178
- attr_writer :pending_subscription_change
179
-
180
- # The [Plan](/core-concepts#plan-and-price) resource represents a plan that can be
181
- # subscribed to by a customer. Plans define the billing behavior of the
182
- # subscription. You can see more about how to configure prices in the
183
- # [Price resource](/reference/price).
184
- sig { returns(T.nilable(Orb::Plan)) }
185
- attr_reader :plan
186
-
187
- sig { params(plan: T.nilable(Orb::Plan::OrHash)).void }
188
- attr_writer :plan
189
-
190
- # The price intervals for this subscription.
191
- sig do
192
- returns(
193
- T::Array[Orb::Models::SubscriptionCancelResponse::PriceInterval]
194
- )
195
- end
196
- attr_accessor :price_intervals
197
-
198
- sig do
199
- returns(
200
- T.nilable(Orb::Models::SubscriptionCancelResponse::RedeemedCoupon)
201
- )
202
- end
203
- attr_reader :redeemed_coupon
204
-
205
- sig do
206
- params(
207
- redeemed_coupon:
208
- T.nilable(
209
- Orb::Models::SubscriptionCancelResponse::RedeemedCoupon::OrHash
210
- )
211
- ).void
212
- end
213
- attr_writer :redeemed_coupon
214
-
215
- # The date Orb starts billing for this subscription.
216
- sig { returns(Time) }
217
- attr_accessor :start_date
218
-
219
- sig do
220
- returns(Orb::Models::SubscriptionCancelResponse::Status::TaggedSymbol)
221
- end
222
- attr_accessor :status
223
-
224
- sig { returns(Orb::Models::SubscriptionCancelResponse::TrialInfo) }
225
- attr_reader :trial_info
226
-
227
- sig do
228
- params(
229
- trial_info: Orb::Models::SubscriptionCancelResponse::TrialInfo::OrHash
230
- ).void
231
- end
232
- attr_writer :trial_info
233
-
234
- # The resources that were changed as part of this operation. Only present when
235
- # fetched through the subscription changes API or if the
236
- # `include_changed_resources` parameter was passed in the request.
237
- sig do
238
- returns(
239
- T.nilable(Orb::Models::SubscriptionCancelResponse::ChangedResources)
240
- )
241
- end
242
- attr_reader :changed_resources
243
-
244
- sig do
245
- params(
246
- changed_resources:
247
- T.nilable(
248
- Orb::Models::SubscriptionCancelResponse::ChangedResources::OrHash
249
- )
250
- ).void
251
- end
252
- attr_writer :changed_resources
253
-
254
- sig do
255
- params(
256
- id: String,
257
- active_plan_phase_order: T.nilable(Integer),
258
- adjustment_intervals:
259
- T::Array[
260
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::OrHash
261
- ],
262
- auto_collection: T.nilable(T::Boolean),
263
- billing_cycle_anchor_configuration:
264
- Orb::Models::SubscriptionCancelResponse::BillingCycleAnchorConfiguration::OrHash,
265
- billing_cycle_day: Integer,
266
- created_at: Time,
267
- current_billing_period_end_date: T.nilable(Time),
268
- current_billing_period_start_date: T.nilable(Time),
269
- customer: Orb::Customer::OrHash,
270
- default_invoice_memo: T.nilable(String),
271
- discount_intervals:
272
- T::Array[
273
- T.any(
274
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::OrHash,
275
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::OrHash,
276
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::OrHash
277
- )
278
- ],
279
- end_date: T.nilable(Time),
280
- fixed_fee_quantity_schedule:
281
- T::Array[
282
- Orb::Models::SubscriptionCancelResponse::FixedFeeQuantitySchedule::OrHash
283
- ],
284
- invoicing_threshold: T.nilable(String),
285
- maximum_intervals:
286
- T::Array[
287
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::OrHash
288
- ],
289
- metadata: T::Hash[Symbol, String],
290
- minimum_intervals:
291
- T::Array[
292
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::OrHash
293
- ],
294
- name: String,
295
- net_terms: Integer,
296
- pending_subscription_change:
297
- T.nilable(
298
- Orb::Models::SubscriptionCancelResponse::PendingSubscriptionChange::OrHash
299
- ),
300
- plan: T.nilable(Orb::Plan::OrHash),
301
- price_intervals:
302
- T::Array[
303
- Orb::Models::SubscriptionCancelResponse::PriceInterval::OrHash
304
- ],
305
- redeemed_coupon:
306
- T.nilable(
307
- Orb::Models::SubscriptionCancelResponse::RedeemedCoupon::OrHash
308
- ),
309
- start_date: Time,
310
- status: Orb::Models::SubscriptionCancelResponse::Status::OrSymbol,
311
- trial_info:
312
- Orb::Models::SubscriptionCancelResponse::TrialInfo::OrHash,
313
- changed_resources:
314
- T.nilable(
315
- Orb::Models::SubscriptionCancelResponse::ChangedResources::OrHash
316
- )
317
- ).returns(T.attached_class)
318
- end
319
- def self.new(
320
- id:,
321
- # The current plan phase that is active, only if the subscription's plan has
322
- # phases.
323
- active_plan_phase_order:,
324
- # The adjustment intervals for this subscription sorted by the start_date of the
325
- # adjustment interval.
326
- adjustment_intervals:,
327
- # Determines whether issued invoices for this subscription will automatically be
328
- # charged with the saved payment method on the due date. This property defaults to
329
- # the plan's behavior. If null, defaults to the customer's setting.
330
- auto_collection:,
331
- billing_cycle_anchor_configuration:,
332
- # The day of the month on which the billing cycle is anchored. If the maximum
333
- # number of days in a month is greater than this value, the last day of the month
334
- # is the billing cycle day (e.g. billing_cycle_day=31 for April means the billing
335
- # period begins on the 30th.
336
- billing_cycle_day:,
337
- created_at:,
338
- # The end of the current billing period. This is an exclusive timestamp, such that
339
- # the instant returned is not part of the billing period. Set to null for
340
- # subscriptions that are not currently active.
341
- current_billing_period_end_date:,
342
- # The start date of the current billing period. This is an inclusive timestamp;
343
- # the instant returned is exactly the beginning of the billing period. Set to null
344
- # if the subscription is not currently active.
345
- current_billing_period_start_date:,
346
- # A customer is a buyer of your products, and the other party to the billing
347
- # relationship.
348
- #
349
- # In Orb, customers are assigned system generated identifiers automatically, but
350
- # it's often desirable to have these match existing identifiers in your system. To
351
- # avoid having to denormalize Orb ID information, you can pass in an
352
- # `external_customer_id` with your own identifier. See
353
- # [Customer ID Aliases](/events-and-metrics/customer-aliases) for further
354
- # information about how these aliases work in Orb.
355
- #
356
- # In addition to having an identifier in your system, a customer may exist in a
357
- # payment provider solution like Stripe. Use the `payment_provider_id` and the
358
- # `payment_provider` enum field to express this mapping.
359
- #
360
- # A customer also has a timezone (from the standard
361
- # [IANA timezone database](https://www.iana.org/time-zones)), which defaults to
362
- # your account's timezone. See [Timezone localization](/essentials/timezones) for
363
- # information on what this timezone parameter influences within Orb.
364
- customer:,
365
- # Determines the default memo on this subscriptions' invoices. Note that if this
366
- # is not provided, it is determined by the plan configuration.
367
- default_invoice_memo:,
368
- # The discount intervals for this subscription sorted by the start_date.
369
- discount_intervals:,
370
- # The date Orb stops billing for this subscription.
371
- end_date:,
372
- fixed_fee_quantity_schedule:,
373
- invoicing_threshold:,
374
- # The maximum intervals for this subscription sorted by the start_date.
375
- maximum_intervals:,
376
- # User specified key-value pairs for the resource. If not present, this defaults
377
- # to an empty dictionary. Individual keys can be removed by setting the value to
378
- # `null`, and the entire metadata mapping can be cleared by setting `metadata` to
379
- # `null`.
380
- metadata:,
381
- # The minimum intervals for this subscription sorted by the start_date.
382
- minimum_intervals:,
383
- # The name of the subscription.
384
- name:,
385
- # Determines the difference between the invoice issue date for subscription
386
- # invoices as the date that they are due. A value of `0` here represents that the
387
- # invoice is due on issue, whereas a value of `30` represents that the customer
388
- # has a month to pay the invoice.
389
- net_terms:,
390
- # A pending subscription change if one exists on this subscription.
391
- pending_subscription_change:,
392
- # The [Plan](/core-concepts#plan-and-price) resource represents a plan that can be
393
- # subscribed to by a customer. Plans define the billing behavior of the
394
- # subscription. You can see more about how to configure prices in the
395
- # [Price resource](/reference/price).
396
- plan:,
397
- # The price intervals for this subscription.
398
- price_intervals:,
399
- redeemed_coupon:,
400
- # The date Orb starts billing for this subscription.
401
- start_date:,
402
- status:,
403
- trial_info:,
404
- # The resources that were changed as part of this operation. Only present when
405
- # fetched through the subscription changes API or if the
406
- # `include_changed_resources` parameter was passed in the request.
407
- changed_resources: nil
408
- )
409
- end
410
-
411
- sig do
412
- override.returns(
413
- {
414
- id: String,
415
- active_plan_phase_order: T.nilable(Integer),
416
- adjustment_intervals:
417
- T::Array[
418
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval
419
- ],
420
- auto_collection: T.nilable(T::Boolean),
421
- billing_cycle_anchor_configuration:
422
- Orb::Models::SubscriptionCancelResponse::BillingCycleAnchorConfiguration,
423
- billing_cycle_day: Integer,
424
- created_at: Time,
425
- current_billing_period_end_date: T.nilable(Time),
426
- current_billing_period_start_date: T.nilable(Time),
427
- customer: Orb::Customer,
428
- default_invoice_memo: T.nilable(String),
429
- discount_intervals:
430
- T::Array[
431
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Variants
432
- ],
433
- end_date: T.nilable(Time),
434
- fixed_fee_quantity_schedule:
435
- T::Array[
436
- Orb::Models::SubscriptionCancelResponse::FixedFeeQuantitySchedule
437
- ],
438
- invoicing_threshold: T.nilable(String),
439
- maximum_intervals:
440
- T::Array[
441
- Orb::Models::SubscriptionCancelResponse::MaximumInterval
442
- ],
443
- metadata: T::Hash[Symbol, String],
444
- minimum_intervals:
445
- T::Array[
446
- Orb::Models::SubscriptionCancelResponse::MinimumInterval
447
- ],
448
- name: String,
449
- net_terms: Integer,
450
- pending_subscription_change:
451
- T.nilable(
452
- Orb::Models::SubscriptionCancelResponse::PendingSubscriptionChange
453
- ),
454
- plan: T.nilable(Orb::Plan),
455
- price_intervals:
456
- T::Array[Orb::Models::SubscriptionCancelResponse::PriceInterval],
457
- redeemed_coupon:
458
- T.nilable(
459
- Orb::Models::SubscriptionCancelResponse::RedeemedCoupon
460
- ),
461
- start_date: Time,
462
- status:
463
- Orb::Models::SubscriptionCancelResponse::Status::TaggedSymbol,
464
- trial_info: Orb::Models::SubscriptionCancelResponse::TrialInfo,
465
- changed_resources:
466
- T.nilable(
467
- Orb::Models::SubscriptionCancelResponse::ChangedResources
468
- )
469
- }
470
- )
471
- end
472
- def to_hash
473
- end
474
-
475
- class AdjustmentInterval < Orb::Internal::Type::BaseModel
476
- OrHash =
477
- T.type_alias do
478
- T.any(
479
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval,
480
- Orb::Internal::AnyHash
481
- )
482
- end
483
-
484
- sig { returns(String) }
485
- attr_accessor :id
486
-
487
- sig do
488
- returns(
489
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Variants
490
- )
491
- end
492
- attr_accessor :adjustment
493
-
494
- # The price interval IDs that this adjustment applies to.
495
- sig { returns(T::Array[String]) }
496
- attr_accessor :applies_to_price_interval_ids
497
-
498
- # The end date of the adjustment interval.
499
- sig { returns(T.nilable(Time)) }
500
- attr_accessor :end_date
501
-
502
- # The start date of the adjustment interval.
503
- sig { returns(Time) }
504
- attr_accessor :start_date
505
-
506
- sig do
507
- params(
508
- id: String,
509
- adjustment:
510
- T.any(
511
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::OrHash,
512
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::OrHash,
513
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::OrHash,
514
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::OrHash,
515
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::OrHash
516
- ),
517
- applies_to_price_interval_ids: T::Array[String],
518
- end_date: T.nilable(Time),
519
- start_date: Time
520
- ).returns(T.attached_class)
521
- end
522
- def self.new(
523
- id:,
524
- adjustment:,
525
- # The price interval IDs that this adjustment applies to.
526
- applies_to_price_interval_ids:,
527
- # The end date of the adjustment interval.
528
- end_date:,
529
- # The start date of the adjustment interval.
530
- start_date:
531
- )
532
- end
533
-
534
- sig do
535
- override.returns(
536
- {
537
- id: String,
538
- adjustment:
539
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Variants,
540
- applies_to_price_interval_ids: T::Array[String],
541
- end_date: T.nilable(Time),
542
- start_date: Time
543
- }
544
- )
545
- end
546
- def to_hash
547
- end
548
-
549
- module Adjustment
550
- extend Orb::Internal::Type::Union
551
-
552
- Variants =
553
- T.type_alias do
554
- T.any(
555
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount,
556
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount,
557
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount,
558
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum,
559
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum
560
- )
561
- end
562
-
563
- class UsageDiscount < Orb::Internal::Type::BaseModel
564
- OrHash =
565
- T.type_alias do
566
- T.any(
567
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount,
568
- Orb::Internal::AnyHash
569
- )
570
- end
571
-
572
- sig { returns(String) }
573
- attr_accessor :id
574
-
575
- sig { returns(Symbol) }
576
- attr_accessor :adjustment_type
577
-
578
- # The price IDs that this adjustment applies to.
579
- sig { returns(T::Array[String]) }
580
- attr_accessor :applies_to_price_ids
581
-
582
- # The filters that determine which prices to apply this adjustment to.
583
- sig do
584
- returns(
585
- T::Array[
586
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter
587
- ]
588
- )
589
- end
590
- attr_accessor :filters
591
-
592
- # True for adjustments that apply to an entire invocice, false for adjustments
593
- # that apply to only one price.
594
- sig { returns(T::Boolean) }
595
- attr_accessor :is_invoice_level
596
-
597
- # The plan phase in which this adjustment is active.
598
- sig { returns(T.nilable(Integer)) }
599
- attr_accessor :plan_phase_order
600
-
601
- # The reason for the adjustment.
602
- sig { returns(T.nilable(String)) }
603
- attr_accessor :reason
604
-
605
- # The number of usage units by which to discount the price this adjustment applies
606
- # to in a given billing period.
607
- sig { returns(Float) }
608
- attr_accessor :usage_discount
609
-
610
- sig do
611
- params(
612
- id: String,
613
- applies_to_price_ids: T::Array[String],
614
- filters:
615
- T::Array[
616
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::OrHash
617
- ],
618
- is_invoice_level: T::Boolean,
619
- plan_phase_order: T.nilable(Integer),
620
- reason: T.nilable(String),
621
- usage_discount: Float,
622
- adjustment_type: Symbol
623
- ).returns(T.attached_class)
624
- end
625
- def self.new(
626
- id:,
627
- # The price IDs that this adjustment applies to.
628
- applies_to_price_ids:,
629
- # The filters that determine which prices to apply this adjustment to.
630
- filters:,
631
- # True for adjustments that apply to an entire invocice, false for adjustments
632
- # that apply to only one price.
633
- is_invoice_level:,
634
- # The plan phase in which this adjustment is active.
635
- plan_phase_order:,
636
- # The reason for the adjustment.
637
- reason:,
638
- # The number of usage units by which to discount the price this adjustment applies
639
- # to in a given billing period.
640
- usage_discount:,
641
- adjustment_type: :usage_discount
642
- )
643
- end
644
-
645
- sig do
646
- override.returns(
647
- {
648
- id: String,
649
- adjustment_type: Symbol,
650
- applies_to_price_ids: T::Array[String],
651
- filters:
652
- T::Array[
653
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter
654
- ],
655
- is_invoice_level: T::Boolean,
656
- plan_phase_order: T.nilable(Integer),
657
- reason: T.nilable(String),
658
- usage_discount: Float
659
- }
660
- )
661
- end
662
- def to_hash
663
- end
664
-
665
- class Filter < Orb::Internal::Type::BaseModel
666
- OrHash =
667
- T.type_alias do
668
- T.any(
669
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter,
670
- Orb::Internal::AnyHash
671
- )
672
- end
673
-
674
- # The property of the price to filter on.
675
- sig do
676
- returns(
677
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol
678
- )
679
- end
680
- attr_accessor :field
681
-
682
- # Should prices that match the filter be included or excluded.
683
- sig do
684
- returns(
685
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator::TaggedSymbol
686
- )
687
- end
688
- attr_accessor :operator
689
-
690
- # The IDs or values that match this filter.
691
- sig { returns(T::Array[String]) }
692
- attr_accessor :values
693
-
694
- sig do
695
- params(
696
- field:
697
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::OrSymbol,
698
- operator:
699
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator::OrSymbol,
700
- values: T::Array[String]
701
- ).returns(T.attached_class)
702
- end
703
- def self.new(
704
- # The property of the price to filter on.
705
- field:,
706
- # Should prices that match the filter be included or excluded.
707
- operator:,
708
- # The IDs or values that match this filter.
709
- values:
710
- )
711
- end
712
-
713
- sig do
714
- override.returns(
715
- {
716
- field:
717
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol,
718
- operator:
719
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator::TaggedSymbol,
720
- values: T::Array[String]
721
- }
722
- )
723
- end
724
- def to_hash
725
- end
726
-
727
- # The property of the price to filter on.
728
- module Field
729
- extend Orb::Internal::Type::Enum
730
-
731
- TaggedSymbol =
732
- T.type_alias do
733
- T.all(
734
- Symbol,
735
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field
736
- )
737
- end
738
- OrSymbol = T.type_alias { T.any(Symbol, String) }
739
-
740
- PRICE_ID =
741
- T.let(
742
- :price_id,
743
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol
744
- )
745
- ITEM_ID =
746
- T.let(
747
- :item_id,
748
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol
749
- )
750
- PRICE_TYPE =
751
- T.let(
752
- :price_type,
753
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol
754
- )
755
- CURRENCY =
756
- T.let(
757
- :currency,
758
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol
759
- )
760
- PRICING_UNIT_ID =
761
- T.let(
762
- :pricing_unit_id,
763
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol
764
- )
765
-
766
- sig do
767
- override.returns(
768
- T::Array[
769
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field::TaggedSymbol
770
- ]
771
- )
772
- end
773
- def self.values
774
- end
775
- end
776
-
777
- # Should prices that match the filter be included or excluded.
778
- module Operator
779
- extend Orb::Internal::Type::Enum
780
-
781
- TaggedSymbol =
782
- T.type_alias do
783
- T.all(
784
- Symbol,
785
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator
786
- )
787
- end
788
- OrSymbol = T.type_alias { T.any(Symbol, String) }
789
-
790
- INCLUDES =
791
- T.let(
792
- :includes,
793
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator::TaggedSymbol
794
- )
795
- EXCLUDES =
796
- T.let(
797
- :excludes,
798
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator::TaggedSymbol
799
- )
800
-
801
- sig do
802
- override.returns(
803
- T::Array[
804
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator::TaggedSymbol
805
- ]
806
- )
807
- end
808
- def self.values
809
- end
810
- end
811
- end
812
- end
813
-
814
- class AmountDiscount < Orb::Internal::Type::BaseModel
815
- OrHash =
816
- T.type_alias do
817
- T.any(
818
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount,
819
- Orb::Internal::AnyHash
820
- )
821
- end
822
-
823
- sig { returns(String) }
824
- attr_accessor :id
825
-
826
- sig { returns(Symbol) }
827
- attr_accessor :adjustment_type
828
-
829
- # The amount by which to discount the prices this adjustment applies to in a given
830
- # billing period.
831
- sig { returns(String) }
832
- attr_accessor :amount_discount
833
-
834
- # The price IDs that this adjustment applies to.
835
- sig { returns(T::Array[String]) }
836
- attr_accessor :applies_to_price_ids
837
-
838
- # The filters that determine which prices to apply this adjustment to.
839
- sig do
840
- returns(
841
- T::Array[
842
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter
843
- ]
844
- )
845
- end
846
- attr_accessor :filters
847
-
848
- # True for adjustments that apply to an entire invocice, false for adjustments
849
- # that apply to only one price.
850
- sig { returns(T::Boolean) }
851
- attr_accessor :is_invoice_level
852
-
853
- # The plan phase in which this adjustment is active.
854
- sig { returns(T.nilable(Integer)) }
855
- attr_accessor :plan_phase_order
856
-
857
- # The reason for the adjustment.
858
- sig { returns(T.nilable(String)) }
859
- attr_accessor :reason
860
-
861
- sig do
862
- params(
863
- id: String,
864
- amount_discount: String,
865
- applies_to_price_ids: T::Array[String],
866
- filters:
867
- T::Array[
868
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::OrHash
869
- ],
870
- is_invoice_level: T::Boolean,
871
- plan_phase_order: T.nilable(Integer),
872
- reason: T.nilable(String),
873
- adjustment_type: Symbol
874
- ).returns(T.attached_class)
875
- end
876
- def self.new(
877
- id:,
878
- # The amount by which to discount the prices this adjustment applies to in a given
879
- # billing period.
880
- amount_discount:,
881
- # The price IDs that this adjustment applies to.
882
- applies_to_price_ids:,
883
- # The filters that determine which prices to apply this adjustment to.
884
- filters:,
885
- # True for adjustments that apply to an entire invocice, false for adjustments
886
- # that apply to only one price.
887
- is_invoice_level:,
888
- # The plan phase in which this adjustment is active.
889
- plan_phase_order:,
890
- # The reason for the adjustment.
891
- reason:,
892
- adjustment_type: :amount_discount
893
- )
894
- end
895
-
896
- sig do
897
- override.returns(
898
- {
899
- id: String,
900
- adjustment_type: Symbol,
901
- amount_discount: String,
902
- applies_to_price_ids: T::Array[String],
903
- filters:
904
- T::Array[
905
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter
906
- ],
907
- is_invoice_level: T::Boolean,
908
- plan_phase_order: T.nilable(Integer),
909
- reason: T.nilable(String)
910
- }
911
- )
912
- end
913
- def to_hash
914
- end
915
-
916
- class Filter < Orb::Internal::Type::BaseModel
917
- OrHash =
918
- T.type_alias do
919
- T.any(
920
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter,
921
- Orb::Internal::AnyHash
922
- )
923
- end
924
-
925
- # The property of the price to filter on.
926
- sig do
927
- returns(
928
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol
929
- )
930
- end
931
- attr_accessor :field
932
-
933
- # Should prices that match the filter be included or excluded.
934
- sig do
935
- returns(
936
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator::TaggedSymbol
937
- )
938
- end
939
- attr_accessor :operator
940
-
941
- # The IDs or values that match this filter.
942
- sig { returns(T::Array[String]) }
943
- attr_accessor :values
944
-
945
- sig do
946
- params(
947
- field:
948
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::OrSymbol,
949
- operator:
950
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator::OrSymbol,
951
- values: T::Array[String]
952
- ).returns(T.attached_class)
953
- end
954
- def self.new(
955
- # The property of the price to filter on.
956
- field:,
957
- # Should prices that match the filter be included or excluded.
958
- operator:,
959
- # The IDs or values that match this filter.
960
- values:
961
- )
962
- end
963
-
964
- sig do
965
- override.returns(
966
- {
967
- field:
968
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol,
969
- operator:
970
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator::TaggedSymbol,
971
- values: T::Array[String]
972
- }
973
- )
974
- end
975
- def to_hash
976
- end
977
-
978
- # The property of the price to filter on.
979
- module Field
980
- extend Orb::Internal::Type::Enum
981
-
982
- TaggedSymbol =
983
- T.type_alias do
984
- T.all(
985
- Symbol,
986
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field
987
- )
988
- end
989
- OrSymbol = T.type_alias { T.any(Symbol, String) }
990
-
991
- PRICE_ID =
992
- T.let(
993
- :price_id,
994
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol
995
- )
996
- ITEM_ID =
997
- T.let(
998
- :item_id,
999
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol
1000
- )
1001
- PRICE_TYPE =
1002
- T.let(
1003
- :price_type,
1004
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol
1005
- )
1006
- CURRENCY =
1007
- T.let(
1008
- :currency,
1009
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol
1010
- )
1011
- PRICING_UNIT_ID =
1012
- T.let(
1013
- :pricing_unit_id,
1014
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol
1015
- )
1016
-
1017
- sig do
1018
- override.returns(
1019
- T::Array[
1020
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field::TaggedSymbol
1021
- ]
1022
- )
1023
- end
1024
- def self.values
1025
- end
1026
- end
1027
-
1028
- # Should prices that match the filter be included or excluded.
1029
- module Operator
1030
- extend Orb::Internal::Type::Enum
1031
-
1032
- TaggedSymbol =
1033
- T.type_alias do
1034
- T.all(
1035
- Symbol,
1036
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator
1037
- )
1038
- end
1039
- OrSymbol = T.type_alias { T.any(Symbol, String) }
1040
-
1041
- INCLUDES =
1042
- T.let(
1043
- :includes,
1044
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator::TaggedSymbol
1045
- )
1046
- EXCLUDES =
1047
- T.let(
1048
- :excludes,
1049
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator::TaggedSymbol
1050
- )
1051
-
1052
- sig do
1053
- override.returns(
1054
- T::Array[
1055
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator::TaggedSymbol
1056
- ]
1057
- )
1058
- end
1059
- def self.values
1060
- end
1061
- end
1062
- end
1063
- end
1064
-
1065
- class PercentageDiscount < Orb::Internal::Type::BaseModel
1066
- OrHash =
1067
- T.type_alias do
1068
- T.any(
1069
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount,
1070
- Orb::Internal::AnyHash
1071
- )
1072
- end
1073
-
1074
- sig { returns(String) }
1075
- attr_accessor :id
1076
-
1077
- sig { returns(Symbol) }
1078
- attr_accessor :adjustment_type
1079
-
1080
- # The price IDs that this adjustment applies to.
1081
- sig { returns(T::Array[String]) }
1082
- attr_accessor :applies_to_price_ids
1083
-
1084
- # The filters that determine which prices to apply this adjustment to.
1085
- sig do
1086
- returns(
1087
- T::Array[
1088
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter
1089
- ]
1090
- )
1091
- end
1092
- attr_accessor :filters
1093
-
1094
- # True for adjustments that apply to an entire invocice, false for adjustments
1095
- # that apply to only one price.
1096
- sig { returns(T::Boolean) }
1097
- attr_accessor :is_invoice_level
1098
-
1099
- # The percentage (as a value between 0 and 1) by which to discount the price
1100
- # intervals this adjustment applies to in a given billing period.
1101
- sig { returns(Float) }
1102
- attr_accessor :percentage_discount
1103
-
1104
- # The plan phase in which this adjustment is active.
1105
- sig { returns(T.nilable(Integer)) }
1106
- attr_accessor :plan_phase_order
1107
-
1108
- # The reason for the adjustment.
1109
- sig { returns(T.nilable(String)) }
1110
- attr_accessor :reason
1111
-
1112
- sig do
1113
- params(
1114
- id: String,
1115
- applies_to_price_ids: T::Array[String],
1116
- filters:
1117
- T::Array[
1118
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::OrHash
1119
- ],
1120
- is_invoice_level: T::Boolean,
1121
- percentage_discount: Float,
1122
- plan_phase_order: T.nilable(Integer),
1123
- reason: T.nilable(String),
1124
- adjustment_type: Symbol
1125
- ).returns(T.attached_class)
1126
- end
1127
- def self.new(
1128
- id:,
1129
- # The price IDs that this adjustment applies to.
1130
- applies_to_price_ids:,
1131
- # The filters that determine which prices to apply this adjustment to.
1132
- filters:,
1133
- # True for adjustments that apply to an entire invocice, false for adjustments
1134
- # that apply to only one price.
1135
- is_invoice_level:,
1136
- # The percentage (as a value between 0 and 1) by which to discount the price
1137
- # intervals this adjustment applies to in a given billing period.
1138
- percentage_discount:,
1139
- # The plan phase in which this adjustment is active.
1140
- plan_phase_order:,
1141
- # The reason for the adjustment.
1142
- reason:,
1143
- adjustment_type: :percentage_discount
1144
- )
1145
- end
1146
-
1147
- sig do
1148
- override.returns(
1149
- {
1150
- id: String,
1151
- adjustment_type: Symbol,
1152
- applies_to_price_ids: T::Array[String],
1153
- filters:
1154
- T::Array[
1155
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter
1156
- ],
1157
- is_invoice_level: T::Boolean,
1158
- percentage_discount: Float,
1159
- plan_phase_order: T.nilable(Integer),
1160
- reason: T.nilable(String)
1161
- }
1162
- )
1163
- end
1164
- def to_hash
1165
- end
1166
-
1167
- class Filter < Orb::Internal::Type::BaseModel
1168
- OrHash =
1169
- T.type_alias do
1170
- T.any(
1171
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter,
1172
- Orb::Internal::AnyHash
1173
- )
1174
- end
1175
-
1176
- # The property of the price to filter on.
1177
- sig do
1178
- returns(
1179
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol
1180
- )
1181
- end
1182
- attr_accessor :field
1183
-
1184
- # Should prices that match the filter be included or excluded.
1185
- sig do
1186
- returns(
1187
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator::TaggedSymbol
1188
- )
1189
- end
1190
- attr_accessor :operator
1191
-
1192
- # The IDs or values that match this filter.
1193
- sig { returns(T::Array[String]) }
1194
- attr_accessor :values
1195
-
1196
- sig do
1197
- params(
1198
- field:
1199
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::OrSymbol,
1200
- operator:
1201
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator::OrSymbol,
1202
- values: T::Array[String]
1203
- ).returns(T.attached_class)
1204
- end
1205
- def self.new(
1206
- # The property of the price to filter on.
1207
- field:,
1208
- # Should prices that match the filter be included or excluded.
1209
- operator:,
1210
- # The IDs or values that match this filter.
1211
- values:
1212
- )
1213
- end
1214
-
1215
- sig do
1216
- override.returns(
1217
- {
1218
- field:
1219
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol,
1220
- operator:
1221
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator::TaggedSymbol,
1222
- values: T::Array[String]
1223
- }
1224
- )
1225
- end
1226
- def to_hash
1227
- end
1228
-
1229
- # The property of the price to filter on.
1230
- module Field
1231
- extend Orb::Internal::Type::Enum
1232
-
1233
- TaggedSymbol =
1234
- T.type_alias do
1235
- T.all(
1236
- Symbol,
1237
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field
1238
- )
1239
- end
1240
- OrSymbol = T.type_alias { T.any(Symbol, String) }
1241
-
1242
- PRICE_ID =
1243
- T.let(
1244
- :price_id,
1245
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol
1246
- )
1247
- ITEM_ID =
1248
- T.let(
1249
- :item_id,
1250
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol
1251
- )
1252
- PRICE_TYPE =
1253
- T.let(
1254
- :price_type,
1255
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol
1256
- )
1257
- CURRENCY =
1258
- T.let(
1259
- :currency,
1260
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol
1261
- )
1262
- PRICING_UNIT_ID =
1263
- T.let(
1264
- :pricing_unit_id,
1265
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol
1266
- )
1267
-
1268
- sig do
1269
- override.returns(
1270
- T::Array[
1271
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field::TaggedSymbol
1272
- ]
1273
- )
1274
- end
1275
- def self.values
1276
- end
1277
- end
1278
-
1279
- # Should prices that match the filter be included or excluded.
1280
- module Operator
1281
- extend Orb::Internal::Type::Enum
1282
-
1283
- TaggedSymbol =
1284
- T.type_alias do
1285
- T.all(
1286
- Symbol,
1287
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator
1288
- )
1289
- end
1290
- OrSymbol = T.type_alias { T.any(Symbol, String) }
1291
-
1292
- INCLUDES =
1293
- T.let(
1294
- :includes,
1295
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator::TaggedSymbol
1296
- )
1297
- EXCLUDES =
1298
- T.let(
1299
- :excludes,
1300
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator::TaggedSymbol
1301
- )
1302
-
1303
- sig do
1304
- override.returns(
1305
- T::Array[
1306
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator::TaggedSymbol
1307
- ]
1308
- )
1309
- end
1310
- def self.values
1311
- end
1312
- end
1313
- end
1314
- end
1315
-
1316
- class Minimum < Orb::Internal::Type::BaseModel
1317
- OrHash =
1318
- T.type_alias do
1319
- T.any(
1320
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum,
1321
- Orb::Internal::AnyHash
1322
- )
1323
- end
1324
-
1325
- sig { returns(String) }
1326
- attr_accessor :id
1327
-
1328
- sig { returns(Symbol) }
1329
- attr_accessor :adjustment_type
1330
-
1331
- # The price IDs that this adjustment applies to.
1332
- sig { returns(T::Array[String]) }
1333
- attr_accessor :applies_to_price_ids
1334
-
1335
- # The filters that determine which prices to apply this adjustment to.
1336
- sig do
1337
- returns(
1338
- T::Array[
1339
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter
1340
- ]
1341
- )
1342
- end
1343
- attr_accessor :filters
1344
-
1345
- # True for adjustments that apply to an entire invocice, false for adjustments
1346
- # that apply to only one price.
1347
- sig { returns(T::Boolean) }
1348
- attr_accessor :is_invoice_level
1349
-
1350
- # The item ID that revenue from this minimum will be attributed to.
1351
- sig { returns(String) }
1352
- attr_accessor :item_id
1353
-
1354
- # The minimum amount to charge in a given billing period for the prices this
1355
- # adjustment applies to.
1356
- sig { returns(String) }
1357
- attr_accessor :minimum_amount
1358
-
1359
- # The plan phase in which this adjustment is active.
1360
- sig { returns(T.nilable(Integer)) }
1361
- attr_accessor :plan_phase_order
1362
-
1363
- # The reason for the adjustment.
1364
- sig { returns(T.nilable(String)) }
1365
- attr_accessor :reason
1366
-
1367
- sig do
1368
- params(
1369
- id: String,
1370
- applies_to_price_ids: T::Array[String],
1371
- filters:
1372
- T::Array[
1373
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::OrHash
1374
- ],
1375
- is_invoice_level: T::Boolean,
1376
- item_id: String,
1377
- minimum_amount: String,
1378
- plan_phase_order: T.nilable(Integer),
1379
- reason: T.nilable(String),
1380
- adjustment_type: Symbol
1381
- ).returns(T.attached_class)
1382
- end
1383
- def self.new(
1384
- id:,
1385
- # The price IDs that this adjustment applies to.
1386
- applies_to_price_ids:,
1387
- # The filters that determine which prices to apply this adjustment to.
1388
- filters:,
1389
- # True for adjustments that apply to an entire invocice, false for adjustments
1390
- # that apply to only one price.
1391
- is_invoice_level:,
1392
- # The item ID that revenue from this minimum will be attributed to.
1393
- item_id:,
1394
- # The minimum amount to charge in a given billing period for the prices this
1395
- # adjustment applies to.
1396
- minimum_amount:,
1397
- # The plan phase in which this adjustment is active.
1398
- plan_phase_order:,
1399
- # The reason for the adjustment.
1400
- reason:,
1401
- adjustment_type: :minimum
1402
- )
1403
- end
1404
-
1405
- sig do
1406
- override.returns(
1407
- {
1408
- id: String,
1409
- adjustment_type: Symbol,
1410
- applies_to_price_ids: T::Array[String],
1411
- filters:
1412
- T::Array[
1413
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter
1414
- ],
1415
- is_invoice_level: T::Boolean,
1416
- item_id: String,
1417
- minimum_amount: String,
1418
- plan_phase_order: T.nilable(Integer),
1419
- reason: T.nilable(String)
1420
- }
1421
- )
1422
- end
1423
- def to_hash
1424
- end
1425
-
1426
- class Filter < Orb::Internal::Type::BaseModel
1427
- OrHash =
1428
- T.type_alias do
1429
- T.any(
1430
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter,
1431
- Orb::Internal::AnyHash
1432
- )
1433
- end
1434
-
1435
- # The property of the price to filter on.
1436
- sig do
1437
- returns(
1438
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol
1439
- )
1440
- end
1441
- attr_accessor :field
1442
-
1443
- # Should prices that match the filter be included or excluded.
1444
- sig do
1445
- returns(
1446
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator::TaggedSymbol
1447
- )
1448
- end
1449
- attr_accessor :operator
1450
-
1451
- # The IDs or values that match this filter.
1452
- sig { returns(T::Array[String]) }
1453
- attr_accessor :values
1454
-
1455
- sig do
1456
- params(
1457
- field:
1458
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::OrSymbol,
1459
- operator:
1460
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator::OrSymbol,
1461
- values: T::Array[String]
1462
- ).returns(T.attached_class)
1463
- end
1464
- def self.new(
1465
- # The property of the price to filter on.
1466
- field:,
1467
- # Should prices that match the filter be included or excluded.
1468
- operator:,
1469
- # The IDs or values that match this filter.
1470
- values:
1471
- )
1472
- end
1473
-
1474
- sig do
1475
- override.returns(
1476
- {
1477
- field:
1478
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol,
1479
- operator:
1480
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator::TaggedSymbol,
1481
- values: T::Array[String]
1482
- }
1483
- )
1484
- end
1485
- def to_hash
1486
- end
1487
-
1488
- # The property of the price to filter on.
1489
- module Field
1490
- extend Orb::Internal::Type::Enum
1491
-
1492
- TaggedSymbol =
1493
- T.type_alias do
1494
- T.all(
1495
- Symbol,
1496
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field
1497
- )
1498
- end
1499
- OrSymbol = T.type_alias { T.any(Symbol, String) }
1500
-
1501
- PRICE_ID =
1502
- T.let(
1503
- :price_id,
1504
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol
1505
- )
1506
- ITEM_ID =
1507
- T.let(
1508
- :item_id,
1509
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol
1510
- )
1511
- PRICE_TYPE =
1512
- T.let(
1513
- :price_type,
1514
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol
1515
- )
1516
- CURRENCY =
1517
- T.let(
1518
- :currency,
1519
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol
1520
- )
1521
- PRICING_UNIT_ID =
1522
- T.let(
1523
- :pricing_unit_id,
1524
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol
1525
- )
1526
-
1527
- sig do
1528
- override.returns(
1529
- T::Array[
1530
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field::TaggedSymbol
1531
- ]
1532
- )
1533
- end
1534
- def self.values
1535
- end
1536
- end
1537
-
1538
- # Should prices that match the filter be included or excluded.
1539
- module Operator
1540
- extend Orb::Internal::Type::Enum
1541
-
1542
- TaggedSymbol =
1543
- T.type_alias do
1544
- T.all(
1545
- Symbol,
1546
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator
1547
- )
1548
- end
1549
- OrSymbol = T.type_alias { T.any(Symbol, String) }
1550
-
1551
- INCLUDES =
1552
- T.let(
1553
- :includes,
1554
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator::TaggedSymbol
1555
- )
1556
- EXCLUDES =
1557
- T.let(
1558
- :excludes,
1559
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator::TaggedSymbol
1560
- )
1561
-
1562
- sig do
1563
- override.returns(
1564
- T::Array[
1565
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator::TaggedSymbol
1566
- ]
1567
- )
1568
- end
1569
- def self.values
1570
- end
1571
- end
1572
- end
1573
- end
1574
-
1575
- class Maximum < Orb::Internal::Type::BaseModel
1576
- OrHash =
1577
- T.type_alias do
1578
- T.any(
1579
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum,
1580
- Orb::Internal::AnyHash
1581
- )
1582
- end
1583
-
1584
- sig { returns(String) }
1585
- attr_accessor :id
1586
-
1587
- sig { returns(Symbol) }
1588
- attr_accessor :adjustment_type
1589
-
1590
- # The price IDs that this adjustment applies to.
1591
- sig { returns(T::Array[String]) }
1592
- attr_accessor :applies_to_price_ids
1593
-
1594
- # The filters that determine which prices to apply this adjustment to.
1595
- sig do
1596
- returns(
1597
- T::Array[
1598
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter
1599
- ]
1600
- )
1601
- end
1602
- attr_accessor :filters
1603
-
1604
- # True for adjustments that apply to an entire invocice, false for adjustments
1605
- # that apply to only one price.
1606
- sig { returns(T::Boolean) }
1607
- attr_accessor :is_invoice_level
1608
-
1609
- # The maximum amount to charge in a given billing period for the prices this
1610
- # adjustment applies to.
1611
- sig { returns(String) }
1612
- attr_accessor :maximum_amount
1613
-
1614
- # The plan phase in which this adjustment is active.
1615
- sig { returns(T.nilable(Integer)) }
1616
- attr_accessor :plan_phase_order
1617
-
1618
- # The reason for the adjustment.
1619
- sig { returns(T.nilable(String)) }
1620
- attr_accessor :reason
1621
-
1622
- sig do
1623
- params(
1624
- id: String,
1625
- applies_to_price_ids: T::Array[String],
1626
- filters:
1627
- T::Array[
1628
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::OrHash
1629
- ],
1630
- is_invoice_level: T::Boolean,
1631
- maximum_amount: String,
1632
- plan_phase_order: T.nilable(Integer),
1633
- reason: T.nilable(String),
1634
- adjustment_type: Symbol
1635
- ).returns(T.attached_class)
1636
- end
1637
- def self.new(
1638
- id:,
1639
- # The price IDs that this adjustment applies to.
1640
- applies_to_price_ids:,
1641
- # The filters that determine which prices to apply this adjustment to.
1642
- filters:,
1643
- # True for adjustments that apply to an entire invocice, false for adjustments
1644
- # that apply to only one price.
1645
- is_invoice_level:,
1646
- # The maximum amount to charge in a given billing period for the prices this
1647
- # adjustment applies to.
1648
- maximum_amount:,
1649
- # The plan phase in which this adjustment is active.
1650
- plan_phase_order:,
1651
- # The reason for the adjustment.
1652
- reason:,
1653
- adjustment_type: :maximum
1654
- )
1655
- end
1656
-
1657
- sig do
1658
- override.returns(
1659
- {
1660
- id: String,
1661
- adjustment_type: Symbol,
1662
- applies_to_price_ids: T::Array[String],
1663
- filters:
1664
- T::Array[
1665
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter
1666
- ],
1667
- is_invoice_level: T::Boolean,
1668
- maximum_amount: String,
1669
- plan_phase_order: T.nilable(Integer),
1670
- reason: T.nilable(String)
1671
- }
1672
- )
1673
- end
1674
- def to_hash
1675
- end
1676
-
1677
- class Filter < Orb::Internal::Type::BaseModel
1678
- OrHash =
1679
- T.type_alias do
1680
- T.any(
1681
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter,
1682
- Orb::Internal::AnyHash
1683
- )
1684
- end
1685
-
1686
- # The property of the price to filter on.
1687
- sig do
1688
- returns(
1689
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol
1690
- )
1691
- end
1692
- attr_accessor :field
1693
-
1694
- # Should prices that match the filter be included or excluded.
1695
- sig do
1696
- returns(
1697
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator::TaggedSymbol
1698
- )
1699
- end
1700
- attr_accessor :operator
1701
-
1702
- # The IDs or values that match this filter.
1703
- sig { returns(T::Array[String]) }
1704
- attr_accessor :values
1705
-
1706
- sig do
1707
- params(
1708
- field:
1709
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::OrSymbol,
1710
- operator:
1711
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator::OrSymbol,
1712
- values: T::Array[String]
1713
- ).returns(T.attached_class)
1714
- end
1715
- def self.new(
1716
- # The property of the price to filter on.
1717
- field:,
1718
- # Should prices that match the filter be included or excluded.
1719
- operator:,
1720
- # The IDs or values that match this filter.
1721
- values:
1722
- )
1723
- end
1724
-
1725
- sig do
1726
- override.returns(
1727
- {
1728
- field:
1729
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol,
1730
- operator:
1731
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator::TaggedSymbol,
1732
- values: T::Array[String]
1733
- }
1734
- )
1735
- end
1736
- def to_hash
1737
- end
1738
-
1739
- # The property of the price to filter on.
1740
- module Field
1741
- extend Orb::Internal::Type::Enum
1742
-
1743
- TaggedSymbol =
1744
- T.type_alias do
1745
- T.all(
1746
- Symbol,
1747
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field
1748
- )
1749
- end
1750
- OrSymbol = T.type_alias { T.any(Symbol, String) }
1751
-
1752
- PRICE_ID =
1753
- T.let(
1754
- :price_id,
1755
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol
1756
- )
1757
- ITEM_ID =
1758
- T.let(
1759
- :item_id,
1760
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol
1761
- )
1762
- PRICE_TYPE =
1763
- T.let(
1764
- :price_type,
1765
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol
1766
- )
1767
- CURRENCY =
1768
- T.let(
1769
- :currency,
1770
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol
1771
- )
1772
- PRICING_UNIT_ID =
1773
- T.let(
1774
- :pricing_unit_id,
1775
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol
1776
- )
1777
-
1778
- sig do
1779
- override.returns(
1780
- T::Array[
1781
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field::TaggedSymbol
1782
- ]
1783
- )
1784
- end
1785
- def self.values
1786
- end
1787
- end
1788
-
1789
- # Should prices that match the filter be included or excluded.
1790
- module Operator
1791
- extend Orb::Internal::Type::Enum
1792
-
1793
- TaggedSymbol =
1794
- T.type_alias do
1795
- T.all(
1796
- Symbol,
1797
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator
1798
- )
1799
- end
1800
- OrSymbol = T.type_alias { T.any(Symbol, String) }
1801
-
1802
- INCLUDES =
1803
- T.let(
1804
- :includes,
1805
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator::TaggedSymbol
1806
- )
1807
- EXCLUDES =
1808
- T.let(
1809
- :excludes,
1810
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator::TaggedSymbol
1811
- )
1812
-
1813
- sig do
1814
- override.returns(
1815
- T::Array[
1816
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator::TaggedSymbol
1817
- ]
1818
- )
1819
- end
1820
- def self.values
1821
- end
1822
- end
1823
- end
1824
- end
1825
-
1826
- sig do
1827
- override.returns(
1828
- T::Array[
1829
- Orb::Models::SubscriptionCancelResponse::AdjustmentInterval::Adjustment::Variants
1830
- ]
1831
- )
1832
- end
1833
- def self.variants
1834
- end
1835
- end
1836
- end
1837
-
1838
- class BillingCycleAnchorConfiguration < Orb::Internal::Type::BaseModel
1839
- OrHash =
1840
- T.type_alias do
1841
- T.any(
1842
- Orb::Models::SubscriptionCancelResponse::BillingCycleAnchorConfiguration,
1843
- Orb::Internal::AnyHash
1844
- )
1845
- end
1846
-
1847
- # The day of the month on which the billing cycle is anchored. If the maximum
1848
- # number of days in a month is greater than this value, the last day of the month
1849
- # is the billing cycle day (e.g. billing_cycle_day=31 for April means the billing
1850
- # period begins on the 30th.
1851
- sig { returns(Integer) }
1852
- attr_accessor :day
1853
-
1854
- # The month on which the billing cycle is anchored (e.g. a quarterly price
1855
- # anchored in February would have cycles starting February, May, August, and
1856
- # November).
1857
- sig { returns(T.nilable(Integer)) }
1858
- attr_accessor :month
1859
-
1860
- # The year on which the billing cycle is anchored (e.g. a 2 year billing cycle
1861
- # anchored on 2021 would have cycles starting on 2021, 2023, 2025, etc.).
1862
- sig { returns(T.nilable(Integer)) }
1863
- attr_accessor :year
1864
-
1865
- sig do
1866
- params(
1867
- day: Integer,
1868
- month: T.nilable(Integer),
1869
- year: T.nilable(Integer)
1870
- ).returns(T.attached_class)
1871
- end
1872
- def self.new(
1873
- # The day of the month on which the billing cycle is anchored. If the maximum
1874
- # number of days in a month is greater than this value, the last day of the month
1875
- # is the billing cycle day (e.g. billing_cycle_day=31 for April means the billing
1876
- # period begins on the 30th.
1877
- day:,
1878
- # The month on which the billing cycle is anchored (e.g. a quarterly price
1879
- # anchored in February would have cycles starting February, May, August, and
1880
- # November).
1881
- month: nil,
1882
- # The year on which the billing cycle is anchored (e.g. a 2 year billing cycle
1883
- # anchored on 2021 would have cycles starting on 2021, 2023, 2025, etc.).
1884
- year: nil
1885
- )
1886
- end
1887
-
1888
- sig do
1889
- override.returns(
1890
- {
1891
- day: Integer,
1892
- month: T.nilable(Integer),
1893
- year: T.nilable(Integer)
1894
- }
1895
- )
1896
- end
1897
- def to_hash
1898
- end
1899
- end
1900
-
1901
- module DiscountInterval
1902
- extend Orb::Internal::Type::Union
1903
-
1904
- Variants =
1905
- T.type_alias do
1906
- T.any(
1907
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount,
1908
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage,
1909
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage
1910
- )
1911
- end
1912
-
1913
- class Amount < Orb::Internal::Type::BaseModel
1914
- OrHash =
1915
- T.type_alias do
1916
- T.any(
1917
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount,
1918
- Orb::Internal::AnyHash
1919
- )
1920
- end
1921
-
1922
- # Only available if discount_type is `amount`.
1923
- sig { returns(String) }
1924
- attr_accessor :amount_discount
1925
-
1926
- # The price interval ids that this discount interval applies to.
1927
- sig { returns(T::Array[String]) }
1928
- attr_accessor :applies_to_price_interval_ids
1929
-
1930
- sig { returns(Symbol) }
1931
- attr_accessor :discount_type
1932
-
1933
- # The end date of the discount interval.
1934
- sig { returns(T.nilable(Time)) }
1935
- attr_accessor :end_date
1936
-
1937
- # The filters that determine which prices this discount interval applies to.
1938
- sig do
1939
- returns(
1940
- T::Array[
1941
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter
1942
- ]
1943
- )
1944
- end
1945
- attr_accessor :filters
1946
-
1947
- # The start date of the discount interval.
1948
- sig { returns(Time) }
1949
- attr_accessor :start_date
1950
-
1951
- sig do
1952
- params(
1953
- amount_discount: String,
1954
- applies_to_price_interval_ids: T::Array[String],
1955
- end_date: T.nilable(Time),
1956
- filters:
1957
- T::Array[
1958
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::OrHash
1959
- ],
1960
- start_date: Time,
1961
- discount_type: Symbol
1962
- ).returns(T.attached_class)
1963
- end
1964
- def self.new(
1965
- # Only available if discount_type is `amount`.
1966
- amount_discount:,
1967
- # The price interval ids that this discount interval applies to.
1968
- applies_to_price_interval_ids:,
1969
- # The end date of the discount interval.
1970
- end_date:,
1971
- # The filters that determine which prices this discount interval applies to.
1972
- filters:,
1973
- # The start date of the discount interval.
1974
- start_date:,
1975
- discount_type: :amount
1976
- )
1977
- end
1978
-
1979
- sig do
1980
- override.returns(
1981
- {
1982
- amount_discount: String,
1983
- applies_to_price_interval_ids: T::Array[String],
1984
- discount_type: Symbol,
1985
- end_date: T.nilable(Time),
1986
- filters:
1987
- T::Array[
1988
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter
1989
- ],
1990
- start_date: Time
1991
- }
1992
- )
1993
- end
1994
- def to_hash
1995
- end
1996
-
1997
- class Filter < Orb::Internal::Type::BaseModel
1998
- OrHash =
1999
- T.type_alias do
2000
- T.any(
2001
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter,
2002
- Orb::Internal::AnyHash
2003
- )
2004
- end
2005
-
2006
- # The property of the price to filter on.
2007
- sig do
2008
- returns(
2009
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol
2010
- )
2011
- end
2012
- attr_accessor :field
2013
-
2014
- # Should prices that match the filter be included or excluded.
2015
- sig do
2016
- returns(
2017
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Operator::TaggedSymbol
2018
- )
2019
- end
2020
- attr_accessor :operator
2021
-
2022
- # The IDs or values that match this filter.
2023
- sig { returns(T::Array[String]) }
2024
- attr_accessor :values
2025
-
2026
- sig do
2027
- params(
2028
- field:
2029
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::OrSymbol,
2030
- operator:
2031
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Operator::OrSymbol,
2032
- values: T::Array[String]
2033
- ).returns(T.attached_class)
2034
- end
2035
- def self.new(
2036
- # The property of the price to filter on.
2037
- field:,
2038
- # Should prices that match the filter be included or excluded.
2039
- operator:,
2040
- # The IDs or values that match this filter.
2041
- values:
2042
- )
2043
- end
2044
-
2045
- sig do
2046
- override.returns(
2047
- {
2048
- field:
2049
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol,
2050
- operator:
2051
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Operator::TaggedSymbol,
2052
- values: T::Array[String]
2053
- }
2054
- )
2055
- end
2056
- def to_hash
2057
- end
2058
-
2059
- # The property of the price to filter on.
2060
- module Field
2061
- extend Orb::Internal::Type::Enum
2062
-
2063
- TaggedSymbol =
2064
- T.type_alias do
2065
- T.all(
2066
- Symbol,
2067
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field
2068
- )
2069
- end
2070
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2071
-
2072
- PRICE_ID =
2073
- T.let(
2074
- :price_id,
2075
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol
2076
- )
2077
- ITEM_ID =
2078
- T.let(
2079
- :item_id,
2080
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol
2081
- )
2082
- PRICE_TYPE =
2083
- T.let(
2084
- :price_type,
2085
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol
2086
- )
2087
- CURRENCY =
2088
- T.let(
2089
- :currency,
2090
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol
2091
- )
2092
- PRICING_UNIT_ID =
2093
- T.let(
2094
- :pricing_unit_id,
2095
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol
2096
- )
2097
-
2098
- sig do
2099
- override.returns(
2100
- T::Array[
2101
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Field::TaggedSymbol
2102
- ]
2103
- )
2104
- end
2105
- def self.values
2106
- end
2107
- end
2108
-
2109
- # Should prices that match the filter be included or excluded.
2110
- module Operator
2111
- extend Orb::Internal::Type::Enum
2112
-
2113
- TaggedSymbol =
2114
- T.type_alias do
2115
- T.all(
2116
- Symbol,
2117
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Operator
2118
- )
2119
- end
2120
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2121
-
2122
- INCLUDES =
2123
- T.let(
2124
- :includes,
2125
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Operator::TaggedSymbol
2126
- )
2127
- EXCLUDES =
2128
- T.let(
2129
- :excludes,
2130
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Operator::TaggedSymbol
2131
- )
2132
-
2133
- sig do
2134
- override.returns(
2135
- T::Array[
2136
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Amount::Filter::Operator::TaggedSymbol
2137
- ]
2138
- )
2139
- end
2140
- def self.values
2141
- end
2142
- end
2143
- end
2144
- end
2145
-
2146
- class Percentage < Orb::Internal::Type::BaseModel
2147
- OrHash =
2148
- T.type_alias do
2149
- T.any(
2150
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage,
2151
- Orb::Internal::AnyHash
2152
- )
2153
- end
2154
-
2155
- # The price interval ids that this discount interval applies to.
2156
- sig { returns(T::Array[String]) }
2157
- attr_accessor :applies_to_price_interval_ids
2158
-
2159
- sig { returns(Symbol) }
2160
- attr_accessor :discount_type
2161
-
2162
- # The end date of the discount interval.
2163
- sig { returns(T.nilable(Time)) }
2164
- attr_accessor :end_date
2165
-
2166
- # The filters that determine which prices this discount interval applies to.
2167
- sig do
2168
- returns(
2169
- T::Array[
2170
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter
2171
- ]
2172
- )
2173
- end
2174
- attr_accessor :filters
2175
-
2176
- # Only available if discount_type is `percentage`.This is a number between 0
2177
- # and 1.
2178
- sig { returns(Float) }
2179
- attr_accessor :percentage_discount
2180
-
2181
- # The start date of the discount interval.
2182
- sig { returns(Time) }
2183
- attr_accessor :start_date
2184
-
2185
- sig do
2186
- params(
2187
- applies_to_price_interval_ids: T::Array[String],
2188
- end_date: T.nilable(Time),
2189
- filters:
2190
- T::Array[
2191
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::OrHash
2192
- ],
2193
- percentage_discount: Float,
2194
- start_date: Time,
2195
- discount_type: Symbol
2196
- ).returns(T.attached_class)
2197
- end
2198
- def self.new(
2199
- # The price interval ids that this discount interval applies to.
2200
- applies_to_price_interval_ids:,
2201
- # The end date of the discount interval.
2202
- end_date:,
2203
- # The filters that determine which prices this discount interval applies to.
2204
- filters:,
2205
- # Only available if discount_type is `percentage`.This is a number between 0
2206
- # and 1.
2207
- percentage_discount:,
2208
- # The start date of the discount interval.
2209
- start_date:,
2210
- discount_type: :percentage
2211
- )
2212
- end
2213
-
2214
- sig do
2215
- override.returns(
2216
- {
2217
- applies_to_price_interval_ids: T::Array[String],
2218
- discount_type: Symbol,
2219
- end_date: T.nilable(Time),
2220
- filters:
2221
- T::Array[
2222
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter
2223
- ],
2224
- percentage_discount: Float,
2225
- start_date: Time
2226
- }
2227
- )
2228
- end
2229
- def to_hash
2230
- end
2231
-
2232
- class Filter < Orb::Internal::Type::BaseModel
2233
- OrHash =
2234
- T.type_alias do
2235
- T.any(
2236
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter,
2237
- Orb::Internal::AnyHash
2238
- )
2239
- end
2240
-
2241
- # The property of the price to filter on.
2242
- sig do
2243
- returns(
2244
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol
2245
- )
2246
- end
2247
- attr_accessor :field
2248
-
2249
- # Should prices that match the filter be included or excluded.
2250
- sig do
2251
- returns(
2252
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Operator::TaggedSymbol
2253
- )
2254
- end
2255
- attr_accessor :operator
2256
-
2257
- # The IDs or values that match this filter.
2258
- sig { returns(T::Array[String]) }
2259
- attr_accessor :values
2260
-
2261
- sig do
2262
- params(
2263
- field:
2264
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::OrSymbol,
2265
- operator:
2266
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Operator::OrSymbol,
2267
- values: T::Array[String]
2268
- ).returns(T.attached_class)
2269
- end
2270
- def self.new(
2271
- # The property of the price to filter on.
2272
- field:,
2273
- # Should prices that match the filter be included or excluded.
2274
- operator:,
2275
- # The IDs or values that match this filter.
2276
- values:
2277
- )
2278
- end
2279
-
2280
- sig do
2281
- override.returns(
2282
- {
2283
- field:
2284
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol,
2285
- operator:
2286
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Operator::TaggedSymbol,
2287
- values: T::Array[String]
2288
- }
2289
- )
2290
- end
2291
- def to_hash
2292
- end
2293
-
2294
- # The property of the price to filter on.
2295
- module Field
2296
- extend Orb::Internal::Type::Enum
2297
-
2298
- TaggedSymbol =
2299
- T.type_alias do
2300
- T.all(
2301
- Symbol,
2302
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field
2303
- )
2304
- end
2305
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2306
-
2307
- PRICE_ID =
2308
- T.let(
2309
- :price_id,
2310
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol
2311
- )
2312
- ITEM_ID =
2313
- T.let(
2314
- :item_id,
2315
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol
2316
- )
2317
- PRICE_TYPE =
2318
- T.let(
2319
- :price_type,
2320
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol
2321
- )
2322
- CURRENCY =
2323
- T.let(
2324
- :currency,
2325
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol
2326
- )
2327
- PRICING_UNIT_ID =
2328
- T.let(
2329
- :pricing_unit_id,
2330
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol
2331
- )
2332
-
2333
- sig do
2334
- override.returns(
2335
- T::Array[
2336
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Field::TaggedSymbol
2337
- ]
2338
- )
2339
- end
2340
- def self.values
2341
- end
2342
- end
2343
-
2344
- # Should prices that match the filter be included or excluded.
2345
- module Operator
2346
- extend Orb::Internal::Type::Enum
2347
-
2348
- TaggedSymbol =
2349
- T.type_alias do
2350
- T.all(
2351
- Symbol,
2352
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Operator
2353
- )
2354
- end
2355
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2356
-
2357
- INCLUDES =
2358
- T.let(
2359
- :includes,
2360
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Operator::TaggedSymbol
2361
- )
2362
- EXCLUDES =
2363
- T.let(
2364
- :excludes,
2365
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Operator::TaggedSymbol
2366
- )
2367
-
2368
- sig do
2369
- override.returns(
2370
- T::Array[
2371
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Percentage::Filter::Operator::TaggedSymbol
2372
- ]
2373
- )
2374
- end
2375
- def self.values
2376
- end
2377
- end
2378
- end
2379
- end
2380
-
2381
- class Usage < Orb::Internal::Type::BaseModel
2382
- OrHash =
2383
- T.type_alias do
2384
- T.any(
2385
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage,
2386
- Orb::Internal::AnyHash
2387
- )
2388
- end
2389
-
2390
- # The price interval ids that this discount interval applies to.
2391
- sig { returns(T::Array[String]) }
2392
- attr_accessor :applies_to_price_interval_ids
2393
-
2394
- sig { returns(Symbol) }
2395
- attr_accessor :discount_type
2396
-
2397
- # The end date of the discount interval.
2398
- sig { returns(T.nilable(Time)) }
2399
- attr_accessor :end_date
2400
-
2401
- # The filters that determine which prices this discount interval applies to.
2402
- sig do
2403
- returns(
2404
- T::Array[
2405
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter
2406
- ]
2407
- )
2408
- end
2409
- attr_accessor :filters
2410
-
2411
- # The start date of the discount interval.
2412
- sig { returns(Time) }
2413
- attr_accessor :start_date
2414
-
2415
- # Only available if discount_type is `usage`. Number of usage units that this
2416
- # discount is for
2417
- sig { returns(Float) }
2418
- attr_accessor :usage_discount
2419
-
2420
- sig do
2421
- params(
2422
- applies_to_price_interval_ids: T::Array[String],
2423
- end_date: T.nilable(Time),
2424
- filters:
2425
- T::Array[
2426
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::OrHash
2427
- ],
2428
- start_date: Time,
2429
- usage_discount: Float,
2430
- discount_type: Symbol
2431
- ).returns(T.attached_class)
2432
- end
2433
- def self.new(
2434
- # The price interval ids that this discount interval applies to.
2435
- applies_to_price_interval_ids:,
2436
- # The end date of the discount interval.
2437
- end_date:,
2438
- # The filters that determine which prices this discount interval applies to.
2439
- filters:,
2440
- # The start date of the discount interval.
2441
- start_date:,
2442
- # Only available if discount_type is `usage`. Number of usage units that this
2443
- # discount is for
2444
- usage_discount:,
2445
- discount_type: :usage
2446
- )
2447
- end
2448
-
2449
- sig do
2450
- override.returns(
2451
- {
2452
- applies_to_price_interval_ids: T::Array[String],
2453
- discount_type: Symbol,
2454
- end_date: T.nilable(Time),
2455
- filters:
2456
- T::Array[
2457
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter
2458
- ],
2459
- start_date: Time,
2460
- usage_discount: Float
2461
- }
2462
- )
2463
- end
2464
- def to_hash
2465
- end
2466
-
2467
- class Filter < Orb::Internal::Type::BaseModel
2468
- OrHash =
2469
- T.type_alias do
2470
- T.any(
2471
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter,
2472
- Orb::Internal::AnyHash
2473
- )
2474
- end
2475
-
2476
- # The property of the price to filter on.
2477
- sig do
2478
- returns(
2479
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol
2480
- )
2481
- end
2482
- attr_accessor :field
2483
-
2484
- # Should prices that match the filter be included or excluded.
2485
- sig do
2486
- returns(
2487
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Operator::TaggedSymbol
2488
- )
2489
- end
2490
- attr_accessor :operator
2491
-
2492
- # The IDs or values that match this filter.
2493
- sig { returns(T::Array[String]) }
2494
- attr_accessor :values
2495
-
2496
- sig do
2497
- params(
2498
- field:
2499
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::OrSymbol,
2500
- operator:
2501
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Operator::OrSymbol,
2502
- values: T::Array[String]
2503
- ).returns(T.attached_class)
2504
- end
2505
- def self.new(
2506
- # The property of the price to filter on.
2507
- field:,
2508
- # Should prices that match the filter be included or excluded.
2509
- operator:,
2510
- # The IDs or values that match this filter.
2511
- values:
2512
- )
2513
- end
2514
-
2515
- sig do
2516
- override.returns(
2517
- {
2518
- field:
2519
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol,
2520
- operator:
2521
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Operator::TaggedSymbol,
2522
- values: T::Array[String]
2523
- }
2524
- )
2525
- end
2526
- def to_hash
2527
- end
2528
-
2529
- # The property of the price to filter on.
2530
- module Field
2531
- extend Orb::Internal::Type::Enum
2532
-
2533
- TaggedSymbol =
2534
- T.type_alias do
2535
- T.all(
2536
- Symbol,
2537
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field
2538
- )
2539
- end
2540
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2541
-
2542
- PRICE_ID =
2543
- T.let(
2544
- :price_id,
2545
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol
2546
- )
2547
- ITEM_ID =
2548
- T.let(
2549
- :item_id,
2550
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol
2551
- )
2552
- PRICE_TYPE =
2553
- T.let(
2554
- :price_type,
2555
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol
2556
- )
2557
- CURRENCY =
2558
- T.let(
2559
- :currency,
2560
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol
2561
- )
2562
- PRICING_UNIT_ID =
2563
- T.let(
2564
- :pricing_unit_id,
2565
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol
2566
- )
2567
-
2568
- sig do
2569
- override.returns(
2570
- T::Array[
2571
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Field::TaggedSymbol
2572
- ]
2573
- )
2574
- end
2575
- def self.values
2576
- end
2577
- end
2578
-
2579
- # Should prices that match the filter be included or excluded.
2580
- module Operator
2581
- extend Orb::Internal::Type::Enum
2582
-
2583
- TaggedSymbol =
2584
- T.type_alias do
2585
- T.all(
2586
- Symbol,
2587
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Operator
2588
- )
2589
- end
2590
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2591
-
2592
- INCLUDES =
2593
- T.let(
2594
- :includes,
2595
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Operator::TaggedSymbol
2596
- )
2597
- EXCLUDES =
2598
- T.let(
2599
- :excludes,
2600
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Operator::TaggedSymbol
2601
- )
2602
-
2603
- sig do
2604
- override.returns(
2605
- T::Array[
2606
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Usage::Filter::Operator::TaggedSymbol
2607
- ]
2608
- )
2609
- end
2610
- def self.values
2611
- end
2612
- end
2613
- end
2614
- end
2615
-
2616
- sig do
2617
- override.returns(
2618
- T::Array[
2619
- Orb::Models::SubscriptionCancelResponse::DiscountInterval::Variants
2620
- ]
2621
- )
2622
- end
2623
- def self.variants
2624
- end
2625
- end
2626
-
2627
- class FixedFeeQuantitySchedule < Orb::Internal::Type::BaseModel
2628
- OrHash =
2629
- T.type_alias do
2630
- T.any(
2631
- Orb::Models::SubscriptionCancelResponse::FixedFeeQuantitySchedule,
2632
- Orb::Internal::AnyHash
2633
- )
2634
- end
2635
-
2636
- sig { returns(T.nilable(Time)) }
2637
- attr_accessor :end_date
2638
-
2639
- sig { returns(String) }
2640
- attr_accessor :price_id
2641
-
2642
- sig { returns(Float) }
2643
- attr_accessor :quantity
2644
-
2645
- sig { returns(Time) }
2646
- attr_accessor :start_date
2647
-
2648
- sig do
2649
- params(
2650
- end_date: T.nilable(Time),
2651
- price_id: String,
2652
- quantity: Float,
2653
- start_date: Time
2654
- ).returns(T.attached_class)
2655
- end
2656
- def self.new(end_date:, price_id:, quantity:, start_date:)
2657
- end
2658
-
2659
- sig do
2660
- override.returns(
2661
- {
2662
- end_date: T.nilable(Time),
2663
- price_id: String,
2664
- quantity: Float,
2665
- start_date: Time
2666
- }
2667
- )
2668
- end
2669
- def to_hash
2670
- end
2671
- end
2672
-
2673
- class MaximumInterval < Orb::Internal::Type::BaseModel
2674
- OrHash =
2675
- T.type_alias do
2676
- T.any(
2677
- Orb::Models::SubscriptionCancelResponse::MaximumInterval,
2678
- Orb::Internal::AnyHash
2679
- )
2680
- end
2681
-
2682
- # The price interval ids that this maximum interval applies to.
2683
- sig { returns(T::Array[String]) }
2684
- attr_accessor :applies_to_price_interval_ids
2685
-
2686
- # The end date of the maximum interval.
2687
- sig { returns(T.nilable(Time)) }
2688
- attr_accessor :end_date
2689
-
2690
- # The filters that determine which prices this maximum interval applies to.
2691
- sig do
2692
- returns(
2693
- T::Array[
2694
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter
2695
- ]
2696
- )
2697
- end
2698
- attr_accessor :filters
2699
-
2700
- # The maximum amount to charge in a given billing period for the price intervals
2701
- # this transform applies to.
2702
- sig { returns(String) }
2703
- attr_accessor :maximum_amount
2704
-
2705
- # The start date of the maximum interval.
2706
- sig { returns(Time) }
2707
- attr_accessor :start_date
2708
-
2709
- sig do
2710
- params(
2711
- applies_to_price_interval_ids: T::Array[String],
2712
- end_date: T.nilable(Time),
2713
- filters:
2714
- T::Array[
2715
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::OrHash
2716
- ],
2717
- maximum_amount: String,
2718
- start_date: Time
2719
- ).returns(T.attached_class)
2720
- end
2721
- def self.new(
2722
- # The price interval ids that this maximum interval applies to.
2723
- applies_to_price_interval_ids:,
2724
- # The end date of the maximum interval.
2725
- end_date:,
2726
- # The filters that determine which prices this maximum interval applies to.
2727
- filters:,
2728
- # The maximum amount to charge in a given billing period for the price intervals
2729
- # this transform applies to.
2730
- maximum_amount:,
2731
- # The start date of the maximum interval.
2732
- start_date:
2733
- )
2734
- end
2735
-
2736
- sig do
2737
- override.returns(
2738
- {
2739
- applies_to_price_interval_ids: T::Array[String],
2740
- end_date: T.nilable(Time),
2741
- filters:
2742
- T::Array[
2743
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter
2744
- ],
2745
- maximum_amount: String,
2746
- start_date: Time
2747
- }
2748
- )
2749
- end
2750
- def to_hash
2751
- end
2752
-
2753
- class Filter < Orb::Internal::Type::BaseModel
2754
- OrHash =
2755
- T.type_alias do
2756
- T.any(
2757
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter,
2758
- Orb::Internal::AnyHash
2759
- )
2760
- end
2761
-
2762
- # The property of the price to filter on.
2763
- sig do
2764
- returns(
2765
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol
2766
- )
2767
- end
2768
- attr_accessor :field
2769
-
2770
- # Should prices that match the filter be included or excluded.
2771
- sig do
2772
- returns(
2773
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Operator::TaggedSymbol
2774
- )
2775
- end
2776
- attr_accessor :operator
2777
-
2778
- # The IDs or values that match this filter.
2779
- sig { returns(T::Array[String]) }
2780
- attr_accessor :values
2781
-
2782
- sig do
2783
- params(
2784
- field:
2785
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::OrSymbol,
2786
- operator:
2787
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Operator::OrSymbol,
2788
- values: T::Array[String]
2789
- ).returns(T.attached_class)
2790
- end
2791
- def self.new(
2792
- # The property of the price to filter on.
2793
- field:,
2794
- # Should prices that match the filter be included or excluded.
2795
- operator:,
2796
- # The IDs or values that match this filter.
2797
- values:
2798
- )
2799
- end
2800
-
2801
- sig do
2802
- override.returns(
2803
- {
2804
- field:
2805
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol,
2806
- operator:
2807
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Operator::TaggedSymbol,
2808
- values: T::Array[String]
2809
- }
2810
- )
2811
- end
2812
- def to_hash
2813
- end
2814
-
2815
- # The property of the price to filter on.
2816
- module Field
2817
- extend Orb::Internal::Type::Enum
2818
-
2819
- TaggedSymbol =
2820
- T.type_alias do
2821
- T.all(
2822
- Symbol,
2823
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field
2824
- )
2825
- end
2826
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2827
-
2828
- PRICE_ID =
2829
- T.let(
2830
- :price_id,
2831
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol
2832
- )
2833
- ITEM_ID =
2834
- T.let(
2835
- :item_id,
2836
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol
2837
- )
2838
- PRICE_TYPE =
2839
- T.let(
2840
- :price_type,
2841
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol
2842
- )
2843
- CURRENCY =
2844
- T.let(
2845
- :currency,
2846
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol
2847
- )
2848
- PRICING_UNIT_ID =
2849
- T.let(
2850
- :pricing_unit_id,
2851
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol
2852
- )
2853
-
2854
- sig do
2855
- override.returns(
2856
- T::Array[
2857
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Field::TaggedSymbol
2858
- ]
2859
- )
2860
- end
2861
- def self.values
2862
- end
2863
- end
2864
-
2865
- # Should prices that match the filter be included or excluded.
2866
- module Operator
2867
- extend Orb::Internal::Type::Enum
2868
-
2869
- TaggedSymbol =
2870
- T.type_alias do
2871
- T.all(
2872
- Symbol,
2873
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Operator
2874
- )
2875
- end
2876
- OrSymbol = T.type_alias { T.any(Symbol, String) }
2877
-
2878
- INCLUDES =
2879
- T.let(
2880
- :includes,
2881
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Operator::TaggedSymbol
2882
- )
2883
- EXCLUDES =
2884
- T.let(
2885
- :excludes,
2886
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Operator::TaggedSymbol
2887
- )
2888
-
2889
- sig do
2890
- override.returns(
2891
- T::Array[
2892
- Orb::Models::SubscriptionCancelResponse::MaximumInterval::Filter::Operator::TaggedSymbol
2893
- ]
2894
- )
2895
- end
2896
- def self.values
2897
- end
2898
- end
2899
- end
2900
- end
2901
-
2902
- class MinimumInterval < Orb::Internal::Type::BaseModel
2903
- OrHash =
2904
- T.type_alias do
2905
- T.any(
2906
- Orb::Models::SubscriptionCancelResponse::MinimumInterval,
2907
- Orb::Internal::AnyHash
2908
- )
2909
- end
2910
-
2911
- # The price interval ids that this minimum interval applies to.
2912
- sig { returns(T::Array[String]) }
2913
- attr_accessor :applies_to_price_interval_ids
2914
-
2915
- # The end date of the minimum interval.
2916
- sig { returns(T.nilable(Time)) }
2917
- attr_accessor :end_date
2918
-
2919
- # The filters that determine which prices this minimum interval applies to.
2920
- sig do
2921
- returns(
2922
- T::Array[
2923
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter
2924
- ]
2925
- )
2926
- end
2927
- attr_accessor :filters
2928
-
2929
- # The minimum amount to charge in a given billing period for the price intervals
2930
- # this minimum applies to.
2931
- sig { returns(String) }
2932
- attr_accessor :minimum_amount
2933
-
2934
- # The start date of the minimum interval.
2935
- sig { returns(Time) }
2936
- attr_accessor :start_date
2937
-
2938
- sig do
2939
- params(
2940
- applies_to_price_interval_ids: T::Array[String],
2941
- end_date: T.nilable(Time),
2942
- filters:
2943
- T::Array[
2944
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::OrHash
2945
- ],
2946
- minimum_amount: String,
2947
- start_date: Time
2948
- ).returns(T.attached_class)
2949
- end
2950
- def self.new(
2951
- # The price interval ids that this minimum interval applies to.
2952
- applies_to_price_interval_ids:,
2953
- # The end date of the minimum interval.
2954
- end_date:,
2955
- # The filters that determine which prices this minimum interval applies to.
2956
- filters:,
2957
- # The minimum amount to charge in a given billing period for the price intervals
2958
- # this minimum applies to.
2959
- minimum_amount:,
2960
- # The start date of the minimum interval.
2961
- start_date:
2962
- )
2963
- end
2964
-
2965
- sig do
2966
- override.returns(
2967
- {
2968
- applies_to_price_interval_ids: T::Array[String],
2969
- end_date: T.nilable(Time),
2970
- filters:
2971
- T::Array[
2972
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter
2973
- ],
2974
- minimum_amount: String,
2975
- start_date: Time
2976
- }
2977
- )
2978
- end
2979
- def to_hash
2980
- end
2981
-
2982
- class Filter < Orb::Internal::Type::BaseModel
2983
- OrHash =
2984
- T.type_alias do
2985
- T.any(
2986
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter,
2987
- Orb::Internal::AnyHash
2988
- )
2989
- end
2990
-
2991
- # The property of the price to filter on.
2992
- sig do
2993
- returns(
2994
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol
2995
- )
2996
- end
2997
- attr_accessor :field
2998
-
2999
- # Should prices that match the filter be included or excluded.
3000
- sig do
3001
- returns(
3002
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Operator::TaggedSymbol
3003
- )
3004
- end
3005
- attr_accessor :operator
3006
-
3007
- # The IDs or values that match this filter.
3008
- sig { returns(T::Array[String]) }
3009
- attr_accessor :values
3010
-
3011
- sig do
3012
- params(
3013
- field:
3014
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::OrSymbol,
3015
- operator:
3016
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Operator::OrSymbol,
3017
- values: T::Array[String]
3018
- ).returns(T.attached_class)
3019
- end
3020
- def self.new(
3021
- # The property of the price to filter on.
3022
- field:,
3023
- # Should prices that match the filter be included or excluded.
3024
- operator:,
3025
- # The IDs or values that match this filter.
3026
- values:
3027
- )
3028
- end
3029
-
3030
- sig do
3031
- override.returns(
3032
- {
3033
- field:
3034
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol,
3035
- operator:
3036
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Operator::TaggedSymbol,
3037
- values: T::Array[String]
3038
- }
3039
- )
3040
- end
3041
- def to_hash
3042
- end
3043
-
3044
- # The property of the price to filter on.
3045
- module Field
3046
- extend Orb::Internal::Type::Enum
3047
-
3048
- TaggedSymbol =
3049
- T.type_alias do
3050
- T.all(
3051
- Symbol,
3052
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field
3053
- )
3054
- end
3055
- OrSymbol = T.type_alias { T.any(Symbol, String) }
3056
-
3057
- PRICE_ID =
3058
- T.let(
3059
- :price_id,
3060
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol
3061
- )
3062
- ITEM_ID =
3063
- T.let(
3064
- :item_id,
3065
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol
3066
- )
3067
- PRICE_TYPE =
3068
- T.let(
3069
- :price_type,
3070
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol
3071
- )
3072
- CURRENCY =
3073
- T.let(
3074
- :currency,
3075
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol
3076
- )
3077
- PRICING_UNIT_ID =
3078
- T.let(
3079
- :pricing_unit_id,
3080
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol
3081
- )
3082
-
3083
- sig do
3084
- override.returns(
3085
- T::Array[
3086
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Field::TaggedSymbol
3087
- ]
3088
- )
3089
- end
3090
- def self.values
3091
- end
3092
- end
3093
-
3094
- # Should prices that match the filter be included or excluded.
3095
- module Operator
3096
- extend Orb::Internal::Type::Enum
3097
-
3098
- TaggedSymbol =
3099
- T.type_alias do
3100
- T.all(
3101
- Symbol,
3102
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Operator
3103
- )
3104
- end
3105
- OrSymbol = T.type_alias { T.any(Symbol, String) }
3106
-
3107
- INCLUDES =
3108
- T.let(
3109
- :includes,
3110
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Operator::TaggedSymbol
3111
- )
3112
- EXCLUDES =
3113
- T.let(
3114
- :excludes,
3115
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Operator::TaggedSymbol
3116
- )
3117
-
3118
- sig do
3119
- override.returns(
3120
- T::Array[
3121
- Orb::Models::SubscriptionCancelResponse::MinimumInterval::Filter::Operator::TaggedSymbol
3122
- ]
3123
- )
3124
- end
3125
- def self.values
3126
- end
3127
- end
3128
- end
3129
- end
3130
-
3131
- class PendingSubscriptionChange < Orb::Internal::Type::BaseModel
3132
- OrHash =
3133
- T.type_alias do
3134
- T.any(
3135
- Orb::Models::SubscriptionCancelResponse::PendingSubscriptionChange,
3136
- Orb::Internal::AnyHash
3137
- )
3138
- end
3139
-
3140
- sig { returns(String) }
3141
- attr_accessor :id
3142
-
3143
- # A pending subscription change if one exists on this subscription.
3144
- sig { params(id: String).returns(T.attached_class) }
3145
- def self.new(id:)
3146
- end
3147
-
3148
- sig { override.returns({ id: String }) }
3149
- def to_hash
3150
- end
3151
- end
3152
-
3153
- class PriceInterval < Orb::Internal::Type::BaseModel
3154
- OrHash =
3155
- T.type_alias do
3156
- T.any(
3157
- Orb::Models::SubscriptionCancelResponse::PriceInterval,
3158
- Orb::Internal::AnyHash
3159
- )
3160
- end
3161
-
3162
- sig { returns(String) }
3163
- attr_accessor :id
3164
-
3165
- # The day of the month that Orb bills for this price
3166
- sig { returns(Integer) }
3167
- attr_accessor :billing_cycle_day
3168
-
3169
- # The end of the current billing period. This is an exclusive timestamp, such that
3170
- # the instant returned is exactly the end of the billing period. Set to null if
3171
- # this price interval is not currently active.
3172
- sig { returns(T.nilable(Time)) }
3173
- attr_accessor :current_billing_period_end_date
3174
-
3175
- # The start date of the current billing period. This is an inclusive timestamp;
3176
- # the instant returned is exactly the beginning of the billing period. Set to null
3177
- # if this price interval is not currently active.
3178
- sig { returns(T.nilable(Time)) }
3179
- attr_accessor :current_billing_period_start_date
3180
-
3181
- # The end date of the price interval. This is the date that Orb stops billing for
3182
- # this price.
3183
- sig { returns(T.nilable(Time)) }
3184
- attr_accessor :end_date
3185
-
3186
- # An additional filter to apply to usage queries.
3187
- sig { returns(T.nilable(String)) }
3188
- attr_accessor :filter
3189
-
3190
- # The fixed fee quantity transitions for this price interval. This is only
3191
- # relevant for fixed fees.
3192
- sig do
3193
- returns(
3194
- T.nilable(
3195
- T::Array[
3196
- Orb::Models::SubscriptionCancelResponse::PriceInterval::FixedFeeQuantityTransition
3197
- ]
3198
- )
3199
- )
3200
- end
3201
- attr_accessor :fixed_fee_quantity_transitions
3202
-
3203
- # The Price resource represents a price that can be billed on a subscription,
3204
- # resulting in a charge on an invoice in the form of an invoice line item. Prices
3205
- # take a quantity and determine an amount to bill.
3206
- #
3207
- # Orb supports a few different pricing models out of the box. Each of these models
3208
- # is serialized differently in a given Price object. The model_type field
3209
- # determines the key for the configuration object that is present.
3210
- #
3211
- # For more on the types of prices, see
3212
- # [the core concepts documentation](/core-concepts#plan-and-price)
3213
- sig { returns(Orb::Price::Variants) }
3214
- attr_accessor :price
3215
-
3216
- # The start date of the price interval. This is the date that Orb starts billing
3217
- # for this price.
3218
- sig { returns(Time) }
3219
- attr_accessor :start_date
3220
-
3221
- # A list of customer IDs whose usage events will be aggregated and billed under
3222
- # this price interval.
3223
- sig { returns(T.nilable(T::Array[String])) }
3224
- attr_accessor :usage_customer_ids
3225
-
3226
- # The Price Interval resource represents a period of time for which a price will
3227
- # bill on a subscription. A subscription’s price intervals define its billing
3228
- # behavior.
3229
- sig do
3230
- params(
3231
- id: String,
3232
- billing_cycle_day: Integer,
3233
- current_billing_period_end_date: T.nilable(Time),
3234
- current_billing_period_start_date: T.nilable(Time),
3235
- end_date: T.nilable(Time),
3236
- filter: T.nilable(String),
3237
- fixed_fee_quantity_transitions:
3238
- T.nilable(
3239
- T::Array[
3240
- Orb::Models::SubscriptionCancelResponse::PriceInterval::FixedFeeQuantityTransition::OrHash
3241
- ]
3242
- ),
3243
- price:
3244
- T.any(
3245
- Orb::Price::Unit::OrHash,
3246
- Orb::Price::Package::OrHash,
3247
- Orb::Price::Matrix::OrHash,
3248
- Orb::Price::Tiered::OrHash,
3249
- Orb::Price::TieredBps::OrHash,
3250
- Orb::Price::Bps::OrHash,
3251
- Orb::Price::BulkBps::OrHash,
3252
- Orb::Price::Bulk::OrHash,
3253
- Orb::Price::ThresholdTotalAmount::OrHash,
3254
- Orb::Price::TieredPackage::OrHash,
3255
- Orb::Price::GroupedTiered::OrHash,
3256
- Orb::Price::TieredWithMinimum::OrHash,
3257
- Orb::Price::TieredPackageWithMinimum::OrHash,
3258
- Orb::Price::PackageWithAllocation::OrHash,
3259
- Orb::Price::UnitWithPercent::OrHash,
3260
- Orb::Price::MatrixWithAllocation::OrHash,
3261
- Orb::Price::TieredWithProration::OrHash,
3262
- Orb::Price::UnitWithProration::OrHash,
3263
- Orb::Price::GroupedAllocation::OrHash,
3264
- Orb::Price::GroupedWithProratedMinimum::OrHash,
3265
- Orb::Price::GroupedWithMeteredMinimum::OrHash,
3266
- Orb::Price::MatrixWithDisplayName::OrHash,
3267
- Orb::Price::BulkWithProration::OrHash,
3268
- Orb::Price::GroupedTieredPackage::OrHash,
3269
- Orb::Price::MaxGroupTieredPackage::OrHash,
3270
- Orb::Price::ScalableMatrixWithUnitPricing::OrHash,
3271
- Orb::Price::ScalableMatrixWithTieredPricing::OrHash,
3272
- Orb::Price::CumulativeGroupedBulk::OrHash
3273
- ),
3274
- start_date: Time,
3275
- usage_customer_ids: T.nilable(T::Array[String])
3276
- ).returns(T.attached_class)
3277
- end
3278
- def self.new(
3279
- id:,
3280
- # The day of the month that Orb bills for this price
3281
- billing_cycle_day:,
3282
- # The end of the current billing period. This is an exclusive timestamp, such that
3283
- # the instant returned is exactly the end of the billing period. Set to null if
3284
- # this price interval is not currently active.
3285
- current_billing_period_end_date:,
3286
- # The start date of the current billing period. This is an inclusive timestamp;
3287
- # the instant returned is exactly the beginning of the billing period. Set to null
3288
- # if this price interval is not currently active.
3289
- current_billing_period_start_date:,
3290
- # The end date of the price interval. This is the date that Orb stops billing for
3291
- # this price.
3292
- end_date:,
3293
- # An additional filter to apply to usage queries.
3294
- filter:,
3295
- # The fixed fee quantity transitions for this price interval. This is only
3296
- # relevant for fixed fees.
3297
- fixed_fee_quantity_transitions:,
3298
- # The Price resource represents a price that can be billed on a subscription,
3299
- # resulting in a charge on an invoice in the form of an invoice line item. Prices
3300
- # take a quantity and determine an amount to bill.
3301
- #
3302
- # Orb supports a few different pricing models out of the box. Each of these models
3303
- # is serialized differently in a given Price object. The model_type field
3304
- # determines the key for the configuration object that is present.
3305
- #
3306
- # For more on the types of prices, see
3307
- # [the core concepts documentation](/core-concepts#plan-and-price)
3308
- price:,
3309
- # The start date of the price interval. This is the date that Orb starts billing
3310
- # for this price.
3311
- start_date:,
3312
- # A list of customer IDs whose usage events will be aggregated and billed under
3313
- # this price interval.
3314
- usage_customer_ids:
3315
- )
3316
- end
3317
-
3318
- sig do
3319
- override.returns(
3320
- {
3321
- id: String,
3322
- billing_cycle_day: Integer,
3323
- current_billing_period_end_date: T.nilable(Time),
3324
- current_billing_period_start_date: T.nilable(Time),
3325
- end_date: T.nilable(Time),
3326
- filter: T.nilable(String),
3327
- fixed_fee_quantity_transitions:
3328
- T.nilable(
3329
- T::Array[
3330
- Orb::Models::SubscriptionCancelResponse::PriceInterval::FixedFeeQuantityTransition
3331
- ]
3332
- ),
3333
- price: Orb::Price::Variants,
3334
- start_date: Time,
3335
- usage_customer_ids: T.nilable(T::Array[String])
3336
- }
3337
- )
3338
- end
3339
- def to_hash
3340
- end
3341
-
3342
- class FixedFeeQuantityTransition < Orb::Internal::Type::BaseModel
3343
- OrHash =
3344
- T.type_alias do
3345
- T.any(
3346
- Orb::Models::SubscriptionCancelResponse::PriceInterval::FixedFeeQuantityTransition,
3347
- Orb::Internal::AnyHash
3348
- )
3349
- end
3350
-
3351
- sig { returns(Time) }
3352
- attr_accessor :effective_date
3353
-
3354
- sig { returns(String) }
3355
- attr_accessor :price_id
3356
-
3357
- sig { returns(Integer) }
3358
- attr_accessor :quantity
3359
-
3360
- sig do
3361
- params(
3362
- effective_date: Time,
3363
- price_id: String,
3364
- quantity: Integer
3365
- ).returns(T.attached_class)
3366
- end
3367
- def self.new(effective_date:, price_id:, quantity:)
3368
- end
3369
-
3370
- sig do
3371
- override.returns(
3372
- { effective_date: Time, price_id: String, quantity: Integer }
3373
- )
3374
- end
3375
- def to_hash
3376
- end
3377
- end
3378
- end
3379
-
3380
- class RedeemedCoupon < Orb::Internal::Type::BaseModel
3381
- OrHash =
3382
- T.type_alias do
3383
- T.any(
3384
- Orb::Models::SubscriptionCancelResponse::RedeemedCoupon,
3385
- Orb::Internal::AnyHash
3386
- )
3387
- end
3388
-
3389
- sig { returns(String) }
3390
- attr_accessor :coupon_id
3391
-
3392
- sig { returns(T.nilable(Time)) }
3393
- attr_accessor :end_date
3394
-
3395
- sig { returns(Time) }
3396
- attr_accessor :start_date
3397
-
3398
- sig do
3399
- params(
3400
- coupon_id: String,
3401
- end_date: T.nilable(Time),
3402
- start_date: Time
3403
- ).returns(T.attached_class)
3404
- end
3405
- def self.new(coupon_id:, end_date:, start_date:)
3406
- end
3407
-
3408
- sig do
3409
- override.returns(
3410
- { coupon_id: String, end_date: T.nilable(Time), start_date: Time }
3411
- )
3412
- end
3413
- def to_hash
3414
- end
3415
- end
3416
-
3417
- module Status
3418
- extend Orb::Internal::Type::Enum
3419
-
3420
- TaggedSymbol =
3421
- T.type_alias do
3422
- T.all(Symbol, Orb::Models::SubscriptionCancelResponse::Status)
3423
- end
3424
- OrSymbol = T.type_alias { T.any(Symbol, String) }
3425
-
3426
- ACTIVE =
3427
- T.let(
3428
- :active,
3429
- Orb::Models::SubscriptionCancelResponse::Status::TaggedSymbol
3430
- )
3431
- ENDED =
3432
- T.let(
3433
- :ended,
3434
- Orb::Models::SubscriptionCancelResponse::Status::TaggedSymbol
3435
- )
3436
- UPCOMING =
3437
- T.let(
3438
- :upcoming,
3439
- Orb::Models::SubscriptionCancelResponse::Status::TaggedSymbol
3440
- )
3441
-
3442
- sig do
3443
- override.returns(
3444
- T::Array[
3445
- Orb::Models::SubscriptionCancelResponse::Status::TaggedSymbol
3446
- ]
3447
- )
3448
- end
3449
- def self.values
3450
- end
3451
- end
3452
-
3453
- class TrialInfo < Orb::Internal::Type::BaseModel
3454
- OrHash =
3455
- T.type_alias do
3456
- T.any(
3457
- Orb::Models::SubscriptionCancelResponse::TrialInfo,
3458
- Orb::Internal::AnyHash
3459
- )
3460
- end
3461
-
3462
- sig { returns(T.nilable(Time)) }
3463
- attr_accessor :end_date
3464
-
3465
- sig { params(end_date: T.nilable(Time)).returns(T.attached_class) }
3466
- def self.new(end_date:)
3467
- end
3468
-
3469
- sig { override.returns({ end_date: T.nilable(Time) }) }
3470
- def to_hash
3471
- end
3472
- end
3473
-
3474
- class ChangedResources < Orb::Internal::Type::BaseModel
3475
- OrHash =
3476
- T.type_alias do
3477
- T.any(
3478
- Orb::Models::SubscriptionCancelResponse::ChangedResources,
3479
- Orb::Internal::AnyHash
3480
- )
3481
- end
3482
-
3483
- # The credit notes that were created as part of this operation.
3484
- sig { returns(T::Array[Orb::CreditNote]) }
3485
- attr_accessor :created_credit_notes
3486
-
3487
- # The invoices that were created as part of this operation.
3488
- sig { returns(T::Array[Orb::Invoice]) }
3489
- attr_accessor :created_invoices
3490
-
3491
- # The credit notes that were voided as part of this operation.
3492
- sig { returns(T::Array[Orb::CreditNote]) }
3493
- attr_accessor :voided_credit_notes
3494
-
3495
- # The invoices that were voided as part of this operation.
3496
- sig { returns(T::Array[Orb::Invoice]) }
3497
- attr_accessor :voided_invoices
3498
-
3499
- # The resources that were changed as part of this operation. Only present when
3500
- # fetched through the subscription changes API or if the
3501
- # `include_changed_resources` parameter was passed in the request.
3502
- sig do
3503
- params(
3504
- created_credit_notes: T::Array[Orb::CreditNote::OrHash],
3505
- created_invoices: T::Array[Orb::Invoice::OrHash],
3506
- voided_credit_notes: T::Array[Orb::CreditNote::OrHash],
3507
- voided_invoices: T::Array[Orb::Invoice::OrHash]
3508
- ).returns(T.attached_class)
3509
- end
3510
- def self.new(
3511
- # The credit notes that were created as part of this operation.
3512
- created_credit_notes:,
3513
- # The invoices that were created as part of this operation.
3514
- created_invoices:,
3515
- # The credit notes that were voided as part of this operation.
3516
- voided_credit_notes:,
3517
- # The invoices that were voided as part of this operation.
3518
- voided_invoices:
3519
- )
3520
- end
3521
-
3522
- sig do
3523
- override.returns(
3524
- {
3525
- created_credit_notes: T::Array[Orb::CreditNote],
3526
- created_invoices: T::Array[Orb::Invoice],
3527
- voided_credit_notes: T::Array[Orb::CreditNote],
3528
- voided_invoices: T::Array[Orb::Invoice]
3529
- }
3530
- )
3531
- end
3532
- def to_hash
3533
- end
3534
- end
3535
- end
3536
- end
3537
- end