orb-billing 1.14.0 → 1.16.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 (351) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +20 -0
  3. data/README.md +1 -1
  4. data/lib/orb/client.rb +14 -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/models/accounting_provider_config.rb +14 -3
  8. data/lib/orb/models/adjustment_interval.rb +185 -3
  9. data/lib/orb/models/alert.rb +105 -1
  10. data/lib/orb/models/alert_create_for_subscription_params.rb +120 -7
  11. data/lib/orb/models/alert_update_params.rb +113 -1
  12. data/lib/orb/models/beta/external_plan_id_create_plan_version_params.rb +2419 -17109
  13. data/lib/orb/models/beta_create_plan_version_params.rb +2361 -16947
  14. data/lib/orb/models/billable_metric.rb +10 -1
  15. data/lib/orb/models/changed_subscription_resources.rb +200 -10
  16. data/lib/orb/models/conversion_rate_config.rb +18 -0
  17. data/lib/orb/models/credit_block_list_invoices_response.rb +192 -1
  18. data/lib/orb/models/credit_block_retrieve_response.rb +185 -1
  19. data/lib/orb/models/customer.rb +111 -4
  20. data/lib/orb/models/customer_create_params.rb +6 -1
  21. data/lib/orb/models/customer_tax_id.rb +15 -1
  22. data/lib/orb/models/customer_update_by_external_id_params.rb +16 -2
  23. data/lib/orb/models/customer_update_params.rb +16 -2
  24. data/lib/orb/models/customers/credit_list_by_external_id_response.rb +192 -1
  25. data/lib/orb/models/customers/credit_list_response.rb +189 -1
  26. data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb +4 -4
  27. data/lib/orb/models/customers/credits/ledger_create_entry_params.rb +4 -4
  28. data/lib/orb/models/dimensional_price_group.rb +1 -1
  29. data/lib/orb/models/discount.rb +145 -1
  30. data/lib/orb/models/event_ingest_params.rb +5 -2
  31. data/lib/orb/models/invoice.rb +198 -10
  32. data/lib/orb/models/invoice_create_params.rb +6 -5
  33. data/lib/orb/models/invoice_fetch_upcoming_response.rb +200 -10
  34. data/lib/orb/models/invoice_issue_summary_response.rb +9 -3
  35. data/lib/orb/models/invoice_level_discount.rb +145 -1
  36. data/lib/orb/models/invoice_line_item_create_response.rb +189 -5
  37. data/lib/orb/models/invoice_list_summary_response.rb +9 -3
  38. data/lib/orb/models/licenses/external_license_get_usage_params.rb +3 -3
  39. data/lib/orb/models/licenses/usage_get_all_usage_params.rb +3 -3
  40. data/lib/orb/models/licenses/usage_get_usage_params.rb +3 -3
  41. data/lib/orb/models/mutated_subscription.rb +169 -4
  42. data/lib/orb/models/new_allocation_price.rb +11 -1
  43. data/lib/orb/models/new_floating_bulk_price.rb +1 -3
  44. data/lib/orb/models/new_floating_bulk_with_proration_price.rb +1 -3
  45. data/lib/orb/models/new_floating_cumulative_grouped_bulk_price.rb +1 -3
  46. data/lib/orb/models/new_floating_grouped_allocation_price.rb +1 -3
  47. data/lib/orb/models/new_floating_grouped_tiered_package_price.rb +1 -3
  48. data/lib/orb/models/new_floating_grouped_tiered_price.rb +1 -3
  49. data/lib/orb/models/new_floating_grouped_with_metered_minimum_price.rb +1 -3
  50. data/lib/orb/models/new_floating_grouped_with_prorated_minimum_price.rb +1 -3
  51. data/lib/orb/models/new_floating_matrix_price.rb +1 -3
  52. data/lib/orb/models/new_floating_matrix_with_allocation_price.rb +1 -3
  53. data/lib/orb/models/new_floating_matrix_with_display_name_price.rb +1 -3
  54. data/lib/orb/models/new_floating_max_group_tiered_package_price.rb +1 -3
  55. data/lib/orb/models/new_floating_minimum_composite_price.rb +1 -3
  56. data/lib/orb/models/new_floating_package_price.rb +1 -3
  57. data/lib/orb/models/new_floating_package_with_allocation_price.rb +1 -3
  58. data/lib/orb/models/new_floating_scalable_matrix_with_tiered_pricing_price.rb +1 -3
  59. data/lib/orb/models/new_floating_scalable_matrix_with_unit_pricing_price.rb +1 -3
  60. data/lib/orb/models/new_floating_threshold_total_amount_price.rb +1 -3
  61. data/lib/orb/models/new_floating_tiered_package_price.rb +1 -3
  62. data/lib/orb/models/new_floating_tiered_package_with_minimum_price.rb +1 -3
  63. data/lib/orb/models/new_floating_tiered_price.rb +1 -3
  64. data/lib/orb/models/new_floating_tiered_with_minimum_price.rb +1 -3
  65. data/lib/orb/models/new_floating_tiered_with_proration_price.rb +1 -3
  66. data/lib/orb/models/new_floating_unit_price.rb +1 -3
  67. data/lib/orb/models/new_floating_unit_with_percent_price.rb +1 -3
  68. data/lib/orb/models/new_floating_unit_with_proration_price.rb +1 -3
  69. data/lib/orb/models/new_plan_bulk_price.rb +1 -1
  70. data/lib/orb/models/new_plan_bulk_with_proration_price.rb +1 -3
  71. data/lib/orb/models/new_plan_cumulative_grouped_bulk_price.rb +1 -3
  72. data/lib/orb/models/new_plan_grouped_allocation_price.rb +1 -3
  73. data/lib/orb/models/new_plan_grouped_tiered_package_price.rb +1 -3
  74. data/lib/orb/models/new_plan_grouped_tiered_price.rb +1 -3
  75. data/lib/orb/models/new_plan_grouped_with_metered_minimum_price.rb +1 -3
  76. data/lib/orb/models/new_plan_grouped_with_prorated_minimum_price.rb +1 -3
  77. data/lib/orb/models/new_plan_matrix_price.rb +1 -5
  78. data/lib/orb/models/new_plan_matrix_with_allocation_price.rb +1 -3
  79. data/lib/orb/models/new_plan_matrix_with_display_name_price.rb +1 -3
  80. data/lib/orb/models/new_plan_max_group_tiered_package_price.rb +1 -3
  81. data/lib/orb/models/new_plan_minimum_composite_price.rb +1 -3
  82. data/lib/orb/models/new_plan_package_price.rb +1 -5
  83. data/lib/orb/models/new_plan_package_with_allocation_price.rb +1 -3
  84. data/lib/orb/models/new_plan_scalable_matrix_with_tiered_pricing_price.rb +1 -3
  85. data/lib/orb/models/new_plan_scalable_matrix_with_unit_pricing_price.rb +1 -3
  86. data/lib/orb/models/new_plan_threshold_total_amount_price.rb +1 -3
  87. data/lib/orb/models/new_plan_tiered_package_price.rb +1 -3
  88. data/lib/orb/models/new_plan_tiered_package_with_minimum_price.rb +1 -3
  89. data/lib/orb/models/new_plan_tiered_price.rb +1 -5
  90. data/lib/orb/models/new_plan_tiered_with_minimum_price.rb +1 -3
  91. data/lib/orb/models/new_plan_unit_price.rb +1 -1
  92. data/lib/orb/models/new_plan_unit_with_percent_price.rb +1 -3
  93. data/lib/orb/models/new_plan_unit_with_proration_price.rb +1 -3
  94. data/lib/orb/models/new_subscription_bulk_price.rb +1 -3
  95. data/lib/orb/models/new_subscription_bulk_with_proration_price.rb +1 -3
  96. data/lib/orb/models/new_subscription_cumulative_grouped_bulk_price.rb +1 -3
  97. data/lib/orb/models/new_subscription_grouped_allocation_price.rb +1 -3
  98. data/lib/orb/models/new_subscription_grouped_tiered_package_price.rb +1 -3
  99. data/lib/orb/models/new_subscription_grouped_tiered_price.rb +1 -3
  100. data/lib/orb/models/new_subscription_grouped_with_metered_minimum_price.rb +1 -3
  101. data/lib/orb/models/new_subscription_grouped_with_prorated_minimum_price.rb +1 -3
  102. data/lib/orb/models/new_subscription_matrix_price.rb +1 -3
  103. data/lib/orb/models/new_subscription_matrix_with_allocation_price.rb +1 -3
  104. data/lib/orb/models/new_subscription_matrix_with_display_name_price.rb +1 -3
  105. data/lib/orb/models/new_subscription_max_group_tiered_package_price.rb +1 -3
  106. data/lib/orb/models/new_subscription_minimum_composite_price.rb +1 -3
  107. data/lib/orb/models/new_subscription_package_price.rb +1 -3
  108. data/lib/orb/models/new_subscription_package_with_allocation_price.rb +1 -3
  109. data/lib/orb/models/new_subscription_scalable_matrix_with_tiered_pricing_price.rb +1 -3
  110. data/lib/orb/models/new_subscription_scalable_matrix_with_unit_pricing_price.rb +1 -3
  111. data/lib/orb/models/new_subscription_threshold_total_amount_price.rb +1 -3
  112. data/lib/orb/models/new_subscription_tiered_package_price.rb +1 -3
  113. data/lib/orb/models/new_subscription_tiered_package_with_minimum_price.rb +1 -3
  114. data/lib/orb/models/new_subscription_tiered_price.rb +1 -3
  115. data/lib/orb/models/new_subscription_tiered_with_minimum_price.rb +1 -3
  116. data/lib/orb/models/new_subscription_unit_price.rb +1 -3
  117. data/lib/orb/models/new_subscription_unit_with_percent_price.rb +1 -3
  118. data/lib/orb/models/new_subscription_unit_with_proration_price.rb +1 -3
  119. data/lib/orb/models/per_price_cost.rb +2 -2
  120. data/lib/orb/models/plan.rb +189 -9
  121. data/lib/orb/models/plan_create_params.rb +1047 -8228
  122. data/lib/orb/models/plan_update_params.rb +9 -1
  123. data/lib/orb/models/plan_version.rb +186 -5
  124. data/lib/orb/models/plans/external_plan_id_update_params.rb +9 -1
  125. data/lib/orb/models/plans/migration_cancel_response.rb +22 -4
  126. data/lib/orb/models/plans/migration_list_response.rb +22 -4
  127. data/lib/orb/models/plans/migration_retrieve_response.rb +22 -4
  128. data/lib/orb/models/price.rb +2614 -1268
  129. data/lib/orb/models/price_create_params.rb +866 -49
  130. data/lib/orb/models/price_evaluate_multiple_params.rb +889 -54
  131. data/lib/orb/models/price_evaluate_preview_events_params.rb +881 -46
  132. data/lib/orb/models/price_interval.rb +2 -2
  133. data/lib/orb/models/subscription.rb +168 -4
  134. data/lib/orb/models/subscription_create_params.rb +2818 -674
  135. data/lib/orb/models/subscription_price_intervals_params.rb +1098 -57
  136. data/lib/orb/models/subscription_schedule_plan_change_params.rb +2834 -687
  137. data/lib/orb/models/subscription_update_params.rb +12 -1
  138. data/lib/orb/models.rb +2 -0
  139. data/lib/orb/resources/alerts.rb +14 -3
  140. data/lib/orb/resources/customers/credits/ledger.rb +28 -14
  141. data/lib/orb/resources/customers.rb +6 -2
  142. data/lib/orb/resources/events.rb +7 -34
  143. data/lib/orb/resources/invoices.rb +6 -2
  144. data/lib/orb/resources/licenses/external_licenses.rb +1 -1
  145. data/lib/orb/resources/licenses/usage.rb +2 -2
  146. data/lib/orb/resources/metrics.rb +5 -5
  147. data/lib/orb/resources/plans/external_plan_id.rb +5 -3
  148. data/lib/orb/resources/plans.rb +9 -5
  149. data/lib/orb/resources/prices/external_price_id.rb +2 -2
  150. data/lib/orb/resources/prices.rb +5 -5
  151. data/lib/orb/resources/subscriptions.rb +20 -3
  152. data/lib/orb/version.rb +1 -1
  153. data/lib/orb.rb +1 -0
  154. data/rbi/orb/models/accounting_provider_config.rbi +38 -5
  155. data/rbi/orb/models/adjustment_interval.rbi +336 -0
  156. data/rbi/orb/models/alert.rbi +172 -3
  157. data/rbi/orb/models/alert_create_for_subscription_params.rbi +268 -9
  158. data/rbi/orb/models/alert_update_params.rbi +208 -0
  159. data/rbi/orb/models/beta/external_plan_id_create_plan_version_params.rbi +3833 -28395
  160. data/rbi/orb/models/beta_create_plan_version_params.rbi +3833 -28363
  161. data/rbi/orb/models/billable_metric.rbi +10 -0
  162. data/rbi/orb/models/changed_subscription_resources.rbi +360 -5
  163. data/rbi/orb/models/conversion_rate_config.rbi +18 -0
  164. data/rbi/orb/models/credit_block_list_invoices_response.rbi +425 -3
  165. data/rbi/orb/models/credit_block_retrieve_response.rbi +421 -3
  166. data/rbi/orb/models/customer.rbi +190 -10
  167. data/rbi/orb/models/customer_create_params.rbi +12 -2
  168. data/rbi/orb/models/customer_tax_id.rbi +15 -1
  169. data/rbi/orb/models/customer_update_by_external_id_params.rbi +22 -2
  170. data/rbi/orb/models/customer_update_params.rbi +22 -2
  171. data/rbi/orb/models/customers/credit_list_by_external_id_response.rbi +425 -3
  172. data/rbi/orb/models/customers/credit_list_response.rbi +426 -3
  173. data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbi +6 -6
  174. data/rbi/orb/models/customers/credits/ledger_create_entry_params.rbi +6 -6
  175. data/rbi/orb/models/dimensional_price_group.rbi +1 -1
  176. data/rbi/orb/models/discount.rbi +269 -1
  177. data/rbi/orb/models/event_ingest_params.rbi +4 -2
  178. data/rbi/orb/models/invoice.rbi +360 -5
  179. data/rbi/orb/models/invoice_create_params.rbi +12 -7
  180. data/rbi/orb/models/invoice_fetch_upcoming_response.rbi +360 -5
  181. data/rbi/orb/models/invoice_issue_summary_response.rbi +19 -4
  182. data/rbi/orb/models/invoice_level_discount.rbi +298 -1
  183. data/rbi/orb/models/invoice_line_item_create_response.rbi +339 -0
  184. data/rbi/orb/models/invoice_list_summary_response.rbi +19 -4
  185. data/rbi/orb/models/licenses/external_license_get_usage_params.rbi +3 -3
  186. data/rbi/orb/models/licenses/usage_get_all_usage_params.rbi +3 -3
  187. data/rbi/orb/models/licenses/usage_get_usage_params.rbi +3 -3
  188. data/rbi/orb/models/mutated_subscription.rbi +324 -2
  189. data/rbi/orb/models/new_allocation_price.rbi +12 -0
  190. data/rbi/orb/models/per_price_cost.rbi +3 -0
  191. data/rbi/orb/models/plan.rbi +339 -2
  192. data/rbi/orb/models/plan_create_params.rbi +1877 -14138
  193. data/rbi/orb/models/plan_update_params.rbi +8 -0
  194. data/rbi/orb/models/plan_version.rbi +339 -0
  195. data/rbi/orb/models/plans/external_plan_id_update_params.rbi +8 -0
  196. data/rbi/orb/models/plans/migration_cancel_response.rbi +22 -1
  197. data/rbi/orb/models/plans/migration_list_response.rbi +22 -1
  198. data/rbi/orb/models/plans/migration_retrieve_response.rbi +22 -1
  199. data/rbi/orb/models/price.rbi +4552 -2285
  200. data/rbi/orb/models/price_create_params.rbi +1540 -114
  201. data/rbi/orb/models/price_evaluate_multiple_params.rbi +1540 -114
  202. data/rbi/orb/models/price_evaluate_preview_events_params.rbi +1540 -114
  203. data/rbi/orb/models/price_interval.rbi +3 -0
  204. data/rbi/orb/models/subscription.rbi +324 -2
  205. data/rbi/orb/models/subscription_create_params.rbi +4998 -1186
  206. data/rbi/orb/models/subscription_price_intervals_params.rbi +2127 -264
  207. data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +4997 -1185
  208. data/rbi/orb/models/subscription_update_params.rbi +14 -0
  209. data/rbi/orb/models.rbi +2 -0
  210. data/rbi/orb/resources/alerts.rbi +39 -4
  211. data/rbi/orb/resources/customers/credits/ledger.rbi +28 -14
  212. data/rbi/orb/resources/customers.rbi +23 -0
  213. data/rbi/orb/resources/events.rbi +8 -35
  214. data/rbi/orb/resources/invoices.rbi +9 -3
  215. data/rbi/orb/resources/licenses/external_licenses.rbi +1 -1
  216. data/rbi/orb/resources/licenses/usage.rbi +2 -2
  217. data/rbi/orb/resources/metrics.rbi +5 -5
  218. data/rbi/orb/resources/plans/external_plan_id.rbi +5 -2
  219. data/rbi/orb/resources/plans.rbi +9 -3
  220. data/rbi/orb/resources/prices.rbi +3 -0
  221. data/rbi/orb/resources/subscriptions.rbi +29 -0
  222. data/sig/orb/models/accounting_provider_config.rbs +21 -4
  223. data/sig/orb/models/adjustment_interval.rbs +134 -0
  224. data/sig/orb/models/alert.rbs +85 -3
  225. data/sig/orb/models/alert_create_for_subscription_params.rbs +86 -4
  226. data/sig/orb/models/alert_update_params.rbs +86 -1
  227. data/sig/orb/models/beta/external_plan_id_create_plan_version_params.rbs +1803 -11601
  228. data/sig/orb/models/beta_create_plan_version_params.rbs +1747 -11541
  229. data/sig/orb/models/billable_metric.rbs +5 -0
  230. data/sig/orb/models/changed_subscription_resources.rbs +140 -1
  231. data/sig/orb/models/conversion_rate_config.rbs +12 -0
  232. data/sig/orb/models/credit_block_list_invoices_response.rbs +142 -3
  233. data/sig/orb/models/credit_block_retrieve_response.rbs +142 -3
  234. data/sig/orb/models/customer.rbs +70 -4
  235. data/sig/orb/models/customer_create_params.rbs +2 -2
  236. data/sig/orb/models/customer_tax_id.rbs +20 -2
  237. data/sig/orb/models/customer_update_by_external_id_params.rbs +7 -2
  238. data/sig/orb/models/customer_update_params.rbs +7 -2
  239. data/sig/orb/models/customers/credit_list_by_external_id_response.rbs +142 -3
  240. data/sig/orb/models/customers/credit_list_response.rbs +142 -3
  241. data/sig/orb/models/discount.rbs +114 -0
  242. data/sig/orb/models/invoice.rbs +140 -1
  243. data/sig/orb/models/invoice_fetch_upcoming_response.rbs +140 -1
  244. data/sig/orb/models/invoice_issue_summary_response.rbs +2 -1
  245. data/sig/orb/models/invoice_level_discount.rbs +117 -1
  246. data/sig/orb/models/invoice_line_item_create_response.rbs +134 -0
  247. data/sig/orb/models/invoice_list_summary_response.rbs +2 -1
  248. data/sig/orb/models/licenses/external_license_get_usage_params.rbs +4 -4
  249. data/sig/orb/models/licenses/usage_get_all_usage_params.rbs +4 -4
  250. data/sig/orb/models/licenses/usage_get_usage_params.rbs +4 -4
  251. data/sig/orb/models/mutated_subscription.rbs +124 -0
  252. data/sig/orb/models/new_allocation_price.rbs +5 -0
  253. data/sig/orb/models/new_floating_bulk_price.rbs +4 -4
  254. data/sig/orb/models/new_floating_bulk_with_proration_price.rbs +4 -4
  255. data/sig/orb/models/new_floating_cumulative_grouped_bulk_price.rbs +4 -4
  256. data/sig/orb/models/new_floating_grouped_allocation_price.rbs +4 -4
  257. data/sig/orb/models/new_floating_grouped_tiered_package_price.rbs +4 -4
  258. data/sig/orb/models/new_floating_grouped_tiered_price.rbs +4 -4
  259. data/sig/orb/models/new_floating_grouped_with_metered_minimum_price.rbs +4 -4
  260. data/sig/orb/models/new_floating_grouped_with_prorated_minimum_price.rbs +4 -4
  261. data/sig/orb/models/new_floating_matrix_price.rbs +4 -4
  262. data/sig/orb/models/new_floating_matrix_with_allocation_price.rbs +4 -4
  263. data/sig/orb/models/new_floating_matrix_with_display_name_price.rbs +4 -4
  264. data/sig/orb/models/new_floating_max_group_tiered_package_price.rbs +4 -4
  265. data/sig/orb/models/new_floating_minimum_composite_price.rbs +4 -4
  266. data/sig/orb/models/new_floating_package_price.rbs +4 -4
  267. data/sig/orb/models/new_floating_package_with_allocation_price.rbs +4 -4
  268. data/sig/orb/models/new_floating_scalable_matrix_with_tiered_pricing_price.rbs +4 -4
  269. data/sig/orb/models/new_floating_scalable_matrix_with_unit_pricing_price.rbs +4 -4
  270. data/sig/orb/models/new_floating_threshold_total_amount_price.rbs +4 -4
  271. data/sig/orb/models/new_floating_tiered_package_price.rbs +4 -4
  272. data/sig/orb/models/new_floating_tiered_package_with_minimum_price.rbs +4 -4
  273. data/sig/orb/models/new_floating_tiered_price.rbs +4 -4
  274. data/sig/orb/models/new_floating_tiered_with_minimum_price.rbs +4 -4
  275. data/sig/orb/models/new_floating_tiered_with_proration_price.rbs +4 -4
  276. data/sig/orb/models/new_floating_unit_price.rbs +4 -4
  277. data/sig/orb/models/new_floating_unit_with_percent_price.rbs +4 -4
  278. data/sig/orb/models/new_floating_unit_with_proration_price.rbs +4 -4
  279. data/sig/orb/models/new_plan_bulk_price.rbs +4 -4
  280. data/sig/orb/models/new_plan_bulk_with_proration_price.rbs +4 -4
  281. data/sig/orb/models/new_plan_cumulative_grouped_bulk_price.rbs +4 -4
  282. data/sig/orb/models/new_plan_grouped_allocation_price.rbs +4 -4
  283. data/sig/orb/models/new_plan_grouped_tiered_package_price.rbs +4 -4
  284. data/sig/orb/models/new_plan_grouped_tiered_price.rbs +4 -4
  285. data/sig/orb/models/new_plan_grouped_with_metered_minimum_price.rbs +4 -4
  286. data/sig/orb/models/new_plan_grouped_with_prorated_minimum_price.rbs +4 -4
  287. data/sig/orb/models/new_plan_matrix_price.rbs +4 -4
  288. data/sig/orb/models/new_plan_matrix_with_allocation_price.rbs +4 -4
  289. data/sig/orb/models/new_plan_matrix_with_display_name_price.rbs +4 -4
  290. data/sig/orb/models/new_plan_max_group_tiered_package_price.rbs +4 -4
  291. data/sig/orb/models/new_plan_minimum_composite_price.rbs +4 -4
  292. data/sig/orb/models/new_plan_package_price.rbs +4 -4
  293. data/sig/orb/models/new_plan_package_with_allocation_price.rbs +4 -4
  294. data/sig/orb/models/new_plan_scalable_matrix_with_tiered_pricing_price.rbs +4 -4
  295. data/sig/orb/models/new_plan_scalable_matrix_with_unit_pricing_price.rbs +4 -4
  296. data/sig/orb/models/new_plan_threshold_total_amount_price.rbs +4 -4
  297. data/sig/orb/models/new_plan_tiered_package_price.rbs +4 -4
  298. data/sig/orb/models/new_plan_tiered_package_with_minimum_price.rbs +4 -4
  299. data/sig/orb/models/new_plan_tiered_price.rbs +4 -4
  300. data/sig/orb/models/new_plan_tiered_with_minimum_price.rbs +4 -4
  301. data/sig/orb/models/new_plan_unit_price.rbs +4 -4
  302. data/sig/orb/models/new_plan_unit_with_percent_price.rbs +4 -4
  303. data/sig/orb/models/new_plan_unit_with_proration_price.rbs +4 -4
  304. data/sig/orb/models/new_subscription_bulk_price.rbs +4 -4
  305. data/sig/orb/models/new_subscription_bulk_with_proration_price.rbs +4 -4
  306. data/sig/orb/models/new_subscription_cumulative_grouped_bulk_price.rbs +4 -4
  307. data/sig/orb/models/new_subscription_grouped_allocation_price.rbs +4 -4
  308. data/sig/orb/models/new_subscription_grouped_tiered_package_price.rbs +4 -4
  309. data/sig/orb/models/new_subscription_grouped_tiered_price.rbs +4 -4
  310. data/sig/orb/models/new_subscription_grouped_with_metered_minimum_price.rbs +4 -4
  311. data/sig/orb/models/new_subscription_grouped_with_prorated_minimum_price.rbs +4 -4
  312. data/sig/orb/models/new_subscription_matrix_price.rbs +4 -4
  313. data/sig/orb/models/new_subscription_matrix_with_allocation_price.rbs +4 -4
  314. data/sig/orb/models/new_subscription_matrix_with_display_name_price.rbs +4 -4
  315. data/sig/orb/models/new_subscription_max_group_tiered_package_price.rbs +4 -4
  316. data/sig/orb/models/new_subscription_minimum_composite_price.rbs +4 -4
  317. data/sig/orb/models/new_subscription_package_price.rbs +4 -4
  318. data/sig/orb/models/new_subscription_package_with_allocation_price.rbs +4 -4
  319. data/sig/orb/models/new_subscription_scalable_matrix_with_tiered_pricing_price.rbs +4 -4
  320. data/sig/orb/models/new_subscription_scalable_matrix_with_unit_pricing_price.rbs +4 -4
  321. data/sig/orb/models/new_subscription_threshold_total_amount_price.rbs +4 -4
  322. data/sig/orb/models/new_subscription_tiered_package_price.rbs +4 -4
  323. data/sig/orb/models/new_subscription_tiered_package_with_minimum_price.rbs +4 -4
  324. data/sig/orb/models/new_subscription_tiered_price.rbs +4 -4
  325. data/sig/orb/models/new_subscription_tiered_with_minimum_price.rbs +4 -4
  326. data/sig/orb/models/new_subscription_unit_price.rbs +4 -4
  327. data/sig/orb/models/new_subscription_unit_with_percent_price.rbs +4 -4
  328. data/sig/orb/models/new_subscription_unit_with_proration_price.rbs +4 -4
  329. data/sig/orb/models/plan.rbs +134 -0
  330. data/sig/orb/models/plan_create_params.rbs +836 -5728
  331. data/sig/orb/models/plan_update_params.rbs +5 -0
  332. data/sig/orb/models/plan_version.rbs +134 -0
  333. data/sig/orb/models/plans/external_plan_id_update_params.rbs +5 -0
  334. data/sig/orb/models/price.rbs +2200 -1150
  335. data/sig/orb/models/price_create_params.rbs +611 -23
  336. data/sig/orb/models/price_evaluate_multiple_params.rbs +626 -23
  337. data/sig/orb/models/price_evaluate_preview_events_params.rbs +626 -23
  338. data/sig/orb/models/subscription.rbs +124 -0
  339. data/sig/orb/models/subscription_create_params.rbs +2009 -430
  340. data/sig/orb/models/subscription_price_intervals_params.rbs +795 -23
  341. data/sig/orb/models/subscription_schedule_plan_change_params.rbs +2009 -430
  342. data/sig/orb/models/subscription_update_params.rbs +5 -0
  343. data/sig/orb/models.rbs +2 -0
  344. data/sig/orb/resources/alerts.rbs +5 -1
  345. data/sig/orb/resources/customers.rbs +2 -0
  346. data/sig/orb/resources/licenses/external_licenses.rbs +1 -1
  347. data/sig/orb/resources/licenses/usage.rbs +2 -2
  348. data/sig/orb/resources/plans/external_plan_id.rbs +1 -0
  349. data/sig/orb/resources/plans.rbs +2 -0
  350. data/sig/orb/resources/subscriptions.rbs +3 -0
  351. metadata +6 -7
