orb-billing 1.13.0 → 1.15.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 (624) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +55 -0
  3. data/README.md +1 -1
  4. data/lib/orb/client.rb +21 -0
  5. data/lib/orb/internal/transport/base_client.rb +5 -0
  6. data/lib/orb/internal/type/union.rb +13 -27
  7. data/lib/orb/internal/util.rb +22 -7
  8. data/lib/orb/models/accounting_provider_config.rb +14 -3
  9. data/lib/orb/models/adjustment_interval.rb +185 -3
  10. data/lib/orb/models/alert.rb +114 -1
  11. data/lib/orb/models/alert_create_for_customer_params.rb +8 -1
  12. data/lib/orb/models/alert_create_for_external_customer_params.rb +8 -1
  13. data/lib/orb/models/alert_create_for_subscription_params.rb +142 -1
  14. data/lib/orb/models/alert_disable_params.rb +8 -1
  15. data/lib/orb/models/alert_enable_params.rb +8 -1
  16. data/lib/orb/models/alert_retrieve_params.rb +7 -1
  17. data/lib/orb/models/alert_update_params.rb +120 -1
  18. data/lib/orb/models/beta/external_plan_id_create_plan_version_params.rb +3296 -631
  19. data/lib/orb/models/beta/external_plan_id_fetch_plan_version_params.rb +7 -1
  20. data/lib/orb/models/beta/external_plan_id_set_default_plan_version_params.rb +8 -1
  21. data/lib/orb/models/beta_create_plan_version_params.rb +3263 -622
  22. data/lib/orb/models/beta_fetch_plan_version_params.rb +7 -1
  23. data/lib/orb/models/beta_set_default_plan_version_params.rb +8 -1
  24. data/lib/orb/models/changed_subscription_resources.rb +200 -10
  25. data/lib/orb/models/conversion_rate_config.rb +18 -0
  26. data/lib/orb/models/coupon_archive_params.rb +7 -1
  27. data/lib/orb/models/coupon_fetch_params.rb +7 -1
  28. data/lib/orb/models/coupons/subscription_list_params.rb +8 -1
  29. data/lib/orb/models/credit_block_delete_params.rb +7 -1
  30. data/lib/orb/models/credit_block_list_invoices_params.rb +7 -1
  31. data/lib/orb/models/credit_block_list_invoices_response.rb +155 -1
  32. data/lib/orb/models/credit_block_retrieve_params.rb +7 -1
  33. data/lib/orb/models/credit_block_retrieve_response.rb +150 -1
  34. data/lib/orb/models/credit_note_fetch_params.rb +7 -1
  35. data/lib/orb/models/customer.rb +122 -3
  36. data/lib/orb/models/customer_create_params.rb +17 -1
  37. data/lib/orb/models/customer_delete_params.rb +7 -1
  38. data/lib/orb/models/customer_fetch_by_external_id_params.rb +7 -1
  39. data/lib/orb/models/customer_fetch_params.rb +7 -1
  40. data/lib/orb/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rb +7 -1
  41. data/lib/orb/models/customer_sync_payment_methods_from_gateway_params.rb +7 -1
  42. data/lib/orb/models/customer_tax_id.rb +15 -1
  43. data/lib/orb/models/customer_update_by_external_id_params.rb +39 -5
  44. data/lib/orb/models/customer_update_params.rb +39 -5
  45. data/lib/orb/models/customers/balance_transaction_create_params.rb +8 -1
  46. data/lib/orb/models/customers/balance_transaction_list_params.rb +8 -1
  47. data/lib/orb/models/customers/cost_list_by_external_id_params.rb +8 -1
  48. data/lib/orb/models/customers/cost_list_params.rb +8 -1
  49. data/lib/orb/models/customers/credit_list_by_external_id_params.rb +8 -1
  50. data/lib/orb/models/customers/credit_list_by_external_id_response.rb +155 -1
  51. data/lib/orb/models/customers/credit_list_params.rb +8 -1
  52. data/lib/orb/models/customers/credit_list_response.rb +152 -1
  53. data/lib/orb/models/customers/credits/decrement_ledger_entry.rb +5 -1
  54. data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb +582 -315
  55. data/lib/orb/models/customers/credits/ledger_create_entry_params.rb +580 -313
  56. data/lib/orb/models/customers/credits/ledger_list_by_external_id_params.rb +8 -1
  57. data/lib/orb/models/customers/credits/ledger_list_params.rb +8 -1
  58. data/lib/orb/models/customers/credits/top_up_create_by_external_id_params.rb +8 -1
  59. data/lib/orb/models/customers/credits/top_up_create_params.rb +8 -1
  60. data/lib/orb/models/customers/credits/top_up_delete_by_external_id_params.rb +7 -1
  61. data/lib/orb/models/customers/credits/top_up_delete_params.rb +7 -1
  62. data/lib/orb/models/customers/credits/top_up_list_by_external_id_params.rb +8 -1
  63. data/lib/orb/models/customers/credits/top_up_list_params.rb +8 -1
  64. data/lib/orb/models/dimensional_price_group.rb +1 -1
  65. data/lib/orb/models/dimensional_price_group_retrieve_params.rb +7 -1
  66. data/lib/orb/models/dimensional_price_group_update_params.rb +8 -1
  67. data/lib/orb/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rb +7 -1
  68. data/lib/orb/models/dimensional_price_groups/external_dimensional_price_group_id_update_params.rb +8 -1
  69. data/lib/orb/models/discount.rb +145 -1
  70. data/lib/orb/models/event_deprecate_params.rb +7 -1
  71. data/lib/orb/models/event_ingest_params.rb +5 -2
  72. data/lib/orb/models/event_update_params.rb +8 -1
  73. data/lib/orb/models/events/backfill_close_params.rb +7 -1
  74. data/lib/orb/models/events/backfill_fetch_params.rb +7 -1
  75. data/lib/orb/models/events/backfill_revert_params.rb +7 -1
  76. data/lib/orb/models/invoice.rb +198 -10
  77. data/lib/orb/models/invoice_create_params.rb +6 -5
  78. data/lib/orb/models/invoice_delete_line_item_params.rb +7 -1
  79. data/lib/orb/models/invoice_fetch_params.rb +7 -1
  80. data/lib/orb/models/invoice_fetch_upcoming_response.rb +200 -10
  81. data/lib/orb/models/invoice_issue_params.rb +8 -1
  82. data/lib/orb/models/invoice_issue_summary_params.rb +8 -1
  83. data/lib/orb/models/invoice_issue_summary_response.rb +9 -3
  84. data/lib/orb/models/invoice_level_discount.rb +145 -1
  85. data/lib/orb/models/invoice_line_item_create_response.rb +189 -5
  86. data/lib/orb/models/invoice_list_summary_response.rb +9 -3
  87. data/lib/orb/models/invoice_mark_paid_params.rb +8 -1
  88. data/lib/orb/models/invoice_pay_params.rb +16 -1
  89. data/lib/orb/models/invoice_update_params.rb +8 -1
  90. data/lib/orb/models/invoice_void_params.rb +7 -1
  91. data/lib/orb/models/item_archive_params.rb +7 -1
  92. data/lib/orb/models/item_fetch_params.rb +7 -1
  93. data/lib/orb/models/item_update_params.rb +8 -1
  94. data/lib/orb/models/license_deactivate_params.rb +8 -1
  95. data/lib/orb/models/license_retrieve_by_external_id_params.rb +8 -1
  96. data/lib/orb/models/license_retrieve_params.rb +7 -1
  97. data/lib/orb/models/license_type_retrieve_params.rb +7 -1
  98. data/lib/orb/models/licenses/external_license_get_usage_params.rb +11 -4
  99. data/lib/orb/models/licenses/usage_get_all_usage_params.rb +3 -3
  100. data/lib/orb/models/licenses/usage_get_usage_params.rb +11 -4
  101. data/lib/orb/models/metric_fetch_params.rb +7 -1
  102. data/lib/orb/models/metric_update_params.rb +8 -1
  103. data/lib/orb/models/mutated_subscription.rb +169 -4
  104. data/lib/orb/models/new_allocation_price.rb +11 -1
  105. data/lib/orb/models/new_floating_bulk_price.rb +1 -3
  106. data/lib/orb/models/new_floating_bulk_with_proration_price.rb +1 -3
  107. data/lib/orb/models/new_floating_cumulative_grouped_bulk_price.rb +1 -3
  108. data/lib/orb/models/new_floating_grouped_allocation_price.rb +1 -3
  109. data/lib/orb/models/new_floating_grouped_tiered_package_price.rb +1 -3
  110. data/lib/orb/models/new_floating_grouped_tiered_price.rb +1 -3
  111. data/lib/orb/models/new_floating_grouped_with_metered_minimum_price.rb +1 -3
  112. data/lib/orb/models/new_floating_grouped_with_prorated_minimum_price.rb +1 -3
  113. data/lib/orb/models/new_floating_matrix_price.rb +1 -3
  114. data/lib/orb/models/new_floating_matrix_with_allocation_price.rb +1 -3
  115. data/lib/orb/models/new_floating_matrix_with_display_name_price.rb +1 -3
  116. data/lib/orb/models/new_floating_max_group_tiered_package_price.rb +1 -3
  117. data/lib/orb/models/new_floating_minimum_composite_price.rb +1 -3
  118. data/lib/orb/models/new_floating_package_price.rb +1 -3
  119. data/lib/orb/models/new_floating_package_with_allocation_price.rb +1 -3
  120. data/lib/orb/models/new_floating_scalable_matrix_with_tiered_pricing_price.rb +1 -3
  121. data/lib/orb/models/new_floating_scalable_matrix_with_unit_pricing_price.rb +1 -3
  122. data/lib/orb/models/new_floating_threshold_total_amount_price.rb +1 -3
  123. data/lib/orb/models/new_floating_tiered_package_price.rb +1 -3
  124. data/lib/orb/models/new_floating_tiered_package_with_minimum_price.rb +1 -3
  125. data/lib/orb/models/new_floating_tiered_price.rb +1 -3
  126. data/lib/orb/models/new_floating_tiered_with_minimum_price.rb +1 -3
  127. data/lib/orb/models/new_floating_tiered_with_proration_price.rb +1 -3
  128. data/lib/orb/models/new_floating_unit_price.rb +1 -3
  129. data/lib/orb/models/new_floating_unit_with_percent_price.rb +1 -3
  130. data/lib/orb/models/new_floating_unit_with_proration_price.rb +1 -3
  131. data/lib/orb/models/new_plan_bulk_price.rb +1 -1
  132. data/lib/orb/models/new_plan_bulk_with_proration_price.rb +1 -3
  133. data/lib/orb/models/new_plan_cumulative_grouped_bulk_price.rb +1 -3
  134. data/lib/orb/models/new_plan_grouped_allocation_price.rb +1 -3
  135. data/lib/orb/models/new_plan_grouped_tiered_package_price.rb +1 -3
  136. data/lib/orb/models/new_plan_grouped_tiered_price.rb +1 -3
  137. data/lib/orb/models/new_plan_grouped_with_metered_minimum_price.rb +1 -3
  138. data/lib/orb/models/new_plan_grouped_with_prorated_minimum_price.rb +1 -3
  139. data/lib/orb/models/new_plan_matrix_price.rb +1 -5
  140. data/lib/orb/models/new_plan_matrix_with_allocation_price.rb +1 -3
  141. data/lib/orb/models/new_plan_matrix_with_display_name_price.rb +1 -3
  142. data/lib/orb/models/new_plan_max_group_tiered_package_price.rb +1 -3
  143. data/lib/orb/models/new_plan_minimum_composite_price.rb +1 -3
  144. data/lib/orb/models/new_plan_package_price.rb +1 -5
  145. data/lib/orb/models/new_plan_package_with_allocation_price.rb +1 -3
  146. data/lib/orb/models/new_plan_scalable_matrix_with_tiered_pricing_price.rb +1 -3
  147. data/lib/orb/models/new_plan_scalable_matrix_with_unit_pricing_price.rb +1 -3
  148. data/lib/orb/models/new_plan_threshold_total_amount_price.rb +1 -3
  149. data/lib/orb/models/new_plan_tiered_package_price.rb +1 -3
  150. data/lib/orb/models/new_plan_tiered_package_with_minimum_price.rb +1 -3
  151. data/lib/orb/models/new_plan_tiered_price.rb +1 -5
  152. data/lib/orb/models/new_plan_tiered_with_minimum_price.rb +1 -3
  153. data/lib/orb/models/new_plan_unit_price.rb +1 -1
  154. data/lib/orb/models/new_plan_unit_with_percent_price.rb +1 -3
  155. data/lib/orb/models/new_plan_unit_with_proration_price.rb +1 -3
  156. data/lib/orb/models/new_subscription_bulk_price.rb +1 -3
  157. data/lib/orb/models/new_subscription_bulk_with_proration_price.rb +1 -3
  158. data/lib/orb/models/new_subscription_cumulative_grouped_bulk_price.rb +1 -3
  159. data/lib/orb/models/new_subscription_grouped_allocation_price.rb +1 -3
  160. data/lib/orb/models/new_subscription_grouped_tiered_package_price.rb +1 -3
  161. data/lib/orb/models/new_subscription_grouped_tiered_price.rb +1 -3
  162. data/lib/orb/models/new_subscription_grouped_with_metered_minimum_price.rb +1 -3
  163. data/lib/orb/models/new_subscription_grouped_with_prorated_minimum_price.rb +1 -3
  164. data/lib/orb/models/new_subscription_matrix_price.rb +1 -3
  165. data/lib/orb/models/new_subscription_matrix_with_allocation_price.rb +1 -3
  166. data/lib/orb/models/new_subscription_matrix_with_display_name_price.rb +1 -3
  167. data/lib/orb/models/new_subscription_max_group_tiered_package_price.rb +1 -3
  168. data/lib/orb/models/new_subscription_minimum_composite_price.rb +1 -3
  169. data/lib/orb/models/new_subscription_package_price.rb +1 -3
  170. data/lib/orb/models/new_subscription_package_with_allocation_price.rb +1 -3
  171. data/lib/orb/models/new_subscription_scalable_matrix_with_tiered_pricing_price.rb +1 -3
  172. data/lib/orb/models/new_subscription_scalable_matrix_with_unit_pricing_price.rb +1 -3
  173. data/lib/orb/models/new_subscription_threshold_total_amount_price.rb +1 -3
  174. data/lib/orb/models/new_subscription_tiered_package_price.rb +1 -3
  175. data/lib/orb/models/new_subscription_tiered_package_with_minimum_price.rb +1 -3
  176. data/lib/orb/models/new_subscription_tiered_price.rb +1 -3
  177. data/lib/orb/models/new_subscription_tiered_with_minimum_price.rb +1 -3
  178. data/lib/orb/models/new_subscription_unit_price.rb +1 -3
  179. data/lib/orb/models/new_subscription_unit_with_percent_price.rb +1 -3
  180. data/lib/orb/models/new_subscription_unit_with_proration_price.rb +1 -3
  181. data/lib/orb/models/per_price_cost.rb +2 -2
  182. data/lib/orb/models/plan.rb +189 -9
  183. data/lib/orb/models/plan_create_params.rb +1478 -158
  184. data/lib/orb/models/plan_fetch_params.rb +7 -1
  185. data/lib/orb/models/plan_update_params.rb +16 -1
  186. data/lib/orb/models/plan_version.rb +186 -5
  187. data/lib/orb/models/plans/external_plan_id_fetch_params.rb +7 -1
  188. data/lib/orb/models/plans/external_plan_id_update_params.rb +16 -1
  189. data/lib/orb/models/plans/migration_cancel_params.rb +7 -1
  190. data/lib/orb/models/plans/migration_cancel_response.rb +22 -4
  191. data/lib/orb/models/plans/migration_list_params.rb +8 -1
  192. data/lib/orb/models/plans/migration_list_response.rb +22 -4
  193. data/lib/orb/models/plans/migration_retrieve_params.rb +7 -1
  194. data/lib/orb/models/plans/migration_retrieve_response.rb +22 -4
  195. data/lib/orb/models/price.rb +2807 -1244
  196. data/lib/orb/models/price_create_params.rb +1800 -1355
  197. data/lib/orb/models/price_evaluate_multiple_params.rb +889 -54
  198. data/lib/orb/models/price_evaluate_params.rb +8 -1
  199. data/lib/orb/models/price_evaluate_preview_events_params.rb +881 -46
  200. data/lib/orb/models/price_fetch_params.rb +7 -1
  201. data/lib/orb/models/price_interval.rb +2 -2
  202. data/lib/orb/models/price_update_params.rb +8 -1
  203. data/lib/orb/models/prices/external_price_id_fetch_params.rb +7 -1
  204. data/lib/orb/models/prices/external_price_id_update_params.rb +8 -1
  205. data/lib/orb/models/subscription.rb +168 -4
  206. data/lib/orb/models/subscription_cancel_params.rb +8 -1
  207. data/lib/orb/models/subscription_change_apply_params.rb +8 -1
  208. data/lib/orb/models/subscription_change_cancel_params.rb +7 -1
  209. data/lib/orb/models/subscription_change_retrieve_params.rb +7 -1
  210. data/lib/orb/models/subscription_create_params.rb +2818 -674
  211. data/lib/orb/models/subscription_fetch_costs_params.rb +8 -1
  212. data/lib/orb/models/subscription_fetch_params.rb +7 -1
  213. data/lib/orb/models/subscription_fetch_schedule_params.rb +8 -1
  214. data/lib/orb/models/subscription_fetch_usage_params.rb +8 -1
  215. data/lib/orb/models/subscription_price_intervals_params.rb +1103 -55
  216. data/lib/orb/models/subscription_redeem_coupon_params.rb +8 -1
  217. data/lib/orb/models/subscription_schedule_plan_change_params.rb +2839 -685
  218. data/lib/orb/models/subscription_trigger_phase_params.rb +8 -1
  219. data/lib/orb/models/subscription_unschedule_cancellation_params.rb +7 -1
  220. data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_params.rb +8 -1
  221. data/lib/orb/models/subscription_unschedule_pending_plan_changes_params.rb +7 -1
  222. data/lib/orb/models/subscription_update_fixed_fee_quantity_params.rb +8 -1
  223. data/lib/orb/models/subscription_update_params.rb +19 -1
  224. data/lib/orb/models/subscription_update_trial_params.rb +8 -1
  225. data/lib/orb/models.rb +2 -0
  226. data/lib/orb/resources/alerts.rb +20 -2
  227. data/lib/orb/resources/coupons.rb +1 -2
  228. data/lib/orb/resources/credit_blocks.rb +11 -8
  229. data/lib/orb/resources/customers/credits/ledger.rb +40 -81
  230. data/lib/orb/resources/customers.rb +12 -7
  231. data/lib/orb/resources/events/backfills.rb +3 -4
  232. data/lib/orb/resources/events.rb +7 -34
  233. data/lib/orb/resources/invoices.rb +18 -7
  234. data/lib/orb/resources/licenses/external_licenses.rb +1 -1
  235. data/lib/orb/resources/licenses/usage.rb +2 -2
  236. data/lib/orb/resources/metrics.rb +5 -5
  237. data/lib/orb/resources/plans/external_plan_id.rb +5 -3
  238. data/lib/orb/resources/plans.rb +9 -5
  239. data/lib/orb/resources/prices/external_price_id.rb +2 -2
  240. data/lib/orb/resources/prices.rb +13 -104
  241. data/lib/orb/resources/subscriptions.rb +24 -7
  242. data/lib/orb/version.rb +1 -1
  243. data/lib/orb.rb +1 -0
  244. data/rbi/orb/client.rbi +6 -0
  245. data/rbi/orb/internal/util.rbi +8 -0
  246. data/rbi/orb/models/accounting_provider_config.rbi +38 -5
  247. data/rbi/orb/models/adjustment_interval.rbi +336 -0
  248. data/rbi/orb/models/alert.rbi +182 -3
  249. data/rbi/orb/models/alert_create_for_customer_params.rbi +6 -0
  250. data/rbi/orb/models/alert_create_for_external_customer_params.rbi +6 -0
  251. data/rbi/orb/models/alert_create_for_subscription_params.rbi +285 -0
  252. data/rbi/orb/models/alert_disable_params.rbi +6 -0
  253. data/rbi/orb/models/alert_enable_params.rbi +6 -0
  254. data/rbi/orb/models/alert_retrieve_params.rbi +13 -5
  255. data/rbi/orb/models/alert_update_params.rbi +214 -0
  256. data/rbi/orb/models/beta/external_plan_id_create_plan_version_params.rbi +5873 -1161
  257. data/rbi/orb/models/beta/external_plan_id_fetch_plan_version_params.rbi +10 -2
  258. data/rbi/orb/models/beta/external_plan_id_set_default_plan_version_params.rbi +10 -1
  259. data/rbi/orb/models/beta_create_plan_version_params.rbi +5877 -1165
  260. data/rbi/orb/models/beta_fetch_plan_version_params.rbi +10 -2
  261. data/rbi/orb/models/beta_set_default_plan_version_params.rbi +10 -1
  262. data/rbi/orb/models/changed_subscription_resources.rbi +360 -5
  263. data/rbi/orb/models/conversion_rate_config.rbi +18 -0
  264. data/rbi/orb/models/coupon_archive_params.rbi +13 -5
  265. data/rbi/orb/models/coupon_fetch_params.rbi +13 -5
  266. data/rbi/orb/models/coupons/subscription_list_params.rbi +6 -0
  267. data/rbi/orb/models/credit_block_delete_params.rbi +13 -5
  268. data/rbi/orb/models/credit_block_list_invoices_params.rbi +13 -5
  269. data/rbi/orb/models/credit_block_list_invoices_response.rbi +346 -3
  270. data/rbi/orb/models/credit_block_retrieve_params.rbi +13 -5
  271. data/rbi/orb/models/credit_block_retrieve_response.rbi +344 -3
  272. data/rbi/orb/models/credit_note_fetch_params.rbi +13 -5
  273. data/rbi/orb/models/customer.rbi +202 -0
  274. data/rbi/orb/models/customer_create_params.rbi +27 -0
  275. data/rbi/orb/models/customer_delete_params.rbi +13 -5
  276. data/rbi/orb/models/customer_fetch_by_external_id_params.rbi +13 -5
  277. data/rbi/orb/models/customer_fetch_params.rbi +13 -5
  278. data/rbi/orb/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rbi +13 -5
  279. data/rbi/orb/models/customer_sync_payment_methods_from_gateway_params.rbi +13 -5
  280. data/rbi/orb/models/customer_tax_id.rbi +15 -1
  281. data/rbi/orb/models/customer_update_by_external_id_params.rbi +51 -4
  282. data/rbi/orb/models/customer_update_params.rbi +51 -4
  283. data/rbi/orb/models/customers/balance_transaction_create_params.rbi +6 -0
  284. data/rbi/orb/models/customers/balance_transaction_list_params.rbi +6 -0
  285. data/rbi/orb/models/customers/cost_list_by_external_id_params.rbi +6 -0
  286. data/rbi/orb/models/customers/cost_list_params.rbi +6 -0
  287. data/rbi/orb/models/customers/credit_list_by_external_id_params.rbi +6 -0
  288. data/rbi/orb/models/customers/credit_list_by_external_id_response.rbi +346 -3
  289. data/rbi/orb/models/customers/credit_list_params.rbi +6 -0
  290. data/rbi/orb/models/customers/credit_list_response.rbi +347 -3
  291. data/rbi/orb/models/customers/credits/decrement_ledger_entry.rbi +4 -0
  292. data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbi +861 -478
  293. data/rbi/orb/models/customers/credits/ledger_create_entry_params.rbi +861 -478
  294. data/rbi/orb/models/customers/credits/ledger_list_by_external_id_params.rbi +6 -0
  295. data/rbi/orb/models/customers/credits/ledger_list_params.rbi +6 -0
  296. data/rbi/orb/models/customers/credits/top_up_create_by_external_id_params.rbi +6 -0
  297. data/rbi/orb/models/customers/credits/top_up_create_params.rbi +6 -0
  298. data/rbi/orb/models/customers/credits/top_up_delete_by_external_id_params.rbi +6 -1
  299. data/rbi/orb/models/customers/credits/top_up_delete_params.rbi +10 -2
  300. data/rbi/orb/models/customers/credits/top_up_list_by_external_id_params.rbi +6 -0
  301. data/rbi/orb/models/customers/credits/top_up_list_params.rbi +6 -0
  302. data/rbi/orb/models/dimensional_price_group.rbi +1 -1
  303. data/rbi/orb/models/dimensional_price_group_retrieve_params.rbi +16 -5
  304. data/rbi/orb/models/dimensional_price_group_update_params.rbi +6 -0
  305. data/rbi/orb/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rbi +16 -5
  306. data/rbi/orb/models/dimensional_price_groups/external_dimensional_price_group_id_update_params.rbi +6 -0
  307. data/rbi/orb/models/discount.rbi +269 -1
  308. data/rbi/orb/models/event_deprecate_params.rbi +13 -5
  309. data/rbi/orb/models/event_ingest_params.rbi +4 -2
  310. data/rbi/orb/models/event_update_params.rbi +6 -0
  311. data/rbi/orb/models/events/backfill_close_params.rbi +13 -5
  312. data/rbi/orb/models/events/backfill_fetch_params.rbi +13 -5
  313. data/rbi/orb/models/events/backfill_revert_params.rbi +13 -5
  314. data/rbi/orb/models/invoice.rbi +360 -5
  315. data/rbi/orb/models/invoice_create_params.rbi +12 -7
  316. data/rbi/orb/models/invoice_delete_line_item_params.rbi +10 -2
  317. data/rbi/orb/models/invoice_fetch_params.rbi +13 -5
  318. data/rbi/orb/models/invoice_fetch_upcoming_response.rbi +360 -5
  319. data/rbi/orb/models/invoice_issue_params.rbi +10 -1
  320. data/rbi/orb/models/invoice_issue_summary_params.rbi +10 -1
  321. data/rbi/orb/models/invoice_issue_summary_response.rbi +19 -4
  322. data/rbi/orb/models/invoice_level_discount.rbi +298 -1
  323. data/rbi/orb/models/invoice_line_item_create_response.rbi +339 -0
  324. data/rbi/orb/models/invoice_list_summary_response.rbi +19 -4
  325. data/rbi/orb/models/invoice_mark_paid_params.rbi +6 -0
  326. data/rbi/orb/models/invoice_pay_params.rbi +27 -5
  327. data/rbi/orb/models/invoice_update_params.rbi +6 -0
  328. data/rbi/orb/models/invoice_void_params.rbi +13 -5
  329. data/rbi/orb/models/item_archive_params.rbi +13 -5
  330. data/rbi/orb/models/item_fetch_params.rbi +13 -5
  331. data/rbi/orb/models/item_update_params.rbi +6 -0
  332. data/rbi/orb/models/license_deactivate_params.rbi +10 -1
  333. data/rbi/orb/models/license_retrieve_by_external_id_params.rbi +6 -0
  334. data/rbi/orb/models/license_retrieve_params.rbi +13 -5
  335. data/rbi/orb/models/license_type_retrieve_params.rbi +13 -5
  336. data/rbi/orb/models/licenses/external_license_get_usage_params.rbi +9 -3
  337. data/rbi/orb/models/licenses/usage_get_all_usage_params.rbi +3 -3
  338. data/rbi/orb/models/licenses/usage_get_usage_params.rbi +9 -3
  339. data/rbi/orb/models/metric_fetch_params.rbi +13 -5
  340. data/rbi/orb/models/metric_update_params.rbi +6 -0
  341. data/rbi/orb/models/mutated_subscription.rbi +324 -2
  342. data/rbi/orb/models/new_allocation_price.rbi +12 -0
  343. data/rbi/orb/models/per_price_cost.rbi +3 -0
  344. data/rbi/orb/models/plan.rbi +339 -2
  345. data/rbi/orb/models/plan_create_params.rbi +2566 -209
  346. data/rbi/orb/models/plan_fetch_params.rbi +13 -5
  347. data/rbi/orb/models/plan_update_params.rbi +14 -0
  348. data/rbi/orb/models/plan_version.rbi +339 -0
  349. data/rbi/orb/models/plans/external_plan_id_fetch_params.rbi +13 -5
  350. data/rbi/orb/models/plans/external_plan_id_update_params.rbi +14 -0
  351. data/rbi/orb/models/plans/migration_cancel_params.rbi +10 -2
  352. data/rbi/orb/models/plans/migration_cancel_response.rbi +22 -1
  353. data/rbi/orb/models/plans/migration_list_params.rbi +6 -0
  354. data/rbi/orb/models/plans/migration_list_response.rbi +22 -1
  355. data/rbi/orb/models/plans/migration_retrieve_params.rbi +10 -2
  356. data/rbi/orb/models/plans/migration_retrieve_response.rbi +22 -1
  357. data/rbi/orb/models/price.rbi +4733 -2280
  358. data/rbi/orb/models/price_create_params.rbi +3022 -2408
  359. data/rbi/orb/models/price_evaluate_multiple_params.rbi +1540 -114
  360. data/rbi/orb/models/price_evaluate_params.rbi +6 -0
  361. data/rbi/orb/models/price_evaluate_preview_events_params.rbi +1540 -114
  362. data/rbi/orb/models/price_fetch_params.rbi +13 -5
  363. data/rbi/orb/models/price_interval.rbi +3 -0
  364. data/rbi/orb/models/price_update_params.rbi +6 -0
  365. data/rbi/orb/models/prices/external_price_id_fetch_params.rbi +13 -5
  366. data/rbi/orb/models/prices/external_price_id_update_params.rbi +6 -0
  367. data/rbi/orb/models/subscription.rbi +324 -2
  368. data/rbi/orb/models/subscription_cancel_params.rbi +6 -0
  369. data/rbi/orb/models/subscription_change_apply_params.rbi +6 -0
  370. data/rbi/orb/models/subscription_change_cancel_params.rbi +16 -5
  371. data/rbi/orb/models/subscription_change_retrieve_params.rbi +16 -5
  372. data/rbi/orb/models/subscription_create_params.rbi +4998 -1186
  373. data/rbi/orb/models/subscription_fetch_costs_params.rbi +6 -0
  374. data/rbi/orb/models/subscription_fetch_params.rbi +13 -5
  375. data/rbi/orb/models/subscription_fetch_schedule_params.rbi +6 -0
  376. data/rbi/orb/models/subscription_fetch_usage_params.rbi +6 -0
  377. data/rbi/orb/models/subscription_price_intervals_params.rbi +2133 -264
  378. data/rbi/orb/models/subscription_redeem_coupon_params.rbi +6 -0
  379. data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +5001 -1183
  380. data/rbi/orb/models/subscription_trigger_phase_params.rbi +6 -0
  381. data/rbi/orb/models/subscription_unschedule_cancellation_params.rbi +13 -5
  382. data/rbi/orb/models/subscription_unschedule_fixed_fee_quantity_updates_params.rbi +10 -1
  383. data/rbi/orb/models/subscription_unschedule_pending_plan_changes_params.rbi +13 -5
  384. data/rbi/orb/models/subscription_update_fixed_fee_quantity_params.rbi +6 -0
  385. data/rbi/orb/models/subscription_update_params.rbi +20 -0
  386. data/rbi/orb/models/subscription_update_trial_params.rbi +6 -0
  387. data/rbi/orb/models.rbi +2 -0
  388. data/rbi/orb/resources/alerts.rbi +43 -0
  389. data/rbi/orb/resources/coupons.rbi +1 -2
  390. data/rbi/orb/resources/credit_blocks.rbi +10 -7
  391. data/rbi/orb/resources/customers/credits/ledger.rbi +50 -146
  392. data/rbi/orb/resources/customers.rbi +35 -7
  393. data/rbi/orb/resources/events/backfills.rbi +3 -4
  394. data/rbi/orb/resources/events.rbi +8 -35
  395. data/rbi/orb/resources/invoices.rbi +20 -6
  396. data/rbi/orb/resources/licenses/external_licenses.rbi +1 -1
  397. data/rbi/orb/resources/licenses/usage.rbi +2 -2
  398. data/rbi/orb/resources/metrics.rbi +5 -5
  399. data/rbi/orb/resources/plans/external_plan_id.rbi +5 -2
  400. data/rbi/orb/resources/plans.rbi +9 -3
  401. data/rbi/orb/resources/prices.rbi +38 -184
  402. data/rbi/orb/resources/subscriptions.rbi +33 -4
  403. data/sig/orb/client.rbs +3 -0
  404. data/sig/orb/internal/util.rbs +4 -0
  405. data/sig/orb/models/accounting_provider_config.rbs +21 -4
  406. data/sig/orb/models/adjustment_interval.rbs +134 -0
  407. data/sig/orb/models/alert.rbs +90 -3
  408. data/sig/orb/models/alert_create_for_customer_params.rbs +5 -0
  409. data/sig/orb/models/alert_create_for_external_customer_params.rbs +5 -0
  410. data/sig/orb/models/alert_create_for_subscription_params.rbs +98 -1
  411. data/sig/orb/models/alert_disable_params.rbs +6 -1
  412. data/sig/orb/models/alert_enable_params.rbs +6 -1
  413. data/sig/orb/models/alert_retrieve_params.rbs +9 -3
  414. data/sig/orb/models/alert_update_params.rbs +90 -1
  415. data/sig/orb/models/beta/external_plan_id_create_plan_version_params.rbs +2318 -397
  416. data/sig/orb/models/beta/external_plan_id_fetch_plan_version_params.rbs +6 -1
  417. data/sig/orb/models/beta/external_plan_id_set_default_plan_version_params.rbs +6 -1
  418. data/sig/orb/models/beta_create_plan_version_params.rbs +2300 -389
  419. data/sig/orb/models/beta_fetch_plan_version_params.rbs +10 -2
  420. data/sig/orb/models/beta_set_default_plan_version_params.rbs +10 -2
  421. data/sig/orb/models/changed_subscription_resources.rbs +140 -1
  422. data/sig/orb/models/conversion_rate_config.rbs +12 -0
  423. data/sig/orb/models/coupon_archive_params.rbs +12 -3
  424. data/sig/orb/models/coupon_fetch_params.rbs +12 -3
  425. data/sig/orb/models/coupons/subscription_list_params.rbs +5 -1
  426. data/sig/orb/models/credit_block_delete_params.rbs +8 -3
  427. data/sig/orb/models/credit_block_list_invoices_params.rbs +8 -3
  428. data/sig/orb/models/credit_block_list_invoices_response.rbs +124 -3
  429. data/sig/orb/models/credit_block_retrieve_params.rbs +8 -3
  430. data/sig/orb/models/credit_block_retrieve_response.rbs +124 -3
  431. data/sig/orb/models/credit_note_fetch_params.rbs +11 -3
  432. data/sig/orb/models/customer.rbs +79 -1
  433. data/sig/orb/models/customer_create_params.rbs +12 -1
  434. data/sig/orb/models/customer_delete_params.rbs +12 -3
  435. data/sig/orb/models/customer_fetch_by_external_id_params.rbs +11 -3
  436. data/sig/orb/models/customer_fetch_params.rbs +12 -3
  437. data/sig/orb/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rbs +11 -3
  438. data/sig/orb/models/customer_sync_payment_methods_from_gateway_params.rbs +11 -3
  439. data/sig/orb/models/customer_tax_id.rbs +20 -2
  440. data/sig/orb/models/customer_update_by_external_id_params.rbs +22 -1
  441. data/sig/orb/models/customer_update_params.rbs +22 -1
  442. data/sig/orb/models/customers/balance_transaction_create_params.rbs +5 -0
  443. data/sig/orb/models/customers/balance_transaction_list_params.rbs +5 -0
  444. data/sig/orb/models/customers/cost_list_by_external_id_params.rbs +5 -0
  445. data/sig/orb/models/customers/cost_list_params.rbs +5 -0
  446. data/sig/orb/models/customers/credit_list_by_external_id_params.rbs +5 -0
  447. data/sig/orb/models/customers/credit_list_by_external_id_response.rbs +124 -3
  448. data/sig/orb/models/customers/credit_list_params.rbs +5 -0
  449. data/sig/orb/models/customers/credit_list_response.rbs +124 -3
  450. data/sig/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbs +345 -157
  451. data/sig/orb/models/customers/credits/ledger_create_entry_params.rbs +345 -157
  452. data/sig/orb/models/customers/credits/ledger_list_by_external_id_params.rbs +5 -0
  453. data/sig/orb/models/customers/credits/ledger_list_params.rbs +5 -0
  454. data/sig/orb/models/customers/credits/top_up_create_by_external_id_params.rbs +5 -0
  455. data/sig/orb/models/customers/credits/top_up_create_params.rbs +5 -0
  456. data/sig/orb/models/customers/credits/top_up_delete_by_external_id_params.rbs +5 -1
  457. data/sig/orb/models/customers/credits/top_up_delete_params.rbs +6 -1
  458. data/sig/orb/models/customers/credits/top_up_list_by_external_id_params.rbs +5 -1
  459. data/sig/orb/models/customers/credits/top_up_list_params.rbs +5 -1
  460. data/sig/orb/models/dimensional_price_group_retrieve_params.rbs +12 -3
  461. data/sig/orb/models/dimensional_price_group_update_params.rbs +5 -0
  462. data/sig/orb/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rbs +12 -3
  463. data/sig/orb/models/dimensional_price_groups/external_dimensional_price_group_id_update_params.rbs +5 -0
  464. data/sig/orb/models/discount.rbs +114 -0
  465. data/sig/orb/models/event_deprecate_params.rbs +9 -3
  466. data/sig/orb/models/event_update_params.rbs +5 -0
  467. data/sig/orb/models/events/backfill_close_params.rbs +11 -3
  468. data/sig/orb/models/events/backfill_fetch_params.rbs +11 -3
  469. data/sig/orb/models/events/backfill_revert_params.rbs +11 -3
  470. data/sig/orb/models/invoice.rbs +140 -1
  471. data/sig/orb/models/invoice_delete_line_item_params.rbs +6 -1
  472. data/sig/orb/models/invoice_fetch_params.rbs +12 -3
  473. data/sig/orb/models/invoice_fetch_upcoming_response.rbs +140 -1
  474. data/sig/orb/models/invoice_issue_params.rbs +6 -1
  475. data/sig/orb/models/invoice_issue_summary_params.rbs +6 -1
  476. data/sig/orb/models/invoice_issue_summary_response.rbs +2 -1
  477. data/sig/orb/models/invoice_level_discount.rbs +117 -1
  478. data/sig/orb/models/invoice_line_item_create_response.rbs +134 -0
  479. data/sig/orb/models/invoice_list_summary_response.rbs +2 -1
  480. data/sig/orb/models/invoice_mark_paid_params.rbs +10 -1
  481. data/sig/orb/models/invoice_pay_params.rbs +17 -3
  482. data/sig/orb/models/invoice_update_params.rbs +5 -0
  483. data/sig/orb/models/invoice_void_params.rbs +12 -3
  484. data/sig/orb/models/item_archive_params.rbs +9 -3
  485. data/sig/orb/models/item_fetch_params.rbs +9 -3
  486. data/sig/orb/models/item_update_params.rbs +5 -0
  487. data/sig/orb/models/license_deactivate_params.rbs +10 -2
  488. data/sig/orb/models/license_retrieve_by_external_id_params.rbs +9 -1
  489. data/sig/orb/models/license_retrieve_params.rbs +11 -3
  490. data/sig/orb/models/license_type_retrieve_params.rbs +11 -3
  491. data/sig/orb/models/licenses/external_license_get_usage_params.rbs +9 -4
  492. data/sig/orb/models/licenses/usage_get_all_usage_params.rbs +4 -4
  493. data/sig/orb/models/licenses/usage_get_usage_params.rbs +9 -4
  494. data/sig/orb/models/metric_fetch_params.rbs +12 -3
  495. data/sig/orb/models/metric_update_params.rbs +5 -1
  496. data/sig/orb/models/mutated_subscription.rbs +124 -0
  497. data/sig/orb/models/new_allocation_price.rbs +5 -0
  498. data/sig/orb/models/new_floating_bulk_price.rbs +4 -4
  499. data/sig/orb/models/new_floating_bulk_with_proration_price.rbs +4 -4
  500. data/sig/orb/models/new_floating_cumulative_grouped_bulk_price.rbs +4 -4
  501. data/sig/orb/models/new_floating_grouped_allocation_price.rbs +4 -4
  502. data/sig/orb/models/new_floating_grouped_tiered_package_price.rbs +4 -4
  503. data/sig/orb/models/new_floating_grouped_tiered_price.rbs +4 -4
  504. data/sig/orb/models/new_floating_grouped_with_metered_minimum_price.rbs +4 -4
  505. data/sig/orb/models/new_floating_grouped_with_prorated_minimum_price.rbs +4 -4
  506. data/sig/orb/models/new_floating_matrix_price.rbs +4 -4
  507. data/sig/orb/models/new_floating_matrix_with_allocation_price.rbs +4 -4
  508. data/sig/orb/models/new_floating_matrix_with_display_name_price.rbs +4 -4
  509. data/sig/orb/models/new_floating_max_group_tiered_package_price.rbs +4 -4
  510. data/sig/orb/models/new_floating_minimum_composite_price.rbs +4 -4
  511. data/sig/orb/models/new_floating_package_price.rbs +4 -4
  512. data/sig/orb/models/new_floating_package_with_allocation_price.rbs +4 -4
  513. data/sig/orb/models/new_floating_scalable_matrix_with_tiered_pricing_price.rbs +4 -4
  514. data/sig/orb/models/new_floating_scalable_matrix_with_unit_pricing_price.rbs +4 -4
  515. data/sig/orb/models/new_floating_threshold_total_amount_price.rbs +4 -4
  516. data/sig/orb/models/new_floating_tiered_package_price.rbs +4 -4
  517. data/sig/orb/models/new_floating_tiered_package_with_minimum_price.rbs +4 -4
  518. data/sig/orb/models/new_floating_tiered_price.rbs +4 -4
  519. data/sig/orb/models/new_floating_tiered_with_minimum_price.rbs +4 -4
  520. data/sig/orb/models/new_floating_tiered_with_proration_price.rbs +4 -4
  521. data/sig/orb/models/new_floating_unit_price.rbs +4 -4
  522. data/sig/orb/models/new_floating_unit_with_percent_price.rbs +4 -4
  523. data/sig/orb/models/new_floating_unit_with_proration_price.rbs +4 -4
  524. data/sig/orb/models/new_plan_bulk_price.rbs +4 -4
  525. data/sig/orb/models/new_plan_bulk_with_proration_price.rbs +4 -4
  526. data/sig/orb/models/new_plan_cumulative_grouped_bulk_price.rbs +4 -4
  527. data/sig/orb/models/new_plan_grouped_allocation_price.rbs +4 -4
  528. data/sig/orb/models/new_plan_grouped_tiered_package_price.rbs +4 -4
  529. data/sig/orb/models/new_plan_grouped_tiered_price.rbs +4 -4
  530. data/sig/orb/models/new_plan_grouped_with_metered_minimum_price.rbs +4 -4
  531. data/sig/orb/models/new_plan_grouped_with_prorated_minimum_price.rbs +4 -4
  532. data/sig/orb/models/new_plan_matrix_price.rbs +4 -4
  533. data/sig/orb/models/new_plan_matrix_with_allocation_price.rbs +4 -4
  534. data/sig/orb/models/new_plan_matrix_with_display_name_price.rbs +4 -4
  535. data/sig/orb/models/new_plan_max_group_tiered_package_price.rbs +4 -4
  536. data/sig/orb/models/new_plan_minimum_composite_price.rbs +4 -4
  537. data/sig/orb/models/new_plan_package_price.rbs +4 -4
  538. data/sig/orb/models/new_plan_package_with_allocation_price.rbs +4 -4
  539. data/sig/orb/models/new_plan_scalable_matrix_with_tiered_pricing_price.rbs +4 -4
  540. data/sig/orb/models/new_plan_scalable_matrix_with_unit_pricing_price.rbs +4 -4
  541. data/sig/orb/models/new_plan_threshold_total_amount_price.rbs +4 -4
  542. data/sig/orb/models/new_plan_tiered_package_price.rbs +4 -4
  543. data/sig/orb/models/new_plan_tiered_package_with_minimum_price.rbs +4 -4
  544. data/sig/orb/models/new_plan_tiered_price.rbs +4 -4
  545. data/sig/orb/models/new_plan_tiered_with_minimum_price.rbs +4 -4
  546. data/sig/orb/models/new_plan_unit_price.rbs +4 -4
  547. data/sig/orb/models/new_plan_unit_with_percent_price.rbs +4 -4
  548. data/sig/orb/models/new_plan_unit_with_proration_price.rbs +4 -4
  549. data/sig/orb/models/new_subscription_bulk_price.rbs +4 -4
  550. data/sig/orb/models/new_subscription_bulk_with_proration_price.rbs +4 -4
  551. data/sig/orb/models/new_subscription_cumulative_grouped_bulk_price.rbs +4 -4
  552. data/sig/orb/models/new_subscription_grouped_allocation_price.rbs +4 -4
  553. data/sig/orb/models/new_subscription_grouped_tiered_package_price.rbs +4 -4
  554. data/sig/orb/models/new_subscription_grouped_tiered_price.rbs +4 -4
  555. data/sig/orb/models/new_subscription_grouped_with_metered_minimum_price.rbs +4 -4
  556. data/sig/orb/models/new_subscription_grouped_with_prorated_minimum_price.rbs +4 -4
  557. data/sig/orb/models/new_subscription_matrix_price.rbs +4 -4
  558. data/sig/orb/models/new_subscription_matrix_with_allocation_price.rbs +4 -4
  559. data/sig/orb/models/new_subscription_matrix_with_display_name_price.rbs +4 -4
  560. data/sig/orb/models/new_subscription_max_group_tiered_package_price.rbs +4 -4
  561. data/sig/orb/models/new_subscription_minimum_composite_price.rbs +4 -4
  562. data/sig/orb/models/new_subscription_package_price.rbs +4 -4
  563. data/sig/orb/models/new_subscription_package_with_allocation_price.rbs +4 -4
  564. data/sig/orb/models/new_subscription_scalable_matrix_with_tiered_pricing_price.rbs +4 -4
  565. data/sig/orb/models/new_subscription_scalable_matrix_with_unit_pricing_price.rbs +4 -4
  566. data/sig/orb/models/new_subscription_threshold_total_amount_price.rbs +4 -4
  567. data/sig/orb/models/new_subscription_tiered_package_price.rbs +4 -4
  568. data/sig/orb/models/new_subscription_tiered_package_with_minimum_price.rbs +4 -4
  569. data/sig/orb/models/new_subscription_tiered_price.rbs +4 -4
  570. data/sig/orb/models/new_subscription_tiered_with_minimum_price.rbs +4 -4
  571. data/sig/orb/models/new_subscription_unit_price.rbs +4 -4
  572. data/sig/orb/models/new_subscription_unit_with_percent_price.rbs +4 -4
  573. data/sig/orb/models/new_subscription_unit_with_proration_price.rbs +4 -4
  574. data/sig/orb/models/plan.rbs +134 -0
  575. data/sig/orb/models/plan_create_params.rbs +1030 -72
  576. data/sig/orb/models/plan_fetch_params.rbs +9 -3
  577. data/sig/orb/models/plan_update_params.rbs +14 -1
  578. data/sig/orb/models/plan_version.rbs +134 -0
  579. data/sig/orb/models/plans/external_plan_id_fetch_params.rbs +11 -3
  580. data/sig/orb/models/plans/external_plan_id_update_params.rbs +14 -1
  581. data/sig/orb/models/plans/migration_cancel_params.rbs +6 -1
  582. data/sig/orb/models/plans/migration_list_params.rbs +5 -1
  583. data/sig/orb/models/plans/migration_retrieve_params.rbs +6 -1
  584. data/sig/orb/models/price.rbs +2361 -1156
  585. data/sig/orb/models/price_create_params.rbs +1124 -931
  586. data/sig/orb/models/price_evaluate_multiple_params.rbs +626 -23
  587. data/sig/orb/models/price_evaluate_params.rbs +5 -0
  588. data/sig/orb/models/price_evaluate_preview_events_params.rbs +626 -23
  589. data/sig/orb/models/price_fetch_params.rbs +9 -3
  590. data/sig/orb/models/price_update_params.rbs +5 -1
  591. data/sig/orb/models/prices/external_price_id_fetch_params.rbs +11 -3
  592. data/sig/orb/models/prices/external_price_id_update_params.rbs +5 -1
  593. data/sig/orb/models/subscription.rbs +124 -0
  594. data/sig/orb/models/subscription_cancel_params.rbs +5 -0
  595. data/sig/orb/models/subscription_change_apply_params.rbs +5 -0
  596. data/sig/orb/models/subscription_change_cancel_params.rbs +12 -3
  597. data/sig/orb/models/subscription_change_retrieve_params.rbs +12 -3
  598. data/sig/orb/models/subscription_create_params.rbs +2009 -430
  599. data/sig/orb/models/subscription_fetch_costs_params.rbs +5 -0
  600. data/sig/orb/models/subscription_fetch_params.rbs +11 -3
  601. data/sig/orb/models/subscription_fetch_schedule_params.rbs +5 -0
  602. data/sig/orb/models/subscription_fetch_usage_params.rbs +5 -0
  603. data/sig/orb/models/subscription_price_intervals_params.rbs +800 -23
  604. data/sig/orb/models/subscription_redeem_coupon_params.rbs +5 -0
  605. data/sig/orb/models/subscription_schedule_plan_change_params.rbs +2014 -430
  606. data/sig/orb/models/subscription_trigger_phase_params.rbs +9 -1
  607. data/sig/orb/models/subscription_unschedule_cancellation_params.rbs +11 -3
  608. data/sig/orb/models/subscription_unschedule_fixed_fee_quantity_updates_params.rbs +10 -2
  609. data/sig/orb/models/subscription_unschedule_pending_plan_changes_params.rbs +11 -3
  610. data/sig/orb/models/subscription_update_fixed_fee_quantity_params.rbs +5 -0
  611. data/sig/orb/models/subscription_update_params.rbs +10 -0
  612. data/sig/orb/models/subscription_update_trial_params.rbs +5 -0
  613. data/sig/orb/models.rbs +2 -0
  614. data/sig/orb/resources/alerts.rbs +6 -0
  615. data/sig/orb/resources/customers/credits/ledger.rbs +2 -26
  616. data/sig/orb/resources/customers.rbs +2 -0
  617. data/sig/orb/resources/invoices.rbs +1 -0
  618. data/sig/orb/resources/licenses/external_licenses.rbs +1 -1
  619. data/sig/orb/resources/licenses/usage.rbs +2 -2
  620. data/sig/orb/resources/plans/external_plan_id.rbs +1 -0
  621. data/sig/orb/resources/plans.rbs +2 -0
  622. data/sig/orb/resources/prices.rbs +1 -48
  623. data/sig/orb/resources/subscriptions.rbs +3 -0
  624. metadata +6 -7