@@ -56,6 +56,13 @@ module Orb
56
56
  # @return [String, nil]
57
57
  optional :currency, String, nil?: true
58
58
 
59
+ # @!attribute default_payment_method_id
60
+ # The Orb ID of the payment method to set as this customer's default. Pass `null`
61
+ # to clear the customer's default payment method.
62
+ #
63
+ # @return [String, nil]
64
+ optional :default_payment_method_id, String, nil?: true
65
+
59
66
  # @!attribute email
60
67
  # A valid customer email, to be used for invoicing and notifications.
61
68
  #
@@ -196,11 +203,13 @@ module Orb
196
203
  # | Estonia | `eu_vat` | European VAT Number |
197
204
  # | Ethiopia | `et_tin` | Ethiopia Tax Identification Number |
198
205
  # | European Union | `eu_oss_vat` | European One Stop Shop VAT Number for non-Union scheme |
206
+ # | Faroe Islands | `fo_vat` | Faroe Islands VAT Number |
199
207
  # | Finland | `eu_vat` | European VAT Number |
200
208
  # | France | `eu_vat` | European VAT Number |
201
209
  # | Georgia | `ge_vat` | Georgian VAT |
202
210
  # | Germany | `de_stn` | German Tax Number (Steuernummer) |
203
211
  # | Germany | `eu_vat` | European VAT Number |
212
+ # | Gibraltar | `gi_tin` | Gibraltar Tax Identification Number |
204
213
  # | Greece | `eu_vat` | European VAT Number |
205
214
  # | Guinea | `gn_nif` | Guinea Tax Identification Number (Número de Identificação Fiscal) |
206
215
  # | Hong Kong | `hk_br` | Hong Kong BR Number |
@@ -212,6 +221,7 @@ module Orb
212
221
  # | Ireland | `eu_vat` | European VAT Number |
213
222
  # | Israel | `il_vat` | Israel VAT |
214
223
  # | Italy | `eu_vat` | European VAT Number |
224
+ # | Italy | `it_cf` | Italian Codice Fiscale Number |
215
225
  # | Japan | `jp_cn` | Japanese Corporate Number (_Hōjin Bangō_) |
216
226
  # | Japan | `jp_rn` | Japanese Registered Foreign Businesses' Registration Number (_Tōroku Kokugai Jigyōsha no Tōroku Bangō_) |
217
227
  # | Japan | `jp_trn` | Japanese Tax Registration Number (_Tōroku Bangō_) |
@@ -242,6 +252,7 @@ module Orb
242
252
  # | Norway | `no_vat` | Norwegian VAT Number |
243
253
  # | Norway | `no_voec` | Norwegian VAT on e-commerce Number |