@@ -8,6 +8,11 @@ module Orb
8
8
  extend Orb::Internal::Type::RequestParameters::Converter
9
9
  include Orb::Internal::Type::RequestParameters
10
10
 
11
+ # @!attribute external_plan_id
12
+ #
13
+ # @return [String]
14
+ required :external_plan_id, String
15
+
11
16
  # @!attribute version
12
17
  # New version number.
13
18
  #
@@ -80,7 +85,9 @@ module Orb
80
85
  # @return [Boolean, nil]
81
86
  optional :set_as_default, Orb::Internal::Type::Boolean, nil?: true
82
87
 
83
- # @!method initialize(version:, add_adjustments: nil, add_prices: nil, remove_adjustments: nil, remove_prices: nil, replace_adjustments: nil, replace_prices: nil, set_as_default: nil, request_options: {})
88
+ # @!method initialize(external_plan_id:, version:, add_adjustments: nil, add_prices: nil, remove_adjustments: nil, remove_prices: nil, replace_adjustments: nil, replace_prices: nil, set_as_default: nil, request_options: {})
89
+ # @param external_plan_id [String]
90
+ #
84
91
  # @param version [Integer] New version number.
85
92
  #
86
93
  # @param add_adjustments [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment>, nil] Additional adjustments to be added to the plan.
@@ -103,7 +110,7 @@ module Orb
103
110
  # @!attribute adjustment
104
111
  # The definition of a new adjustment to create and add to the plan.
105
112
  #
106
- # @return [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum]
113
+ # @return [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount]
107
114
  required :adjustment,
108
115
  union: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment }
109
116
 
@@ -114,7 +121,7 @@ module Orb
114
121
  optional :plan_phase_order, Integer, nil?: true
115
122
 
116
123
  # @!method initialize(adjustment:, plan_phase_order: nil)
117
- # @param adjustment [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum] The definition of a new adjustment to create and add to the plan.
124
+ # @param adjustment [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount] The definition of a new adjustment to create and add to the plan.
118
125
  #
119
126
  # @param plan_phase_order [Integer, nil] The phase to add this adjustment to.
120
127
 
@@ -136,8 +143,221 @@ module Orb
136
143
 
137
144
  variant :maximum, -> { Orb::NewMaximum }
138
145
 
146
+ variant :tiered_percentage_discount,
147
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount }
148
+
149
+ class TieredPercentageDiscount < Orb::Internal::Type::BaseModel
150
+ # @!attribute adjustment_type
151
+ #
152
+ # @return [Symbol, :tiered_percentage_discount]
153
+ required :adjustment_type, const: :tiered_percentage_discount
154
+
155
+ # @!attribute tiers
156
+ #
157
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Tier>]
158
+ required :tiers,
159
+ -> do
160
+ Orb::Internal::Type::ArrayOf[
161
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Tier
162
+ ]
163
+ end
164
+
165
+ # @!attribute applies_to_all
166
+ # If set, the adjustment will apply to every price on the subscription.
167
+ #
168
+ # @return [Boolean, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::AppliesToAll, nil]
169
+ optional :applies_to_all,
170
+ enum: -> {
171
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::AppliesToAll
172
+ },
173
+ nil?: true
174
+
175
+ # @!attribute applies_to_item_ids
176
+ # The set of item IDs to which this adjustment applies.
177
+ #
178
+ # @return [Array<String>, nil]
179
+ optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
180
+
181
+ # @!attribute applies_to_price_ids
182
+ # The set of price IDs to which this adjustment applies.
183
+ #
184
+ # @return [Array<String>, nil]
185
+ optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
186
+
187
+ # @!attribute currency
188
+ # If set, only prices in the specified currency will have the adjustment applied.
189
+ #
190
+ # @return [String, nil]
191
+ optional :currency, String, nil?: true
192
+
193
+ # @!attribute filters
194
+ # A list of filters that determine which prices this adjustment will apply to.
195
+ #
196
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter>, nil]
197
+ optional :filters,
198
+ -> do
199
+ Orb::Internal::Type::ArrayOf[
200
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter
201
+ ]
202
+ end,
203
+ nil?: true
204
+
205
+ # @!attribute is_invoice_level
206
+ # When false, this adjustment will be applied to a single price. Otherwise, it
207
+ # will be applied at the invoice level, possibly to multiple prices.
208
+ #
209
+ # @return [Boolean, nil]
210
+ optional :is_invoice_level, Orb::Internal::Type::Boolean
211
+
212
+ # @!attribute price_type
213
+ # If set, only prices of the specified type will have the adjustment applied.
214
+ #
215
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::PriceType, nil]
216
+ optional :price_type,
217
+ enum: -> {
218
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::PriceType
219
+ },
220
+ nil?: true
221
+
222
+ # @!method initialize(tiers:, applies_to_all: nil, applies_to_item_ids: nil, applies_to_price_ids: nil, currency: nil, filters: nil, is_invoice_level: nil, price_type: nil, adjustment_type: :tiered_percentage_discount)
223
+ # Some parameter documentations has been truncated, see
224
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount}
225
+ # for more details.
226
+ #
227
+ # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Tier>]
228
+ #
229
+ # @param applies_to_all [Boolean, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
230
+ #
231
+ # @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
232
+ #
233
+ # @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
234
+ #
235
+ # @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
236
+ #
237
+ # @param filters [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
238
+ #
239
+ # @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
240
+ #
241
+ # @param price_type [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
242
+ #
243
+ # @param adjustment_type [Symbol, :tiered_percentage_discount]
244
+
245
+ class Tier < Orb::Internal::Type::BaseModel
246
+ # @!attribute lower_bound
247
+ # Exclusive lower bound of cumulative spend for this tier.
248
+ #
249
+ # @return [Float]
250
+ required :lower_bound, Float
251
+
252
+ # @!attribute percentage
253
+ # The percentage (0-1) discounted from spend in this tier.
254
+ #
255
+ # @return [Float]
256
+ required :percentage, Float
257
+
258
+ # @!attribute upper_bound
259
+ # Inclusive upper bound of cumulative spend; null for the final open-ended tier.
260
+ #
261
+ # @return [Float, nil]
262
+ optional :upper_bound, Float, nil?: true
263
+
264
+ # @!method initialize(lower_bound:, percentage:, upper_bound: nil)
265
+ # @param lower_bound [Float] Exclusive lower bound of cumulative spend for this tier.
266
+ #
267
+ # @param percentage [Float] The percentage (0-1) discounted from spend in this tier.
268
+ #
269
+ # @param upper_bound [Float, nil] Inclusive upper bound of cumulative spend; null for the final open-ended tier.
270
+ end
271
+
272
+ # If set, the adjustment will apply to every price on the subscription.
273
+ #
274
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount#applies_to_all
275
+ module AppliesToAll
276
+ extend Orb::Internal::Type::Enum
277
+
278
+ TRUE = true
279
+
280
+ # @!method self.values
281
+ # @return [Array<Boolean>]
282
+ end
283
+
284
+ class Filter < Orb::Internal::Type::BaseModel
285
+ # @!attribute field
286
+ # The property of the price to filter on.
287
+ #
288
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter::Field]
289
+ required :field,
290
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter::Field }
291
+
292
+ # @!attribute operator
293
+ # Should prices that match the filter be included or excluded.
294
+ #
295
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter::Operator]
296
+ required :operator,
297
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter::Operator }
298
+
299
+ # @!attribute values
300
+ # The IDs or values that match this filter.
301
+ #
302
+ # @return [Array<String>]
303
+ required :values, Orb::Internal::Type::ArrayOf[String]
304
+
305
+ # @!method initialize(field:, operator:, values:)
306
+ # @param field [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter::Field] The property of the price to filter on.
307
+ #
308
+ # @param operator [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
309
+ #
310
+ # @param values [Array<String>] The IDs or values that match this filter.
311
+
312
+ # The property of the price to filter on.
313
+ #
314
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter#field
315
+ module Field
316
+ extend Orb::Internal::Type::Enum
317
+
318
+ PRICE_ID = :price_id
319
+ ITEM_ID = :item_id
320
+ PRICE_TYPE = :price_type
321
+ CURRENCY = :currency
322
+ PRICING_UNIT_ID = :pricing_unit_id
323
+
324
+ # @!method self.values
325
+ # @return [Array<Symbol>]
326
+ end
327
+
328
+ # Should prices that match the filter be included or excluded.
329
+ #
330
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount::Filter#operator
331
+ module Operator
332
+ extend Orb::Internal::Type::Enum
333
+
334
+ INCLUDES = :includes
335
+ EXCLUDES = :excludes
336
+
337
+ # @!method self.values
338
+ # @return [Array<Symbol>]
339
+ end
340
+ end
341
+
342
+ # If set, only prices of the specified type will have the adjustment applied.
343
+ #
344
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount#price_type
345
+ module PriceType
346
+ extend Orb::Internal::Type::Enum
347
+
348
+ USAGE = :usage
349
+ FIXED_IN_ADVANCE = :fixed_in_advance
350
+ FIXED_IN_ARREARS = :fixed_in_arrears
351
+ FIXED = :fixed
352
+ IN_ARREARS = :in_arrears
353
+
354
+ # @!method self.values
355
+ # @return [Array<Symbol>]
356
+ end
357
+ end
358
+
139
359
  # @!method self.variants