244
254
  # | Oman | `om_vat` | Omani VAT Number |
255
+ # | Paraguay | `py_ruc` | Paraguayan RUC Number |
245
256
  # | Peru | `pe_ruc` | Peruvian RUC Number |
246
257
  # | Philippines | `ph_tin` | Philippines Tax Identification Number |
247
258
  # | Poland | `eu_vat` | European VAT Number |
@@ -263,6 +274,7 @@ module Orb
263
274
  # | South Korea | `kr_brn` | Korean BRN |
264
275
  # | Spain | `es_cif` | Spanish NIF Number (previously Spanish CIF Number) |
265
276
  # | Spain | `eu_vat` | European VAT Number |
277
+ # | Sri Lanka | `lk_vat` | Sri Lanka VAT Number |
266
278
  # | Suriname | `sr_fin` | Suriname FIN Number |
267
279
  # | Sweden | `eu_vat` | European VAT Number |
268
280
  # | Switzerland | `ch_uid` | Switzerland UID Number |
@@ -288,7 +300,7 @@ module Orb
288
300
  # @return [Orb::Models::CustomerTaxID, nil]
289
301
  optional :tax_id, -> { Orb::CustomerTaxID }, nil?: true
290
302
 
291
- # @!method initialize(customer_id:, accounting_sync_configuration: nil, additional_emails: nil, auto_collection: nil, auto_issuance: nil, billing_address: nil, currency: nil, email: nil, email_delivery: nil, external_customer_id: nil, hierarchy: nil, metadata: nil, name: nil, payment_configuration: nil, payment_provider: nil, payment_provider_id: nil, reporting_configuration: nil, shipping_address: nil, tax_configuration: nil, tax_id: nil, request_options: {})
303
+ # @!method initialize(customer_id:, accounting_sync_configuration: nil, additional_emails: nil, auto_collection: nil, auto_issuance: nil, billing_address: nil, currency: nil, default_payment_method_id: nil, email: nil, email_delivery: nil, external_customer_id: nil, hierarchy: nil, metadata: nil, name: nil, payment_configuration: nil, payment_provider: nil, payment_provider_id: nil, reporting_configuration: nil, shipping_address: nil, tax_configuration: nil, tax_id: nil, request_options: {})
292
304
  # Some parameter documentations has been truncated, see
293
305
  # {Orb::Models::CustomerUpdateParams} for more details.
294
306
  #
@@ -306,6 +318,8 @@ module Orb
306
318
  #
307
319
  # @param currency [String, nil] An ISO 4217 currency string used for the customer's invoices and balance. This c
308
320
  #
321
+ # @param default_payment_method_id [String, nil] The Orb ID of the payment method to set as this customer's default. Pass `null`
322
+ #
309
323
  # @param email [String, nil] A valid customer email, to be used for invoicing and notifications.
310
324
  #
311
325
  # @param email_delivery [Boolean, nil]
@@ -414,7 +428,7 @@ module Orb
414
428
  STRIPE_CHARGE = :stripe_charge
415
429
  STRIPE_INVOICE = :stripe_invoice
416
430
  NETSUITE = :netsuite
417
- NETSUITE_AMPERSAND = :netsuite_ampersand
431
+ ADYEN = :adyen
418
432
 
419
433
  # @!method self.values
420
434
  # @return [Array<Symbol>]
@@ -15,6 +15,17 @@ module Orb
15
15
  # @return [Float]
16
16
  required :balance, Float
17
17
 
18
+ # @!attribute credit_block_source
19
+ # How this credit block was created: `allocation` (a subscription's recurring
20
+ # credit allocation), `top_up` (an automatic balance-threshold top-up),
21
+ # `commitment` (a subscription commitment true-up rolled forward as credit), or
22
+ # `manual` (a manual credit ledger increment, including credits voided or expired
23
+ # off another block).
24
+ #
25
+ # @return [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::CreditBlockSource]
26
+ required :credit_block_source,
27
+ enum: -> { Orb::Models::Customers::CreditListByExternalIDResponse::CreditBlockSource }
28
+
18
29
  # @!attribute effective_date