140
- # @return [Array(Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum)]
360
+ # @return [Array(Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment::TieredPercentageDiscount)]
141
361
  end
142
362
  end
143
363
 
@@ -148,6 +368,14 @@ module Orb
148
368
  # @return [Orb::Models::NewAllocationPrice, nil]
149
369
  optional :allocation_price, -> { Orb::NewAllocationPrice }, nil?: true
150
370
 
371
+ # @!attribute license_allocation_price
372
+ # The license allocation price to add to the plan.
373
+ #
374
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice, nil]
375
+ optional :license_allocation_price,
376
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice },
377
+ nil?: true
378
+
151
379
  # @!attribute plan_phase_order
152
380
  # The phase to add this price to.
153
381
  #
@@ -157,17 +385,263 @@ module Orb
157
385
  # @!attribute price
158
386
  # New plan price request body params.
159
387
  #
160
- # @return [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput, nil]
388
+ # @return [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput, nil]
161
389
  optional :price,
162
390
  union: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price },
163
391
  nil?: true
164
392
 
165
- # @!method initialize(allocation_price: nil, plan_phase_order: nil, price: nil)
393
+ # @!method initialize(allocation_price: nil, license_allocation_price: nil, plan_phase_order: nil, price: nil)
166
394
  # @param allocation_price [Orb::Models::NewAllocationPrice, nil] The allocation price to add to the plan.
167
395
  #
396
+ # @param license_allocation_price [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice, nil] The license allocation price to add to the plan.
397
+ #
168
398
  # @param plan_phase_order [Integer, nil] The phase to add this price to.
169
399
  #
170
- # @param price [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput, nil] New plan price request body params.
400
+ # @param price [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput, nil] New plan price request body params.
401
+
402
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice#license_allocation_price
403
+ class LicenseAllocationPrice < Orb::Internal::Type::BaseModel
404
+ # @!attribute cadence
405
+ # The cadence to bill for this price on.
406
+ #
407
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::Cadence]
408
+ required :cadence,
409
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::Cadence }
410
+
411
+ # @!attribute item_id
412
+ # The id of the item the price will be associated with.
413
+ #
414
+ # @return [String]
415
+ required :item_id, String
416
+
417
+ # @!attribute license_allocations
418
+ # License allocations to associate with this price. Each entry defines a
419
+ # per-license credit pool granted each cadence. Requires license_type_id or
420
+ # license_type_configuration to be set.
421
+ #
422
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::LicenseAllocation>]
423
+ required :license_allocations,
424
+ -> { Orb::Internal::Type::ArrayOf[Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::LicenseAllocation] }
425
+
426
+ # @!attribute model_type
427
+ # The pricing model type
428
+ #
429
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::ModelType]
430
+ required :model_type,
431
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::ModelType }
432
+
433
+ # @!attribute name
434
+ # The name of the price.
435
+ #
436
+ # @return [String]
437
+ required :name, String
438
+
439
+ # @!attribute unit_config
440
+ # Configuration for unit pricing
441
+ #
442
+ # @return [Orb::Models::UnitConfig]
443
+ required :unit_config, -> { Orb::UnitConfig }
444
+
445
+ # @!attribute billable_metric_id
446
+ # The id of the billable metric for the price. Only needed if the price is
447
+ # usage-based.
448
+ #
449
+ # @return [String, nil]
450
+ optional :billable_metric_id, String, nil?: true
451
+
452
+ # @!attribute billed_in_advance
453
+ # If the Price represents a fixed cost, the price will be billed in-advance if
454
+ # this is true, and in-arrears if this is false.
455
+ #
456
+ # @return [Boolean, nil]
457
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
458
+
459
+ # @!attribute billing_cycle_configuration
460
+ # For custom cadence: specifies the duration of the billing period in days or
461
+ # months.
462
+ #
463
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
464
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
465
+
466
+ # @!attribute conversion_rate
467
+ # The per unit conversion rate of the price currency to the invoicing currency.
468
+ #
469
+ # @return [Float, nil]
470
+ optional :conversion_rate, Float, nil?: true
471
+
472
+ # @!attribute conversion_rate_config
473
+ # The configuration for the rate of the price currency to the invoicing currency.
474
+ #
475
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
476
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
477
+
478
+ # @!attribute currency
479
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
480
+ # price is billed.
481
+ #
482
+ # @return [String, nil]
483
+ optional :currency, String, nil?: true
484
+
485
+ # @!attribute dimensional_price_configuration
486
+ # For dimensional price: specifies a price group and dimension values
487
+ #
488
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
489
+ optional :dimensional_price_configuration,
490
+ -> {
491
+ Orb::NewDimensionalPriceConfiguration
492
+ },
493
+ nil?: true
494
+
495
+ # @!attribute external_price_id
496
+ # An alias for the price.
497
+ #
498
+ # @return [String, nil]
499
+ optional :external_price_id, String, nil?: true
500
+
501
+ # @!attribute fixed_price_quantity
502
+ # If the Price represents a fixed cost, this represents the quantity of units
503
+ # applied.
504
+ #
505
+ # @return [Float, nil]
506
+ optional :fixed_price_quantity, Float, nil?: true
507
+
508
+ # @!attribute invoice_grouping_key
509
+ # The property used to group this price on an invoice
510
+ #
511
+ # @return [String, nil]
512
+ optional :invoice_grouping_key, String, nil?: true
513
+
514
+ # @!attribute invoicing_cycle_configuration
515
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
516
+ # If unspecified, a single invoice is produced per billing cycle.
517
+ #
518
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
519
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
520
+
521
+ # @!attribute license_type_id
522
+ # The ID of the license type to associate with this price.
523
+ #
524
+ # @return [String, nil]
525
+ optional :license_type_id, String, nil?: true
526
+
527
+ # @!attribute metadata
528
+ # User-specified key/value pairs for the resource. Individual keys can be removed
529
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
530
+ # by setting `metadata` to `null`.
531
+ #
532
+ # @return [Hash{Symbol=>String, nil}, nil]
533
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
534
+
535
+ # @!attribute reference_id
536
+ # A transient ID that can be used to reference this price when adding adjustments
537
+ # in the same API call.
538
+ #
539
+ # @return [String, nil]
540
+ optional :reference_id, String, nil?: true
541
+
542
+ # @!method initialize(cadence:, item_id:, license_allocations:, model_type:, name:, unit_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil)
543
+ # Some parameter documentations has been truncated, see
544
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice}
545
+ # for more details.
546
+ #
547
+ # The license allocation price to add to the plan.
548
+ #
549
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::Cadence] The cadence to bill for this price on.
550
+ #
551
+ # @param item_id [String] The id of the item the price will be associated with.
552
+ #
553
+ # @param license_allocations [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::LicenseAllocation>] License allocations to associate with this price. Each entry defines a per-licen
554
+ #
555
+ # @param model_type [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice::ModelType] The pricing model type
556
+ #
557
+ # @param name [String] The name of the price.
558
+ #
559
+ # @param unit_config [Orb::Models::UnitConfig] Configuration for unit pricing
560
+ #
561
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
562
+ #
563
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
564
+ #
565
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
566
+ #
567
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
568
+ #
569
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
570
+ #
571
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
572
+ #
573
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
574
+ #
575
+ # @param external_price_id [String, nil] An alias for the price.
576
+ #
577
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
578
+ #
579
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
580
+ #
581
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
582
+ #
583
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
584
+ #
585
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
586
+ #
587
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
588
+
589
+ # The cadence to bill for this price on.
590
+ #
591
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice#cadence
592
+ module Cadence
593
+ extend Orb::Internal::Type::Enum
594
+
595
+ ANNUAL = :annual
596
+ SEMI_ANNUAL = :semi_annual
597
+ MONTHLY = :monthly
598
+ QUARTERLY = :quarterly
599
+ ONE_TIME = :one_time
600
+ CUSTOM = :custom
601
+
602
+ # @!method self.values
603
+ # @return [Array<Symbol>]
604
+ end
605
+
606
+ class LicenseAllocation < Orb::Internal::Type::BaseModel
607
+ # @!attribute amount
608
+ # The amount of credits granted per active license per cadence.
609
+ #
610
+ # @return [String]
611
+ required :amount, String
612
+
613
+ # @!attribute currency
614
+ # The currency of the license allocation.
615
+ #
616
+ # @return [String]
617
+ required :currency, String
618
+
619
+ # @!attribute write_off_overage
620
+ # When True, overage beyond the allocation is written off.
621
+ #
622
+ # @return [Boolean, nil]
623
+ optional :write_off_overage, Orb::Internal::Type::Boolean, nil?: true
624
+
625
+ # @!method initialize(amount:, currency:, write_off_overage: nil)
626
+ # @param amount [String] The amount of credits granted per active license per cadence.
627
+ #
628
+ # @param currency [String] The currency of the license allocation.
629
+ #
630
+ # @param write_off_overage [Boolean, nil] When True, overage beyond the allocation is written off.
631
+ end
632
+
633
+ # The pricing model type
634
+ #
635
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::LicenseAllocationPrice#model_type
636
+ module ModelType
637
+ extend Orb::Internal::Type::Enum
638
+
639
+ UNIT = :unit
640
+
641
+ # @!method self.values
642
+ # @return [Array<Symbol>]
643
+ end
644
+ end
171
645
 
172
646
  # New plan price request body params.
173
647
  #
@@ -206,6 +680,9 @@ module Orb
206
680
 
207
681
  variant :matrix_with_allocation, -> { Orb::NewPlanMatrixWithAllocationPrice }
208
682
 
683
+ variant :matrix_with_threshold_discounts,
684
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts }
685
+
209
686
  variant :tiered_with_proration,
210
687
  -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration }
211
688
 
@@ -237,6 +714,12 @@ module Orb
237
714
  variant :cumulative_grouped_allocation,
238
715
  -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation }
239
716
 
717
+ variant :daily_credit_allowance,
718
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance }
719
+
720
+ variant :metered_allowance,
721
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance }
722
+
240
723
  variant :minimum_composite, -> { Orb::NewPlanMinimumCompositePrice }
241
724
 
242
725
  variant :percent, -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent }
@@ -308,11 +791,7 @@ module Orb
308
791
  # The configuration for the rate of the price currency to the invoicing currency.
309
792
  #
310
793
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
311
- optional :conversion_rate_config,
312
- union: -> {
313
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::BulkWithFilters::ConversionRateConfig
314
- },
315
- nil?: true
794
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
316
795
 
317
796
  # @!attribute currency
318
797
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -513,13 +992,13 @@ module Orb
513
992
  end
514
993
  end
515
994
 
516
- class TieredWithProration < Orb::Internal::Type::BaseModel
995
+ class MatrixWithThresholdDiscounts < Orb::Internal::Type::BaseModel
517
996
  # @!attribute cadence
518
997
  # The cadence to bill for this price on.
519
998
  #
520
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::Cadence]
999
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::Cadence]
521
1000
  required :cadence,
522
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::Cadence }
1001
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::Cadence }
523
1002
 
524
1003
  # @!attribute item_id
525
1004
  # The id of the item the price will be associated with.
@@ -527,11 +1006,18 @@ module Orb
527
1006
  # @return [String]
528
1007
  required :item_id, String
529
1008
 
1009
+ # @!attribute matrix_with_threshold_discounts_config
1010
+ # Configuration for matrix_with_threshold_discounts pricing
1011
+ #
1012
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig]
1013
+ required :matrix_with_threshold_discounts_config,
1014
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig }
1015
+
530
1016
  # @!attribute model_type
531
1017
  # The pricing model type
532
1018
  #
533
- # @return [Symbol, :tiered_with_proration]
534
- required :model_type, const: :tiered_with_proration
1019
+ # @return [Symbol, :matrix_with_threshold_discounts]
1020
+ required :model_type, const: :matrix_with_threshold_discounts
535
1021
 
536
1022
  # @!attribute name
537
1023
  # The name of the price.
@@ -539,13 +1025,6 @@ module Orb
539
1025
  # @return [String]
540
1026
  required :name, String
541
1027
 
542
- # @!attribute tiered_with_proration_config
543
- # Configuration for tiered_with_proration pricing
544
- #
545
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig]
546
- required :tiered_with_proration_config,
547
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig }
548
-
549
1028
  # @!attribute billable_metric_id
550
1029
  # The id of the billable metric for the price. Only needed if the price is
551
1030
  # usage-based.
@@ -577,11 +1056,7 @@ module Orb
577
1056
  # The configuration for the rate of the price currency to the invoicing currency.
578
1057
  #
579
1058
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
580
- optional :conversion_rate_config,
581
- union: -> {
582
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::ConversionRateConfig
583
- },
584
- nil?: true
1059
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
585
1060
 
586
1061
  # @!attribute currency
587
1062
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -647,18 +1122,18 @@ module Orb
647
1122
  # @return [String, nil]
648
1123
  optional :reference_id, String, nil?: true
649
1124
 
650
- # @!method initialize(cadence:, item_id:, name:, tiered_with_proration_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :tiered_with_proration)
1125
+ # @!method initialize(cadence:, item_id:, matrix_with_threshold_discounts_config:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :matrix_with_threshold_discounts)
651
1126
  # Some parameter documentations has been truncated, see
652
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration}
1127
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts}
653
1128
  # for more details.
654
1129
  #
655
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::Cadence] The cadence to bill for this price on.
1130
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::Cadence] The cadence to bill for this price on.
656
1131
  #
657
1132
  # @param item_id [String] The id of the item the price will be associated with.
658
1133
  #
659
- # @param name [String] The name of the price.
1134
+ # @param matrix_with_threshold_discounts_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig] Configuration for matrix_with_threshold_discounts pricing
660
1135
  #
661
- # @param tiered_with_proration_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig] Configuration for tiered_with_proration pricing
1136
+ # @param name [String] The name of the price.
662
1137
  #
663
1138
  # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
664
1139
  #
@@ -688,11 +1163,11 @@ module Orb
688
1163
  #
689
1164
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
690
1165
  #
691
- # @param model_type [Symbol, :tiered_with_proration] The pricing model type
1166
+ # @param model_type [Symbol, :matrix_with_threshold_discounts] The pricing model type
692
1167
 
693
1168
  # The cadence to bill for this price on.
694
1169
  #
695
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration#cadence
1170
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts#cadence
696
1171
  module Cadence
697
1172
  extend Orb::Internal::Type::Enum
698
1173
 
@@ -707,66 +1182,139 @@ module Orb
707
1182
  # @return [Array<Symbol>]
708
1183
  end
709
1184
 
710
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration#tiered_with_proration_config
711
- class TieredWithProrationConfig < Orb::Internal::Type::BaseModel
712
- # @!attribute tiers
713
- # Tiers for rating based on total usage quantities into the specified tier with
714
- # proration
1185
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts#matrix_with_threshold_discounts_config
1186
+ class MatrixWithThresholdDiscountsConfig < Orb::Internal::Type::BaseModel
1187
+ # @!attribute default_unit_amount
1188
+ # Unit price used for usage that does not match any defined matrix cell.
715
1189
  #
716
- # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>]
717
- required :tiers,
1190
+ # @return [String]
1191
+ required :default_unit_amount, String
1192
+
1193
+ # @!attribute first_dimension
1194
+ # First matrix dimension key.
1195
+ #
1196
+ # @return [String]
1197
+ required :first_dimension, String
1198
+
1199
+ # @!attribute matrix_values
1200
+ # Per-cell unit prices.
1201
+ #
1202
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::MatrixValue>]
1203
+ required :matrix_values,
718
1204
  -> do
719
1205
  Orb::Internal::Type::ArrayOf[
720
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig::Tier
1206
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::MatrixValue
721
1207
  ]
722
1208
  end
723
1209
 
724
- # @!method initialize(tiers:)
725
- # Some parameter documentations has been truncated, see
726
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig}
727
- # for more details.
1210
+ # @!attribute second_dimension
1211
+ # Optional second matrix dimension key.
728
1212
  #
729
- # Configuration for tiered_with_proration pricing
1213
+ # @return [String, nil]
1214
+ optional :second_dimension, String, nil?: true
1215
+
1216
+ # @!attribute threshold_discount_groups
730
1217
  #
731
- # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>] Tiers for rating based on total usage quantities into the specified tier with pr
1218
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup>, nil]
1219
+ optional :threshold_discount_groups,
1220
+ -> do
1221
+ Orb::Internal::Type::ArrayOf[
1222
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup
1223
+ ]
1224
+ end
732
1225
 
733
- class Tier < Orb::Internal::Type::BaseModel
734
- # @!attribute tier_lower_bound
735
- # Inclusive tier starting value
1226
+ # @!method initialize(default_unit_amount:, first_dimension:, matrix_values:, second_dimension: nil, threshold_discount_groups: nil)
1227
+ # Configuration for matrix_with_threshold_discounts pricing
1228
+ #
1229
+ # @param default_unit_amount [String] Unit price used for usage that does not match any defined matrix cell.
1230
+ #
1231
+ # @param first_dimension [String] First matrix dimension key.
1232
+ #
1233
+ # @param matrix_values [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::MatrixValue>] Per-cell unit prices.
1234
+ #
1235
+ # @param second_dimension [String, nil] Optional second matrix dimension key.
1236
+ #
1237
+ # @param threshold_discount_groups [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup>]
1238
+
1239
+ class MatrixValue < Orb::Internal::Type::BaseModel
1240
+ # @!attribute first_dimension_value
736
1241
  #
737
1242
  # @return [String]
738
- required :tier_lower_bound, String
1243
+ required :first_dimension_value, String
739
1244
 
740
1245
  # @!attribute unit_amount
741
- # Amount per unit
742
1246
  #
743
1247
  # @return [String]
744
1248
  required :unit_amount, String
745
1249
 
746
- # @!method initialize(tier_lower_bound:, unit_amount:)
747
- # Configuration for a single tiered with proration tier
1250
+ # @!attribute second_dimension_value
748
1251
  #
749
- # @param tier_lower_bound [String] Inclusive tier starting value
1252
+ # @return [String, nil]
1253
+ optional :second_dimension_value, String, nil?: true
1254
+
1255
+ # @!method initialize(first_dimension_value:, unit_amount:, second_dimension_value: nil)
1256
+ # @param first_dimension_value [String]
1257
+ # @param unit_amount [String]
1258
+ # @param second_dimension_value [String, nil]
1259
+ end
1260
+
1261
+ class ThresholdDiscountGroup < Orb::Internal::Type::BaseModel
1262
+ # @!attribute above_threshold_discount_percentage
1263
+ # Discount rate applied to spend above the threshold.
750
1264
  #
751
- # @param unit_amount [String] Amount per unit
1265
+ # @return [String]
1266
+ required :above_threshold_discount_percentage, String
1267
+
1268
+ # @!attribute below_threshold_discount_percentage
1269
+ # Discount rate applied to spend at or below the threshold. Set to 0 for no
1270
+ # baseline discount.
1271
+ #
1272
+ # @return [String]
1273
+ required :below_threshold_discount_percentage, String
1274
+
1275
+ # @!attribute cell_coordinates
1276
+ # Semicolon-separated list of matrix cell coordinates targeted by this group. Each
1277
+ # coordinate is `first,second` when the matrix has two dimensions, or just `first`
1278
+ # for a single-dimension matrix. Example: `blue,circle;green,triangle`.
1279
+ #
1280
+ # @return [String]
1281
+ required :cell_coordinates, String
1282
+
1283
+ # @!attribute threshold_amount
1284
+ #
1285
+ # @return [String]
1286
+ required :threshold_amount, String
1287
+
1288
+ # @!attribute description
1289
+ #
1290
+ # @return [String, nil]
1291
+ optional :description, String, nil?: true
1292
+
1293
+ # @!method initialize(above_threshold_discount_percentage:, below_threshold_discount_percentage:, cell_coordinates:, threshold_amount:, description: nil)
1294
+ # Some parameter documentations has been truncated, see
1295
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup}
1296
+ # for more details.
1297
+ #
1298
+ # @param above_threshold_discount_percentage [String] Discount rate applied to spend above the threshold.
1299
+ #
1300
+ # @param below_threshold_discount_percentage [String] Discount rate applied to spend at or below the threshold. Set to 0 for no baseli
1301
+ #
1302
+ # @param cell_coordinates [String] Semicolon-separated list of matrix cell coordinates targeted by this group. Each
1303
+ #
1304
+ # @param threshold_amount [String]
1305
+ #
1306
+ # @param description [String, nil]
752
1307
  end
753
1308
  end
754
1309
  end
755
1310
 
756
- class GroupedWithMinMaxThresholds < Orb::Internal::Type::BaseModel
1311
+ class TieredWithProration < Orb::Internal::Type::BaseModel
757
1312
  # @!attribute cadence
758
1313
  # The cadence to bill for this price on.
759
1314
  #
760
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::Cadence]
1315
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::Cadence]
761
1316
  required :cadence,
762
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::Cadence }
763
-
764
- # @!attribute grouped_with_min_max_thresholds_config
765
- # Configuration for grouped_with_min_max_thresholds pricing
766
- #
767
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig]
768
- required :grouped_with_min_max_thresholds_config,
769
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig }
1317
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::Cadence }
770
1318
 
771
1319
  # @!attribute item_id
772
1320
  # The id of the item the price will be associated with.
@@ -777,8 +1325,8 @@ module Orb
777
1325
  # @!attribute model_type
778
1326
  # The pricing model type
779
1327
  #
780
- # @return [Symbol, :grouped_with_min_max_thresholds]
781
- required :model_type, const: :grouped_with_min_max_thresholds
1328
+ # @return [Symbol, :tiered_with_proration]
1329
+ required :model_type, const: :tiered_with_proration
782
1330
 
783
1331
  # @!attribute name
784
1332
  # The name of the price.
@@ -786,6 +1334,13 @@ module Orb
786
1334
  # @return [String]
787
1335
  required :name, String
788
1336
 
1337
+ # @!attribute tiered_with_proration_config
1338
+ # Configuration for tiered_with_proration pricing
1339
+ #
1340
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig]
1341
+ required :tiered_with_proration_config,
1342
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig }
1343
+
789
1344
  # @!attribute billable_metric_id
790
1345
  # The id of the billable metric for the price. Only needed if the price is
791
1346
  # usage-based.
@@ -817,11 +1372,7 @@ module Orb
817
1372
  # The configuration for the rate of the price currency to the invoicing currency.
818
1373
  #
819
1374
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
820
- optional :conversion_rate_config,
821
- union: -> {
822
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::ConversionRateConfig
823
- },
824
- nil?: true
1375
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
825
1376
 
826
1377
  # @!attribute currency
827
1378
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -887,19 +1438,19 @@ module Orb
887
1438
  # @return [String, nil]
888
1439
  optional :reference_id, String, nil?: true
889
1440
 
890
- # @!method initialize(cadence:, grouped_with_min_max_thresholds_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :grouped_with_min_max_thresholds)
1441
+ # @!method initialize(cadence:, item_id:, name:, tiered_with_proration_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :tiered_with_proration)
891
1442
  # Some parameter documentations has been truncated, see
892
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds}
1443
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration}
893
1444
  # for more details.
894
1445
  #
895
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::Cadence] The cadence to bill for this price on.
896
- #
897
- # @param grouped_with_min_max_thresholds_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig] Configuration for grouped_with_min_max_thresholds pricing
1446
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::Cadence] The cadence to bill for this price on.
898
1447
  #
899
1448
  # @param item_id [String] The id of the item the price will be associated with.
900
1449
  #
901
1450
  # @param name [String] The name of the price.
902
1451
  #
1452
+ # @param tiered_with_proration_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig] Configuration for tiered_with_proration pricing
1453
+ #
903
1454
  # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
904
1455
  #
905
1456
  # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
@@ -928,11 +1479,11 @@ module Orb
928
1479
  #
929
1480
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
930
1481
  #
931
- # @param model_type [Symbol, :grouped_with_min_max_thresholds] The pricing model type
1482
+ # @param model_type [Symbol, :tiered_with_proration] The pricing model type
932
1483
 
933
1484
  # The cadence to bill for this price on.
934
1485
  #
935
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds#cadence
1486
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration#cadence
936
1487
  module Cadence
937
1488
  extend Orb::Internal::Type::Enum
938
1489
 
@@ -947,59 +1498,66 @@ module Orb
947
1498
  # @return [Array<Symbol>]
948
1499
  end
949
1500
 
950
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds#grouped_with_min_max_thresholds_config
951
- class GroupedWithMinMaxThresholdsConfig < Orb::Internal::Type::BaseModel
952
- # @!attribute grouping_key
953
- # The event property used to group before applying thresholds
1501
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration#tiered_with_proration_config
1502
+ class TieredWithProrationConfig < Orb::Internal::Type::BaseModel
1503
+ # @!attribute tiers
1504
+ # Tiers for rating based on total usage quantities into the specified tier with
1505
+ # proration
954
1506
  #
955
- # @return [String]
956
- required :grouping_key, String
1507
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>]
1508
+ required :tiers,
1509
+ -> do
1510
+ Orb::Internal::Type::ArrayOf[
1511
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig::Tier
1512
+ ]
1513
+ end
957
1514
 
958
- # @!attribute maximum_charge
959
- # The maximum amount to charge each group
1515
+ # @!method initialize(tiers:)
1516
+ # Some parameter documentations has been truncated, see
1517
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig}
1518
+ # for more details.
960
1519
  #
961
- # @return [String]
962
- required :maximum_charge, String
963
-
964
- # @!attribute minimum_charge
965
- # The minimum amount to charge each group, regardless of usage
1520
+ # Configuration for tiered_with_proration pricing
966
1521
  #
967
- # @return [String]
968
- required :minimum_charge, String
1522
+ # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>] Tiers for rating based on total usage quantities into the specified tier with pr
969
1523
 
970
- # @!attribute per_unit_rate
971
- # The base price charged per group
972
- #
973
- # @return [String]
974
- required :per_unit_rate, String
1524
+ class Tier < Orb::Internal::Type::BaseModel
1525
+ # @!attribute tier_lower_bound
1526
+ # Inclusive tier starting value
1527
+ #
1528
+ # @return [String]
1529
+ required :tier_lower_bound, String
975
1530
 
976
- # @!method initialize(grouping_key:, maximum_charge:, minimum_charge:, per_unit_rate:)
977
- # Configuration for grouped_with_min_max_thresholds pricing
978
- #
979
- # @param grouping_key [String] The event property used to group before applying thresholds
980
- #
981
- # @param maximum_charge [String] The maximum amount to charge each group
982
- #
983
- # @param minimum_charge [String] The minimum amount to charge each group, regardless of usage
984
- #
985
- # @param per_unit_rate [String] The base price charged per group
1531
+ # @!attribute unit_amount
1532
+ # Amount per unit
1533
+ #
1534
+ # @return [String]
1535
+ required :unit_amount, String
1536
+
1537
+ # @!method initialize(tier_lower_bound:, unit_amount:)
1538
+ # Configuration for a single tiered with proration tier
1539
+ #
1540
+ # @param tier_lower_bound [String] Inclusive tier starting value
1541
+ #
1542
+ # @param unit_amount [String] Amount per unit
1543
+ end
986
1544
  end
987
1545
  end
988
1546
 
989
- class CumulativeGroupedAllocation < Orb::Internal::Type::BaseModel
1547
+ class GroupedWithMinMaxThresholds < Orb::Internal::Type::BaseModel
990
1548
  # @!attribute cadence
991
1549
  # The cadence to bill for this price on.
992
1550
  #
993
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::Cadence]
1551
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::Cadence]
994
1552
  required :cadence,
995
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::Cadence }
1553
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::Cadence }
996
1554
 
997
- # @!attribute cumulative_grouped_allocation_config
998
- # Configuration for cumulative_grouped_allocation pricing
1555
+ # @!attribute grouped_with_min_max_thresholds_config
1556
+ # Configuration for grouped_with_min_max_thresholds pricing
999
1557
  #
1000
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig]
1001
- required :cumulative_grouped_allocation_config,
1002
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig }
1558
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig]
1559
+ required :grouped_with_min_max_thresholds_config,
1560
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig }
1003
1561
 
1004
1562
  # @!attribute item_id
1005
1563
  # The id of the item the price will be associated with.
@@ -1010,8 +1568,8 @@ module Orb
1010
1568
  # @!attribute model_type
1011
1569
  # The pricing model type
1012
1570
  #
1013
- # @return [Symbol, :cumulative_grouped_allocation]
1014
- required :model_type, const: :cumulative_grouped_allocation
1571
+ # @return [Symbol, :grouped_with_min_max_thresholds]
1572
+ required :model_type, const: :grouped_with_min_max_thresholds
1015
1573
 
1016
1574
  # @!attribute name
1017
1575
  # The name of the price.
@@ -1050,11 +1608,7 @@ module Orb
1050
1608
  # The configuration for the rate of the price currency to the invoicing currency.
1051
1609
  #
1052
1610
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
1053
- optional :conversion_rate_config,
1054
- union: -> {
1055
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::ConversionRateConfig
1056
- },
1057
- nil?: true
1611
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
1058
1612
 
1059
1613
  # @!attribute currency
1060
1614
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -1120,14 +1674,14 @@ module Orb
1120
1674
  # @return [String, nil]
1121
1675
  optional :reference_id, String, nil?: true
1122
1676
 
1123
- # @!method initialize(cadence:, cumulative_grouped_allocation_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :cumulative_grouped_allocation)
1677
+ # @!method initialize(cadence:, grouped_with_min_max_thresholds_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :grouped_with_min_max_thresholds)
1124
1678
  # Some parameter documentations has been truncated, see
1125
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation}
1679
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds}
1126
1680
  # for more details.
1127
1681
  #
1128
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::Cadence] The cadence to bill for this price on.
1682
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::Cadence] The cadence to bill for this price on.
1129
1683
  #
1130
- # @param cumulative_grouped_allocation_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig] Configuration for cumulative_grouped_allocation pricing
1684
+ # @param grouped_with_min_max_thresholds_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig] Configuration for grouped_with_min_max_thresholds pricing
1131
1685
  #
1132
1686
  # @param item_id [String] The id of the item the price will be associated with.
1133
1687
  #
@@ -1161,11 +1715,11 @@ module Orb
1161
1715
  #
1162
1716
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
1163
1717
  #
1164
- # @param model_type [Symbol, :cumulative_grouped_allocation] The pricing model type
1718
+ # @param model_type [Symbol, :grouped_with_min_max_thresholds] The pricing model type
1165
1719
 
1166
1720
  # The cadence to bill for this price on.
1167
1721
  #
1168
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation#cadence
1722
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds#cadence
1169
1723
  module Cadence
1170
1724
  extend Orb::Internal::Type::Enum
1171
1725
 
@@ -1180,52 +1734,59 @@ module Orb
1180
1734
  # @return [Array<Symbol>]
1181
1735
  end
1182
1736
 
1183
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation#cumulative_grouped_allocation_config
1184
- class CumulativeGroupedAllocationConfig < Orb::Internal::Type::BaseModel
1185
- # @!attribute cumulative_allocation
1186
- # The overall allocation across all groups
1737
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds#grouped_with_min_max_thresholds_config
1738
+ class GroupedWithMinMaxThresholdsConfig < Orb::Internal::Type::BaseModel
1739
+ # @!attribute grouping_key
1740
+ # The event property used to group before applying thresholds
1187
1741
  #
1188
1742
  # @return [String]
1189
- required :cumulative_allocation, String
1743
+ required :grouping_key, String
1190
1744
 
1191
- # @!attribute group_allocation
1192
- # The allocation per individual group
1745
+ # @!attribute maximum_charge
1746
+ # The maximum amount to charge each group
1193
1747
  #
1194
1748
  # @return [String]
1195
- required :group_allocation, String
1749
+ required :maximum_charge, String
1196
1750
 
1197
- # @!attribute grouping_key
1198
- # The event property used to group usage before applying allocations
1751
+ # @!attribute minimum_charge
1752
+ # The minimum amount to charge each group, regardless of usage
1199
1753
  #
1200
1754
  # @return [String]
1201
- required :grouping_key, String
1755
+ required :minimum_charge, String
1202
1756
 
1203
- # @!attribute unit_amount
1204
- # The amount to charge for each unit outside of the allocation
1757
+ # @!attribute per_unit_rate
1758
+ # The base price charged per group
1205
1759
  #
1206
1760
  # @return [String]
1207
- required :unit_amount, String
1761
+ required :per_unit_rate, String
1208
1762
 
1209
- # @!method initialize(cumulative_allocation:, group_allocation:, grouping_key:, unit_amount:)
1210
- # Configuration for cumulative_grouped_allocation pricing
1763
+ # @!method initialize(grouping_key:, maximum_charge:, minimum_charge:, per_unit_rate:)
1764
+ # Configuration for grouped_with_min_max_thresholds pricing
1211
1765
  #
1212
- # @param cumulative_allocation [String] The overall allocation across all groups
1766
+ # @param grouping_key [String] The event property used to group before applying thresholds
1213
1767
  #
1214
- # @param group_allocation [String] The allocation per individual group
1768
+ # @param maximum_charge [String] The maximum amount to charge each group
1215
1769
  #
1216
- # @param grouping_key [String] The event property used to group usage before applying allocations
1770
+ # @param minimum_charge [String] The minimum amount to charge each group, regardless of usage
1217
1771
  #
1218
- # @param unit_amount [String] The amount to charge for each unit outside of the allocation
1772
+ # @param per_unit_rate [String] The base price charged per group
1219
1773
  end
1220
1774
  end
1221
1775
 
1222
- class Percent < Orb::Internal::Type::BaseModel
1776
+ class CumulativeGroupedAllocation < Orb::Internal::Type::BaseModel
1223
1777
  # @!attribute cadence
1224
1778
  # The cadence to bill for this price on.
1225
1779
  #
1226
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::Cadence]
1780
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::Cadence]
1227
1781
  required :cadence,
1228
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::Cadence }
1782
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::Cadence }
1783
+
1784
+ # @!attribute cumulative_grouped_allocation_config
1785
+ # Configuration for cumulative_grouped_allocation pricing
1786
+ #
1787
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig]
1788
+ required :cumulative_grouped_allocation_config,
1789
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig }
1229
1790
 
1230
1791
  # @!attribute item_id
1231
1792
  # The id of the item the price will be associated with.
@@ -1236,8 +1797,8 @@ module Orb
1236
1797
  # @!attribute model_type
1237
1798
  # The pricing model type
1238
1799
  #
1239
- # @return [Symbol, :percent]
1240
- required :model_type, const: :percent
1800
+ # @return [Symbol, :cumulative_grouped_allocation]
1801
+ required :model_type, const: :cumulative_grouped_allocation
1241
1802
 
1242
1803
  # @!attribute name
1243
1804
  # The name of the price.
@@ -1245,13 +1806,6 @@ module Orb
1245
1806
  # @return [String]
1246
1807
  required :name, String
1247
1808
 
1248
- # @!attribute percent_config
1249
- # Configuration for percent pricing
1250
- #
1251
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::PercentConfig]
1252
- required :percent_config,
1253
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::PercentConfig }
1254
-
1255
1809
  # @!attribute billable_metric_id
1256
1810
  # The id of the billable metric for the price. Only needed if the price is
1257
1811
  # usage-based.
@@ -1283,11 +1837,7 @@ module Orb
1283
1837
  # The configuration for the rate of the price currency to the invoicing currency.
1284
1838
  #
1285
1839
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
1286
- optional :conversion_rate_config,
1287
- union: -> {
1288
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::ConversionRateConfig
1289
- },
1290
- nil?: true
1840
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
1291
1841
 
1292
1842
  # @!attribute currency
1293
1843
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -1353,19 +1903,19 @@ module Orb
1353
1903
  # @return [String, nil]
1354
1904
  optional :reference_id, String, nil?: true
1355
1905
 
1356
- # @!method initialize(cadence:, item_id:, name:, percent_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :percent)
1906
+ # @!method initialize(cadence:, cumulative_grouped_allocation_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :cumulative_grouped_allocation)
1357
1907
  # Some parameter documentations has been truncated, see
1358
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent}
1908
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation}
1359
1909
  # for more details.
1360
1910
  #
1361
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::Cadence] The cadence to bill for this price on.
1911
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::Cadence] The cadence to bill for this price on.
1912
+ #
1913
+ # @param cumulative_grouped_allocation_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig] Configuration for cumulative_grouped_allocation pricing
1362
1914
  #
1363
1915
  # @param item_id [String] The id of the item the price will be associated with.
1364
1916
  #
1365
1917
  # @param name [String] The name of the price.
1366
1918
  #
1367
- # @param percent_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::PercentConfig] Configuration for percent pricing
1368
- #
1369
1919
  # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
1370
1920
  #
1371
1921
  # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
@@ -1394,11 +1944,11 @@ module Orb
1394
1944
  #
1395
1945
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
1396
1946
  #
1397
- # @param model_type [Symbol, :percent] The pricing model type
1947
+ # @param model_type [Symbol, :cumulative_grouped_allocation] The pricing model type
1398
1948
 
1399
1949
  # The cadence to bill for this price on.
1400
1950
  #
1401
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent#cadence
1951
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation#cadence
1402
1952
  module Cadence
1403
1953
  extend Orb::Internal::Type::Enum
1404
1954
 
@@ -1413,35 +1963,59 @@ module Orb
1413
1963
  # @return [Array<Symbol>]
1414
1964
  end
1415
1965
 
1416
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent#percent_config
1417
- class PercentConfig < Orb::Internal::Type::BaseModel
1418
- # @!attribute percent
1419
- # What percent of the component subtotals to charge
1966
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation#cumulative_grouped_allocation_config
1967
+ class CumulativeGroupedAllocationConfig < Orb::Internal::Type::BaseModel
1968
+ # @!attribute cumulative_allocation
1969
+ # The overall allocation across all groups
1420
1970
  #
1421
- # @return [Float]
1422
- required :percent, Float
1971
+ # @return [String]
1972
+ required :cumulative_allocation, String
1423
1973
 
1424
- # @!method initialize(percent:)
1425
- # Configuration for percent pricing
1974
+ # @!attribute group_allocation
1975
+ # The allocation per individual group
1976
+ #
1977
+ # @return [String]
1978
+ required :group_allocation, String
1979
+
1980
+ # @!attribute grouping_key
1981
+ # The event property used to group usage before applying allocations
1982
+ #
1983
+ # @return [String]
1984
+ required :grouping_key, String
1985
+
1986
+ # @!attribute unit_amount
1987
+ # The amount to charge for each unit outside of the allocation
1988
+ #
1989
+ # @return [String]
1990
+ required :unit_amount, String
1991
+
1992
+ # @!method initialize(cumulative_allocation:, group_allocation:, grouping_key:, unit_amount:)
1993
+ # Configuration for cumulative_grouped_allocation pricing
1994
+ #
1995
+ # @param cumulative_allocation [String] The overall allocation across all groups
1996
+ #
1997
+ # @param group_allocation [String] The allocation per individual group
1998
+ #
1999
+ # @param grouping_key [String] The event property used to group usage before applying allocations
1426
2000
  #
1427
- # @param percent [Float] What percent of the component subtotals to charge
2001
+ # @param unit_amount [String] The amount to charge for each unit outside of the allocation
1428
2002
  end
1429
2003
  end
1430
2004
 
1431
- class EventOutput < Orb::Internal::Type::BaseModel
2005
+ class DailyCreditAllowance < Orb::Internal::Type::BaseModel
1432
2006
  # @!attribute cadence
1433
2007
  # The cadence to bill for this price on.
1434
2008
  #
1435
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::Cadence]
2009
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::Cadence]
1436
2010
  required :cadence,
1437
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::Cadence }
2011
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::Cadence }
1438
2012
 
1439
- # @!attribute event_output_config
1440
- # Configuration for event_output pricing
2013
+ # @!attribute daily_credit_allowance_config
2014
+ # Configuration for daily_credit_allowance pricing
1441
2015
  #
1442
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig]
1443
- required :event_output_config,
1444
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig }
2016
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig]
2017
+ required :daily_credit_allowance_config,
2018
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig }
1445
2019
 
1446
2020
  # @!attribute item_id
1447
2021
  # The id of the item the price will be associated with.
@@ -1452,8 +2026,8 @@ module Orb
1452
2026
  # @!attribute model_type
1453
2027
  # The pricing model type
1454
2028
  #
1455
- # @return [Symbol, :event_output]
1456
- required :model_type, const: :event_output
2029
+ # @return [Symbol, :daily_credit_allowance]
2030
+ required :model_type, const: :daily_credit_allowance
1457
2031
 
1458
2032
  # @!attribute name
1459
2033
  # The name of the price.
@@ -1492,11 +2066,7 @@ module Orb
1492
2066
  # The configuration for the rate of the price currency to the invoicing currency.
1493
2067
  #
1494
2068
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
1495
- optional :conversion_rate_config,
1496
- union: -> {
1497
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::ConversionRateConfig
1498
- },
1499
- nil?: true
2069
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
1500
2070
 
1501
2071
  # @!attribute currency
1502
2072
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -1562,14 +2132,14 @@ module Orb
1562
2132
  # @return [String, nil]
1563
2133
  optional :reference_id, String, nil?: true
1564
2134
 
1565
- # @!method initialize(cadence:, event_output_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :event_output)
2135
+ # @!method initialize(cadence:, daily_credit_allowance_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :daily_credit_allowance)
1566
2136
  # Some parameter documentations has been truncated, see
1567
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput}
2137
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance}
1568
2138
  # for more details.
1569
2139
  #
1570
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::Cadence] The cadence to bill for this price on.
2140
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::Cadence] The cadence to bill for this price on.
1571
2141
  #
1572
- # @param event_output_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig] Configuration for event_output pricing
2142
+ # @param daily_credit_allowance_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig] Configuration for daily_credit_allowance pricing
1573
2143
  #
1574
2144
  # @param item_id [String] The id of the item the price will be associated with.
1575
2145
  #
@@ -1603,11 +2173,11 @@ module Orb
1603
2173
  #
1604
2174
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
1605
2175
  #
1606
- # @param model_type [Symbol, :event_output] The pricing model type
2176
+ # @param model_type [Symbol, :daily_credit_allowance] The pricing model type
1607
2177
 
1608
2178
  # The cadence to bill for this price on.
1609
2179
  #
1610
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput#cadence
2180
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance#cadence
1611
2181
  module Cadence
1612
2182
  extend Orb::Internal::Type::Enum
1613
2183
 
@@ -1622,262 +2192,2322 @@ module Orb
1622
2192
  # @return [Array<Symbol>]
1623
2193
  end
1624
2194
 
1625
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput#event_output_config
1626
- class EventOutputConfig < Orb::Internal::Type::BaseModel
1627
- # @!attribute unit_rating_key
1628
- # The key in the event data to extract the unit rate from.
2195
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance#daily_credit_allowance_config
2196
+ class DailyCreditAllowanceConfig < Orb::Internal::Type::BaseModel
2197
+ # @!attribute daily_allowance
2198
+ # Credits granted per day. Lose-it-or-use-it; does not roll over.
1629
2199
  #
1630
2200
  # @return [String]
1631
- required :unit_rating_key, String
2201
+ required :daily_allowance, String
1632
2202
 
1633
- # @!attribute default_unit_rate
1634
- # If provided, this amount will be used as the unit rate when an event does not
1635
- # have a value for the `unit_rating_key`. If not provided, events missing a unit
1636
- # rate will be ignored.
2203
+ # @!attribute default_unit_amount
2204
+ # Default per-unit credit rate for any usage not bucketed into a specified
2205
+ # matrix_value
1637
2206
  #
1638
- # @return [String, nil]
1639
- optional :default_unit_rate, String, nil?: true
2207
+ # @return [String]
2208
+ required :default_unit_amount, String
1640
2209
 
1641
- # @!attribute grouping_key
1642
- # An optional key in the event data to group by (e.g., event ID). All events will
1643
- # also be grouped by their unit rate.
2210
+ # @!attribute dimensions
2211
+ # One or two event property values to evaluate matrix groups by
1644
2212
  #
1645
- # @return [String, nil]
1646
- optional :grouping_key, String, nil?: true
2213
+ # @return [Array<String, nil>]
2214
+ required :dimensions, Orb::Internal::Type::ArrayOf[String, nil?: true]
1647
2215
 
1648
- # @!method initialize(unit_rating_key:, default_unit_rate: nil, grouping_key: nil)
2216
+ # @!attribute event_day_property
2217
+ # Event property whose value identifies the day bucket the event belongs to (e.g.
2218
+ # 'event_day' set to an ISO date string in the customer's timezone). The allowance
2219
+ # resets per distinct value of this property.
2220
+ #
2221
+ # @return [String]
2222
+ required :event_day_property, String
2223
+
2224
+ # @!attribute matrix_values
2225
+ # Per-dimension credit rates
2226
+ #
2227
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue>]
2228
+ required :matrix_values,
2229
+ -> do
2230
+ Orb::Internal::Type::ArrayOf[
2231
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue
2232
+ ]
2233
+ end
2234
+
2235
+ # @!method initialize(daily_allowance:, default_unit_amount:, dimensions:, event_day_property:, matrix_values:)
1649
2236
  # Some parameter documentations has been truncated, see