19
30
  #
20
31
  # @return [Time, nil]
@@ -55,7 +66,25 @@ module Orb
55
66
  # @return [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::Status]
56
67
  required :status, enum: -> { Orb::Models::Customers::CreditListByExternalIDResponse::Status }
57
68
 
58
- # @!method initialize(id:, balance:, effective_date:, expiry_date:, filters:, maximum_initial_balance:, metadata:, per_unit_cost_basis:, status:)
69
+ # @!attribute credit_allocation
70
+ # The credit allocation that funded a block. Extends the allocation resource
71
+ # serialized on prices with the catalog-item attribution of the funding price.
72
+ #
73
+ # @return [Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation, nil]
74
+ optional :credit_allocation,
75
+ -> { Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation },
76
+ nil?: true
77
+
78
+ # @!attribute credit_commitment
79
+ # The subscription commitment whose true-up rolled forward into this credit block.
80
+ # Present only when `credit_block_source` is `commitment`.
81
+ #
82
+ # @return [Orb::Models::Customers::CreditListByExternalIDResponse::CreditCommitment, nil]
83
+ optional :credit_commitment,
84
+ -> { Orb::Models::Customers::CreditListByExternalIDResponse::CreditCommitment },
85
+ nil?: true
86
+
87
+ # @!method initialize(id:, balance:, credit_block_source:, effective_date:, expiry_date:, filters:, maximum_initial_balance:, metadata:, per_unit_cost_basis:, status:, credit_allocation: nil, credit_commitment: nil)
59
88
  # Some parameter documentations has been truncated, see
60
89
  # {Orb::Models::Customers::CreditListByExternalIDResponse} for more details.
61
90
  #
@@ -63,6 +92,8 @@ module Orb
63
92
  #
64
93
  # @param balance [Float]
65
94
  #
95
+ # @param credit_block_source [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::CreditBlockSource] How this credit block was created: `allocation` (a subscription's recurring cred
96
+ #
66
97
  # @param effective_date [Time, nil]
67
98
  #
68
99
  # @param expiry_date [Time, nil]
@@ -76,6 +107,29 @@ module Orb
76
107
  # @param per_unit_cost_basis [String, nil]
77
108
  #
78
109
  # @param status [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::Status]
110
+ #
111
+ # @param credit_allocation [Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation, nil] The credit allocation that funded a block. Extends the allocation resource
112
+ #
113
+ # @param credit_commitment [Orb::Models::Customers::CreditListByExternalIDResponse::CreditCommitment, nil] The subscription commitment whose true-up rolled forward into this credit block.
114
+
115
+ # How this credit block was created: `allocation` (a subscription's recurring
116
+ # credit allocation), `top_up` (an automatic balance-threshold top-up),
117
+ # `commitment` (a subscription commitment true-up rolled forward as credit), or
118
+ # `manual` (a manual credit ledger increment, including credits voided or expired
119
+ # off another block).
120
+ #
121
+ # @see Orb::Models::Customers::CreditListByExternalIDResponse#credit_block_source
122
+ module CreditBlockSource
123
+ extend Orb::Internal::Type::Enum
124
+
125
+ ALLOCATION = :allocation
126
+ TOP_UP = :top_up
127
+ COMMITMENT = :commitment
128
+ MANUAL = :manual
129
+
130
+ # @!method self.values
131
+ # @return [Array<Symbol>]
132
+ end
79
133
 
80
134
  class Filter < Orb::Internal::Type::BaseModel
81
135
  # @!attribute field
@@ -141,6 +195,143 @@ module Orb
141
195
  # @!method self.values
142
196
  # @return [Array<Symbol>]
143
197
  end
198
+
199
+ # @see Orb::Models::Customers::CreditListByExternalIDResponse#credit_allocation
200
+ class CreditAllocation < Orb::Internal::Type::BaseModel
201
+ # @!attribute allows_rollover
202
+ #
203
+ # @return [Boolean]
204
+ required :allows_rollover, Orb::Internal::Type::Boolean
205
+
206
+ # @!attribute currency
207
+ #
208
+ # @return [String]
209
+ required :currency, String
210
+
211
+ # @!attribute custom_expiration
212
+ #
213
+ # @return [Orb::Models::CustomExpiration, nil]
214
+ required :custom_expiration, -> { Orb::CustomExpiration }, nil?: true
215
+
216
+ # @!attribute item_id
217
+ # The ID of the catalog item this block was allocated from, derived from the
218
+ # allocation's price.
219
+ #
220
+ # @return [String]
221
+ required :item_id, String
222
+
223
+ # @!attribute filters
224
+ #
225
+ # @return [Array<Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter>, nil]
226
+ optional :filters,
227
+ -> { Orb::Internal::Type::ArrayOf[Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter] }
228
+
229
+ # @!attribute license_type_id
230
+ #
231
+ # @return [String, nil]
232
+ optional :license_type_id, String, nil?: true
233
+
234
+ # @!method initialize(allows_rollover:, currency:, custom_expiration:, item_id:, filters: nil, license_type_id: nil)
235
+ # Some parameter documentations has been truncated, see
236
+ # {Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation} for
237
+ # more details.
238
+ #
239
+ # The credit allocation that funded a block. Extends the allocation resource
240
+ # serialized on prices with the catalog-item attribution of the funding price.
241
+ #
242
+ # @param allows_rollover [Boolean]
243
+ #
244
+ # @param currency [String]
245
+ #
246
+ # @param custom_expiration [Orb::Models::CustomExpiration, nil]
247
+ #
248
+ # @param item_id [String] The ID of the catalog item this block was allocated from, derived from the alloc
249
+ #
250
+ # @param filters [Array<Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter>]
251
+ #
252
+ # @param license_type_id [String, nil]
253
+
254
+ class Filter < Orb::Internal::Type::BaseModel
255
+ # @!attribute field
256
+ # The property of the price to filter on.
257
+ #
258
+ # @return [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter::Field]
259
+ required :field,
260
+ enum: -> { Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter::Field }
261
+
262
+ # @!attribute operator
263
+ # Should prices that match the filter be included or excluded.
264
+ #
265
+ # @return [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter::Operator]
266
+ required :operator,
267
+ enum: -> { Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter::Operator }
268
+
269
+ # @!attribute values
270
+ # The IDs or values that match this filter.
271
+ #
272
+ # @return [Array<String>]
273
+ required :values, Orb::Internal::Type::ArrayOf[String]
274
+
275
+ # @!method initialize(field:, operator:, values:)
276
+ # @param field [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter::Field] The property of the price to filter on.
277
+ #
278
+ # @param operator [Symbol, Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter::Operator] Should prices that match the filter be included or excluded.
279
+ #
280
+ # @param values [Array<String>] The IDs or values that match this filter.
281
+
282
+ # The property of the price to filter on.
283
+ #
284
+ # @see Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter#field
285
+ module Field
286
+ extend Orb::Internal::Type::Enum
287
+
288
+ PRICE_ID = :price_id
289
+ ITEM_ID = :item_id
290
+ PRICE_TYPE = :price_type
291
+ CURRENCY = :currency
292
+ PRICING_UNIT_ID = :pricing_unit_id
293
+
294
+ # @!method self.values
295
+ # @return [Array<Symbol>]
296
+ end
297
+
298
+ # Should prices that match the filter be included or excluded.
299
+ #
300
+ # @see Orb::Models::Customers::CreditListByExternalIDResponse::CreditAllocation::Filter#operator
301
+ module Operator
302
+ extend Orb::Internal::Type::Enum
303
+
304
+ INCLUDES = :includes
305
+ EXCLUDES = :excludes
306
+
307
+ # @!method self.values
308
+ # @return [Array<Symbol>]
309
+ end
310
+ end
311
+ end
312
+
313
+ # @see Orb::Models::Customers::CreditListByExternalIDResponse#credit_commitment
314
+ class CreditCommitment < Orb::Internal::Type::BaseModel
315
+ # @!attribute id
316
+ # The ID of the subscription commitment this block was rolled forward from.
317
+ #
318
+ # @return [String]
319
+ required :id, String
320
+
321
+ # @!attribute subscription_id
322
+ # The subscription the commitment belongs to.
323
+ #
324
+ # @return [String, nil]
325
+ optional :subscription_id, String, nil?: true
326
+
327
+ # @!method initialize(id:, subscription_id: nil)
328
+ # The subscription commitment whose true-up rolled forward into this credit block.
329
+ # Present only when `credit_block_source` is `commitment`.
330
+ #
331
+ # @param id [String] The ID of the subscription commitment this block was rolled forward from.
332
+ #
333
+ # @param subscription_id [String, nil] The subscription the commitment belongs to.
334
+ end
144
335
  end
145
336
  end
146
337
  end
@@ -15,6 +15,16 @@ module Orb
15
15
  # @return [Float]
16
16
  required :balance, Float
17
17
 
18
+ # @!attribute credit_block_source
19
+ # How this credit block was created: `allocation` (a subscription's recurring
20
+ # credit allocation), `top_up` (an automatic balance-threshold top-up),
21
+ # `commitment` (a subscription commitment true-up rolled forward as credit), or
22
+ # `manual` (a manual credit ledger increment, including credits voided or expired
23
+ # off another block).
24
+ #
25
+ # @return [Symbol, Orb::Models::Customers::CreditListResponse::CreditBlockSource]
26
+ required :credit_block_source, enum: -> { Orb::Models::Customers::CreditListResponse::CreditBlockSource }
27
+
18
28
  # @!attribute effective_date
19
29
  #
20
30
  # @return [Time, nil]
@@ -54,7 +64,25 @@ module Orb
54
64
  # @return [Symbol, Orb::Models::Customers::CreditListResponse::Status]
55
65
  required :status, enum: -> { Orb::Models::Customers::CreditListResponse::Status }
56
66
 
57
- # @!method initialize(id:, balance:, effective_date:, expiry_date:, filters:, maximum_initial_balance:, metadata:, per_unit_cost_basis:, status:)
67
+ # @!attribute credit_allocation
68
+ # The credit allocation that funded a block. Extends the allocation resource
69
+ # serialized on prices with the catalog-item attribution of the funding price.
70
+ #
71
+ # @return [Orb::Models::Customers::CreditListResponse::CreditAllocation, nil]
72
+ optional :credit_allocation,
73
+ -> { Orb::Models::Customers::CreditListResponse::CreditAllocation },
74
+ nil?: true
75
+
76
+ # @!attribute credit_commitment
77
+ # The subscription commitment whose true-up rolled forward into this credit block.
78
+ # Present only when `credit_block_source` is `commitment`.
79
+ #
80
+ # @return [Orb::Models::Customers::CreditListResponse::CreditCommitment, nil]
81
+ optional :credit_commitment,
82
+ -> { Orb::Models::Customers::CreditListResponse::CreditCommitment },
83
+ nil?: true
84
+
85
+ # @!method initialize(id:, balance:, credit_block_source:, effective_date:, expiry_date:, filters:, maximum_initial_balance:, metadata:, per_unit_cost_basis:, status:, credit_allocation: nil, credit_commitment: nil)
58
86
  # Some parameter documentations has been truncated, see
59
87
  # {Orb::Models::Customers::CreditListResponse} for more details.
60
88
  #
@@ -62,6 +90,8 @@ module Orb
62
90
  #
63
91
  # @param balance [Float]
64
92
  #
93
+ # @param credit_block_source [Symbol, Orb::Models::Customers::CreditListResponse::CreditBlockSource] How this credit block was created: `allocation` (a subscription's recurring cred
94
+ #
65
95
  # @param effective_date [Time, nil]
66
96
  #
67
97
  # @param expiry_date [Time, nil]
@@ -75,6 +105,29 @@ module Orb
75
105
  # @param per_unit_cost_basis [String, nil]
76
106
  #
77
107
  # @param status [Symbol, Orb::Models::Customers::CreditListResponse::Status]
108
+ #
109
+ # @param credit_allocation [Orb::Models::Customers::CreditListResponse::CreditAllocation, nil] The credit allocation that funded a block. Extends the allocation resource
110
+ #
111
+ # @param credit_commitment [Orb::Models::Customers::CreditListResponse::CreditCommitment, nil] The subscription commitment whose true-up rolled forward into this credit block.
112
+
113
+ # How this credit block was created: `allocation` (a subscription's recurring
114
+ # credit allocation), `top_up` (an automatic balance-threshold top-up),
115
+ # `commitment` (a subscription commitment true-up rolled forward as credit), or
116
+ # `manual` (a manual credit ledger increment, including credits voided or expired
117
+ # off another block).
118
+ #
119
+ # @see Orb::Models::Customers::CreditListResponse#credit_block_source
120
+ module CreditBlockSource
121
+ extend Orb::Internal::Type::Enum
122
+
123
+ ALLOCATION = :allocation
124
+ TOP_UP = :top_up
125
+ COMMITMENT = :commitment
126
+ MANUAL = :manual
127
+
128
+ # @!method self.values
129
+ # @return [Array<Symbol>]
130
+ end
78
131
 
79
132
  class Filter < Orb::Internal::Type::BaseModel
80
133
  # @!attribute field
@@ -140,6 +193,141 @@ module Orb
140
193
  # @!method self.values
141
194
  # @return [Array<Symbol>]
142
195
  end