1650
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig}
2237
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig}
2238
+ # for more details.
2239
+ #
2240
+ # Configuration for daily_credit_allowance pricing
2241
+ #
2242
+ # @param daily_allowance [String] Credits granted per day. Lose-it-or-use-it; does not roll over.
2243
+ #
2244
+ # @param default_unit_amount [String] Default per-unit credit rate for any usage not bucketed into a specified
2245
+ # matrix\_
2246
+ #
2247
+ # @param dimensions [Array<String, nil>] One or two event property values to evaluate matrix groups by
2248
+ #
2249
+ # @param event_day_property [String] Event property whose value identifies the day bucket the event belongs to (e.g.
2250
+ #
2251
+ # @param matrix_values [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue>] Per-dimension credit rates
2252
+
2253
+ class MatrixValue < Orb::Internal::Type::BaseModel
2254
+ # @!attribute dimension_values
2255
+ # One or two matrix keys to filter usage to this value by. For example, ["model"]
2256
+ # could be used to apply a different credit rate to each AI model.
2257
+ #
2258
+ # @return [Array<String, nil>]
2259
+ required :dimension_values, Orb::Internal::Type::ArrayOf[String, nil?: true]
2260
+
2261
+ # @!attribute unit_amount
2262
+ # Credits charged per unit of usage matching the specified dimension_values
2263
+ #
2264
+ # @return [String]
2265
+ required :unit_amount, String
2266
+
2267
+ # @!method initialize(dimension_values:, unit_amount:)
2268
+ # Some parameter documentations has been truncated, see
2269
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue}
2270
+ # for more details.
2271
+ #
2272
+ # Per-dimension credit price for the daily credit allowance model.
2273
+ #
2274
+ # @param dimension_values [Array<String, nil>] One or two matrix keys to filter usage to this value by. For example, ["model"]
2275
+ #
2276
+ # @param unit_amount [String] Credits charged per unit of usage matching the specified dimension_values
2277
+ end
2278
+ end
2279
+ end
2280
+
2281
+ class MeteredAllowance < Orb::Internal::Type::BaseModel
2282
+ # @!attribute cadence
2283
+ # The cadence to bill for this price on.
2284
+ #
2285
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance::Cadence]
2286
+ required :cadence,
2287
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance::Cadence }
2288
+
2289
+ # @!attribute item_id
2290
+ # The id of the item the price will be associated with.
2291
+ #
2292
+ # @return [String]
2293
+ required :item_id, String
2294
+
2295
+ # @!attribute metered_allowance_config
2296
+ # Configuration for metered_allowance pricing
2297
+ #
2298
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance::MeteredAllowanceConfig]
2299
+ required :metered_allowance_config,
2300
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance::MeteredAllowanceConfig }
2301
+
2302
+ # @!attribute model_type
2303
+ # The pricing model type
2304
+ #
2305
+ # @return [Symbol, :metered_allowance]
2306
+ required :model_type, const: :metered_allowance
2307
+
2308
+ # @!attribute name
2309
+ # The name of the price.
2310
+ #
2311
+ # @return [String]
2312
+ required :name, String
2313
+
2314
+ # @!attribute billable_metric_id
2315
+ # The id of the billable metric for the price. Only needed if the price is
2316
+ # usage-based.
2317
+ #
2318
+ # @return [String, nil]
2319
+ optional :billable_metric_id, String, nil?: true
2320
+
2321
+ # @!attribute billed_in_advance
2322
+ # If the Price represents a fixed cost, the price will be billed in-advance if
2323
+ # this is true, and in-arrears if this is false.
2324
+ #
2325
+ # @return [Boolean, nil]
2326
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
2327
+
2328
+ # @!attribute billing_cycle_configuration
2329
+ # For custom cadence: specifies the duration of the billing period in days or
2330
+ # months.
2331
+ #
2332
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
2333
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
2334
+
2335
+ # @!attribute conversion_rate
2336
+ # The per unit conversion rate of the price currency to the invoicing currency.
2337
+ #
2338
+ # @return [Float, nil]
2339
+ optional :conversion_rate, Float, nil?: true
2340
+
2341
+ # @!attribute conversion_rate_config
2342
+ # The configuration for the rate of the price currency to the invoicing currency.
2343
+ #
2344
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
2345
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
2346
+
2347
+ # @!attribute currency
2348
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
2349
+ # price is billed.
2350
+ #
2351
+ # @return [String, nil]
2352
+ optional :currency, String, nil?: true
2353
+
2354
+ # @!attribute dimensional_price_configuration
2355
+ # For dimensional price: specifies a price group and dimension values
2356
+ #
2357
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
2358
+ optional :dimensional_price_configuration,
2359
+ -> {
2360
+ Orb::NewDimensionalPriceConfiguration
2361
+ },
2362
+ nil?: true
2363
+
2364
+ # @!attribute external_price_id
2365
+ # An alias for the price.
2366
+ #
2367
+ # @return [String, nil]
2368
+ optional :external_price_id, String, nil?: true
2369
+
2370
+ # @!attribute fixed_price_quantity
2371
+ # If the Price represents a fixed cost, this represents the quantity of units
2372
+ # applied.
2373
+ #
2374
+ # @return [Float, nil]
2375
+ optional :fixed_price_quantity, Float, nil?: true
2376
+
2377
+ # @!attribute invoice_grouping_key
2378
+ # The property used to group this price on an invoice
2379
+ #
2380
+ # @return [String, nil]
2381
+ optional :invoice_grouping_key, String, nil?: true
2382
+
2383
+ # @!attribute invoicing_cycle_configuration
2384
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
2385
+ # If unspecified, a single invoice is produced per billing cycle.
2386
+ #
2387
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
2388
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
2389
+
2390
+ # @!attribute license_type_id
2391
+ # The ID of the license type to associate with this price.
2392
+ #
2393
+ # @return [String, nil]
2394
+ optional :license_type_id, String, nil?: true
2395
+
2396
+ # @!attribute metadata
2397
+ # User-specified key/value pairs for the resource. Individual keys can be removed
2398
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
2399
+ # by setting `metadata` to `null`.
2400
+ #
2401
+ # @return [Hash{Symbol=>String, nil}, nil]
2402
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
2403
+
2404
+ # @!attribute reference_id
2405
+ # A transient ID that can be used to reference this price when adding adjustments
2406
+ # in the same API call.
2407
+ #
2408
+ # @return [String, nil]
2409
+ optional :reference_id, String, nil?: true
2410
+
2411
+ # @!method initialize(cadence:, item_id:, metered_allowance_config:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :metered_allowance)
2412
+ # Some parameter documentations has been truncated, see
2413
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance}
2414
+ # for more details.
2415
+ #
2416
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance::Cadence] The cadence to bill for this price on.
2417
+ #
2418
+ # @param item_id [String] The id of the item the price will be associated with.
2419
+ #
2420
+ # @param metered_allowance_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance::MeteredAllowanceConfig] Configuration for metered_allowance pricing
2421
+ #
2422
+ # @param name [String] The name of the price.
2423
+ #
2424
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
2425
+ #
2426
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
2427
+ #
2428
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
2429
+ #
2430
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
2431
+ #
2432
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
2433
+ #
2434
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
2435
+ #
2436
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
2437
+ #
2438
+ # @param external_price_id [String, nil] An alias for the price.
2439
+ #
2440
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
2441
+ #
2442
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
2443
+ #
2444
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
2445
+ #
2446
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
2447
+ #
2448
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
2449
+ #
2450
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
2451
+ #
2452
+ # @param model_type [Symbol, :metered_allowance] The pricing model type
2453
+
2454
+ # The cadence to bill for this price on.
2455
+ #
2456
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance#cadence
2457
+ module Cadence
2458
+ extend Orb::Internal::Type::Enum
2459
+
2460
+ ANNUAL = :annual
2461
+ SEMI_ANNUAL = :semi_annual
2462
+ MONTHLY = :monthly
2463
+ QUARTERLY = :quarterly
2464
+ ONE_TIME = :one_time
2465
+ CUSTOM = :custom
2466
+
2467
+ # @!method self.values
2468
+ # @return [Array<Symbol>]
2469
+ end
2470
+
2471
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance#metered_allowance_config
2472
+ class MeteredAllowanceConfig < Orb::Internal::Type::BaseModel
2473
+ # @!attribute allowance_grouping_value
2474
+ # The grouping_key value whose summed quantity represents the allowance for this
2475
+ # period (e.g. 'storage_snapshot' emitting 3 × avg storage). Capped at consumption
2476
+ # — credit can never exceed actual usage.
2477
+ #
2478
+ # @return [String]
2479
+ required :allowance_grouping_value, String
2480
+
2481
+ # @!attribute consumption_grouping_value
2482
+ # The grouping_key value whose summed quantity represents consumption (e.g.
2483
+ # 'download'). Charged at unit_amount.
2484
+ #
2485
+ # @return [String]
2486
+ required :consumption_grouping_value, String
2487
+
2488
+ # @!attribute grouping_key
2489
+ # Event property used to partition the metric into consumption and allowance
2490
+ # quantities (e.g. 'event_name'). The metric is queried with this key and the two
2491
+ # values below select which partition is which.
2492
+ #
2493
+ # @return [String]
2494
+ required :grouping_key, String
2495
+
2496
+ # @!attribute unit_amount
2497
+ # Per-unit price applied to gross consumption and to the allowance credit.
2498
+ #
2499
+ # @return [String]
2500
+ required :unit_amount, String
2501
+
2502
+ # @!attribute allowance_display_name
2503
+ # Sub-line label for the credit row (e.g. 'Up to 3x free egress').
2504
+ #
2505
+ # @return [String, nil]
2506
+ optional :allowance_display_name, String
2507
+
2508
+ # @!attribute consumption_display_name
2509
+ # Sub-line label for the gross consumption row (e.g. 'bytes gotten').
2510
+ #
2511
+ # @return [String, nil]
2512
+ optional :consumption_display_name, String
2513
+
2514
+ # @!method initialize(allowance_grouping_value:, consumption_grouping_value:, grouping_key:, unit_amount:, allowance_display_name: nil, consumption_display_name: nil)
2515
+ # Some parameter documentations has been truncated, see
2516
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance::MeteredAllowanceConfig}
2517
+ # for more details.
2518
+ #
2519
+ # Configuration for metered_allowance pricing
2520
+ #
2521
+ # @param allowance_grouping_value [String] The grouping_key value whose summed quantity represents the allowance for this p
2522
+ #
2523
+ # @param consumption_grouping_value [String] The grouping_key value whose summed quantity represents consumption (e.g. 'downl
2524
+ #
2525
+ # @param grouping_key [String] Event property used to partition the metric into consumption and allowance quant
2526
+ #
2527
+ # @param unit_amount [String] Per-unit price applied to gross consumption and to the allowance credit.
2528
+ #
2529
+ # @param allowance_display_name [String] Sub-line label for the credit row (e.g. 'Up to 3x free egress').
2530
+ #
2531
+ # @param consumption_display_name [String] Sub-line label for the gross consumption row (e.g. 'bytes gotten').
2532
+ end
2533
+ end
2534
+
2535
+ class Percent < Orb::Internal::Type::BaseModel
2536
+ # @!attribute cadence
2537
+ # The cadence to bill for this price on.
2538
+ #
2539
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::Cadence]
2540
+ required :cadence,
2541
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::Cadence }
2542
+
2543
+ # @!attribute item_id
2544
+ # The id of the item the price will be associated with.
2545
+ #
2546
+ # @return [String]
2547
+ required :item_id, String
2548
+
2549
+ # @!attribute model_type
2550
+ # The pricing model type
2551
+ #
2552
+ # @return [Symbol, :percent]
2553
+ required :model_type, const: :percent
2554
+
2555
+ # @!attribute name
2556
+ # The name of the price.
2557
+ #
2558
+ # @return [String]
2559
+ required :name, String
2560
+
2561
+ # @!attribute percent_config
2562
+ # Configuration for percent pricing
2563
+ #
2564
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::PercentConfig]
2565
+ required :percent_config,
2566
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::PercentConfig }
2567
+
2568
+ # @!attribute billable_metric_id
2569
+ # The id of the billable metric for the price. Only needed if the price is
2570
+ # usage-based.
2571
+ #
2572
+ # @return [String, nil]
2573
+ optional :billable_metric_id, String, nil?: true
2574
+
2575
+ # @!attribute billed_in_advance
2576
+ # If the Price represents a fixed cost, the price will be billed in-advance if
2577
+ # this is true, and in-arrears if this is false.
2578
+ #
2579
+ # @return [Boolean, nil]
2580
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
2581
+
2582
+ # @!attribute billing_cycle_configuration
2583
+ # For custom cadence: specifies the duration of the billing period in days or
2584
+ # months.
2585
+ #
2586
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
2587
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
2588
+
2589
+ # @!attribute conversion_rate
2590
+ # The per unit conversion rate of the price currency to the invoicing currency.
2591
+ #
2592
+ # @return [Float, nil]
2593
+ optional :conversion_rate, Float, nil?: true
2594
+
2595
+ # @!attribute conversion_rate_config
2596
+ # The configuration for the rate of the price currency to the invoicing currency.
2597
+ #
2598
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
2599
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
2600
+
2601
+ # @!attribute currency
2602
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
2603
+ # price is billed.
2604
+ #
2605
+ # @return [String, nil]
2606
+ optional :currency, String, nil?: true
2607
+
2608
+ # @!attribute dimensional_price_configuration
2609
+ # For dimensional price: specifies a price group and dimension values
2610
+ #
2611
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
2612
+ optional :dimensional_price_configuration,
2613
+ -> {
2614
+ Orb::NewDimensionalPriceConfiguration
2615
+ },
2616
+ nil?: true
2617
+
2618
+ # @!attribute external_price_id
2619
+ # An alias for the price.
2620
+ #
2621
+ # @return [String, nil]
2622
+ optional :external_price_id, String, nil?: true
2623
+
2624
+ # @!attribute fixed_price_quantity
2625
+ # If the Price represents a fixed cost, this represents the quantity of units
2626
+ # applied.
2627
+ #
2628
+ # @return [Float, nil]
2629
+ optional :fixed_price_quantity, Float, nil?: true
2630
+
2631
+ # @!attribute invoice_grouping_key
2632
+ # The property used to group this price on an invoice
2633
+ #
2634
+ # @return [String, nil]
2635
+ optional :invoice_grouping_key, String, nil?: true
2636
+
2637
+ # @!attribute invoicing_cycle_configuration
2638
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
2639
+ # If unspecified, a single invoice is produced per billing cycle.
2640
+ #
2641
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
2642
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
2643
+
2644
+ # @!attribute license_type_id
2645
+ # The ID of the license type to associate with this price.
2646
+ #
2647
+ # @return [String, nil]
2648
+ optional :license_type_id, String, nil?: true
2649
+
2650
+ # @!attribute metadata
2651
+ # User-specified key/value pairs for the resource. Individual keys can be removed
2652
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
2653
+ # by setting `metadata` to `null`.
2654
+ #
2655
+ # @return [Hash{Symbol=>String, nil}, nil]
2656
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
2657
+
2658
+ # @!attribute reference_id
2659
+ # A transient ID that can be used to reference this price when adding adjustments
2660
+ # in the same API call.
2661
+ #
2662
+ # @return [String, nil]
2663
+ optional :reference_id, String, nil?: true
2664
+
2665
+ # @!method initialize(cadence:, item_id:, name:, percent_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :percent)
2666
+ # Some parameter documentations has been truncated, see
2667
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent}
2668
+ # for more details.
2669
+ #
2670
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::Cadence] The cadence to bill for this price on.
2671
+ #
2672
+ # @param item_id [String] The id of the item the price will be associated with.
2673
+ #
2674
+ # @param name [String] The name of the price.
2675
+ #
2676
+ # @param percent_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::PercentConfig] Configuration for percent pricing
2677
+ #
2678
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
2679
+ #
2680
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
2681
+ #
2682
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
2683
+ #
2684
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
2685
+ #
2686
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
2687
+ #
2688
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
2689
+ #
2690
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
2691
+ #
2692
+ # @param external_price_id [String, nil] An alias for the price.
2693
+ #
2694
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
2695
+ #
2696
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
2697
+ #
2698
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
2699
+ #
2700
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
2701
+ #
2702
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
2703
+ #
2704
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
2705
+ #
2706
+ # @param model_type [Symbol, :percent] The pricing model type
2707
+
2708
+ # The cadence to bill for this price on.
2709
+ #
2710
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent#cadence
2711
+ module Cadence
2712
+ extend Orb::Internal::Type::Enum
2713
+
2714
+ ANNUAL = :annual
2715
+ SEMI_ANNUAL = :semi_annual
2716
+ MONTHLY = :monthly
2717
+ QUARTERLY = :quarterly
2718
+ ONE_TIME = :one_time
2719
+ CUSTOM = :custom
2720
+
2721
+ # @!method self.values
2722
+ # @return [Array<Symbol>]
2723
+ end
2724
+
2725
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent#percent_config
2726
+ class PercentConfig < Orb::Internal::Type::BaseModel
2727
+ # @!attribute percent
2728
+ # Fraction of the component subtotals to charge (0 < percent <= 1).
2729
+ #
2730
+ # @return [Float]
2731
+ required :percent, Float
2732
+
2733
+ # @!attribute maximum_amount
2734
+ # Maximum amount to charge. If unset, the fee has no upper bound.
2735
+ #
2736
+ # @return [String, nil]
2737
+ optional :maximum_amount, String, nil?: true
2738
+
2739
+ # @!attribute minimum_amount
2740
+ # Minimum amount to charge. If unset, the fee is bounded below by 0.
2741
+ #
2742
+ # @return [String, nil]
2743
+ optional :minimum_amount, String, nil?: true
2744
+
2745
+ # @!attribute prorated
2746
+ # If true, the minimum_amount is prorated based on the service period. The
2747
+ # maximum_amount is an absolute cap (never prorated), and the percent applied to
2748
+ # upstream subtotals is never prorated either.
2749
+ #
2750
+ # @return [Boolean, nil]
2751
+ optional :prorated, Orb::Internal::Type::Boolean
2752
+
2753
+ # @!method initialize(percent:, maximum_amount: nil, minimum_amount: nil, prorated: nil)
2754
+ # Some parameter documentations has been truncated, see
2755
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent::PercentConfig}
2756
+ # for more details.
2757
+ #
2758
+ # Configuration for percent pricing
2759
+ #
2760
+ # @param percent [Float] Fraction of the component subtotals to charge (0 < percent <= 1).
2761
+ #
2762
+ # @param maximum_amount [String, nil] Maximum amount to charge. If unset, the fee has no upper bound.
2763
+ #
2764
+ # @param minimum_amount [String, nil] Minimum amount to charge. If unset, the fee is bounded below by 0.
2765
+ #
2766
+ # @param prorated [Boolean] If true, the minimum_amount is prorated based on the service period. The maximum
2767
+ end
2768
+ end
2769
+
2770
+ class EventOutput < Orb::Internal::Type::BaseModel
2771
+ # @!attribute cadence
2772
+ # The cadence to bill for this price on.
2773
+ #
2774
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::Cadence]
2775
+ required :cadence,
2776
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::Cadence }
2777
+
2778
+ # @!attribute event_output_config
2779
+ # Configuration for event_output pricing
2780
+ #
2781
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig]
2782
+ required :event_output_config,
2783
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig }
2784
+
2785
+ # @!attribute item_id
2786
+ # The id of the item the price will be associated with.
2787
+ #
2788
+ # @return [String]
2789
+ required :item_id, String
2790
+
2791
+ # @!attribute model_type
2792
+ # The pricing model type
2793
+ #
2794
+ # @return [Symbol, :event_output]
2795
+ required :model_type, const: :event_output
2796
+
2797
+ # @!attribute name
2798
+ # The name of the price.
2799
+ #
2800
+ # @return [String]
2801
+ required :name, String
2802
+
2803
+ # @!attribute billable_metric_id
2804
+ # The id of the billable metric for the price. Only needed if the price is
2805
+ # usage-based.
2806
+ #
2807
+ # @return [String, nil]
2808
+ optional :billable_metric_id, String, nil?: true
2809
+
2810
+ # @!attribute billed_in_advance
2811
+ # If the Price represents a fixed cost, the price will be billed in-advance if
2812
+ # this is true, and in-arrears if this is false.
2813
+ #
2814
+ # @return [Boolean, nil]
2815
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
2816
+
2817
+ # @!attribute billing_cycle_configuration
2818
+ # For custom cadence: specifies the duration of the billing period in days or
2819
+ # months.
2820
+ #
2821
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
2822
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
2823
+
2824
+ # @!attribute conversion_rate
2825
+ # The per unit conversion rate of the price currency to the invoicing currency.
2826
+ #
2827
+ # @return [Float, nil]
2828
+ optional :conversion_rate, Float, nil?: true
2829
+
2830
+ # @!attribute conversion_rate_config
2831
+ # The configuration for the rate of the price currency to the invoicing currency.
2832
+ #
2833
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
2834
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
2835
+
2836
+ # @!attribute currency
2837
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
2838
+ # price is billed.
2839
+ #
2840
+ # @return [String, nil]
2841
+ optional :currency, String, nil?: true
2842
+
2843
+ # @!attribute dimensional_price_configuration
2844
+ # For dimensional price: specifies a price group and dimension values
2845
+ #
2846
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
2847
+ optional :dimensional_price_configuration,
2848
+ -> {
2849
+ Orb::NewDimensionalPriceConfiguration
2850
+ },
2851
+ nil?: true
2852
+
2853
+ # @!attribute external_price_id
2854
+ # An alias for the price.
2855
+ #
2856
+ # @return [String, nil]
2857
+ optional :external_price_id, String, nil?: true
2858
+
2859
+ # @!attribute fixed_price_quantity
2860
+ # If the Price represents a fixed cost, this represents the quantity of units
2861
+ # applied.
2862
+ #
2863
+ # @return [Float, nil]
2864
+ optional :fixed_price_quantity, Float, nil?: true
2865
+
2866
+ # @!attribute invoice_grouping_key
2867
+ # The property used to group this price on an invoice
2868
+ #
2869
+ # @return [String, nil]
2870
+ optional :invoice_grouping_key, String, nil?: true
2871
+
2872
+ # @!attribute invoicing_cycle_configuration
2873
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
2874
+ # If unspecified, a single invoice is produced per billing cycle.
2875
+ #
2876
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
2877
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
2878
+
2879
+ # @!attribute license_type_id
2880
+ # The ID of the license type to associate with this price.
2881
+ #
2882
+ # @return [String, nil]
2883
+ optional :license_type_id, String, nil?: true
2884
+
2885
+ # @!attribute metadata
2886
+ # User-specified key/value pairs for the resource. Individual keys can be removed
2887
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
2888
+ # by setting `metadata` to `null`.
2889
+ #
2890
+ # @return [Hash{Symbol=>String, nil}, nil]
2891
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
2892
+
2893
+ # @!attribute reference_id
2894
+ # A transient ID that can be used to reference this price when adding adjustments
2895
+ # in the same API call.
2896
+ #
2897
+ # @return [String, nil]
2898
+ optional :reference_id, String, nil?: true
2899
+
2900
+ # @!method initialize(cadence:, event_output_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :event_output)
2901
+ # Some parameter documentations has been truncated, see
2902
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput}
2903
+ # for more details.
2904
+ #
2905
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::Cadence] The cadence to bill for this price on.
2906
+ #
2907
+ # @param event_output_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig] Configuration for event_output pricing
2908
+ #
2909
+ # @param item_id [String] The id of the item the price will be associated with.
2910
+ #
2911
+ # @param name [String] The name of the price.
2912
+ #
2913
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
2914
+ #
2915
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
2916
+ #
2917
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
2918
+ #
2919
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
2920
+ #
2921
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
2922
+ #
2923
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
2924
+ #
2925
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
2926
+ #
2927
+ # @param external_price_id [String, nil] An alias for the price.
2928
+ #
2929
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
2930
+ #
2931
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
2932
+ #
2933
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
2934
+ #
2935
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
2936
+ #
2937
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
2938
+ #
2939
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
2940
+ #
2941
+ # @param model_type [Symbol, :event_output] The pricing model type
2942
+
2943
+ # The cadence to bill for this price on.
2944
+ #
2945
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput#cadence
2946
+ module Cadence
2947
+ extend Orb::Internal::Type::Enum
2948
+
2949
+ ANNUAL = :annual
2950
+ SEMI_ANNUAL = :semi_annual
2951
+ MONTHLY = :monthly
2952
+ QUARTERLY = :quarterly
2953
+ ONE_TIME = :one_time
2954
+ CUSTOM = :custom
2955
+
2956
+ # @!method self.values
2957
+ # @return [Array<Symbol>]
2958
+ end
2959
+
2960
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput#event_output_config
2961
+ class EventOutputConfig < Orb::Internal::Type::BaseModel
2962
+ # @!attribute unit_rating_key
2963
+ # The key in the event data to extract the unit rate from.
2964
+ #
2965
+ # @return [String]
2966
+ required :unit_rating_key, String
2967
+
2968
+ # @!attribute default_unit_rate
2969
+ # If provided, this amount will be used as the unit rate when an event does not
2970
+ # have a value for the `unit_rating_key`. If not provided, events missing a unit
2971
+ # rate will be ignored.
2972
+ #
2973
+ # @return [String, nil]
2974
+ optional :default_unit_rate, String, nil?: true
2975
+
2976
+ # @!attribute grouping_key
2977
+ # An optional key in the event data to group by (e.g., event ID). All events will
2978
+ # also be grouped by their unit rate.
2979
+ #
2980
+ # @return [String, nil]
2981
+ optional :grouping_key, String, nil?: true
2982
+
2983
+ # @!method initialize(unit_rating_key:, default_unit_rate: nil, grouping_key: nil)
2984
+ # Some parameter documentations has been truncated, see
2985
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput::EventOutputConfig}
1651
2986
  # for more details.
1652
2987
  #
1653
2988
  # Configuration for event_output pricing
1654
2989
  #