196
+
197
+ # @see Orb::Models::Customers::CreditListResponse#credit_allocation
198
+ class CreditAllocation < Orb::Internal::Type::BaseModel
199
+ # @!attribute allows_rollover
200
+ #
201
+ # @return [Boolean]
202
+ required :allows_rollover, Orb::Internal::Type::Boolean
203
+
204
+ # @!attribute currency
205
+ #
206
+ # @return [String]
207
+ required :currency, String
208
+
209
+ # @!attribute custom_expiration
210
+ #
211
+ # @return [Orb::Models::CustomExpiration, nil]
212
+ required :custom_expiration, -> { Orb::CustomExpiration }, nil?: true
213
+
214
+ # @!attribute item_id
215
+ # The ID of the catalog item this block was allocated from, derived from the
216
+ # allocation's price.
217
+ #
218
+ # @return [String]
219
+ required :item_id, String
220
+
221
+ # @!attribute filters
222
+ #
223
+ # @return [Array<Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter>, nil]
224
+ optional :filters,
225
+ -> { Orb::Internal::Type::ArrayOf[Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter] }
226
+
227
+ # @!attribute license_type_id
228
+ #
229
+ # @return [String, nil]
230
+ optional :license_type_id, String, nil?: true
231
+
232
+ # @!method initialize(allows_rollover:, currency:, custom_expiration:, item_id:, filters: nil, license_type_id: nil)
233
+ # Some parameter documentations has been truncated, see
234
+ # {Orb::Models::Customers::CreditListResponse::CreditAllocation} for more details.
235
+ #
236
+ # The credit allocation that funded a block. Extends the allocation resource
237
+ # serialized on prices with the catalog-item attribution of the funding price.
238
+ #
239
+ # @param allows_rollover [Boolean]
240
+ #
241
+ # @param currency [String]
242
+ #
243
+ # @param custom_expiration [Orb::Models::CustomExpiration, nil]
244
+ #
245
+ # @param item_id [String] The ID of the catalog item this block was allocated from, derived from the alloc
246
+ #
247
+ # @param filters [Array<Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter>]
248
+ #
249
+ # @param license_type_id [String, nil]
250
+
251
+ class Filter < Orb::Internal::Type::BaseModel
252
+ # @!attribute field
253
+ # The property of the price to filter on.
254
+ #
255
+ # @return [Symbol, Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter::Field]
256
+ required :field, enum: -> { Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter::Field }
257
+
258
+ # @!attribute operator
259
+ # Should prices that match the filter be included or excluded.
260
+ #
261
+ # @return [Symbol, Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter::Operator]
262
+ required :operator,
263
+ enum: -> { Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter::Operator }
264
+
265
+ # @!attribute values
266
+ # The IDs or values that match this filter.
267
+ #
268
+ # @return [Array<String>]
269
+ required :values, Orb::Internal::Type::ArrayOf[String]
270
+
271
+ # @!method initialize(field:, operator:, values:)
272
+ # @param field [Symbol, Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter::Field] The property of the price to filter on.
273
+ #
274
+ # @param operator [Symbol, Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter::Operator] Should prices that match the filter be included or excluded.
275
+ #
276
+ # @param values [Array<String>] The IDs or values that match this filter.
277
+
278
+ # The property of the price to filter on.
279
+ #
280
+ # @see Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter#field
281
+ module Field
282
+ extend Orb::Internal::Type::Enum
283
+
284
+ PRICE_ID = :price_id
285
+ ITEM_ID = :item_id
286
+ PRICE_TYPE = :price_type
287
+ CURRENCY = :currency
288
+ PRICING_UNIT_ID = :pricing_unit_id
289
+
290
+ # @!method self.values
291
+ # @return [Array<Symbol>]
292
+ end
293
+
294
+ # Should prices that match the filter be included or excluded.
295
+ #
296
+ # @see Orb::Models::Customers::CreditListResponse::CreditAllocation::Filter#operator
297
+ module Operator
298
+ extend Orb::Internal::Type::Enum
299
+
300
+ INCLUDES = :includes
301
+ EXCLUDES = :excludes
302
+
303
+ # @!method self.values
304
+ # @return [Array<Symbol>]
305
+ end
306
+ end
307
+ end
308
+
309
+ # @see Orb::Models::Customers::CreditListResponse#credit_commitment
310
+ class CreditCommitment < Orb::Internal::Type::BaseModel
311
+ # @!attribute id
312
+ # The ID of the subscription commitment this block was rolled forward from.
313
+ #
314
+ # @return [String]
315
+ required :id, String
316
+
317
+ # @!attribute subscription_id
318
+ # The subscription the commitment belongs to.
319
+ #
320
+ # @return [String, nil]
321
+ optional :subscription_id, String, nil?: true
322
+
323
+ # @!method initialize(id:, subscription_id: nil)
324
+ # The subscription commitment whose true-up rolled forward into this credit block.
325
+ # Present only when `credit_block_source` is `commitment`.
326
+ #
327
+ # @param id [String] The ID of the subscription commitment this block was rolled forward from.
328
+ #
329
+ # @param subscription_id [String, nil] The subscription the commitment belongs to.
330
+ end
143
331
  end
144
332
  end
145
333
  end
@@ -388,9 +388,9 @@ module Orb
388
388
  required :entry_type, const: :expiration_change
389
389
 
390
390
  # @!attribute target_expiry_date
391
- # A future date (specified in YYYY-MM-DD format) used for expiration change,
392
- # denoting when credits transferred (as part of a partial block expiration) should
393
- # expire.
391
+ # A date (specified in YYYY-MM-DD format) used for expiration change, denoting
392
+ # when credits transferred (as part of a partial block expiration) should expire.
393
+ # This date must be on or after the effective date of the credit block.
394
394
  #
395
395
  # @return [Date]
396
396
  required :target_expiry_date, Date
@@ -443,7 +443,7 @@ module Orb
443
443
  # {Orb::Models::Customers::Credits::LedgerCreateEntryByExternalIDParams::Body::ExpirationChange}
444
444
  # for more details.
445
445
  #
446
- # @param target_expiry_date [Date] A future date (specified in YYYY-MM-DD format) used for expiration change, denot
446
+ # @param target_expiry_date [Date] A date (specified in YYYY-MM-DD format) used for expiration change, denoting whe
447
447
  #
448
448
  # @param amount [Float, nil] The number of credits to effect. Note that this is required for increment, decre
449
449
  #
@@ -388,9 +388,9 @@ module Orb
388
388
  required :entry_type, const: :expiration_change
389
389
 
390
390
  # @!attribute target_expiry_date
391
- # A future date (specified in YYYY-MM-DD format) used for expiration change,
392
- # denoting when credits transferred (as part of a partial block expiration) should
393
- # expire.
391
+ # A date (specified in YYYY-MM-DD format) used for expiration change, denoting
392
+ # when credits transferred (as part of a partial block expiration) should expire.
393
+ # This date must be on or after the effective date of the credit block.
394
394
  #
395
395
  # @return [Date]
396
396
  required :target_expiry_date, Date
@@ -443,7 +443,7 @@ module Orb
443
443
  # {Orb::Models::Customers::Credits::LedgerCreateEntryParams::Body::ExpirationChange}
444
444
  # for more details.
445
445
  #
446
- # @param target_expiry_date [Date] A future date (specified in YYYY-MM-DD format) used for expiration change, denot
446
+ # @param target_expiry_date [Date] A date (specified in YYYY-MM-DD format) used for expiration change, denoting whe
447
447
  #
448
448
  # @param amount [Float, nil] The number of credits to effect. Note that this is required for increment, decre
449
449
  #
@@ -49,7 +49,7 @@ module Orb
49
49
  # {Orb::Models::DimensionalPriceGroup} for more details.
50
50
  #
51
51
  # A dimensional price group is used to partition the result of a billable metric
52
- # by a set of dimensions. Prices in a price group must specify the parition used
52
+ # by a set of dimensions. Prices in a price group must specify the partition used
53
53
  # to derive their usage.
54
54
  #
55
55
  # @param id [String]