1655
- # @param unit_rating_key [String] The key in the event data to extract the unit rate from.
2990
+ # @param unit_rating_key [String] The key in the event data to extract the unit rate from.
2991
+ #
2992
+ # @param default_unit_rate [String, nil] If provided, this amount will be used as the unit rate when an event does not ha
2993
+ #
2994
+ # @param grouping_key [String, nil] An optional key in the event data to group by (e.g., event ID). All events will
2995
+ end
2996
+ end
2997
+
2998
+ # @!method self.variants
2999
+ # @return [Array(Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MatrixWithThresholdDiscounts, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::DailyCreditAllowance, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::MeteredAllowance, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput)]
3000
+ end
3001
+ end
3002
+
3003
+ class RemoveAdjustment < Orb::Internal::Type::BaseModel
3004
+ # @!attribute adjustment_id
3005
+ # The id of the adjustment to remove from on the plan.
3006
+ #
3007
+ # @return [String]
3008
+ required :adjustment_id, String
3009
+
3010
+ # @!attribute plan_phase_order
3011
+ # The phase to remove this adjustment from.
3012
+ #
3013
+ # @return [Integer, nil]
3014
+ optional :plan_phase_order, Integer, nil?: true
3015
+
3016
+ # @!method initialize(adjustment_id:, plan_phase_order: nil)
3017
+ # @param adjustment_id [String] The id of the adjustment to remove from on the plan.
3018
+ #
3019
+ # @param plan_phase_order [Integer, nil] The phase to remove this adjustment from.
3020
+ end
3021
+
3022
+ class RemovePrice < Orb::Internal::Type::BaseModel
3023
+ # @!attribute price_id
3024
+ # The id of the price to remove from the plan.
3025
+ #
3026
+ # @return [String]
3027
+ required :price_id, String
3028
+
3029
+ # @!attribute plan_phase_order
3030
+ # The phase to remove this price from.
3031
+ #
3032
+ # @return [Integer, nil]
3033
+ optional :plan_phase_order, Integer, nil?: true
3034
+
3035
+ # @!method initialize(price_id:, plan_phase_order: nil)
3036
+ # @param price_id [String] The id of the price to remove from the plan.
3037
+ #
3038
+ # @param plan_phase_order [Integer, nil] The phase to remove this price from.
3039
+ end
3040
+
3041
+ class ReplaceAdjustment < Orb::Internal::Type::BaseModel
3042
+ # @!attribute adjustment
3043
+ # The definition of a new adjustment to create and add to the plan.
3044
+ #
3045
+ # @return [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount]
3046
+ required :adjustment,
3047
+ union: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment }
3048
+
3049
+ # @!attribute replaces_adjustment_id
3050
+ # The id of the adjustment on the plan to replace in the plan.
3051
+ #
3052
+ # @return [String]
3053
+ required :replaces_adjustment_id, String
3054
+
3055
+ # @!attribute plan_phase_order
3056
+ # The phase to replace this adjustment from.
3057
+ #
3058
+ # @return [Integer, nil]
3059
+ optional :plan_phase_order, Integer, nil?: true
3060
+
3061
+ # @!method initialize(adjustment:, replaces_adjustment_id:, plan_phase_order: nil)
3062
+ # @param adjustment [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount] The definition of a new adjustment to create and add to the plan.
3063
+ #
3064
+ # @param replaces_adjustment_id [String] The id of the adjustment on the plan to replace in the plan.
3065
+ #
3066
+ # @param plan_phase_order [Integer, nil] The phase to replace this adjustment from.
3067
+
3068
+ # The definition of a new adjustment to create and add to the plan.
3069
+ #
3070
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment#adjustment
3071
+ module Adjustment
3072
+ extend Orb::Internal::Type::Union
3073
+
3074
+ discriminator :adjustment_type
3075
+
3076
+ variant :percentage_discount, -> { Orb::NewPercentageDiscount }
3077
+
3078
+ variant :usage_discount, -> { Orb::NewUsageDiscount }
3079
+
3080
+ variant :amount_discount, -> { Orb::NewAmountDiscount }
3081
+
3082
+ variant :minimum, -> { Orb::NewMinimum }
3083
+
3084
+ variant :maximum, -> { Orb::NewMaximum }
3085
+
3086
+ variant :tiered_percentage_discount,
3087
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount }
3088
+
3089
+ class TieredPercentageDiscount < Orb::Internal::Type::BaseModel
3090
+ # @!attribute adjustment_type
3091
+ #
3092
+ # @return [Symbol, :tiered_percentage_discount]
3093
+ required :adjustment_type, const: :tiered_percentage_discount
3094
+
3095
+ # @!attribute tiers
3096
+ #
3097
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Tier>]
3098
+ required :tiers,
3099
+ -> do
3100
+ Orb::Internal::Type::ArrayOf[
3101
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Tier
3102
+ ]
3103
+ end
3104
+
3105
+ # @!attribute applies_to_all
3106
+ # If set, the adjustment will apply to every price on the subscription.
3107
+ #
3108
+ # @return [Boolean, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::AppliesToAll, nil]
3109
+ optional :applies_to_all,
3110
+ enum: -> {
3111
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::AppliesToAll
3112
+ },
3113
+ nil?: true
3114
+
3115
+ # @!attribute applies_to_item_ids
3116
+ # The set of item IDs to which this adjustment applies.
3117
+ #
3118
+ # @return [Array<String>, nil]
3119
+ optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
3120
+
3121
+ # @!attribute applies_to_price_ids
3122
+ # The set of price IDs to which this adjustment applies.
3123
+ #
3124
+ # @return [Array<String>, nil]
3125
+ optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
3126
+
3127
+ # @!attribute currency
3128
+ # If set, only prices in the specified currency will have the adjustment applied.
3129
+ #
3130
+ # @return [String, nil]
3131
+ optional :currency, String, nil?: true
3132
+
3133
+ # @!attribute filters
3134
+ # A list of filters that determine which prices this adjustment will apply to.
3135
+ #
3136
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter>, nil]
3137
+ optional :filters,
3138
+ -> do
3139
+ Orb::Internal::Type::ArrayOf[
3140
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter
3141
+ ]
3142
+ end,
3143
+ nil?: true
3144
+
3145
+ # @!attribute is_invoice_level
3146
+ # When false, this adjustment will be applied to a single price. Otherwise, it
3147
+ # will be applied at the invoice level, possibly to multiple prices.
3148
+ #
3149
+ # @return [Boolean, nil]
3150
+ optional :is_invoice_level, Orb::Internal::Type::Boolean
3151
+
3152
+ # @!attribute price_type
3153
+ # If set, only prices of the specified type will have the adjustment applied.
3154
+ #
3155
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::PriceType, nil]
3156
+ optional :price_type,
3157
+ enum: -> {
3158
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::PriceType
3159
+ },
3160
+ nil?: true
3161
+
3162
+ # @!method initialize(tiers:, applies_to_all: nil, applies_to_item_ids: nil, applies_to_price_ids: nil, currency: nil, filters: nil, is_invoice_level: nil, price_type: nil, adjustment_type: :tiered_percentage_discount)
3163
+ # Some parameter documentations has been truncated, see
3164
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount}
3165
+ # for more details.
3166
+ #
3167
+ # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Tier>]
3168
+ #
3169
+ # @param applies_to_all [Boolean, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
3170
+ #
3171
+ # @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
3172
+ #
3173
+ # @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
3174
+ #
3175
+ # @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
3176
+ #
3177
+ # @param filters [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
3178
+ #
3179
+ # @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
3180
+ #
3181
+ # @param price_type [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
3182
+ #
3183
+ # @param adjustment_type [Symbol, :tiered_percentage_discount]
3184
+
3185
+ class Tier < Orb::Internal::Type::BaseModel
3186
+ # @!attribute lower_bound
3187
+ # Exclusive lower bound of cumulative spend for this tier.
3188
+ #
3189
+ # @return [Float]
3190
+ required :lower_bound, Float
3191
+
3192
+ # @!attribute percentage
3193
+ # The percentage (0-1) discounted from spend in this tier.
3194
+ #
3195
+ # @return [Float]
3196
+ required :percentage, Float
3197
+
3198
+ # @!attribute upper_bound
3199
+ # Inclusive upper bound of cumulative spend; null for the final open-ended tier.
3200
+ #
3201
+ # @return [Float, nil]
3202
+ optional :upper_bound, Float, nil?: true
3203
+
3204
+ # @!method initialize(lower_bound:, percentage:, upper_bound: nil)
3205
+ # @param lower_bound [Float] Exclusive lower bound of cumulative spend for this tier.
3206
+ #
3207
+ # @param percentage [Float] The percentage (0-1) discounted from spend in this tier.
3208
+ #
3209
+ # @param upper_bound [Float, nil] Inclusive upper bound of cumulative spend; null for the final open-ended tier.
3210
+ end
3211
+
3212
+ # If set, the adjustment will apply to every price on the subscription.
3213
+ #
3214
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount#applies_to_all
3215
+ module AppliesToAll
3216
+ extend Orb::Internal::Type::Enum
3217
+
3218
+ TRUE = true
3219
+
3220
+ # @!method self.values
3221
+ # @return [Array<Boolean>]
3222
+ end
3223
+
3224
+ class Filter < Orb::Internal::Type::BaseModel
3225
+ # @!attribute field
3226
+ # The property of the price to filter on.
3227
+ #
3228
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter::Field]
3229
+ required :field,
3230
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter::Field }
3231
+
3232
+ # @!attribute operator
3233
+ # Should prices that match the filter be included or excluded.
3234
+ #
3235
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter::Operator]
3236
+ required :operator,
3237
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter::Operator }
3238
+
3239
+ # @!attribute values
3240
+ # The IDs or values that match this filter.
3241
+ #
3242
+ # @return [Array<String>]
3243
+ required :values, Orb::Internal::Type::ArrayOf[String]
3244
+
3245
+ # @!method initialize(field:, operator:, values:)
3246
+ # @param field [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter::Field] The property of the price to filter on.
3247
+ #
3248
+ # @param operator [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
3249
+ #
3250
+ # @param values [Array<String>] The IDs or values that match this filter.
3251
+
3252
+ # The property of the price to filter on.
3253
+ #
3254
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter#field
3255
+ module Field
3256
+ extend Orb::Internal::Type::Enum
3257
+
3258
+ PRICE_ID = :price_id
3259
+ ITEM_ID = :item_id
3260
+ PRICE_TYPE = :price_type
3261
+ CURRENCY = :currency
3262
+ PRICING_UNIT_ID = :pricing_unit_id
3263
+
3264
+ # @!method self.values
3265
+ # @return [Array<Symbol>]
3266
+ end
3267
+
3268
+ # Should prices that match the filter be included or excluded.
3269
+ #
3270
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount::Filter#operator
3271
+ module Operator
3272
+ extend Orb::Internal::Type::Enum
3273
+
3274
+ INCLUDES = :includes
3275
+ EXCLUDES = :excludes
3276
+
3277
+ # @!method self.values
3278
+ # @return [Array<Symbol>]
3279
+ end
3280
+ end
3281
+
3282
+ # If set, only prices of the specified type will have the adjustment applied.
3283
+ #
3284
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount#price_type
3285
+ module PriceType
3286
+ extend Orb::Internal::Type::Enum
3287
+
3288
+ USAGE = :usage
3289
+ FIXED_IN_ADVANCE = :fixed_in_advance
3290
+ FIXED_IN_ARREARS = :fixed_in_arrears
3291
+ FIXED = :fixed
3292
+ IN_ARREARS = :in_arrears
3293
+
3294
+ # @!method self.values
3295
+ # @return [Array<Symbol>]
3296
+ end
3297
+ end
3298
+
3299
+ # @!method self.variants
3300
+ # @return [Array(Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment::TieredPercentageDiscount)]
3301
+ end
3302
+ end
3303
+
3304
+ class ReplacePrice < Orb::Internal::Type::BaseModel
3305
+ # @!attribute replaces_price_id
3306
+ # The id of the price on the plan to replace in the plan.
3307
+ #
3308
+ # @return [String]
3309
+ required :replaces_price_id, String
3310
+
3311
+ # @!attribute allocation_price
3312
+ # The allocation price to add to the plan.
3313
+ #
3314
+ # @return [Orb::Models::NewAllocationPrice, nil]
3315
+ optional :allocation_price, -> { Orb::NewAllocationPrice }, nil?: true
3316
+
3317
+ # @!attribute license_allocation_price
3318
+ # The license allocation price to add to the plan.
3319
+ #
3320
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice, nil]
3321
+ optional :license_allocation_price,
3322
+ -> {
3323
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice
3324
+ },
3325
+ nil?: true
3326
+
3327
+ # @!attribute plan_phase_order
3328
+ # The phase to replace this price from.
3329
+ #
3330
+ # @return [Integer, nil]
3331
+ optional :plan_phase_order, Integer, nil?: true
3332
+
3333
+ # @!attribute price
3334
+ # New plan price request body params.
3335
+ #
3336
+ # @return [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput, nil]
3337
+ optional :price,
3338
+ union: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price },
3339
+ nil?: true
3340
+
3341
+ # @!method initialize(replaces_price_id:, allocation_price: nil, license_allocation_price: nil, plan_phase_order: nil, price: nil)
3342
+ # @param replaces_price_id [String] The id of the price on the plan to replace in the plan.
3343
+ #
3344
+ # @param allocation_price [Orb::Models::NewAllocationPrice, nil] The allocation price to add to the plan.
3345
+ #
3346
+ # @param license_allocation_price [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice, nil] The license allocation price to add to the plan.
3347
+ #
3348
+ # @param plan_phase_order [Integer, nil] The phase to replace this price from.
3349
+ #
3350
+ # @param price [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput, nil] New plan price request body params.
3351
+
3352
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice#license_allocation_price
3353
+ class LicenseAllocationPrice < Orb::Internal::Type::BaseModel
3354
+ # @!attribute cadence
3355
+ # The cadence to bill for this price on.
3356
+ #
3357
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::Cadence]
3358
+ required :cadence,
3359
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::Cadence }
3360
+
3361
+ # @!attribute item_id
3362
+ # The id of the item the price will be associated with.
3363
+ #
3364
+ # @return [String]
3365
+ required :item_id, String
3366
+
3367
+ # @!attribute license_allocations
3368
+ # License allocations to associate with this price. Each entry defines a
3369
+ # per-license credit pool granted each cadence. Requires license_type_id or
3370
+ # license_type_configuration to be set.
3371
+ #
3372
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::LicenseAllocation>]
3373
+ required :license_allocations,
3374
+ -> { Orb::Internal::Type::ArrayOf[Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::LicenseAllocation] }
3375
+
3376
+ # @!attribute model_type
3377
+ # The pricing model type
3378
+ #
3379
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::ModelType]
3380
+ required :model_type,
3381
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::ModelType }
3382
+
3383
+ # @!attribute name
3384
+ # The name of the price.
3385
+ #
3386
+ # @return [String]
3387
+ required :name, String
3388
+
3389
+ # @!attribute unit_config
3390
+ # Configuration for unit pricing
3391
+ #
3392
+ # @return [Orb::Models::UnitConfig]
3393
+ required :unit_config, -> { Orb::UnitConfig }
3394
+
3395
+ # @!attribute billable_metric_id
3396
+ # The id of the billable metric for the price. Only needed if the price is
3397
+ # usage-based.
3398
+ #
3399
+ # @return [String, nil]
3400
+ optional :billable_metric_id, String, nil?: true
3401
+
3402
+ # @!attribute billed_in_advance
3403
+ # If the Price represents a fixed cost, the price will be billed in-advance if
3404
+ # this is true, and in-arrears if this is false.
3405
+ #
3406
+ # @return [Boolean, nil]
3407
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
3408
+
3409
+ # @!attribute billing_cycle_configuration
3410
+ # For custom cadence: specifies the duration of the billing period in days or
3411
+ # months.
3412
+ #
3413
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
3414
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
3415
+
3416
+ # @!attribute conversion_rate
3417
+ # The per unit conversion rate of the price currency to the invoicing currency.
3418
+ #
3419
+ # @return [Float, nil]
3420
+ optional :conversion_rate, Float, nil?: true
3421
+
3422
+ # @!attribute conversion_rate_config
3423
+ # The configuration for the rate of the price currency to the invoicing currency.
3424
+ #
3425
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
3426
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
3427
+
3428
+ # @!attribute currency
3429
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
3430
+ # price is billed.
3431
+ #
3432
+ # @return [String, nil]
3433
+ optional :currency, String, nil?: true
3434
+
3435
+ # @!attribute dimensional_price_configuration
3436
+ # For dimensional price: specifies a price group and dimension values
3437
+ #
3438
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
3439
+ optional :dimensional_price_configuration,
3440
+ -> {
3441
+ Orb::NewDimensionalPriceConfiguration
3442
+ },
3443
+ nil?: true
3444
+
3445
+ # @!attribute external_price_id
3446
+ # An alias for the price.
3447
+ #
3448
+ # @return [String, nil]
3449
+ optional :external_price_id, String, nil?: true
3450
+
3451
+ # @!attribute fixed_price_quantity
3452
+ # If the Price represents a fixed cost, this represents the quantity of units
3453
+ # applied.
3454
+ #
3455
+ # @return [Float, nil]
3456
+ optional :fixed_price_quantity, Float, nil?: true
3457
+
3458
+ # @!attribute invoice_grouping_key
3459
+ # The property used to group this price on an invoice
3460
+ #
3461
+ # @return [String, nil]
3462
+ optional :invoice_grouping_key, String, nil?: true
3463
+
3464
+ # @!attribute invoicing_cycle_configuration
3465
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
3466
+ # If unspecified, a single invoice is produced per billing cycle.
3467
+ #
3468
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
3469
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
3470
+
3471
+ # @!attribute license_type_id
3472
+ # The ID of the license type to associate with this price.
3473
+ #
3474
+ # @return [String, nil]
3475
+ optional :license_type_id, String, nil?: true
3476
+
3477
+ # @!attribute metadata
3478
+ # User-specified key/value pairs for the resource. Individual keys can be removed
3479
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
3480
+ # by setting `metadata` to `null`.
3481
+ #
3482
+ # @return [Hash{Symbol=>String, nil}, nil]
3483
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
3484
+
3485
+ # @!attribute reference_id
3486
+ # A transient ID that can be used to reference this price when adding adjustments
3487
+ # in the same API call.
3488
+ #
3489
+ # @return [String, nil]
3490
+ optional :reference_id, String, nil?: true
3491
+
3492
+ # @!method initialize(cadence:, item_id:, license_allocations:, model_type:, name:, unit_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil)
3493
+ # Some parameter documentations has been truncated, see
3494
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice}
3495
+ # for more details.
3496
+ #
3497
+ # The license allocation price to add to the plan.
3498
+ #
3499
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::Cadence] The cadence to bill for this price on.
3500
+ #
3501
+ # @param item_id [String] The id of the item the price will be associated with.
3502
+ #
3503
+ # @param license_allocations [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::LicenseAllocation>] License allocations to associate with this price. Each entry defines a per-licen
3504
+ #
3505
+ # @param model_type [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice::ModelType] The pricing model type
3506
+ #
3507
+ # @param name [String] The name of the price.
3508
+ #
3509
+ # @param unit_config [Orb::Models::UnitConfig] Configuration for unit pricing
3510
+ #
3511
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
3512
+ #
3513
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
3514
+ #
3515
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
3516
+ #
3517
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
3518
+ #
3519
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
3520
+ #
3521
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
3522
+ #
3523
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
3524
+ #
3525
+ # @param external_price_id [String, nil] An alias for the price.
3526
+ #
3527
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
3528
+ #
3529
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
3530
+ #
3531
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
3532
+ #
3533
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
3534
+ #
3535
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
3536
+ #
3537
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
3538
+
3539
+ # The cadence to bill for this price on.
3540
+ #
3541
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice#cadence
3542
+ module Cadence
3543
+ extend Orb::Internal::Type::Enum
3544
+
3545
+ ANNUAL = :annual
3546
+ SEMI_ANNUAL = :semi_annual
3547
+ MONTHLY = :monthly
3548
+ QUARTERLY = :quarterly
3549
+ ONE_TIME = :one_time
3550
+ CUSTOM = :custom
3551
+
3552
+ # @!method self.values
3553
+ # @return [Array<Symbol>]
3554
+ end
3555
+
3556
+ class LicenseAllocation < Orb::Internal::Type::BaseModel
3557
+ # @!attribute amount
3558
+ # The amount of credits granted per active license per cadence.
3559
+ #
3560
+ # @return [String]
3561
+ required :amount, String
3562
+
3563
+ # @!attribute currency
3564
+ # The currency of the license allocation.
3565
+ #
3566
+ # @return [String]
3567
+ required :currency, String
3568
+
3569
+ # @!attribute write_off_overage
3570
+ # When True, overage beyond the allocation is written off.
3571
+ #
3572
+ # @return [Boolean, nil]
3573
+ optional :write_off_overage, Orb::Internal::Type::Boolean, nil?: true
3574
+
3575
+ # @!method initialize(amount:, currency:, write_off_overage: nil)
3576
+ # @param amount [String] The amount of credits granted per active license per cadence.
3577
+ #
3578
+ # @param currency [String] The currency of the license allocation.
3579
+ #
3580
+ # @param write_off_overage [Boolean, nil] When True, overage beyond the allocation is written off.
3581
+ end
3582
+
3583
+ # The pricing model type
3584
+ #
3585
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::LicenseAllocationPrice#model_type
3586
+ module ModelType
3587
+ extend Orb::Internal::Type::Enum
3588
+
3589
+ UNIT = :unit
3590
+
3591
+ # @!method self.values
3592
+ # @return [Array<Symbol>]
3593
+ end
3594
+ end
3595
+
3596
+ # New plan price request body params.
3597
+ #
3598
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice#price
3599
+ module Price
3600
+ extend Orb::Internal::Type::Union
3601
+
3602
+ discriminator :model_type
3603
+
3604
+ variant :unit, -> { Orb::NewPlanUnitPrice }
3605
+
3606
+ variant :tiered, -> { Orb::NewPlanTieredPrice }
3607
+
3608
+ variant :bulk, -> { Orb::NewPlanBulkPrice }
3609
+
3610
+ variant :bulk_with_filters,
3611
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters }
3612
+
3613
+ variant :package, -> { Orb::NewPlanPackagePrice }
3614
+
3615
+ variant :matrix, -> { Orb::NewPlanMatrixPrice }
3616
+
3617
+ variant :threshold_total_amount, -> { Orb::NewPlanThresholdTotalAmountPrice }
3618
+
3619
+ variant :tiered_package, -> { Orb::NewPlanTieredPackagePrice }
3620
+
3621
+ variant :tiered_with_minimum, -> { Orb::NewPlanTieredWithMinimumPrice }
3622
+
3623
+ variant :grouped_tiered, -> { Orb::NewPlanGroupedTieredPrice }
3624
+
3625
+ variant :tiered_package_with_minimum, -> { Orb::NewPlanTieredPackageWithMinimumPrice }
3626
+
3627
+ variant :package_with_allocation, -> { Orb::NewPlanPackageWithAllocationPrice }
3628
+
3629
+ variant :unit_with_percent, -> { Orb::NewPlanUnitWithPercentPrice }
3630
+
3631
+ variant :matrix_with_allocation, -> { Orb::NewPlanMatrixWithAllocationPrice }
3632
+
3633
+ variant :matrix_with_threshold_discounts,
3634
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts }
3635
+
3636
+ variant :tiered_with_proration,
3637
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration }
3638
+
3639
+ variant :unit_with_proration, -> { Orb::NewPlanUnitWithProrationPrice }
3640
+
3641
+ variant :grouped_allocation, -> { Orb::NewPlanGroupedAllocationPrice }
3642
+
3643
+ variant :bulk_with_proration, -> { Orb::NewPlanBulkWithProrationPrice }
3644
+
3645
+ variant :grouped_with_prorated_minimum, -> { Orb::NewPlanGroupedWithProratedMinimumPrice }
3646
+
3647
+ variant :grouped_with_metered_minimum, -> { Orb::NewPlanGroupedWithMeteredMinimumPrice }
3648
+
3649
+ variant :grouped_with_min_max_thresholds,
3650
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds }
3651
+
3652
+ variant :matrix_with_display_name, -> { Orb::NewPlanMatrixWithDisplayNamePrice }
3653
+
3654
+ variant :grouped_tiered_package, -> { Orb::NewPlanGroupedTieredPackagePrice }
3655
+
3656
+ variant :max_group_tiered_package, -> { Orb::NewPlanMaxGroupTieredPackagePrice }
3657
+
3658
+ variant :scalable_matrix_with_unit_pricing, -> { Orb::NewPlanScalableMatrixWithUnitPricingPrice }
3659
+
3660
+ variant :scalable_matrix_with_tiered_pricing, -> { Orb::NewPlanScalableMatrixWithTieredPricingPrice }
3661
+
3662
+ variant :cumulative_grouped_bulk, -> { Orb::NewPlanCumulativeGroupedBulkPrice }
3663
+
3664
+ variant :cumulative_grouped_allocation,
3665
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation }
3666
+
3667
+ variant :daily_credit_allowance,
3668
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance }
3669
+
3670
+ variant :metered_allowance,
3671
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance }
3672
+
3673
+ variant :minimum_composite, -> { Orb::NewPlanMinimumCompositePrice }
3674
+
3675
+ variant :percent, -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent }
3676
+
3677
+ variant :event_output,
3678
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput }
3679
+
3680
+ class BulkWithFilters < Orb::Internal::Type::BaseModel
3681
+ # @!attribute bulk_with_filters_config
3682
+ # Configuration for bulk_with_filters pricing
3683
+ #
3684
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig]
3685
+ required :bulk_with_filters_config,
3686
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig }
3687
+
3688
+ # @!attribute cadence
3689
+ # The cadence to bill for this price on.
3690
+ #
3691
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::Cadence]
3692
+ required :cadence,
3693
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::Cadence }
3694
+
3695
+ # @!attribute item_id
3696
+ # The id of the item the price will be associated with.
3697
+ #
3698
+ # @return [String]
3699
+ required :item_id, String
3700
+
3701
+ # @!attribute model_type
3702
+ # The pricing model type
3703
+ #
3704
+ # @return [Symbol, :bulk_with_filters]
3705
+ required :model_type, const: :bulk_with_filters
3706
+
3707
+ # @!attribute name
3708
+ # The name of the price.
3709
+ #
3710
+ # @return [String]
3711
+ required :name, String
3712
+
3713
+ # @!attribute billable_metric_id
3714
+ # The id of the billable metric for the price. Only needed if the price is
3715
+ # usage-based.
3716
+ #
3717
+ # @return [String, nil]
3718
+ optional :billable_metric_id, String, nil?: true
3719
+
3720
+ # @!attribute billed_in_advance
3721
+ # If the Price represents a fixed cost, the price will be billed in-advance if
3722
+ # this is true, and in-arrears if this is false.
3723
+ #
3724
+ # @return [Boolean, nil]
3725
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
3726
+
3727
+ # @!attribute billing_cycle_configuration
3728
+ # For custom cadence: specifies the duration of the billing period in days or
3729
+ # months.
3730
+ #
3731
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
3732
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
3733
+
3734
+ # @!attribute conversion_rate
3735
+ # The per unit conversion rate of the price currency to the invoicing currency.
3736
+ #
3737
+ # @return [Float, nil]
3738
+ optional :conversion_rate, Float, nil?: true
3739
+
3740
+ # @!attribute conversion_rate_config
3741
+ # The configuration for the rate of the price currency to the invoicing currency.
3742
+ #
3743
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
3744
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
3745
+
3746
+ # @!attribute currency
3747
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
3748
+ # price is billed.
3749
+ #
3750
+ # @return [String, nil]
3751
+ optional :currency, String, nil?: true
3752
+
3753
+ # @!attribute dimensional_price_configuration
3754
+ # For dimensional price: specifies a price group and dimension values
3755
+ #
3756
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
3757
+ optional :dimensional_price_configuration,
3758
+ -> {
3759
+ Orb::NewDimensionalPriceConfiguration
3760
+ },
3761
+ nil?: true
3762
+
3763
+ # @!attribute external_price_id
3764
+ # An alias for the price.
3765
+ #
3766
+ # @return [String, nil]
3767
+ optional :external_price_id, String, nil?: true
3768
+
3769
+ # @!attribute fixed_price_quantity
3770
+ # If the Price represents a fixed cost, this represents the quantity of units
3771
+ # applied.
3772
+ #
3773
+ # @return [Float, nil]
3774
+ optional :fixed_price_quantity, Float, nil?: true
3775
+
3776
+ # @!attribute invoice_grouping_key
3777
+ # The property used to group this price on an invoice
3778
+ #
3779
+ # @return [String, nil]
3780
+ optional :invoice_grouping_key, String, nil?: true
3781
+
3782
+ # @!attribute invoicing_cycle_configuration
3783
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
3784
+ # If unspecified, a single invoice is produced per billing cycle.
3785
+ #
3786
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
3787
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
3788
+
3789
+ # @!attribute license_type_id
3790
+ # The ID of the license type to associate with this price.
3791
+ #
3792
+ # @return [String, nil]
3793
+ optional :license_type_id, String, nil?: true
3794
+
3795
+ # @!attribute metadata
3796
+ # User-specified key/value pairs for the resource. Individual keys can be removed
3797
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
3798
+ # by setting `metadata` to `null`.
3799
+ #
3800
+ # @return [Hash{Symbol=>String, nil}, nil]
3801
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
3802
+
3803
+ # @!attribute reference_id
3804
+ # A transient ID that can be used to reference this price when adding adjustments
3805
+ # in the same API call.
3806
+ #
3807
+ # @return [String, nil]
3808
+ optional :reference_id, String, nil?: true
3809
+
3810
+ # @!method initialize(bulk_with_filters_config:, cadence:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :bulk_with_filters)
3811
+ # Some parameter documentations has been truncated, see
3812
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters}
3813
+ # for more details.
3814
+ #
3815
+ # @param bulk_with_filters_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig] Configuration for bulk_with_filters pricing
3816
+ #
3817
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::Cadence] The cadence to bill for this price on.
3818
+ #
3819
+ # @param item_id [String] The id of the item the price will be associated with.
3820
+ #
3821
+ # @param name [String] The name of the price.
3822
+ #
3823
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
3824
+ #
3825
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
3826
+ #
3827
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
3828
+ #
3829
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
3830
+ #
3831
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
3832
+ #
3833
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
3834
+ #
3835
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
3836
+ #
3837
+ # @param external_price_id [String, nil] An alias for the price.
3838
+ #
3839
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
3840
+ #
3841
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
3842
+ #
3843
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
3844
+ #
3845
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
3846
+ #
3847
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
3848
+ #
3849
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
3850
+ #
3851
+ # @param model_type [Symbol, :bulk_with_filters] The pricing model type
3852
+
3853
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters#bulk_with_filters_config
3854
+ class BulkWithFiltersConfig < Orb::Internal::Type::BaseModel
3855
+ # @!attribute filters
3856
+ # Property filters to apply (all must match)
3857
+ #
3858
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Filter>]
3859
+ required :filters,
3860
+ -> do
3861
+ Orb::Internal::Type::ArrayOf[
3862
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Filter
3863
+ ]
3864
+ end
3865
+
3866
+ # @!attribute tiers
3867
+ # Bulk tiers for rating based on total usage volume
3868
+ #
3869
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Tier>]
3870
+ required :tiers,
3871
+ -> do
3872
+ Orb::Internal::Type::ArrayOf[
3873
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Tier
3874
+ ]
3875
+ end
3876
+
3877
+ # @!method initialize(filters:, tiers:)
3878
+ # Configuration for bulk_with_filters pricing
1656
3879
  #
1657
- # @param default_unit_rate [String, nil] If provided, this amount will be used as the unit rate when an event does not ha
3880
+ # @param filters [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Filter>] Property filters to apply (all must match)
1658
3881
  #
1659
- # @param grouping_key [String, nil] An optional key in the event data to group by (e.g., event ID). All events will
3882
+ # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Tier>] Bulk tiers for rating based on total usage volume
3883
+
3884
+ class Filter < Orb::Internal::Type::BaseModel
3885
+ # @!attribute property_key
3886
+ # Event property key to filter on
3887
+ #
3888
+ # @return [String]
3889
+ required :property_key, String
3890
+
3891
+ # @!attribute property_value
3892
+ # Event property value to match
3893
+ #
3894
+ # @return [String]
3895
+ required :property_value, String
3896
+
3897
+ # @!method initialize(property_key:, property_value:)
3898
+ # Configuration for a single property filter
3899
+ #
3900
+ # @param property_key [String] Event property key to filter on
3901
+ #
3902
+ # @param property_value [String] Event property value to match
3903
+ end
3904
+
3905
+ class Tier < Orb::Internal::Type::BaseModel
3906
+ # @!attribute unit_amount
3907
+ # Amount per unit
3908
+ #
3909
+ # @return [String]
3910
+ required :unit_amount, String
3911
+
3912
+ # @!attribute tier_lower_bound
3913
+ # The lower bound for this tier
3914
+ #
3915
+ # @return [String, nil]
3916
+ optional :tier_lower_bound, String, nil?: true
3917
+
3918
+ # @!method initialize(unit_amount:, tier_lower_bound: nil)
3919
+ # Configuration for a single bulk pricing tier
3920
+ #
3921
+ # @param unit_amount [String] Amount per unit
3922
+ #
3923
+ # @param tier_lower_bound [String, nil] The lower bound for this tier
3924
+ end
3925
+ end
3926
+
3927
+ # The cadence to bill for this price on.
3928
+ #
3929
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters#cadence
3930
+ module Cadence
3931
+ extend Orb::Internal::Type::Enum
3932
+
3933
+ ANNUAL = :annual
3934
+ SEMI_ANNUAL = :semi_annual
3935
+ MONTHLY = :monthly
3936
+ QUARTERLY = :quarterly
3937
+ ONE_TIME = :one_time
3938
+ CUSTOM = :custom
3939
+
3940
+ # @!method self.values
3941
+ # @return [Array<Symbol>]
1660
3942
  end
1661
3943
  end
1662
3944
 
1663
- # @!method self.variants
1664
- # @return [Array(Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::CumulativeGroupedAllocation, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddPrice::Price::EventOutput)]
1665
- end
1666
- end
3945
+ class MatrixWithThresholdDiscounts < Orb::Internal::Type::BaseModel
3946
+ # @!attribute cadence
3947
+ # The cadence to bill for this price on.
3948
+ #
3949
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::Cadence]
3950
+ required :cadence,
3951
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::Cadence }
1667
3952
 
1668
- class RemoveAdjustment < Orb::Internal::Type::BaseModel
1669
- # @!attribute adjustment_id
1670
- # The id of the adjustment to remove from on the plan.
1671
- #
1672
- # @return [String]
1673
- required :adjustment_id, String
3953
+ # @!attribute item_id
3954
+ # The id of the item the price will be associated with.
3955
+ #
3956
+ # @return [String]
3957
+ required :item_id, String
1674
3958
 
1675
- # @!attribute plan_phase_order
1676
- # The phase to remove this adjustment from.
1677
- #
1678
- # @return [Integer, nil]
1679
- optional :plan_phase_order, Integer, nil?: true
3959
+ # @!attribute matrix_with_threshold_discounts_config
3960
+ # Configuration for matrix_with_threshold_discounts pricing
3961
+ #
3962
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig]
3963
+ required :matrix_with_threshold_discounts_config,
3964
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig }
1680
3965
 
1681
- # @!method initialize(adjustment_id:, plan_phase_order: nil)
1682
- # @param adjustment_id [String] The id of the adjustment to remove from on the plan.
1683
- #
1684
- # @param plan_phase_order [Integer, nil] The phase to remove this adjustment from.
1685
- end
3966
+ # @!attribute model_type
3967
+ # The pricing model type
3968
+ #
3969
+ # @return [Symbol, :matrix_with_threshold_discounts]
3970
+ required :model_type, const: :matrix_with_threshold_discounts
1686
3971
 
1687
- class RemovePrice < Orb::Internal::Type::BaseModel
1688
- # @!attribute price_id
1689
- # The id of the price to remove from the plan.
1690
- #
1691
- # @return [String]
1692
- required :price_id, String
3972
+ # @!attribute name
3973
+ # The name of the price.
3974
+ #
3975
+ # @return [String]
3976
+ required :name, String
1693
3977
 
1694
- # @!attribute plan_phase_order
1695
- # The phase to remove this price from.
1696
- #
1697
- # @return [Integer, nil]
1698
- optional :plan_phase_order, Integer, nil?: true
3978
+ # @!attribute billable_metric_id
3979
+ # The id of the billable metric for the price. Only needed if the price is
3980
+ # usage-based.
3981
+ #
3982
+ # @return [String, nil]
3983
+ optional :billable_metric_id, String, nil?: true
1699
3984
 
1700
- # @!method initialize(price_id:, plan_phase_order: nil)
1701
- # @param price_id [String] The id of the price to remove from the plan.
1702
- #
1703
- # @param plan_phase_order [Integer, nil] The phase to remove this price from.
1704
- end
3985
+ # @!attribute billed_in_advance
3986
+ # If the Price represents a fixed cost, the price will be billed in-advance if
3987
+ # this is true, and in-arrears if this is false.
3988
+ #
3989
+ # @return [Boolean, nil]
3990
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
1705
3991
 
1706
- class ReplaceAdjustment < Orb::Internal::Type::BaseModel
1707
- # @!attribute adjustment
1708
- # The definition of a new adjustment to create and add to the plan.
1709
- #
1710
- # @return [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum]
1711
- required :adjustment,
1712
- union: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment::Adjustment }
3992
+ # @!attribute billing_cycle_configuration
3993
+ # For custom cadence: specifies the duration of the billing period in days or
3994
+ # months.
3995
+ #
3996
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
3997
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
1713
3998
 
1714
- # @!attribute replaces_adjustment_id
1715
- # The id of the adjustment on the plan to replace in the plan.
1716
- #
1717
- # @return [String]
1718
- required :replaces_adjustment_id, String
3999
+ # @!attribute conversion_rate
4000
+ # The per unit conversion rate of the price currency to the invoicing currency.
4001
+ #
4002
+ # @return [Float, nil]
4003
+ optional :conversion_rate, Float, nil?: true
1719
4004
 
1720
- # @!attribute plan_phase_order
1721
- # The phase to replace this adjustment from.
1722
- #
1723
- # @return [Integer, nil]
1724
- optional :plan_phase_order, Integer, nil?: true
4005
+ # @!attribute conversion_rate_config
4006
+ # The configuration for the rate of the price currency to the invoicing currency.
4007
+ #
4008
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
4009
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
1725
4010
 
1726
- # @!method initialize(adjustment:, replaces_adjustment_id:, plan_phase_order: nil)
1727
- # @param adjustment [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum] The definition of a new adjustment to create and add to the plan.
1728
- #
1729
- # @param replaces_adjustment_id [String] The id of the adjustment on the plan to replace in the plan.
1730
- #
1731
- # @param plan_phase_order [Integer, nil] The phase to replace this adjustment from.
4011
+ # @!attribute currency
4012
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
4013
+ # price is billed.
4014
+ #
4015
+ # @return [String, nil]
4016
+ optional :currency, String, nil?: true
4017
+
4018
+ # @!attribute dimensional_price_configuration
4019
+ # For dimensional price: specifies a price group and dimension values
4020
+ #
4021
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
4022
+ optional :dimensional_price_configuration,
4023
+ -> {
4024
+ Orb::NewDimensionalPriceConfiguration
4025
+ },
4026
+ nil?: true
4027
+
4028
+ # @!attribute external_price_id
4029
+ # An alias for the price.
4030
+ #
4031
+ # @return [String, nil]
4032
+ optional :external_price_id, String, nil?: true
4033
+
4034
+ # @!attribute fixed_price_quantity
4035
+ # If the Price represents a fixed cost, this represents the quantity of units
4036
+ # applied.
4037
+ #
4038
+ # @return [Float, nil]
4039
+ optional :fixed_price_quantity, Float, nil?: true
4040
+
4041
+ # @!attribute invoice_grouping_key
4042
+ # The property used to group this price on an invoice
4043
+ #
4044
+ # @return [String, nil]
4045
+ optional :invoice_grouping_key, String, nil?: true
4046
+
4047
+ # @!attribute invoicing_cycle_configuration
4048
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
4049
+ # If unspecified, a single invoice is produced per billing cycle.
4050
+ #
4051
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
4052
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
4053
+
4054
+ # @!attribute license_type_id
4055
+ # The ID of the license type to associate with this price.
4056
+ #
4057
+ # @return [String, nil]
4058
+ optional :license_type_id, String, nil?: true
4059
+
4060
+ # @!attribute metadata
4061
+ # User-specified key/value pairs for the resource. Individual keys can be removed
4062
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
4063
+ # by setting `metadata` to `null`.
4064
+ #
4065
+ # @return [Hash{Symbol=>String, nil}, nil]
4066
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
4067
+
4068
+ # @!attribute reference_id
4069
+ # A transient ID that can be used to reference this price when adding adjustments
4070
+ # in the same API call.
4071
+ #
4072
+ # @return [String, nil]
4073
+ optional :reference_id, String, nil?: true
4074
+
4075
+ # @!method initialize(cadence:, item_id:, matrix_with_threshold_discounts_config:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :matrix_with_threshold_discounts)
4076
+ # Some parameter documentations has been truncated, see
4077
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts}
4078
+ # for more details.
4079
+ #
4080
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::Cadence] The cadence to bill for this price on.
4081
+ #
4082
+ # @param item_id [String] The id of the item the price will be associated with.
4083
+ #
4084
+ # @param matrix_with_threshold_discounts_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig] Configuration for matrix_with_threshold_discounts pricing
4085
+ #
4086
+ # @param name [String] The name of the price.
4087
+ #
4088
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
4089
+ #
4090
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
4091
+ #
4092
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
4093
+ #
4094
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
4095
+ #
4096
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
4097
+ #
4098
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
4099
+ #
4100
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
4101
+ #
4102
+ # @param external_price_id [String, nil] An alias for the price.
4103
+ #
4104
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
4105
+ #
4106
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
4107
+ #
4108
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
4109
+ #
4110
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
4111
+ #
4112
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
4113
+ #
4114
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
4115
+ #
4116
+ # @param model_type [Symbol, :matrix_with_threshold_discounts] The pricing model type
1732
4117
 
1733
- # The definition of a new adjustment to create and add to the plan.
1734
- #
1735
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplaceAdjustment#adjustment
1736
- module Adjustment
1737
- extend Orb::Internal::Type::Union
4118
+ # The cadence to bill for this price on.
4119
+ #
4120
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts#cadence
4121
+ module Cadence
4122
+ extend Orb::Internal::Type::Enum
1738
4123
 
1739
- discriminator :adjustment_type
4124
+ ANNUAL = :annual
4125
+ SEMI_ANNUAL = :semi_annual
4126
+ MONTHLY = :monthly
4127
+ QUARTERLY = :quarterly
4128
+ ONE_TIME = :one_time
4129
+ CUSTOM = :custom
1740
4130
 
1741
- variant :percentage_discount, -> { Orb::NewPercentageDiscount }
4131
+ # @!method self.values
4132
+ # @return [Array<Symbol>]
4133
+ end
1742
4134
 
1743
- variant :usage_discount, -> { Orb::NewUsageDiscount }
4135
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts#matrix_with_threshold_discounts_config
4136
+ class MatrixWithThresholdDiscountsConfig < Orb::Internal::Type::BaseModel
4137
+ # @!attribute default_unit_amount
4138
+ # Unit price used for usage that does not match any defined matrix cell.
4139
+ #
4140
+ # @return [String]
4141
+ required :default_unit_amount, String
1744
4142
 
1745
- variant :amount_discount, -> { Orb::NewAmountDiscount }
4143
+ # @!attribute first_dimension
4144
+ # First matrix dimension key.
4145
+ #
4146
+ # @return [String]
4147
+ required :first_dimension, String
1746
4148
 
1747
- variant :minimum, -> { Orb::NewMinimum }
4149
+ # @!attribute matrix_values
4150
+ # Per-cell unit prices.
4151
+ #
4152
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::MatrixValue>]
4153
+ required :matrix_values,
4154
+ -> do
4155
+ Orb::Internal::Type::ArrayOf[
4156
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::MatrixValue
4157
+ ]
4158
+ end
1748
4159
 
1749
- variant :maximum, -> { Orb::NewMaximum }
4160
+ # @!attribute second_dimension
4161
+ # Optional second matrix dimension key.
4162
+ #
4163
+ # @return [String, nil]
4164
+ optional :second_dimension, String, nil?: true
1750
4165
 
1751
- # @!method self.variants
1752
- # @return [Array(Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum)]
1753
- end
1754
- end
4166
+ # @!attribute threshold_discount_groups
4167
+ #
4168
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup>, nil]
4169
+ optional :threshold_discount_groups,
4170
+ -> do
4171
+ Orb::Internal::Type::ArrayOf[
4172
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup
4173
+ ]
4174
+ end
1755
4175
 
1756
- class ReplacePrice < Orb::Internal::Type::BaseModel
1757
- # @!attribute replaces_price_id
1758
- # The id of the price on the plan to replace in the plan.
1759
- #
1760
- # @return [String]
1761
- required :replaces_price_id, String
4176
+ # @!method initialize(default_unit_amount:, first_dimension:, matrix_values:, second_dimension: nil, threshold_discount_groups: nil)
4177
+ # Configuration for matrix_with_threshold_discounts pricing
4178
+ #
4179
+ # @param default_unit_amount [String] Unit price used for usage that does not match any defined matrix cell.
4180
+ #
4181
+ # @param first_dimension [String] First matrix dimension key.
4182
+ #
4183
+ # @param matrix_values [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::MatrixValue>] Per-cell unit prices.
4184
+ #
4185
+ # @param second_dimension [String, nil] Optional second matrix dimension key.
4186
+ #
4187
+ # @param threshold_discount_groups [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup>]
1762
4188
 
1763
- # @!attribute allocation_price
1764
- # The allocation price to add to the plan.
1765
- #
1766
- # @return [Orb::Models::NewAllocationPrice, nil]
1767
- optional :allocation_price, -> { Orb::NewAllocationPrice }, nil?: true
4189
+ class MatrixValue < Orb::Internal::Type::BaseModel
4190
+ # @!attribute first_dimension_value
4191
+ #
4192
+ # @return [String]
4193
+ required :first_dimension_value, String
1768
4194
 
1769
- # @!attribute plan_phase_order
1770
- # The phase to replace this price from.
1771
- #
1772
- # @return [Integer, nil]
1773
- optional :plan_phase_order, Integer, nil?: true
4195
+ # @!attribute unit_amount
4196
+ #
4197
+ # @return [String]
4198
+ required :unit_amount, String
1774
4199
 
1775
- # @!attribute price
1776
- # New plan price request body params.
1777
- #
1778
- # @return [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput, nil]
1779
- optional :price,
1780
- union: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price },
1781
- nil?: true
4200
+ # @!attribute second_dimension_value
4201
+ #
4202
+ # @return [String, nil]
4203
+ optional :second_dimension_value, String, nil?: true
1782
4204
 
1783
- # @!method initialize(replaces_price_id:, allocation_price: nil, plan_phase_order: nil, price: nil)
1784
- # @param replaces_price_id [String] The id of the price on the plan to replace in the plan.
1785
- #
1786
- # @param allocation_price [Orb::Models::NewAllocationPrice, nil] The allocation price to add to the plan.
1787
- #
1788
- # @param plan_phase_order [Integer, nil] The phase to replace this price from.
1789
- #
1790
- # @param price [Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput, nil] New plan price request body params.
4205
+ # @!method initialize(first_dimension_value:, unit_amount:, second_dimension_value: nil)
4206
+ # @param first_dimension_value [String]
4207
+ # @param unit_amount [String]
4208
+ # @param second_dimension_value [String, nil]
4209
+ end
1791
4210
 
1792
- # New plan price request body params.
1793
- #
1794
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice#price
1795
- module Price
1796
- extend Orb::Internal::Type::Union
4211
+ class ThresholdDiscountGroup < Orb::Internal::Type::BaseModel
4212
+ # @!attribute above_threshold_discount_percentage
4213
+ # Discount rate applied to spend above the threshold.
4214
+ #
4215
+ # @return [String]
4216
+ required :above_threshold_discount_percentage, String
1797
4217
 
1798
- discriminator :model_type
4218
+ # @!attribute below_threshold_discount_percentage
4219
+ # Discount rate applied to spend at or below the threshold. Set to 0 for no
4220
+ # baseline discount.
4221
+ #
4222
+ # @return [String]
4223
+ required :below_threshold_discount_percentage, String
1799
4224
 
1800
- variant :unit, -> { Orb::NewPlanUnitPrice }
4225
+ # @!attribute cell_coordinates
4226
+ # Semicolon-separated list of matrix cell coordinates targeted by this group. Each
4227
+ # coordinate is `first,second` when the matrix has two dimensions, or just `first`
4228
+ # for a single-dimension matrix. Example: `blue,circle;green,triangle`.
4229
+ #
4230
+ # @return [String]
4231
+ required :cell_coordinates, String
1801
4232
 
1802
- variant :tiered, -> { Orb::NewPlanTieredPrice }
4233
+ # @!attribute threshold_amount
4234
+ #
4235
+ # @return [String]
4236
+ required :threshold_amount, String
1803
4237
 
1804
- variant :bulk, -> { Orb::NewPlanBulkPrice }
4238
+ # @!attribute description
4239
+ #
4240
+ # @return [String, nil]
4241
+ optional :description, String, nil?: true
1805
4242
 
1806
- variant :bulk_with_filters,
1807
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters }
4243
+ # @!method initialize(above_threshold_discount_percentage:, below_threshold_discount_percentage:, cell_coordinates:, threshold_amount:, description: nil)
4244
+ # Some parameter documentations has been truncated, see
4245
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts::MatrixWithThresholdDiscountsConfig::ThresholdDiscountGroup}
4246
+ # for more details.
4247
+ #
4248
+ # @param above_threshold_discount_percentage [String] Discount rate applied to spend above the threshold.
4249
+ #
4250
+ # @param below_threshold_discount_percentage [String] Discount rate applied to spend at or below the threshold. Set to 0 for no baseli
4251
+ #
4252
+ # @param cell_coordinates [String] Semicolon-separated list of matrix cell coordinates targeted by this group. Each
4253
+ #
4254
+ # @param threshold_amount [String]
4255
+ #
4256
+ # @param description [String, nil]
4257
+ end
4258
+ end
4259
+ end
1808
4260
 
1809
- variant :package, -> { Orb::NewPlanPackagePrice }
4261
+ class TieredWithProration < Orb::Internal::Type::BaseModel
4262
+ # @!attribute cadence
4263
+ # The cadence to bill for this price on.
4264
+ #
4265
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::Cadence]
4266
+ required :cadence,
4267
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::Cadence }
1810
4268
 
1811
- variant :matrix, -> { Orb::NewPlanMatrixPrice }
4269
+ # @!attribute item_id
4270
+ # The id of the item the price will be associated with.
4271
+ #
4272
+ # @return [String]
4273
+ required :item_id, String
1812
4274
 
1813
- variant :threshold_total_amount, -> { Orb::NewPlanThresholdTotalAmountPrice }
4275
+ # @!attribute model_type
4276
+ # The pricing model type
4277
+ #
4278
+ # @return [Symbol, :tiered_with_proration]
4279
+ required :model_type, const: :tiered_with_proration
1814
4280
 
1815
- variant :tiered_package, -> { Orb::NewPlanTieredPackagePrice }
4281
+ # @!attribute name
4282
+ # The name of the price.
4283
+ #
4284
+ # @return [String]
4285
+ required :name, String
1816
4286
 
1817
- variant :tiered_with_minimum, -> { Orb::NewPlanTieredWithMinimumPrice }
4287
+ # @!attribute tiered_with_proration_config
4288
+ # Configuration for tiered_with_proration pricing
4289
+ #
4290
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig]
4291
+ required :tiered_with_proration_config,
4292
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig }
1818
4293
 
1819
- variant :grouped_tiered, -> { Orb::NewPlanGroupedTieredPrice }
4294
+ # @!attribute billable_metric_id
4295
+ # The id of the billable metric for the price. Only needed if the price is
4296
+ # usage-based.
4297
+ #
4298
+ # @return [String, nil]
4299
+ optional :billable_metric_id, String, nil?: true
1820
4300
 
1821
- variant :tiered_package_with_minimum, -> { Orb::NewPlanTieredPackageWithMinimumPrice }
4301
+ # @!attribute billed_in_advance
4302
+ # If the Price represents a fixed cost, the price will be billed in-advance if
4303
+ # this is true, and in-arrears if this is false.
4304
+ #
4305
+ # @return [Boolean, nil]
4306
+ optional :billed_in_advance, Orb::Internal::Type::Boolean, nil?: true
1822
4307
 
1823
- variant :package_with_allocation, -> { Orb::NewPlanPackageWithAllocationPrice }
4308
+ # @!attribute billing_cycle_configuration
4309
+ # For custom cadence: specifies the duration of the billing period in days or
4310
+ # months.
4311
+ #
4312
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
4313
+ optional :billing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
1824
4314
 
1825
- variant :unit_with_percent, -> { Orb::NewPlanUnitWithPercentPrice }
4315
+ # @!attribute conversion_rate
4316
+ # The per unit conversion rate of the price currency to the invoicing currency.
4317
+ #
4318
+ # @return [Float, nil]
4319
+ optional :conversion_rate, Float, nil?: true
1826
4320
 
1827
- variant :matrix_with_allocation, -> { Orb::NewPlanMatrixWithAllocationPrice }
4321
+ # @!attribute conversion_rate_config
4322
+ # The configuration for the rate of the price currency to the invoicing currency.
4323
+ #
4324
+ # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
4325
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
1828
4326
 
1829
- variant :tiered_with_proration,
1830
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration }
4327
+ # @!attribute currency
4328
+ # An ISO 4217 currency string, or custom pricing unit identifier, in which this
4329
+ # price is billed.
4330
+ #
4331
+ # @return [String, nil]
4332
+ optional :currency, String, nil?: true
1831
4333
 
1832
- variant :unit_with_proration, -> { Orb::NewPlanUnitWithProrationPrice }
4334
+ # @!attribute dimensional_price_configuration
4335
+ # For dimensional price: specifies a price group and dimension values
4336
+ #
4337
+ # @return [Orb::Models::NewDimensionalPriceConfiguration, nil]
4338
+ optional :dimensional_price_configuration,
4339
+ -> {
4340
+ Orb::NewDimensionalPriceConfiguration
4341
+ },
4342
+ nil?: true
1833
4343
 
1834
- variant :grouped_allocation, -> { Orb::NewPlanGroupedAllocationPrice }
4344
+ # @!attribute external_price_id
4345
+ # An alias for the price.
4346
+ #
4347
+ # @return [String, nil]
4348
+ optional :external_price_id, String, nil?: true
1835
4349
 
1836
- variant :bulk_with_proration, -> { Orb::NewPlanBulkWithProrationPrice }
4350
+ # @!attribute fixed_price_quantity
4351
+ # If the Price represents a fixed cost, this represents the quantity of units
4352
+ # applied.
4353
+ #
4354
+ # @return [Float, nil]
4355
+ optional :fixed_price_quantity, Float, nil?: true
1837
4356
 
1838
- variant :grouped_with_prorated_minimum, -> { Orb::NewPlanGroupedWithProratedMinimumPrice }
4357
+ # @!attribute invoice_grouping_key
4358
+ # The property used to group this price on an invoice
4359
+ #
4360
+ # @return [String, nil]
4361
+ optional :invoice_grouping_key, String, nil?: true
1839
4362
 
1840
- variant :grouped_with_metered_minimum, -> { Orb::NewPlanGroupedWithMeteredMinimumPrice }
4363
+ # @!attribute invoicing_cycle_configuration
4364
+ # Within each billing cycle, specifies the cadence at which invoices are produced.
4365
+ # If unspecified, a single invoice is produced per billing cycle.
4366
+ #
4367
+ # @return [Orb::Models::NewBillingCycleConfiguration, nil]
4368
+ optional :invoicing_cycle_configuration, -> { Orb::NewBillingCycleConfiguration }, nil?: true
1841
4369
 
1842
- variant :grouped_with_min_max_thresholds,
1843
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds }
4370
+ # @!attribute license_type_id
4371
+ # The ID of the license type to associate with this price.
4372
+ #
4373
+ # @return [String, nil]
4374
+ optional :license_type_id, String, nil?: true
1844
4375
 
1845
- variant :matrix_with_display_name, -> { Orb::NewPlanMatrixWithDisplayNamePrice }
4376
+ # @!attribute metadata
4377
+ # User-specified key/value pairs for the resource. Individual keys can be removed
4378
+ # by setting the value to `null`, and the entire metadata mapping can be cleared
4379
+ # by setting `metadata` to `null`.
4380
+ #
4381
+ # @return [Hash{Symbol=>String, nil}, nil]
4382
+ optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
1846
4383
 
1847
- variant :grouped_tiered_package, -> { Orb::NewPlanGroupedTieredPackagePrice }
4384
+ # @!attribute reference_id
4385
+ # A transient ID that can be used to reference this price when adding adjustments
4386
+ # in the same API call.
4387
+ #
4388
+ # @return [String, nil]
4389
+ optional :reference_id, String, nil?: true
1848
4390
 
1849
- variant :max_group_tiered_package, -> { Orb::NewPlanMaxGroupTieredPackagePrice }
4391
+ # @!method initialize(cadence:, item_id:, name:, tiered_with_proration_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :tiered_with_proration)
4392
+ # Some parameter documentations has been truncated, see
4393
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration}
4394
+ # for more details.
4395
+ #
4396
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::Cadence] The cadence to bill for this price on.
4397
+ #
4398
+ # @param item_id [String] The id of the item the price will be associated with.
4399
+ #
4400
+ # @param name [String] The name of the price.
4401
+ #
4402
+ # @param tiered_with_proration_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig] Configuration for tiered_with_proration pricing
4403
+ #
4404
+ # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
4405
+ #
4406
+ # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
4407
+ #
4408
+ # @param billing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] For custom cadence: specifies the duration of the billing period in days or mont
4409
+ #
4410
+ # @param conversion_rate [Float, nil] The per unit conversion rate of the price currency to the invoicing currency.
4411
+ #
4412
+ # @param conversion_rate_config [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil] The configuration for the rate of the price currency to the invoicing currency.
4413
+ #
4414
+ # @param currency [String, nil] An ISO 4217 currency string, or custom pricing unit identifier, in which this pr
4415
+ #
4416
+ # @param dimensional_price_configuration [Orb::Models::NewDimensionalPriceConfiguration, nil] For dimensional price: specifies a price group and dimension values
4417
+ #
4418
+ # @param external_price_id [String, nil] An alias for the price.
4419
+ #
4420
+ # @param fixed_price_quantity [Float, nil] If the Price represents a fixed cost, this represents the quantity of units appl
4421
+ #
4422
+ # @param invoice_grouping_key [String, nil] The property used to group this price on an invoice
4423
+ #
4424
+ # @param invoicing_cycle_configuration [Orb::Models::NewBillingCycleConfiguration, nil] Within each billing cycle, specifies the cadence at which invoices are produced.
4425
+ #
4426
+ # @param license_type_id [String, nil] The ID of the license type to associate with this price.
4427
+ #
4428
+ # @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
4429
+ #
4430
+ # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
4431
+ #
4432
+ # @param model_type [Symbol, :tiered_with_proration] The pricing model type
1850
4433
 
1851
- variant :scalable_matrix_with_unit_pricing, -> { Orb::NewPlanScalableMatrixWithUnitPricingPrice }
4434
+ # The cadence to bill for this price on.
4435
+ #
4436
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration#cadence
4437
+ module Cadence
4438
+ extend Orb::Internal::Type::Enum
1852
4439
 
1853
- variant :scalable_matrix_with_tiered_pricing, -> { Orb::NewPlanScalableMatrixWithTieredPricingPrice }
4440
+ ANNUAL = :annual
4441
+ SEMI_ANNUAL = :semi_annual
4442
+ MONTHLY = :monthly
4443
+ QUARTERLY = :quarterly
4444
+ ONE_TIME = :one_time
4445
+ CUSTOM = :custom
1854
4446
 
1855
- variant :cumulative_grouped_bulk, -> { Orb::NewPlanCumulativeGroupedBulkPrice }
4447
+ # @!method self.values
4448
+ # @return [Array<Symbol>]
4449
+ end
1856
4450
 
1857
- variant :cumulative_grouped_allocation,
1858
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation }
4451
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration#tiered_with_proration_config
4452
+ class TieredWithProrationConfig < Orb::Internal::Type::BaseModel
4453
+ # @!attribute tiers
4454
+ # Tiers for rating based on total usage quantities into the specified tier with
4455
+ # proration
4456
+ #
4457
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>]
4458
+ required :tiers,
4459
+ -> do
4460
+ Orb::Internal::Type::ArrayOf[
4461
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig::Tier
4462
+ ]
4463
+ end
1859
4464
 
1860
- variant :minimum_composite, -> { Orb::NewPlanMinimumCompositePrice }
4465
+ # @!method initialize(tiers:)
4466
+ # Some parameter documentations has been truncated, see
4467
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig}
4468
+ # for more details.
4469
+ #
4470
+ # Configuration for tiered_with_proration pricing
4471
+ #
4472
+ # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>] Tiers for rating based on total usage quantities into the specified tier with pr
1861
4473
 
1862
- variant :percent, -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent }
4474
+ class Tier < Orb::Internal::Type::BaseModel
4475
+ # @!attribute tier_lower_bound
4476
+ # Inclusive tier starting value
4477
+ #
4478
+ # @return [String]
4479
+ required :tier_lower_bound, String
1863
4480
 
1864
- variant :event_output,
1865
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput }
4481
+ # @!attribute unit_amount
4482
+ # Amount per unit
4483
+ #
4484
+ # @return [String]
4485
+ required :unit_amount, String
1866
4486
 
1867
- class BulkWithFilters < Orb::Internal::Type::BaseModel
1868
- # @!attribute bulk_with_filters_config
1869
- # Configuration for bulk_with_filters pricing
1870
- #
1871
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig]
1872
- required :bulk_with_filters_config,
1873
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig }
4487
+ # @!method initialize(tier_lower_bound:, unit_amount:)
4488
+ # Configuration for a single tiered with proration tier
4489
+ #
4490
+ # @param tier_lower_bound [String] Inclusive tier starting value
4491
+ #
4492
+ # @param unit_amount [String] Amount per unit
4493
+ end
4494
+ end
4495
+ end
1874
4496
 
4497
+ class GroupedWithMinMaxThresholds < Orb::Internal::Type::BaseModel
1875
4498
  # @!attribute cadence
1876
4499
  # The cadence to bill for this price on.
1877
4500
  #
1878
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::Cadence]
4501
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::Cadence]
1879
4502
  required :cadence,
1880
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::Cadence }
4503
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::Cadence }
4504
+
4505
+ # @!attribute grouped_with_min_max_thresholds_config
4506
+ # Configuration for grouped_with_min_max_thresholds pricing
4507
+ #
4508
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig]
4509
+ required :grouped_with_min_max_thresholds_config,
4510
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig }
1881
4511
 
1882
4512
  # @!attribute item_id
1883
4513
  # The id of the item the price will be associated with.
@@ -1888,8 +4518,8 @@ module Orb
1888
4518
  # @!attribute model_type
1889
4519
  # The pricing model type
1890
4520
  #
1891
- # @return [Symbol, :bulk_with_filters]
1892
- required :model_type, const: :bulk_with_filters
4521
+ # @return [Symbol, :grouped_with_min_max_thresholds]
4522
+ required :model_type, const: :grouped_with_min_max_thresholds
1893
4523
 
1894
4524
  # @!attribute name
1895
4525
  # The name of the price.
@@ -1928,11 +4558,7 @@ module Orb
1928
4558
  # The configuration for the rate of the price currency to the invoicing currency.
1929
4559
  #
1930
4560
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
1931
- optional :conversion_rate_config,
1932
- union: -> {
1933
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::ConversionRateConfig
1934
- },
1935
- nil?: true
4561
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
1936
4562
 
1937
4563
  # @!attribute currency
1938
4564
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -1998,14 +4624,14 @@ module Orb
1998
4624
  # @return [String, nil]
1999
4625
  optional :reference_id, String, nil?: true
2000
4626
 
2001
- # @!method initialize(bulk_with_filters_config:, cadence:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :bulk_with_filters)
4627
+ # @!method initialize(cadence:, grouped_with_min_max_thresholds_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :grouped_with_min_max_thresholds)
2002
4628
  # Some parameter documentations has been truncated, see
2003
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters}
4629
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds}
2004
4630
  # for more details.
2005
4631
  #
2006
- # @param bulk_with_filters_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig] Configuration for bulk_with_filters pricing
4632
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::Cadence] The cadence to bill for this price on.
2007
4633
  #
2008
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::Cadence] The cadence to bill for this price on.
4634
+ # @param grouped_with_min_max_thresholds_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig] Configuration for grouped_with_min_max_thresholds pricing
2009
4635
  #
2010
4636
  # @param item_id [String] The id of the item the price will be associated with.
2011
4637
  #
@@ -2039,85 +4665,11 @@ module Orb
2039
4665
  #
2040
4666
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
2041
4667
  #
2042
- # @param model_type [Symbol, :bulk_with_filters] The pricing model type
2043
-
2044
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters#bulk_with_filters_config
2045
- class BulkWithFiltersConfig < Orb::Internal::Type::BaseModel
2046
- # @!attribute filters
2047
- # Property filters to apply (all must match)
2048
- #
2049
- # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Filter>]
2050
- required :filters,
2051
- -> do
2052
- Orb::Internal::Type::ArrayOf[
2053
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Filter
2054
- ]
2055
- end
2056
-
2057
- # @!attribute tiers
2058
- # Bulk tiers for rating based on total usage volume
2059
- #
2060
- # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Tier>]
2061
- required :tiers,
2062
- -> do
2063
- Orb::Internal::Type::ArrayOf[
2064
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Tier
2065
- ]
2066
- end
2067
-
2068
- # @!method initialize(filters:, tiers:)
2069
- # Configuration for bulk_with_filters pricing
2070
- #
2071
- # @param filters [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Filter>] Property filters to apply (all must match)
2072
- #
2073
- # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters::BulkWithFiltersConfig::Tier>] Bulk tiers for rating based on total usage volume
2074
-
2075
- class Filter < Orb::Internal::Type::BaseModel
2076
- # @!attribute property_key
2077
- # Event property key to filter on
2078
- #
2079
- # @return [String]
2080
- required :property_key, String
2081
-
2082
- # @!attribute property_value
2083
- # Event property value to match
2084
- #
2085
- # @return [String]
2086
- required :property_value, String
2087
-
2088
- # @!method initialize(property_key:, property_value:)
2089
- # Configuration for a single property filter
2090
- #
2091
- # @param property_key [String] Event property key to filter on
2092
- #
2093
- # @param property_value [String] Event property value to match
2094
- end
2095
-
2096
- class Tier < Orb::Internal::Type::BaseModel
2097
- # @!attribute unit_amount
2098
- # Amount per unit
2099
- #
2100
- # @return [String]
2101
- required :unit_amount, String
2102
-
2103
- # @!attribute tier_lower_bound
2104
- # The lower bound for this tier
2105
- #
2106
- # @return [String, nil]
2107
- optional :tier_lower_bound, String, nil?: true
2108
-
2109
- # @!method initialize(unit_amount:, tier_lower_bound: nil)
2110
- # Configuration for a single bulk pricing tier
2111
- #
2112
- # @param unit_amount [String] Amount per unit
2113
- #
2114
- # @param tier_lower_bound [String, nil] The lower bound for this tier
2115
- end
2116
- end
4668
+ # @param model_type [Symbol, :grouped_with_min_max_thresholds] The pricing model type
2117
4669
 
2118
4670
  # The cadence to bill for this price on.
2119
4671
  #
2120
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters#cadence
4672
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds#cadence
2121
4673
  module Cadence
2122
4674
  extend Orb::Internal::Type::Enum
2123
4675
 
@@ -2128,18 +4680,63 @@ module Orb
2128
4680
  ONE_TIME = :one_time
2129
4681
  CUSTOM = :custom
2130
4682
 
2131
- # @!method self.values
2132
- # @return [Array<Symbol>]
4683
+ # @!method self.values
4684
+ # @return [Array<Symbol>]
4685
+ end
4686
+
4687
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds#grouped_with_min_max_thresholds_config
4688
+ class GroupedWithMinMaxThresholdsConfig < Orb::Internal::Type::BaseModel
4689
+ # @!attribute grouping_key
4690
+ # The event property used to group before applying thresholds
4691
+ #
4692
+ # @return [String]
4693
+ required :grouping_key, String
4694
+
4695
+ # @!attribute maximum_charge
4696
+ # The maximum amount to charge each group
4697
+ #
4698
+ # @return [String]
4699
+ required :maximum_charge, String
4700
+
4701
+ # @!attribute minimum_charge
4702
+ # The minimum amount to charge each group, regardless of usage
4703
+ #
4704
+ # @return [String]
4705
+ required :minimum_charge, String
4706
+
4707
+ # @!attribute per_unit_rate
4708
+ # The base price charged per group
4709
+ #
4710
+ # @return [String]
4711
+ required :per_unit_rate, String
4712
+
4713
+ # @!method initialize(grouping_key:, maximum_charge:, minimum_charge:, per_unit_rate:)
4714
+ # Configuration for grouped_with_min_max_thresholds pricing
4715
+ #
4716
+ # @param grouping_key [String] The event property used to group before applying thresholds
4717
+ #
4718
+ # @param maximum_charge [String] The maximum amount to charge each group
4719
+ #
4720
+ # @param minimum_charge [String] The minimum amount to charge each group, regardless of usage
4721
+ #
4722
+ # @param per_unit_rate [String] The base price charged per group
2133
4723
  end
2134
4724
  end
2135
4725
 
2136
- class TieredWithProration < Orb::Internal::Type::BaseModel
4726
+ class CumulativeGroupedAllocation < Orb::Internal::Type::BaseModel
2137
4727
  # @!attribute cadence
2138
4728
  # The cadence to bill for this price on.
2139
4729
  #
2140
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::Cadence]
4730
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::Cadence]
2141
4731
  required :cadence,
2142
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::Cadence }
4732
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::Cadence }
4733
+
4734
+ # @!attribute cumulative_grouped_allocation_config
4735
+ # Configuration for cumulative_grouped_allocation pricing
4736
+ #
4737
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig]
4738
+ required :cumulative_grouped_allocation_config,
4739
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig }
2143
4740
 
2144
4741
  # @!attribute item_id
2145
4742
  # The id of the item the price will be associated with.
@@ -2150,8 +4747,8 @@ module Orb
2150
4747
  # @!attribute model_type
2151
4748
  # The pricing model type
2152
4749
  #
2153
- # @return [Symbol, :tiered_with_proration]
2154
- required :model_type, const: :tiered_with_proration
4750
+ # @return [Symbol, :cumulative_grouped_allocation]
4751
+ required :model_type, const: :cumulative_grouped_allocation
2155
4752
 
2156
4753
  # @!attribute name
2157
4754
  # The name of the price.
@@ -2159,13 +4756,6 @@ module Orb
2159
4756
  # @return [String]
2160
4757
  required :name, String
2161
4758
 
2162
- # @!attribute tiered_with_proration_config
2163
- # Configuration for tiered_with_proration pricing
2164
- #
2165
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig]
2166
- required :tiered_with_proration_config,
2167
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig }
2168
-
2169
4759
  # @!attribute billable_metric_id
2170
4760
  # The id of the billable metric for the price. Only needed if the price is
2171
4761
  # usage-based.
@@ -2197,11 +4787,7 @@ module Orb
2197
4787
  # The configuration for the rate of the price currency to the invoicing currency.
2198
4788
  #
2199
4789
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
2200
- optional :conversion_rate_config,
2201
- union: -> {
2202
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::ConversionRateConfig
2203
- },
2204
- nil?: true
4790
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
2205
4791
 
2206
4792
  # @!attribute currency
2207
4793
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -2267,19 +4853,19 @@ module Orb
2267
4853
  # @return [String, nil]
2268
4854
  optional :reference_id, String, nil?: true
2269
4855
 
2270
- # @!method initialize(cadence:, item_id:, name:, tiered_with_proration_config:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :tiered_with_proration)
4856
+ # @!method initialize(cadence:, cumulative_grouped_allocation_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :cumulative_grouped_allocation)
2271
4857
  # Some parameter documentations has been truncated, see
2272
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration}
4858
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation}
2273
4859
  # for more details.
2274
4860
  #
2275
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::Cadence] The cadence to bill for this price on.
4861
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::Cadence] The cadence to bill for this price on.
4862
+ #
4863
+ # @param cumulative_grouped_allocation_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig] Configuration for cumulative_grouped_allocation pricing
2276
4864
  #
2277
4865
  # @param item_id [String] The id of the item the price will be associated with.
2278
4866
  #
2279
4867
  # @param name [String] The name of the price.
2280
4868
  #
2281
- # @param tiered_with_proration_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig] Configuration for tiered_with_proration pricing
2282
- #
2283
4869
  # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
2284
4870
  #
2285
4871
  # @param billed_in_advance [Boolean, nil] If the Price represents a fixed cost, the price will be billed in-advance if thi
@@ -2308,11 +4894,11 @@ module Orb
2308
4894
  #
2309
4895
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
2310
4896
  #
2311
- # @param model_type [Symbol, :tiered_with_proration] The pricing model type
4897
+ # @param model_type [Symbol, :cumulative_grouped_allocation] The pricing model type
2312
4898
 
2313
4899
  # The cadence to bill for this price on.
2314
4900
  #
2315
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration#cadence
4901
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation#cadence
2316
4902
  module Cadence
2317
4903
  extend Orb::Internal::Type::Enum
2318
4904
 
@@ -2327,66 +4913,59 @@ module Orb
2327
4913
  # @return [Array<Symbol>]
2328
4914
  end
2329
4915
 
2330
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration#tiered_with_proration_config
2331
- class TieredWithProrationConfig < Orb::Internal::Type::BaseModel
2332
- # @!attribute tiers
2333
- # Tiers for rating based on total usage quantities into the specified tier with
2334
- # proration
4916
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation#cumulative_grouped_allocation_config
4917
+ class CumulativeGroupedAllocationConfig < Orb::Internal::Type::BaseModel
4918
+ # @!attribute cumulative_allocation
4919
+ # The overall allocation across all groups
2335
4920
  #
2336
- # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>]
2337
- required :tiers,
2338
- -> do
2339
- Orb::Internal::Type::ArrayOf[
2340
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig::Tier
2341
- ]
2342
- end
4921
+ # @return [String]
4922
+ required :cumulative_allocation, String
2343
4923
 
2344
- # @!method initialize(tiers:)
2345
- # Some parameter documentations has been truncated, see
2346
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig}
2347
- # for more details.
2348
- #
2349
- # Configuration for tiered_with_proration pricing
4924
+ # @!attribute group_allocation
4925
+ # The allocation per individual group
2350
4926
  #
2351
- # @param tiers [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration::TieredWithProrationConfig::Tier>] Tiers for rating based on total usage quantities into the specified tier with pr
4927
+ # @return [String]
4928
+ required :group_allocation, String
2352
4929
 
2353
- class Tier < Orb::Internal::Type::BaseModel
2354
- # @!attribute tier_lower_bound
2355
- # Inclusive tier starting value
2356
- #
2357
- # @return [String]
2358
- required :tier_lower_bound, String
4930
+ # @!attribute grouping_key
4931
+ # The event property used to group usage before applying allocations
4932
+ #
4933
+ # @return [String]
4934
+ required :grouping_key, String
2359
4935
 
2360
- # @!attribute unit_amount
2361
- # Amount per unit
2362
- #
2363
- # @return [String]
2364
- required :unit_amount, String
4936
+ # @!attribute unit_amount
4937
+ # The amount to charge for each unit outside of the allocation
4938
+ #
4939
+ # @return [String]
4940
+ required :unit_amount, String
2365
4941
 
2366
- # @!method initialize(tier_lower_bound:, unit_amount:)
2367
- # Configuration for a single tiered with proration tier
2368
- #
2369
- # @param tier_lower_bound [String] Inclusive tier starting value
2370
- #
2371
- # @param unit_amount [String] Amount per unit
2372
- end
4942
+ # @!method initialize(cumulative_allocation:, group_allocation:, grouping_key:, unit_amount:)
4943
+ # Configuration for cumulative_grouped_allocation pricing
4944
+ #
4945
+ # @param cumulative_allocation [String] The overall allocation across all groups
4946
+ #
4947
+ # @param group_allocation [String] The allocation per individual group
4948
+ #
4949
+ # @param grouping_key [String] The event property used to group usage before applying allocations
4950
+ #
4951
+ # @param unit_amount [String] The amount to charge for each unit outside of the allocation
2373
4952
  end
2374
4953
  end
2375
4954
 
2376
- class GroupedWithMinMaxThresholds < Orb::Internal::Type::BaseModel
4955
+ class DailyCreditAllowance < Orb::Internal::Type::BaseModel
2377
4956
  # @!attribute cadence
2378
4957
  # The cadence to bill for this price on.
2379
4958
  #
2380
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::Cadence]
4959
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::Cadence]
2381
4960
  required :cadence,
2382
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::Cadence }
4961
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::Cadence }
2383
4962
 
2384
- # @!attribute grouped_with_min_max_thresholds_config
2385
- # Configuration for grouped_with_min_max_thresholds pricing
4963
+ # @!attribute daily_credit_allowance_config
4964
+ # Configuration for daily_credit_allowance pricing
2386
4965
  #
2387
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig]
2388
- required :grouped_with_min_max_thresholds_config,
2389
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig }
4966
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig]
4967
+ required :daily_credit_allowance_config,
4968
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig }
2390
4969
 
2391
4970
  # @!attribute item_id
2392
4971
  # The id of the item the price will be associated with.
@@ -2397,8 +4976,8 @@ module Orb
2397
4976
  # @!attribute model_type
2398
4977
  # The pricing model type
2399
4978
  #
2400
- # @return [Symbol, :grouped_with_min_max_thresholds]
2401
- required :model_type, const: :grouped_with_min_max_thresholds
4979
+ # @return [Symbol, :daily_credit_allowance]
4980
+ required :model_type, const: :daily_credit_allowance
2402
4981
 
2403
4982
  # @!attribute name
2404
4983
  # The name of the price.
@@ -2437,11 +5016,7 @@ module Orb
2437
5016
  # The configuration for the rate of the price currency to the invoicing currency.
2438
5017
  #
2439
5018
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
2440
- optional :conversion_rate_config,
2441
- union: -> {
2442
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::ConversionRateConfig
2443
- },
2444
- nil?: true
5019
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
2445
5020
 
2446
5021
  # @!attribute currency
2447
5022
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -2507,14 +5082,14 @@ module Orb
2507
5082
  # @return [String, nil]
2508
5083
  optional :reference_id, String, nil?: true
2509
5084
 
2510
- # @!method initialize(cadence:, grouped_with_min_max_thresholds_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :grouped_with_min_max_thresholds)
5085
+ # @!method initialize(cadence:, daily_credit_allowance_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :daily_credit_allowance)
2511
5086
  # Some parameter documentations has been truncated, see
2512
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds}
5087
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance}
2513
5088
  # for more details.
2514
5089
  #
2515
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::Cadence] The cadence to bill for this price on.
5090
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::Cadence] The cadence to bill for this price on.
2516
5091
  #
2517
- # @param grouped_with_min_max_thresholds_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds::GroupedWithMinMaxThresholdsConfig] Configuration for grouped_with_min_max_thresholds pricing
5092
+ # @param daily_credit_allowance_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig] Configuration for daily_credit_allowance pricing
2518
5093
  #
2519
5094
  # @param item_id [String] The id of the item the price will be associated with.
2520
5095
  #
@@ -2548,11 +5123,11 @@ module Orb
2548
5123
  #
2549
5124
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
2550
5125
  #
2551
- # @param model_type [Symbol, :grouped_with_min_max_thresholds] The pricing model type
5126
+ # @param model_type [Symbol, :daily_credit_allowance] The pricing model type
2552
5127
 
2553
5128
  # The cadence to bill for this price on.
2554
5129
  #
2555
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds#cadence
5130
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance#cadence
2556
5131
  module Cadence
2557
5132
  extend Orb::Internal::Type::Enum
2558
5133
 
@@ -2567,59 +5142,99 @@ module Orb
2567
5142
  # @return [Array<Symbol>]
2568
5143
  end
2569
5144
 
2570
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds#grouped_with_min_max_thresholds_config
2571
- class GroupedWithMinMaxThresholdsConfig < Orb::Internal::Type::BaseModel
2572
- # @!attribute grouping_key
2573
- # The event property used to group before applying thresholds
5145
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance#daily_credit_allowance_config
5146
+ class DailyCreditAllowanceConfig < Orb::Internal::Type::BaseModel
5147
+ # @!attribute daily_allowance
5148
+ # Credits granted per day. Lose-it-or-use-it; does not roll over.
2574
5149
  #
2575
5150
  # @return [String]
2576
- required :grouping_key, String
5151
+ required :daily_allowance, String
2577
5152
 
2578
- # @!attribute maximum_charge
2579
- # The maximum amount to charge each group
5153
+ # @!attribute default_unit_amount
5154
+ # Default per-unit credit rate for any usage not bucketed into a specified
5155
+ # matrix_value
2580
5156
  #
2581
5157
  # @return [String]
2582
- required :maximum_charge, String
5158
+ required :default_unit_amount, String
2583
5159
 
2584
- # @!attribute minimum_charge
2585
- # The minimum amount to charge each group, regardless of usage
5160
+ # @!attribute dimensions
5161
+ # One or two event property values to evaluate matrix groups by
2586
5162
  #
2587
- # @return [String]
2588
- required :minimum_charge, String
5163
+ # @return [Array<String, nil>]
5164
+ required :dimensions, Orb::Internal::Type::ArrayOf[String, nil?: true]
2589
5165
 
2590
- # @!attribute per_unit_rate
2591
- # The base price charged per group
5166
+ # @!attribute event_day_property
5167
+ # Event property whose value identifies the day bucket the event belongs to (e.g.
5168
+ # 'event_day' set to an ISO date string in the customer's timezone). The allowance
5169
+ # resets per distinct value of this property.
2592
5170
  #
2593
5171
  # @return [String]
2594
- required :per_unit_rate, String
5172
+ required :event_day_property, String
2595
5173
 
2596
- # @!method initialize(grouping_key:, maximum_charge:, minimum_charge:, per_unit_rate:)
2597
- # Configuration for grouped_with_min_max_thresholds pricing
5174
+ # @!attribute matrix_values
5175
+ # Per-dimension credit rates
2598
5176
  #
2599
- # @param grouping_key [String] The event property used to group before applying thresholds
5177
+ # @return [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue>]
5178
+ required :matrix_values,
5179
+ -> do
5180
+ Orb::Internal::Type::ArrayOf[
5181
+ Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue
5182
+ ]
5183
+ end
5184
+
5185
+ # @!method initialize(daily_allowance:, default_unit_amount:, dimensions:, event_day_property:, matrix_values:)
5186
+ # Some parameter documentations has been truncated, see
5187
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig}
5188
+ # for more details.
2600
5189
  #
2601
- # @param maximum_charge [String] The maximum amount to charge each group
5190
+ # Configuration for daily_credit_allowance pricing
2602
5191
  #
2603
- # @param minimum_charge [String] The minimum amount to charge each group, regardless of usage
5192
+ # @param daily_allowance [String] Credits granted per day. Lose-it-or-use-it; does not roll over.
2604
5193
  #
2605
- # @param per_unit_rate [String] The base price charged per group
5194
+ # @param default_unit_amount [String] Default per-unit credit rate for any usage not bucketed into a specified
5195
+ # matrix\_
5196
+ #
5197
+ # @param dimensions [Array<String, nil>] One or two event property values to evaluate matrix groups by
5198
+ #
5199
+ # @param event_day_property [String] Event property whose value identifies the day bucket the event belongs to (e.g.
5200
+ #
5201
+ # @param matrix_values [Array<Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue>] Per-dimension credit rates
5202
+
5203
+ class MatrixValue < Orb::Internal::Type::BaseModel
5204
+ # @!attribute dimension_values
5205
+ # One or two matrix keys to filter usage to this value by. For example, ["model"]
5206
+ # could be used to apply a different credit rate to each AI model.
5207
+ #
5208
+ # @return [Array<String, nil>]
5209
+ required :dimension_values, Orb::Internal::Type::ArrayOf[String, nil?: true]
5210
+
5211
+ # @!attribute unit_amount
5212
+ # Credits charged per unit of usage matching the specified dimension_values
5213
+ #
5214
+ # @return [String]
5215
+ required :unit_amount, String
5216
+
5217
+ # @!method initialize(dimension_values:, unit_amount:)
5218
+ # Some parameter documentations has been truncated, see
5219
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance::DailyCreditAllowanceConfig::MatrixValue}
5220
+ # for more details.
5221
+ #
5222
+ # Per-dimension credit price for the daily credit allowance model.
5223
+ #
5224
+ # @param dimension_values [Array<String, nil>] One or two matrix keys to filter usage to this value by. For example, ["model"]
5225
+ #
5226
+ # @param unit_amount [String] Credits charged per unit of usage matching the specified dimension_values
5227
+ end
2606
5228
  end
2607
5229
  end
2608
5230
 
2609
- class CumulativeGroupedAllocation < Orb::Internal::Type::BaseModel
5231
+ class MeteredAllowance < Orb::Internal::Type::BaseModel
2610
5232
  # @!attribute cadence
2611
5233
  # The cadence to bill for this price on.
2612
5234
  #
2613
- # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::Cadence]
5235
+ # @return [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance::Cadence]
2614
5236
  required :cadence,
2615
- enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::Cadence }
2616
-
2617
- # @!attribute cumulative_grouped_allocation_config
2618
- # Configuration for cumulative_grouped_allocation pricing
2619
- #
2620
- # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig]
2621
- required :cumulative_grouped_allocation_config,
2622
- -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig }
5237
+ enum: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance::Cadence }
2623
5238
 
2624
5239
  # @!attribute item_id
2625
5240
  # The id of the item the price will be associated with.
@@ -2627,11 +5242,18 @@ module Orb
2627
5242
  # @return [String]
2628
5243
  required :item_id, String
2629
5244
 
5245
+ # @!attribute metered_allowance_config
5246
+ # Configuration for metered_allowance pricing
5247
+ #
5248
+ # @return [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance::MeteredAllowanceConfig]
5249
+ required :metered_allowance_config,
5250
+ -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance::MeteredAllowanceConfig }
5251
+
2630
5252
  # @!attribute model_type
2631
5253
  # The pricing model type
2632
5254
  #
2633
- # @return [Symbol, :cumulative_grouped_allocation]
2634
- required :model_type, const: :cumulative_grouped_allocation
5255
+ # @return [Symbol, :metered_allowance]
5256
+ required :model_type, const: :metered_allowance
2635
5257
 
2636
5258
  # @!attribute name
2637
5259
  # The name of the price.
@@ -2670,11 +5292,7 @@ module Orb
2670
5292
  # The configuration for the rate of the price currency to the invoicing currency.
2671
5293
  #
2672
5294
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
2673
- optional :conversion_rate_config,
2674
- union: -> {
2675
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::ConversionRateConfig
2676
- },
2677
- nil?: true
5295
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
2678
5296
 
2679
5297
  # @!attribute currency
2680
5298
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -2740,17 +5358,17 @@ module Orb
2740
5358
  # @return [String, nil]
2741
5359
  optional :reference_id, String, nil?: true
2742
5360
 
2743
- # @!method initialize(cadence:, cumulative_grouped_allocation_config:, item_id:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :cumulative_grouped_allocation)
5361
+ # @!method initialize(cadence:, item_id:, metered_allowance_config:, name:, billable_metric_id: nil, billed_in_advance: nil, billing_cycle_configuration: nil, conversion_rate: nil, conversion_rate_config: nil, currency: nil, dimensional_price_configuration: nil, external_price_id: nil, fixed_price_quantity: nil, invoice_grouping_key: nil, invoicing_cycle_configuration: nil, license_type_id: nil, metadata: nil, reference_id: nil, model_type: :metered_allowance)
2744
5362
  # Some parameter documentations has been truncated, see
2745
- # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation}
5363
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance}
2746
5364
  # for more details.
2747
5365
  #
2748
- # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::Cadence] The cadence to bill for this price on.
2749
- #
2750
- # @param cumulative_grouped_allocation_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation::CumulativeGroupedAllocationConfig] Configuration for cumulative_grouped_allocation pricing
5366
+ # @param cadence [Symbol, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance::Cadence] The cadence to bill for this price on.
2751
5367
  #
2752
5368
  # @param item_id [String] The id of the item the price will be associated with.
2753
5369
  #
5370
+ # @param metered_allowance_config [Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance::MeteredAllowanceConfig] Configuration for metered_allowance pricing
5371
+ #
2754
5372
  # @param name [String] The name of the price.
2755
5373
  #
2756
5374
  # @param billable_metric_id [String, nil] The id of the billable metric for the price. Only needed if the price is usage-b
@@ -2781,11 +5399,11 @@ module Orb
2781
5399
  #
2782
5400
  # @param reference_id [String, nil] A transient ID that can be used to reference this price when adding adjustments
2783
5401
  #
2784
- # @param model_type [Symbol, :cumulative_grouped_allocation] The pricing model type
5402
+ # @param model_type [Symbol, :metered_allowance] The pricing model type
2785
5403
 
2786
5404
  # The cadence to bill for this price on.
2787
5405
  #
2788
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation#cadence
5406
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance#cadence
2789
5407
  module Cadence
2790
5408
  extend Orb::Internal::Type::Enum
2791
5409
 
@@ -2800,42 +5418,67 @@ module Orb
2800
5418
  # @return [Array<Symbol>]
2801
5419
  end
2802
5420
 
2803
- # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation#cumulative_grouped_allocation_config
2804
- class CumulativeGroupedAllocationConfig < Orb::Internal::Type::BaseModel
2805
- # @!attribute cumulative_allocation
2806
- # The overall allocation across all groups
5421
+ # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance#metered_allowance_config
5422
+ class MeteredAllowanceConfig < Orb::Internal::Type::BaseModel
5423
+ # @!attribute allowance_grouping_value
5424
+ # The grouping_key value whose summed quantity represents the allowance for this
5425
+ # period (e.g. 'storage_snapshot' emitting 3 × avg storage). Capped at consumption
5426
+ # — credit can never exceed actual usage.
2807
5427
  #
2808
5428
  # @return [String]
2809
- required :cumulative_allocation, String
5429
+ required :allowance_grouping_value, String
2810
5430
 
2811
- # @!attribute group_allocation
2812
- # The allocation per individual group
5431
+ # @!attribute consumption_grouping_value
5432
+ # The grouping_key value whose summed quantity represents consumption (e.g.
5433
+ # 'download'). Charged at unit_amount.
2813
5434
  #
2814
5435
  # @return [String]
2815
- required :group_allocation, String
5436
+ required :consumption_grouping_value, String
2816
5437
 
2817
5438
  # @!attribute grouping_key
2818
- # The event property used to group usage before applying allocations
5439
+ # Event property used to partition the metric into consumption and allowance
5440
+ # quantities (e.g. 'event_name'). The metric is queried with this key and the two
5441
+ # values below select which partition is which.
2819
5442
  #
2820
5443
  # @return [String]
2821
5444
  required :grouping_key, String
2822
5445
 
2823
5446
  # @!attribute unit_amount
2824
- # The amount to charge for each unit outside of the allocation
5447
+ # Per-unit price applied to gross consumption and to the allowance credit.
2825
5448
  #
2826
5449
  # @return [String]
2827
5450
  required :unit_amount, String
2828
5451
 
2829
- # @!method initialize(cumulative_allocation:, group_allocation:, grouping_key:, unit_amount:)
2830
- # Configuration for cumulative_grouped_allocation pricing
5452
+ # @!attribute allowance_display_name
5453
+ # Sub-line label for the credit row (e.g. 'Up to 3x free egress').
2831
5454
  #
2832
- # @param cumulative_allocation [String] The overall allocation across all groups
5455
+ # @return [String, nil]
5456
+ optional :allowance_display_name, String
5457
+
5458
+ # @!attribute consumption_display_name
5459
+ # Sub-line label for the gross consumption row (e.g. 'bytes gotten').
2833
5460
  #
2834
- # @param group_allocation [String] The allocation per individual group
5461
+ # @return [String, nil]
5462
+ optional :consumption_display_name, String
5463
+
5464
+ # @!method initialize(allowance_grouping_value:, consumption_grouping_value:, grouping_key:, unit_amount:, allowance_display_name: nil, consumption_display_name: nil)
5465
+ # Some parameter documentations has been truncated, see
5466
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance::MeteredAllowanceConfig}
5467
+ # for more details.
2835
5468
  #
2836
- # @param grouping_key [String] The event property used to group usage before applying allocations
5469
+ # Configuration for metered_allowance pricing
2837
5470
  #
2838
- # @param unit_amount [String] The amount to charge for each unit outside of the allocation
5471
+ # @param allowance_grouping_value [String] The grouping_key value whose summed quantity represents the allowance for this p
5472
+ #
5473
+ # @param consumption_grouping_value [String] The grouping_key value whose summed quantity represents consumption (e.g. 'downl
5474
+ #
5475
+ # @param grouping_key [String] Event property used to partition the metric into consumption and allowance quant
5476
+ #
5477
+ # @param unit_amount [String] Per-unit price applied to gross consumption and to the allowance credit.
5478
+ #
5479
+ # @param allowance_display_name [String] Sub-line label for the credit row (e.g. 'Up to 3x free egress').
5480
+ #
5481
+ # @param consumption_display_name [String] Sub-line label for the gross consumption row (e.g. 'bytes gotten').
2839
5482
  end
2840
5483
  end
2841
5484
 
@@ -2903,11 +5546,7 @@ module Orb
2903
5546
  # The configuration for the rate of the price currency to the invoicing currency.
2904
5547
  #
2905
5548
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
2906
- optional :conversion_rate_config,
2907
- union: -> {
2908
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent::ConversionRateConfig
2909
- },
2910
- nil?: true
5549
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
2911
5550
 
2912
5551
  # @!attribute currency
2913
5552
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -3036,15 +5675,45 @@ module Orb
3036
5675
  # @see Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent#percent_config
3037
5676
  class PercentConfig < Orb::Internal::Type::BaseModel
3038
5677
  # @!attribute percent
3039
- # What percent of the component subtotals to charge
5678
+ # Fraction of the component subtotals to charge (0 < percent <= 1).
3040
5679
  #
3041
5680
  # @return [Float]
3042
5681
  required :percent, Float
3043
5682
 
3044
- # @!method initialize(percent:)
5683
+ # @!attribute maximum_amount
5684
+ # Maximum amount to charge. If unset, the fee has no upper bound.
5685
+ #
5686
+ # @return [String, nil]
5687
+ optional :maximum_amount, String, nil?: true
5688
+
5689
+ # @!attribute minimum_amount
5690
+ # Minimum amount to charge. If unset, the fee is bounded below by 0.
5691
+ #
5692
+ # @return [String, nil]
5693
+ optional :minimum_amount, String, nil?: true
5694
+
5695
+ # @!attribute prorated
5696
+ # If true, the minimum_amount is prorated based on the service period. The
5697
+ # maximum_amount is an absolute cap (never prorated), and the percent applied to
5698
+ # upstream subtotals is never prorated either.
5699
+ #
5700
+ # @return [Boolean, nil]
5701
+ optional :prorated, Orb::Internal::Type::Boolean
5702
+
5703
+ # @!method initialize(percent:, maximum_amount: nil, minimum_amount: nil, prorated: nil)
5704
+ # Some parameter documentations has been truncated, see
5705
+ # {Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent::PercentConfig}
5706
+ # for more details.
5707
+ #
3045
5708
  # Configuration for percent pricing
3046
5709
  #
3047
- # @param percent [Float] What percent of the component subtotals to charge
5710
+ # @param percent [Float] Fraction of the component subtotals to charge (0 < percent <= 1).
5711
+ #
5712
+ # @param maximum_amount [String, nil] Maximum amount to charge. If unset, the fee has no upper bound.
5713
+ #
5714
+ # @param minimum_amount [String, nil] Minimum amount to charge. If unset, the fee is bounded below by 0.
5715
+ #
5716
+ # @param prorated [Boolean] If true, the minimum_amount is prorated based on the service period. The maximum
3048
5717
  end
3049
5718
  end
3050
5719
 
@@ -3112,11 +5781,7 @@ module Orb
3112
5781
  # The configuration for the rate of the price currency to the invoicing currency.
3113
5782
  #
3114
5783
  # @return [Orb::Models::UnitConversionRateConfig, Orb::Models::TieredConversionRateConfig, nil]
3115
- optional :conversion_rate_config,
3116
- union: -> {
3117
- Orb::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput::ConversionRateConfig
3118
- },
3119
- nil?: true
5784
+ optional :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true
3120
5785
 
3121
5786
  # @!attribute currency
3122
5787
  # An ISO 4217 currency string, or custom pricing unit identifier, in which this
@@ -3281,7 +5946,7 @@ module Orb
3281
5946
  end
3282
5947
 
3283
5948
  # @!method self.variants
3284
- # @return [Array(Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput)]
5949
+ # @return [Array(Orb::Models::NewPlanUnitPrice, Orb::Models::NewPlanTieredPrice, Orb::Models::NewPlanBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewPlanPackagePrice, Orb::Models::NewPlanMatrixPrice, Orb::Models::NewPlanThresholdTotalAmountPrice, Orb::Models::NewPlanTieredPackagePrice, Orb::Models::NewPlanTieredWithMinimumPrice, Orb::Models::NewPlanGroupedTieredPrice, Orb::Models::NewPlanTieredPackageWithMinimumPrice, Orb::Models::NewPlanPackageWithAllocationPrice, Orb::Models::NewPlanUnitWithPercentPrice, Orb::Models::NewPlanMatrixWithAllocationPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MatrixWithThresholdDiscounts, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewPlanUnitWithProrationPrice, Orb::Models::NewPlanGroupedAllocationPrice, Orb::Models::NewPlanBulkWithProrationPrice, Orb::Models::NewPlanGroupedWithProratedMinimumPrice, Orb::Models::NewPlanGroupedWithMeteredMinimumPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewPlanMatrixWithDisplayNamePrice, Orb::Models::NewPlanGroupedTieredPackagePrice, Orb::Models::NewPlanMaxGroupTieredPackagePrice, Orb::Models::NewPlanScalableMatrixWithUnitPricingPrice, Orb::Models::NewPlanScalableMatrixWithTieredPricingPrice, Orb::Models::NewPlanCumulativeGroupedBulkPrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::DailyCreditAllowance, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::MeteredAllowance, Orb::Models::NewPlanMinimumCompositePrice, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::Percent, Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::ReplacePrice::Price::EventOutput)]
3285
5950
  end
3286
5951
  end
3287
5952
  end