metronome-sdk 0.1.0.pre.alpha.3 → 0.1.0.pre.alpha.4

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 (403) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +40 -0
  3. data/README.md +1 -1
  4. data/lib/metronome_sdk/errors.rb +22 -0
  5. data/lib/metronome_sdk/internal/transport/base_client.rb +10 -2
  6. data/lib/metronome_sdk/internal/type/array_of.rb +6 -1
  7. data/lib/metronome_sdk/internal/type/base_model.rb +82 -26
  8. data/lib/metronome_sdk/internal/type/boolean.rb +7 -1
  9. data/lib/metronome_sdk/internal/type/converter.rb +42 -34
  10. data/lib/metronome_sdk/internal/type/enum.rb +16 -5
  11. data/lib/metronome_sdk/internal/type/file_input.rb +6 -1
  12. data/lib/metronome_sdk/internal/type/hash_of.rb +6 -1
  13. data/lib/metronome_sdk/internal/type/union.rb +17 -9
  14. data/lib/metronome_sdk/internal/type/unknown.rb +7 -1
  15. data/lib/metronome_sdk/internal/util.rb +8 -9
  16. data/lib/metronome_sdk/models/base_usage_filter.rb +27 -0
  17. data/lib/metronome_sdk/models/commit.rb +1010 -0
  18. data/lib/metronome_sdk/models/contract_without_amendments.rb +1803 -0
  19. data/lib/metronome_sdk/models/credit.rb +634 -0
  20. data/lib/metronome_sdk/models/credit_type_data.rb +21 -0
  21. data/lib/metronome_sdk/models/discount.rb +68 -0
  22. data/lib/metronome_sdk/models/event_type_filter.rb +33 -0
  23. data/lib/metronome_sdk/models/id.rb +15 -0
  24. data/lib/metronome_sdk/models/override.rb +381 -0
  25. data/lib/metronome_sdk/models/pro_service.rb +73 -0
  26. data/lib/metronome_sdk/models/property_filter.rb +52 -0
  27. data/lib/metronome_sdk/models/rate.rb +101 -0
  28. data/lib/metronome_sdk/models/schedule_duration.rb +50 -0
  29. data/lib/metronome_sdk/models/schedule_point_in_time.rb +62 -0
  30. data/lib/metronome_sdk/models/scheduled_charge.rb +76 -0
  31. data/lib/metronome_sdk/models/tier.rb +21 -0
  32. data/lib/metronome_sdk/models/v1/alert_archive_response.rb +3 -14
  33. data/lib/metronome_sdk/models/v1/alert_create_params.rb +4 -1
  34. data/lib/metronome_sdk/models/v1/alert_create_response.rb +3 -14
  35. data/lib/metronome_sdk/models/v1/billable_metric_archive_params.rb +2 -8
  36. data/lib/metronome_sdk/models/v1/billable_metric_archive_response.rb +3 -14
  37. data/lib/metronome_sdk/models/v1/billable_metric_create_params.rb +6 -86
  38. data/lib/metronome_sdk/models/v1/billable_metric_create_response.rb +3 -14
  39. data/lib/metronome_sdk/models/v1/billable_metric_list_response.rb +6 -85
  40. data/lib/metronome_sdk/models/v1/billable_metric_retrieve_response.rb +8 -85
  41. data/lib/metronome_sdk/models/v1/contract_amend_params.rb +312 -35
  42. data/lib/metronome_sdk/models/v1/contract_amend_response.rb +3 -14
  43. data/lib/metronome_sdk/models/v1/contract_archive_response.rb +3 -14
  44. data/lib/metronome_sdk/models/v1/contract_create_historical_invoices_response.rb +3 -1276
  45. data/lib/metronome_sdk/models/v1/contract_create_params.rb +550 -102
  46. data/lib/metronome_sdk/models/v1/contract_create_response.rb +3 -14
  47. data/lib/metronome_sdk/models/v1/contract_list_balances_response.rb +5 -1645
  48. data/lib/metronome_sdk/models/v1/contract_list_response.rb +253 -10692
  49. data/lib/metronome_sdk/models/v1/contract_retrieve_rate_schedule_response.rb +9 -295
  50. data/lib/metronome_sdk/models/v1/contract_retrieve_response.rb +254 -10721
  51. data/lib/metronome_sdk/models/v1/contract_schedule_pro_services_invoice_response.rb +3 -1276
  52. data/lib/metronome_sdk/models/v1/contract_update_end_date_response.rb +3 -14
  53. data/lib/metronome_sdk/models/v1/contracts/product_archive_response.rb +3 -14
  54. data/lib/metronome_sdk/models/v1/contracts/product_create_params.rb +6 -97
  55. data/lib/metronome_sdk/models/v1/contracts/product_create_response.rb +3 -14
  56. data/lib/metronome_sdk/models/v1/contracts/product_list_item_state.rb +148 -0
  57. data/lib/metronome_sdk/models/v1/contracts/product_list_response.rb +12 -561
  58. data/lib/metronome_sdk/models/v1/contracts/product_retrieve_params.rb +2 -8
  59. data/lib/metronome_sdk/models/v1/contracts/product_retrieve_response.rb +14 -559
  60. data/lib/metronome_sdk/models/v1/contracts/product_update_params.rb +6 -97
  61. data/lib/metronome_sdk/models/v1/contracts/product_update_response.rb +3 -14
  62. data/lib/metronome_sdk/models/v1/contracts/quantity_conversion.rb +57 -0
  63. data/lib/metronome_sdk/models/v1/contracts/quantity_rounding.rb +45 -0
  64. data/lib/metronome_sdk/models/v1/contracts/rate_card_archive_params.rb +2 -8
  65. data/lib/metronome_sdk/models/v1/contracts/rate_card_archive_response.rb +3 -14
  66. data/lib/metronome_sdk/models/v1/contracts/rate_card_create_response.rb +3 -14
  67. data/lib/metronome_sdk/models/v1/contracts/rate_card_list_response.rb +6 -42
  68. data/lib/metronome_sdk/models/v1/contracts/rate_card_retrieve_params.rb +2 -8
  69. data/lib/metronome_sdk/models/v1/contracts/rate_card_retrieve_rate_schedule_response.rb +6 -159
  70. data/lib/metronome_sdk/models/v1/contracts/rate_card_retrieve_response.rb +6 -42
  71. data/lib/metronome_sdk/models/v1/contracts/rate_card_update_response.rb +3 -14
  72. data/lib/metronome_sdk/models/v1/contracts/rate_cards/product_order_set_response.rb +3 -14
  73. data/lib/metronome_sdk/models/v1/contracts/rate_cards/product_order_update_response.rb +3 -14
  74. data/lib/metronome_sdk/models/v1/contracts/rate_cards/rate_add_many_params.rb +6 -44
  75. data/lib/metronome_sdk/models/v1/contracts/rate_cards/rate_add_many_response.rb +3 -16
  76. data/lib/metronome_sdk/models/v1/contracts/rate_cards/rate_add_params.rb +6 -44
  77. data/lib/metronome_sdk/models/v1/contracts/rate_cards/rate_add_response.rb +9 -61
  78. data/lib/metronome_sdk/models/v1/contracts/rate_cards/rate_list_response.rb +6 -158
  79. data/lib/metronome_sdk/models/v1/credit_grant_create_params.rb +5 -77
  80. data/lib/metronome_sdk/models/v1/credit_grant_create_response.rb +3 -14
  81. data/lib/metronome_sdk/models/v1/credit_grant_edit_response.rb +3 -14
  82. data/lib/metronome_sdk/models/v1/credit_grant_list_entries_params.rb +20 -1
  83. data/lib/metronome_sdk/models/v1/credit_grant_list_entries_response.rb +11 -153
  84. data/lib/metronome_sdk/models/v1/credit_grant_list_response.rb +14 -175
  85. data/lib/metronome_sdk/models/v1/credit_grant_void_response.rb +3 -14
  86. data/lib/metronome_sdk/models/v1/credit_ledger_entry.rb +69 -0
  87. data/lib/metronome_sdk/models/v1/customer.rb +53 -0
  88. data/lib/metronome_sdk/models/v1/customer_archive_params.rb +2 -8
  89. data/lib/metronome_sdk/models/v1/customer_archive_response.rb +3 -14
  90. data/lib/metronome_sdk/models/v1/customer_create_response.rb +3 -50
  91. data/lib/metronome_sdk/models/v1/{customer_list_response.rb → customer_detail.rb} +14 -15
  92. data/lib/metronome_sdk/models/v1/customer_list_billable_metrics_response.rb +6 -86
  93. data/lib/metronome_sdk/models/v1/customer_preview_events_params.rb +115 -0
  94. data/lib/metronome_sdk/models/v1/customer_preview_events_response.rb +18 -0
  95. data/lib/metronome_sdk/models/v1/customer_retrieve_response.rb +3 -126
  96. data/lib/metronome_sdk/models/v1/customer_set_name_response.rb +3 -50
  97. data/lib/metronome_sdk/models/v1/customers/alert_list_response.rb +5 -276
  98. data/lib/metronome_sdk/models/v1/customers/alert_retrieve_response.rb +3 -279
  99. data/lib/metronome_sdk/models/v1/customers/billing_config_retrieve_response.rb +9 -1
  100. data/lib/metronome_sdk/models/v1/customers/commit_create_params.rb +8 -6
  101. data/lib/metronome_sdk/models/v1/customers/commit_create_response.rb +3 -14
  102. data/lib/metronome_sdk/models/v1/customers/commit_list_response.rb +3 -1047
  103. data/lib/metronome_sdk/models/v1/customers/commit_update_end_date_response.rb +3 -14
  104. data/lib/metronome_sdk/models/v1/customers/credit_create_response.rb +3 -14
  105. data/lib/metronome_sdk/models/v1/customers/credit_list_response.rb +3 -593
  106. data/lib/metronome_sdk/models/v1/customers/credit_update_end_date_response.rb +3 -14
  107. data/lib/metronome_sdk/models/v1/customers/customer_alert.rb +270 -0
  108. data/lib/metronome_sdk/models/v1/customers/{invoice_list_response.rb → invoice.rb} +119 -303
  109. data/lib/metronome_sdk/models/v1/customers/invoice_list_breakdowns_response.rb +2 -1271
  110. data/lib/metronome_sdk/models/v1/customers/invoice_retrieve_response.rb +3 -1276
  111. data/lib/metronome_sdk/models/v1/customers/plan_add_response.rb +3 -14
  112. data/lib/metronome_sdk/models/v1/customers/plan_list_response.rb +3 -21
  113. data/lib/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rb +1 -0
  114. data/lib/metronome_sdk/models/v1/plan_detail.rb +200 -0
  115. data/lib/metronome_sdk/models/v1/plan_get_details_response.rb +3 -286
  116. data/lib/metronome_sdk/models/v1/plan_list_charges_response.rb +3 -20
  117. data/lib/metronome_sdk/models/v1/plan_list_customers_response.rb +3 -128
  118. data/lib/metronome_sdk/models/v1/rollover_amount_max_amount.rb +38 -0
  119. data/lib/metronome_sdk/models/v1/rollover_amount_max_percentage.rb +38 -0
  120. data/lib/metronome_sdk/models/v1/usage_search_params.rb +24 -0
  121. data/lib/metronome_sdk/models/v1/usage_search_response.rb +249 -0
  122. data/lib/metronome_sdk/models/v2/contract_edit_commit_params.rb +11 -8
  123. data/lib/metronome_sdk/models/v2/contract_edit_commit_response.rb +3 -14
  124. data/lib/metronome_sdk/models/v2/contract_edit_credit_params.rb +3 -2
  125. data/lib/metronome_sdk/models/v2/contract_edit_credit_response.rb +3 -14
  126. data/lib/metronome_sdk/models/v2/contract_edit_params.rb +885 -103
  127. data/lib/metronome_sdk/models/v2/contract_edit_response.rb +3 -14
  128. data/lib/metronome_sdk/models/v2/contract_get_edit_history_response.rb +351 -625
  129. data/lib/metronome_sdk/models/v2/contract_list_response.rb +590 -749
  130. data/lib/metronome_sdk/models/v2/contract_retrieve_response.rb +590 -751
  131. data/lib/metronome_sdk/models.rb +36 -4
  132. data/lib/metronome_sdk/resources/v1/alerts.rb +1 -1
  133. data/lib/metronome_sdk/resources/v1/billable_metrics.rb +2 -2
  134. data/lib/metronome_sdk/resources/v1/contracts/products.rb +4 -4
  135. data/lib/metronome_sdk/resources/v1/contracts/rate_cards/rates.rb +1 -1
  136. data/lib/metronome_sdk/resources/v1/contracts.rb +8 -4
  137. data/lib/metronome_sdk/resources/v1/credit_grants.rb +4 -2
  138. data/lib/metronome_sdk/resources/v1/customers/commits.rb +2 -2
  139. data/lib/metronome_sdk/resources/v1/customers/invoices.rb +2 -2
  140. data/lib/metronome_sdk/resources/v1/customers.rb +40 -2
  141. data/lib/metronome_sdk/resources/v1/usage.rb +25 -0
  142. data/lib/metronome_sdk/resources/v2/contracts.rb +11 -9
  143. data/lib/metronome_sdk/version.rb +1 -1
  144. data/lib/metronome_sdk.rb +31 -2
  145. data/rbi/metronome_sdk/errors.rbi +16 -0
  146. data/rbi/metronome_sdk/internal/type/boolean.rbi +2 -0
  147. data/rbi/metronome_sdk/internal/type/converter.rbi +15 -15
  148. data/rbi/metronome_sdk/internal/type/union.rbi +5 -0
  149. data/rbi/metronome_sdk/internal/type/unknown.rbi +2 -0
  150. data/rbi/metronome_sdk/internal/util.rbi +2 -0
  151. data/rbi/metronome_sdk/models/base_usage_filter.rbi +46 -0
  152. data/rbi/metronome_sdk/models/commit.rbi +1962 -0
  153. data/rbi/metronome_sdk/models/contract_without_amendments.rbi +3676 -0
  154. data/rbi/metronome_sdk/models/credit.rbi +1230 -0
  155. data/rbi/metronome_sdk/models/credit_type_data.rbi +26 -0
  156. data/rbi/metronome_sdk/models/discount.rbi +106 -0
  157. data/rbi/metronome_sdk/models/event_type_filter.rbi +57 -0
  158. data/rbi/metronome_sdk/models/id.rbi +23 -0
  159. data/rbi/metronome_sdk/models/override.rbi +675 -0
  160. data/rbi/metronome_sdk/models/pro_service.rbi +98 -0
  161. data/rbi/metronome_sdk/models/property_filter.rbi +88 -0
  162. data/rbi/metronome_sdk/models/rate.rbi +155 -0
  163. data/rbi/metronome_sdk/models/schedule_duration.rbi +89 -0
  164. data/rbi/metronome_sdk/models/schedule_point_in_time.rbi +121 -0
  165. data/rbi/metronome_sdk/models/scheduled_charge.rbi +119 -0
  166. data/rbi/metronome_sdk/models/tier.rbi +29 -0
  167. data/rbi/metronome_sdk/models/v1/alert_archive_response.rbi +4 -37
  168. data/rbi/metronome_sdk/models/v1/alert_create_params.rbi +6 -0
  169. data/rbi/metronome_sdk/models/v1/alert_create_response.rbi +4 -37
  170. data/rbi/metronome_sdk/models/v1/billable_metric_archive_params.rbi +6 -12
  171. data/rbi/metronome_sdk/models/v1/billable_metric_archive_response.rbi +4 -44
  172. data/rbi/metronome_sdk/models/v1/billable_metric_create_params.rbi +8 -177
  173. data/rbi/metronome_sdk/models/v1/billable_metric_create_response.rbi +4 -43
  174. data/rbi/metronome_sdk/models/v1/billable_metric_list_response.rbi +8 -177
  175. data/rbi/metronome_sdk/models/v1/billable_metric_retrieve_response.rbi +8 -175
  176. data/rbi/metronome_sdk/models/v1/contract_amend_params.rbi +712 -68
  177. data/rbi/metronome_sdk/models/v1/contract_amend_response.rbi +4 -37
  178. data/rbi/metronome_sdk/models/v1/contract_archive_response.rbi +4 -39
  179. data/rbi/metronome_sdk/models/v1/contract_create_historical_invoices_response.rbi +3 -2595
  180. data/rbi/metronome_sdk/models/v1/contract_create_params.rbi +1100 -172
  181. data/rbi/metronome_sdk/models/v1/contract_create_response.rbi +4 -37
  182. data/rbi/metronome_sdk/models/v1/contract_list_balances_response.rbi +3 -3366
  183. data/rbi/metronome_sdk/models/v1/contract_list_response.rbi +375 -22523
  184. data/rbi/metronome_sdk/models/v1/contract_retrieve_rate_schedule_response.rbi +12 -632
  185. data/rbi/metronome_sdk/models/v1/contract_retrieve_response.rbi +375 -22523
  186. data/rbi/metronome_sdk/models/v1/contract_schedule_pro_services_invoice_response.rbi +3 -2595
  187. data/rbi/metronome_sdk/models/v1/contract_update_end_date_response.rbi +4 -44
  188. data/rbi/metronome_sdk/models/v1/contracts/product_archive_response.rbi +4 -44
  189. data/rbi/metronome_sdk/models/v1/contracts/product_create_params.rbi +8 -209
  190. data/rbi/metronome_sdk/models/v1/contracts/product_create_response.rbi +4 -44
  191. data/rbi/metronome_sdk/models/v1/contracts/product_list_item_state.rbi +237 -0
  192. data/rbi/metronome_sdk/models/v1/contracts/product_list_response.rbi +76 -1143
  193. data/rbi/metronome_sdk/models/v1/contracts/product_retrieve_params.rbi +3 -9
  194. data/rbi/metronome_sdk/models/v1/contracts/product_retrieve_response.rbi +76 -1137
  195. data/rbi/metronome_sdk/models/v1/contracts/product_update_params.rbi +8 -209
  196. data/rbi/metronome_sdk/models/v1/contracts/product_update_response.rbi +4 -44
  197. data/rbi/metronome_sdk/models/v1/contracts/quantity_conversion.rbi +111 -0
  198. data/rbi/metronome_sdk/models/v1/contracts/quantity_rounding.rbi +94 -0
  199. data/rbi/metronome_sdk/models/v1/contracts/rate_card_archive_params.rbi +3 -9
  200. data/rbi/metronome_sdk/models/v1/contracts/rate_card_archive_response.rbi +4 -44
  201. data/rbi/metronome_sdk/models/v1/contracts/rate_card_create_response.rbi +4 -44
  202. data/rbi/metronome_sdk/models/v1/contracts/rate_card_list_response.rbi +8 -74
  203. data/rbi/metronome_sdk/models/v1/contracts/rate_card_retrieve_params.rbi +3 -9
  204. data/rbi/metronome_sdk/models/v1/contracts/rate_card_retrieve_rate_schedule_response.rbi +8 -344
  205. data/rbi/metronome_sdk/models/v1/contracts/rate_card_retrieve_response.rbi +8 -74
  206. data/rbi/metronome_sdk/models/v1/contracts/rate_card_update_response.rbi +4 -44
  207. data/rbi/metronome_sdk/models/v1/contracts/rate_cards/product_order_set_response.rbi +4 -44
  208. data/rbi/metronome_sdk/models/v1/contracts/rate_cards/product_order_update_response.rbi +4 -44
  209. data/rbi/metronome_sdk/models/v1/contracts/rate_cards/rate_add_many_params.rbi +8 -108
  210. data/rbi/metronome_sdk/models/v1/contracts/rate_cards/rate_add_many_response.rbi +4 -45
  211. data/rbi/metronome_sdk/models/v1/contracts/rate_cards/rate_add_params.rbi +8 -108
  212. data/rbi/metronome_sdk/models/v1/contracts/rate_cards/rate_add_response.rbi +12 -149
  213. data/rbi/metronome_sdk/models/v1/contracts/rate_cards/rate_list_response.rbi +8 -344
  214. data/rbi/metronome_sdk/models/v1/credit_grant_create_params.rbi +8 -166
  215. data/rbi/metronome_sdk/models/v1/credit_grant_create_response.rbi +4 -41
  216. data/rbi/metronome_sdk/models/v1/credit_grant_edit_response.rbi +4 -39
  217. data/rbi/metronome_sdk/models/v1/credit_grant_list_entries_params.rbi +58 -0
  218. data/rbi/metronome_sdk/models/v1/credit_grant_list_entries_response.rbi +10 -231
  219. data/rbi/metronome_sdk/models/v1/credit_grant_list_response.rbi +14 -281
  220. data/rbi/metronome_sdk/models/v1/credit_grant_void_response.rbi +4 -39
  221. data/rbi/metronome_sdk/models/v1/credit_ledger_entry.rbi +90 -0
  222. data/rbi/metronome_sdk/models/v1/customer.rbi +74 -0
  223. data/rbi/metronome_sdk/models/v1/customer_archive_params.rbi +6 -12
  224. data/rbi/metronome_sdk/models/v1/customer_archive_response.rbi +4 -39
  225. data/rbi/metronome_sdk/models/v1/customer_create_response.rbi +6 -84
  226. data/rbi/metronome_sdk/models/v1/{customer_list_response.rbi → customer_detail.rbi} +19 -26
  227. data/rbi/metronome_sdk/models/v1/customer_list_billable_metrics_response.rbi +8 -177
  228. data/rbi/metronome_sdk/models/v1/customer_preview_events_params.rbi +214 -0
  229. data/rbi/metronome_sdk/models/v1/customer_preview_events_response.rbi +35 -0
  230. data/rbi/metronome_sdk/models/v1/customer_retrieve_response.rbi +6 -255
  231. data/rbi/metronome_sdk/models/v1/customer_set_name_response.rbi +6 -86
  232. data/rbi/metronome_sdk/models/v1/customers/alert_list_response.rbi +3 -623
  233. data/rbi/metronome_sdk/models/v1/customers/alert_retrieve_response.rbi +4 -622
  234. data/rbi/metronome_sdk/models/v1/customers/billing_config_retrieve_response.rbi +11 -0
  235. data/rbi/metronome_sdk/models/v1/customers/commit_create_params.rbi +12 -8
  236. data/rbi/metronome_sdk/models/v1/customers/commit_create_response.rbi +4 -44
  237. data/rbi/metronome_sdk/models/v1/customers/commit_list_response.rbi +3 -2164
  238. data/rbi/metronome_sdk/models/v1/customers/commit_update_end_date_response.rbi +4 -44
  239. data/rbi/metronome_sdk/models/v1/customers/credit_create_response.rbi +4 -44
  240. data/rbi/metronome_sdk/models/v1/customers/credit_list_response.rbi +3 -1224
  241. data/rbi/metronome_sdk/models/v1/customers/credit_update_end_date_response.rbi +4 -44
  242. data/rbi/metronome_sdk/models/v1/customers/customer_alert.rbi +572 -0
  243. data/rbi/metronome_sdk/models/v1/customers/{invoice_list_response.rbi → invoice.rbi} +182 -589
  244. data/rbi/metronome_sdk/models/v1/customers/invoice_list_breakdowns_response.rbi +4 -2561
  245. data/rbi/metronome_sdk/models/v1/customers/invoice_retrieve_response.rbi +6 -2612
  246. data/rbi/metronome_sdk/models/v1/customers/plan_add_response.rbi +4 -41
  247. data/rbi/metronome_sdk/models/v1/customers/plan_list_response.rbi +4 -39
  248. data/rbi/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rbi +5 -0
  249. data/rbi/metronome_sdk/models/v1/plan_detail.rbi +349 -0
  250. data/rbi/metronome_sdk/models/v1/plan_get_details_response.rbi +6 -560
  251. data/rbi/metronome_sdk/models/v1/plan_list_charges_response.rbi +4 -37
  252. data/rbi/metronome_sdk/models/v1/plan_list_customers_response.rbi +4 -248
  253. data/rbi/metronome_sdk/models/v1/rollover_amount_max_amount.rbi +79 -0
  254. data/rbi/metronome_sdk/models/v1/rollover_amount_max_percentage.rbi +80 -0
  255. data/rbi/metronome_sdk/models/v1/usage_search_params.rbi +48 -0
  256. data/rbi/metronome_sdk/models/v1/usage_search_response.rbi +438 -0
  257. data/rbi/metronome_sdk/models/v2/contract_edit_commit_params.rbi +23 -23
  258. data/rbi/metronome_sdk/models/v2/contract_edit_commit_response.rbi +4 -41
  259. data/rbi/metronome_sdk/models/v2/contract_edit_credit_params.rbi +11 -15
  260. data/rbi/metronome_sdk/models/v2/contract_edit_credit_response.rbi +4 -41
  261. data/rbi/metronome_sdk/models/v2/contract_edit_params.rbi +1859 -202
  262. data/rbi/metronome_sdk/models/v2/contract_edit_response.rbi +4 -37
  263. data/rbi/metronome_sdk/models/v2/contract_get_edit_history_response.rbi +700 -1447
  264. data/rbi/metronome_sdk/models/v2/contract_list_response.rbi +1204 -1472
  265. data/rbi/metronome_sdk/models/v2/contract_retrieve_response.rbi +1204 -1472
  266. data/rbi/metronome_sdk/models.rbi +32 -0
  267. data/rbi/metronome_sdk/resources/v1/alerts.rbi +3 -0
  268. data/rbi/metronome_sdk/resources/v1/billable_metrics.rbi +2 -6
  269. data/rbi/metronome_sdk/resources/v1/contracts/products.rbi +4 -4
  270. data/rbi/metronome_sdk/resources/v1/contracts/rate_cards/rates.rbi +1 -4
  271. data/rbi/metronome_sdk/resources/v1/contracts.rbi +10 -4
  272. data/rbi/metronome_sdk/resources/v1/credit_grants.rbi +4 -0
  273. data/rbi/metronome_sdk/resources/v1/customers/commits.rbi +6 -4
  274. data/rbi/metronome_sdk/resources/v1/customers/invoices.rbi +1 -1
  275. data/rbi/metronome_sdk/resources/v1/customers.rbi +34 -3
  276. data/rbi/metronome_sdk/resources/v1/usage.rbi +17 -0
  277. data/rbi/metronome_sdk/resources/v2/contracts.rbi +24 -14
  278. data/sig/metronome_sdk/errors.rbs +9 -0
  279. data/sig/metronome_sdk/internal/type/converter.rbs +7 -1
  280. data/sig/metronome_sdk/models/base_usage_filter.rbs +28 -0
  281. data/sig/metronome_sdk/models/commit.rbs +1020 -0
  282. data/sig/metronome_sdk/models/contract_without_amendments.rbs +1582 -0
  283. data/sig/metronome_sdk/models/credit.rbs +643 -0
  284. data/sig/metronome_sdk/models/credit_type_data.rbs +15 -0
  285. data/sig/metronome_sdk/models/discount.rbs +63 -0
  286. data/sig/metronome_sdk/models/event_type_filter.rbs +26 -0
  287. data/sig/metronome_sdk/models/id.rbs +13 -0
  288. data/sig/metronome_sdk/models/override.rbs +399 -0
  289. data/sig/metronome_sdk/models/pro_service.rbs +61 -0
  290. data/sig/metronome_sdk/models/property_filter.rbs +41 -0
  291. data/sig/metronome_sdk/models/rate.rbs +94 -0
  292. data/sig/metronome_sdk/models/schedule_duration.rbs +56 -0
  293. data/sig/metronome_sdk/models/schedule_point_in_time.rbs +75 -0
  294. data/sig/metronome_sdk/models/scheduled_charge.rbs +70 -0
  295. data/sig/metronome_sdk/models/tier.rbs +17 -0
  296. data/sig/metronome_sdk/models/v1/alert_archive_response.rbs +4 -19
  297. data/sig/metronome_sdk/models/v1/alert_create_response.rbs +4 -19
  298. data/sig/metronome_sdk/models/v1/billable_metric_archive_params.rbs +4 -12
  299. data/sig/metronome_sdk/models/v1/billable_metric_archive_response.rbs +4 -19
  300. data/sig/metronome_sdk/models/v1/billable_metric_create_params.rbs +12 -73
  301. data/sig/metronome_sdk/models/v1/billable_metric_create_response.rbs +4 -19
  302. data/sig/metronome_sdk/models/v1/billable_metric_list_response.rbs +12 -73
  303. data/sig/metronome_sdk/models/v1/billable_metric_retrieve_response.rbs +12 -73
  304. data/sig/metronome_sdk/models/v1/contract_amend_params.rbs +291 -24
  305. data/sig/metronome_sdk/models/v1/contract_amend_response.rbs +4 -19
  306. data/sig/metronome_sdk/models/v1/contract_archive_response.rbs +4 -19
  307. data/sig/metronome_sdk/models/v1/contract_create_historical_invoices_response.rbs +4 -1291
  308. data/sig/metronome_sdk/models/v1/contract_create_params.rbs +448 -84
  309. data/sig/metronome_sdk/models/v1/contract_create_response.rbs +4 -19
  310. data/sig/metronome_sdk/models/v1/contract_list_balances_response.rbs +1 -1642
  311. data/sig/metronome_sdk/models/v1/contract_list_response.rbs +188 -10437
  312. data/sig/metronome_sdk/models/v1/contract_retrieve_rate_schedule_response.rbs +15 -271
  313. data/sig/metronome_sdk/models/v1/contract_retrieve_response.rbs +188 -10437
  314. data/sig/metronome_sdk/models/v1/contract_schedule_pro_services_invoice_response.rbs +4 -1291
  315. data/sig/metronome_sdk/models/v1/contract_update_end_date_response.rbs +4 -19
  316. data/sig/metronome_sdk/models/v1/contracts/product_archive_response.rbs +4 -21
  317. data/sig/metronome_sdk/models/v1/contracts/product_create_params.rbs +8 -82
  318. data/sig/metronome_sdk/models/v1/contracts/product_create_response.rbs +4 -21
  319. data/sig/metronome_sdk/models/v1/contracts/product_list_item_state.rbs +121 -0
  320. data/sig/metronome_sdk/models/v1/contracts/product_list_response.rbs +16 -466
  321. data/sig/metronome_sdk/models/v1/contracts/product_retrieve_params.rbs +4 -12
  322. data/sig/metronome_sdk/models/v1/contracts/product_retrieve_response.rbs +16 -466
  323. data/sig/metronome_sdk/models/v1/contracts/product_update_params.rbs +8 -82
  324. data/sig/metronome_sdk/models/v1/contracts/product_update_response.rbs +4 -21
  325. data/sig/metronome_sdk/models/v1/contracts/quantity_conversion.rbs +47 -0
  326. data/sig/metronome_sdk/models/v1/contracts/quantity_rounding.rbs +41 -0
  327. data/sig/metronome_sdk/models/v1/contracts/rate_card_archive_params.rbs +4 -12
  328. data/sig/metronome_sdk/models/v1/contracts/rate_card_archive_response.rbs +4 -21
  329. data/sig/metronome_sdk/models/v1/contracts/rate_card_create_response.rbs +4 -21
  330. data/sig/metronome_sdk/models/v1/contracts/rate_card_list_response.rbs +10 -34
  331. data/sig/metronome_sdk/models/v1/contracts/rate_card_retrieve_params.rbs +4 -12
  332. data/sig/metronome_sdk/models/v1/contracts/rate_card_retrieve_rate_schedule_response.rbs +10 -144
  333. data/sig/metronome_sdk/models/v1/contracts/rate_card_retrieve_response.rbs +10 -34
  334. data/sig/metronome_sdk/models/v1/contracts/rate_card_update_response.rbs +4 -21
  335. data/sig/metronome_sdk/models/v1/contracts/rate_cards/product_order_set_response.rbs +4 -21
  336. data/sig/metronome_sdk/models/v1/contracts/rate_cards/product_order_update_response.rbs +4 -21
  337. data/sig/metronome_sdk/models/v1/contracts/rate_cards/rate_add_many_params.rbs +12 -40
  338. data/sig/metronome_sdk/models/v1/contracts/rate_cards/rate_add_many_response.rbs +4 -21
  339. data/sig/metronome_sdk/models/v1/contracts/rate_cards/rate_add_params.rbs +12 -40
  340. data/sig/metronome_sdk/models/v1/contracts/rate_cards/rate_add_response.rbs +18 -58
  341. data/sig/metronome_sdk/models/v1/contracts/rate_cards/rate_list_response.rbs +10 -144
  342. data/sig/metronome_sdk/models/v1/credit_grant_create_params.rbs +2 -66
  343. data/sig/metronome_sdk/models/v1/credit_grant_create_response.rbs +4 -19
  344. data/sig/metronome_sdk/models/v1/credit_grant_edit_response.rbs +4 -19
  345. data/sig/metronome_sdk/models/v1/credit_grant_list_entries_params.rbs +20 -0
  346. data/sig/metronome_sdk/models/v1/credit_grant_list_entries_response.rbs +12 -118
  347. data/sig/metronome_sdk/models/v1/credit_grant_list_response.rbs +16 -140
  348. data/sig/metronome_sdk/models/v1/credit_grant_void_response.rbs +4 -19
  349. data/sig/metronome_sdk/models/v1/credit_ledger_entry.rbs +52 -0
  350. data/sig/metronome_sdk/models/v1/customer.rbs +44 -0
  351. data/sig/metronome_sdk/models/v1/customer_archive_params.rbs +4 -12
  352. data/sig/metronome_sdk/models/v1/customer_archive_response.rbs +4 -19
  353. data/sig/metronome_sdk/models/v1/customer_create_response.rbs +4 -48
  354. data/sig/metronome_sdk/models/v1/{customer_list_response.rbs → customer_detail.rbs} +17 -17
  355. data/sig/metronome_sdk/models/v1/customer_list_billable_metrics_response.rbs +12 -73
  356. data/sig/metronome_sdk/models/v1/customer_preview_events_params.rbs +105 -0
  357. data/sig/metronome_sdk/models/v1/customer_preview_events_response.rbs +16 -0
  358. data/sig/metronome_sdk/models/v1/customer_retrieve_response.rbs +4 -112
  359. data/sig/metronome_sdk/models/v1/customer_set_name_response.rbs +4 -48
  360. data/sig/metronome_sdk/models/v1/customers/alert_list_response.rbs +4 -243
  361. data/sig/metronome_sdk/models/v1/customers/alert_retrieve_response.rbs +4 -247
  362. data/sig/metronome_sdk/models/v1/customers/billing_config_retrieve_response.rbs +7 -0
  363. data/sig/metronome_sdk/models/v1/customers/commit_create_response.rbs +4 -21
  364. data/sig/metronome_sdk/models/v1/customers/commit_list_response.rbs +4 -1057
  365. data/sig/metronome_sdk/models/v1/customers/commit_update_end_date_response.rbs +4 -21
  366. data/sig/metronome_sdk/models/v1/customers/credit_create_response.rbs +4 -21
  367. data/sig/metronome_sdk/models/v1/customers/credit_list_response.rbs +4 -596
  368. data/sig/metronome_sdk/models/v1/customers/credit_update_end_date_response.rbs +4 -21
  369. data/sig/metronome_sdk/models/v1/customers/customer_alert.rbs +234 -0
  370. data/sig/metronome_sdk/models/v1/customers/{invoice_list_response.rbs → invoice.rbs} +147 -305
  371. data/sig/metronome_sdk/models/v1/customers/invoice_list_breakdowns_response.rbs +8 -1278
  372. data/sig/metronome_sdk/models/v1/customers/invoice_retrieve_response.rbs +4 -1294
  373. data/sig/metronome_sdk/models/v1/customers/plan_add_response.rbs +4 -19
  374. data/sig/metronome_sdk/models/v1/customers/plan_list_response.rbs +4 -16
  375. data/sig/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rbs +2 -1
  376. data/sig/metronome_sdk/models/v1/plan_detail.rbs +203 -0
  377. data/sig/metronome_sdk/models/v1/plan_get_details_response.rbs +4 -267
  378. data/sig/metronome_sdk/models/v1/plan_list_charges_response.rbs +4 -16
  379. data/sig/metronome_sdk/models/v1/plan_list_customers_response.rbs +4 -108
  380. data/sig/metronome_sdk/models/v1/rollover_amount_max_amount.rbs +37 -0
  381. data/sig/metronome_sdk/models/v1/rollover_amount_max_percentage.rbs +37 -0
  382. data/sig/metronome_sdk/models/v1/usage_search_params.rbs +26 -0
  383. data/sig/metronome_sdk/models/v1/usage_search_response.rbs +230 -0
  384. data/sig/metronome_sdk/models/v2/contract_edit_commit_params.rbs +4 -8
  385. data/sig/metronome_sdk/models/v2/contract_edit_commit_response.rbs +4 -19
  386. data/sig/metronome_sdk/models/v2/contract_edit_credit_params.rbs +4 -8
  387. data/sig/metronome_sdk/models/v2/contract_edit_credit_response.rbs +4 -19
  388. data/sig/metronome_sdk/models/v2/contract_edit_params.rbs +743 -77
  389. data/sig/metronome_sdk/models/v2/contract_edit_response.rbs +4 -19
  390. data/sig/metronome_sdk/models/v2/contract_get_edit_history_response.rbs +274 -665
  391. data/sig/metronome_sdk/models/v2/contract_list_response.rbs +567 -759
  392. data/sig/metronome_sdk/models/v2/contract_retrieve_response.rbs +567 -759
  393. data/sig/metronome_sdk/models.rbs +32 -0
  394. data/sig/metronome_sdk/resources/v1/billable_metrics.rbs +2 -2
  395. data/sig/metronome_sdk/resources/v1/contracts/products.rbs +4 -4
  396. data/sig/metronome_sdk/resources/v1/contracts/rate_cards/rates.rbs +1 -1
  397. data/sig/metronome_sdk/resources/v1/contracts.rbs +3 -1
  398. data/sig/metronome_sdk/resources/v1/credit_grants.rbs +1 -0
  399. data/sig/metronome_sdk/resources/v1/customers/invoices.rbs +1 -1
  400. data/sig/metronome_sdk/resources/v1/customers.rbs +9 -1
  401. data/sig/metronome_sdk/resources/v1/usage.rbs +5 -0
  402. data/sig/metronome_sdk/resources/v2/contracts.rbs +3 -2
  403. metadata +95 -8
@@ -0,0 +1,1803 @@
1
+ # frozen_string_literal: true
2
+
3
+ module MetronomeSDK
4
+ module Models
5
+ class ContractWithoutAmendments < MetronomeSDK::Internal::Type::BaseModel
6
+ # @!attribute commits
7
+ #
8
+ # @return [Array<MetronomeSDK::Models::Commit>]
9
+ required :commits, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Commit] }
10
+
11
+ # @!attribute created_at
12
+ #
13
+ # @return [Time]
14
+ required :created_at, Time
15
+
16
+ # @!attribute created_by
17
+ #
18
+ # @return [String]
19
+ required :created_by, String
20
+
21
+ # @!attribute overrides
22
+ #
23
+ # @return [Array<MetronomeSDK::Models::Override>]
24
+ required :overrides, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Override] }
25
+
26
+ # @!attribute scheduled_charges
27
+ #
28
+ # @return [Array<MetronomeSDK::Models::ScheduledCharge>]
29
+ required :scheduled_charges, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ScheduledCharge] }
30
+
31
+ # @!attribute starting_at
32
+ #
33
+ # @return [Time]
34
+ required :starting_at, Time
35
+
36
+ # @!attribute transitions
37
+ #
38
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::Transition>]
39
+ required :transitions,
40
+ -> {
41
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::Transition]
42
+ }
43
+
44
+ # @!attribute usage_statement_schedule
45
+ #
46
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::UsageStatementSchedule]
47
+ required :usage_statement_schedule,
48
+ -> {
49
+ MetronomeSDK::ContractWithoutAmendments::UsageStatementSchedule
50
+ }
51
+
52
+ # @!attribute credits
53
+ #
54
+ # @return [Array<MetronomeSDK::Models::Credit>, nil]
55
+ optional :credits, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Credit] }
56
+
57
+ # @!attribute discounts
58
+ # This field's availability is dependent on your client's configuration.
59
+ #
60
+ # @return [Array<MetronomeSDK::Models::Discount>, nil]
61
+ optional :discounts, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Discount] }
62
+
63
+ # @!attribute ending_before
64
+ #
65
+ # @return [Time, nil]
66
+ optional :ending_before, Time
67
+
68
+ # @!attribute hierarchy_configuration
69
+ # Either a **parent** configuration with a list of children or a **child**
70
+ # configuration with a single parent.
71
+ #
72
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ParentHierarchyConfiguration, MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration, nil]
73
+ optional :hierarchy_configuration,
74
+ union: -> { MetronomeSDK::ContractWithoutAmendments::HierarchyConfiguration }
75
+
76
+ # @!attribute name
77
+ #
78
+ # @return [String, nil]
79
+ optional :name, String
80
+
81
+ # @!attribute net_payment_terms_days
82
+ #
83
+ # @return [Float, nil]
84
+ optional :net_payment_terms_days, Float
85
+
86
+ # @!attribute netsuite_sales_order_id
87
+ # This field's availability is dependent on your client's configuration.
88
+ #
89
+ # @return [String, nil]
90
+ optional :netsuite_sales_order_id, String
91
+
92
+ # @!attribute prepaid_balance_threshold_configuration
93
+ #
94
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration, nil]
95
+ optional :prepaid_balance_threshold_configuration,
96
+ -> { MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration }
97
+
98
+ # @!attribute professional_services
99
+ # This field's availability is dependent on your client's configuration.
100
+ #
101
+ # @return [Array<MetronomeSDK::Models::ProService>, nil]
102
+ optional :professional_services, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ProService] }
103
+
104
+ # @!attribute rate_card_id
105
+ #
106
+ # @return [String, nil]
107
+ optional :rate_card_id, String
108
+
109
+ # @!attribute recurring_commits
110
+ #
111
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit>, nil]
112
+ optional :recurring_commits,
113
+ -> {
114
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::RecurringCommit]
115
+ }
116
+
117
+ # @!attribute recurring_credits
118
+ #
119
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit>, nil]
120
+ optional :recurring_credits,
121
+ -> {
122
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::RecurringCredit]
123
+ }
124
+
125
+ # @!attribute reseller_royalties
126
+ # This field's availability is dependent on your client's configuration.
127
+ #
128
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::ResellerRoyalty>, nil]
129
+ optional :reseller_royalties,
130
+ -> {
131
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::ResellerRoyalty]
132
+ }
133
+
134
+ # @!attribute salesforce_opportunity_id
135
+ # This field's availability is dependent on your client's configuration.
136
+ #
137
+ # @return [String, nil]
138
+ optional :salesforce_opportunity_id, String
139
+
140
+ # @!attribute scheduled_charges_on_usage_invoices
141
+ # Determines which scheduled and commit charges to consolidate onto the Contract's
142
+ # usage invoice. The charge's `timestamp` must match the usage invoice's
143
+ # `ending_before` date for consolidation to occur. This field cannot be modified
144
+ # after a Contract has been created. If this field is omitted, charges will appear
145
+ # on a separate invoice from usage charges.
146
+ #
147
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::ScheduledChargesOnUsageInvoices, nil]
148
+ optional :scheduled_charges_on_usage_invoices,
149
+ enum: -> { MetronomeSDK::ContractWithoutAmendments::ScheduledChargesOnUsageInvoices }
150
+
151
+ # @!attribute spend_threshold_configuration
152
+ #
153
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration, nil]
154
+ optional :spend_threshold_configuration,
155
+ -> { MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration }
156
+
157
+ # @!attribute total_contract_value
158
+ # This field's availability is dependent on your client's configuration.
159
+ #
160
+ # @return [Float, nil]
161
+ optional :total_contract_value, Float
162
+
163
+ # @!attribute usage_filter
164
+ #
165
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::UsageFilter, nil]
166
+ optional :usage_filter, -> { MetronomeSDK::ContractWithoutAmendments::UsageFilter }
167
+
168
+ # @!method initialize(commits:, created_at:, created_by:, overrides:, scheduled_charges:, starting_at:, transitions:, usage_statement_schedule:, credits: nil, discounts: nil, ending_before: nil, hierarchy_configuration: nil, name: nil, net_payment_terms_days: nil, netsuite_sales_order_id: nil, prepaid_balance_threshold_configuration: nil, professional_services: nil, rate_card_id: nil, recurring_commits: nil, recurring_credits: nil, reseller_royalties: nil, salesforce_opportunity_id: nil, scheduled_charges_on_usage_invoices: nil, spend_threshold_configuration: nil, total_contract_value: nil, usage_filter: nil)
169
+ # Some parameter documentations has been truncated, see
170
+ # {MetronomeSDK::Models::ContractWithoutAmendments} for more details.
171
+ #
172
+ # @param commits [Array<MetronomeSDK::Models::Commit>]
173
+ #
174
+ # @param created_at [Time]
175
+ #
176
+ # @param created_by [String]
177
+ #
178
+ # @param overrides [Array<MetronomeSDK::Models::Override>]
179
+ #
180
+ # @param scheduled_charges [Array<MetronomeSDK::Models::ScheduledCharge>]
181
+ #
182
+ # @param starting_at [Time]
183
+ #
184
+ # @param transitions [Array<MetronomeSDK::Models::ContractWithoutAmendments::Transition>]
185
+ #
186
+ # @param usage_statement_schedule [MetronomeSDK::Models::ContractWithoutAmendments::UsageStatementSchedule]
187
+ #
188
+ # @param credits [Array<MetronomeSDK::Models::Credit>]
189
+ #
190
+ # @param discounts [Array<MetronomeSDK::Models::Discount>] This field's availability is dependent on your client's configuration.
191
+ #
192
+ # @param ending_before [Time]
193
+ #
194
+ # @param hierarchy_configuration [MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ParentHierarchyConfiguration, MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration] Either a **parent** configuration with a list of children or a **child** configu
195
+ #
196
+ # @param name [String]
197
+ #
198
+ # @param net_payment_terms_days [Float]
199
+ #
200
+ # @param netsuite_sales_order_id [String] This field's availability is dependent on your client's configuration.
201
+ #
202
+ # @param prepaid_balance_threshold_configuration [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration]
203
+ #
204
+ # @param professional_services [Array<MetronomeSDK::Models::ProService>] This field's availability is dependent on your client's configuration.
205
+ #
206
+ # @param rate_card_id [String]
207
+ #
208
+ # @param recurring_commits [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit>]
209
+ #
210
+ # @param recurring_credits [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit>]
211
+ #
212
+ # @param reseller_royalties [Array<MetronomeSDK::Models::ContractWithoutAmendments::ResellerRoyalty>] This field's availability is dependent on your client's configuration.
213
+ #
214
+ # @param salesforce_opportunity_id [String] This field's availability is dependent on your client's configuration.
215
+ #
216
+ # @param scheduled_charges_on_usage_invoices [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::ScheduledChargesOnUsageInvoices] Determines which scheduled and commit charges to consolidate onto the Contract's
217
+ #
218
+ # @param spend_threshold_configuration [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration]
219
+ #
220
+ # @param total_contract_value [Float] This field's availability is dependent on your client's configuration.
221
+ #
222
+ # @param usage_filter [MetronomeSDK::Models::ContractWithoutAmendments::UsageFilter]
223
+
224
+ class Transition < MetronomeSDK::Internal::Type::BaseModel
225
+ # @!attribute from_contract_id
226
+ #
227
+ # @return [String]
228
+ required :from_contract_id, String
229
+
230
+ # @!attribute to_contract_id
231
+ #
232
+ # @return [String]
233
+ required :to_contract_id, String
234
+
235
+ # @!attribute type
236
+ #
237
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::Transition::Type]
238
+ required :type, enum: -> { MetronomeSDK::ContractWithoutAmendments::Transition::Type }
239
+
240
+ # @!method initialize(from_contract_id:, to_contract_id:, type:)
241
+ # @param from_contract_id [String]
242
+ # @param to_contract_id [String]
243
+ # @param type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::Transition::Type]
244
+
245
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::Transition#type
246
+ module Type
247
+ extend MetronomeSDK::Internal::Type::Enum
248
+
249
+ SUPERSEDE = :SUPERSEDE
250
+ RENEWAL = :RENEWAL
251
+
252
+ # @!method self.values
253
+ # @return [Array<Symbol>]
254
+ end
255
+ end
256
+
257
+ # @see MetronomeSDK::Models::ContractWithoutAmendments#usage_statement_schedule
258
+ class UsageStatementSchedule < MetronomeSDK::Internal::Type::BaseModel
259
+ # @!attribute billing_anchor_date
260
+ # Contract usage statements follow a selected cadence based on this date.
261
+ #
262
+ # @return [Time]
263
+ required :billing_anchor_date, Time
264
+
265
+ # @!attribute frequency
266
+ #
267
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::UsageStatementSchedule::Frequency]
268
+ required :frequency,
269
+ enum: -> { MetronomeSDK::ContractWithoutAmendments::UsageStatementSchedule::Frequency }
270
+
271
+ # @!method initialize(billing_anchor_date:, frequency:)
272
+ # @param billing_anchor_date [Time] Contract usage statements follow a selected cadence based on this date.
273
+ #
274
+ # @param frequency [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::UsageStatementSchedule::Frequency]
275
+
276
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::UsageStatementSchedule#frequency
277
+ module Frequency
278
+ extend MetronomeSDK::Internal::Type::Enum
279
+
280
+ MONTHLY = :MONTHLY
281
+ QUARTERLY = :QUARTERLY
282
+ ANNUAL = :ANNUAL
283
+ WEEKLY = :WEEKLY
284
+
285
+ # @!method self.values
286
+ # @return [Array<Symbol>]
287
+ end
288
+ end
289
+
290
+ # Either a **parent** configuration with a list of children or a **child**
291
+ # configuration with a single parent.
292
+ #
293
+ # @see MetronomeSDK::Models::ContractWithoutAmendments#hierarchy_configuration
294
+ module HierarchyConfiguration
295
+ extend MetronomeSDK::Internal::Type::Union
296
+
297
+ variant -> {
298
+ MetronomeSDK::ContractWithoutAmendments::HierarchyConfiguration::ParentHierarchyConfiguration
299
+ }
300
+
301
+ variant -> {
302
+ MetronomeSDK::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration
303
+ }
304
+
305
+ class ParentHierarchyConfiguration < MetronomeSDK::Internal::Type::BaseModel
306
+ # @!attribute children
307
+ # List of contracts that belong to this parent.
308
+ #
309
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ParentHierarchyConfiguration::Child>]
310
+ required :children,
311
+ -> {
312
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::HierarchyConfiguration::ParentHierarchyConfiguration::Child]
313
+ }
314
+
315
+ # @!method initialize(children:)
316
+ # @param children [Array<MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ParentHierarchyConfiguration::Child>] List of contracts that belong to this parent.
317
+
318
+ class Child < MetronomeSDK::Internal::Type::BaseModel
319
+ # @!attribute contract_id
320
+ #
321
+ # @return [String]
322
+ required :contract_id, String
323
+
324
+ # @!attribute customer_id
325
+ #
326
+ # @return [String]
327
+ required :customer_id, String
328
+
329
+ # @!method initialize(contract_id:, customer_id:)
330
+ # @param contract_id [String]
331
+ # @param customer_id [String]
332
+ end
333
+ end
334
+
335
+ class ChildHierarchyConfiguration < MetronomeSDK::Internal::Type::BaseModel
336
+ # @!attribute parent
337
+ # The single parent contract/customer for this child.
338
+ #
339
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration::Parent]
340
+ required :parent,
341
+ -> {
342
+ MetronomeSDK::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration::Parent
343
+ }
344
+
345
+ # @!method initialize(parent:)
346
+ # @param parent [MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration::Parent] The single parent contract/customer for this child.
347
+
348
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration#parent
349
+ class Parent < MetronomeSDK::Internal::Type::BaseModel
350
+ # @!attribute contract_id
351
+ #
352
+ # @return [String]
353
+ required :contract_id, String
354
+
355
+ # @!attribute customer_id
356
+ #
357
+ # @return [String]
358
+ required :customer_id, String
359
+
360
+ # @!method initialize(contract_id:, customer_id:)
361
+ # The single parent contract/customer for this child.
362
+ #
363
+ # @param contract_id [String]
364
+ # @param customer_id [String]
365
+ end
366
+ end
367
+
368
+ # @!method self.variants
369
+ # @return [Array(MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ParentHierarchyConfiguration, MetronomeSDK::Models::ContractWithoutAmendments::HierarchyConfiguration::ChildHierarchyConfiguration)]
370
+ end
371
+
372
+ # @see MetronomeSDK::Models::ContractWithoutAmendments#prepaid_balance_threshold_configuration
373
+ class PrepaidBalanceThresholdConfiguration < MetronomeSDK::Internal::Type::BaseModel
374
+ # @!attribute commit
375
+ #
376
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit]
377
+ required :commit,
378
+ -> { MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit }
379
+
380
+ # @!attribute is_enabled
381
+ # When set to false, the contract will not be evaluated against the
382
+ # threshold_amount. Toggling to true will result an immediate evaluation,
383
+ # regardless of prior state.
384
+ #
385
+ # @return [Boolean]
386
+ required :is_enabled, MetronomeSDK::Internal::Type::Boolean
387
+
388
+ # @!attribute payment_gate_config
389
+ #
390
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig]
391
+ required :payment_gate_config,
392
+ -> {
393
+ MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig
394
+ }
395
+
396
+ # @!attribute recharge_to_amount
397
+ # Specify the amount the balance should be recharged to.
398
+ #
399
+ # @return [Float]
400
+ required :recharge_to_amount, Float
401
+
402
+ # @!attribute threshold_amount
403
+ # Specify the threshold amount for the contract. Each time the contract's prepaid
404
+ # balance lowers to this amount, a threshold charge will be initiated.
405
+ #
406
+ # @return [Float]
407
+ required :threshold_amount, Float
408
+
409
+ # @!attribute custom_credit_type_id
410
+ # If provided, the threshold, recharge-to amount, and the resulting threshold
411
+ # commit amount will be in terms of this credit type instead of the fiat currency.
412
+ #
413
+ # @return [String, nil]
414
+ optional :custom_credit_type_id, String
415
+
416
+ # @!method initialize(commit:, is_enabled:, payment_gate_config:, recharge_to_amount:, threshold_amount:, custom_credit_type_id: nil)
417
+ # Some parameter documentations has been truncated, see
418
+ # {MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration}
419
+ # for more details.
420
+ #
421
+ # @param commit [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit]
422
+ #
423
+ # @param is_enabled [Boolean] When set to false, the contract will not be evaluated against the threshold_amou
424
+ #
425
+ # @param payment_gate_config [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig]
426
+ #
427
+ # @param recharge_to_amount [Float] Specify the amount the balance should be recharged to.
428
+ #
429
+ # @param threshold_amount [Float] Specify the threshold amount for the contract. Each time the contract's prepaid
430
+ #
431
+ # @param custom_credit_type_id [String] If provided, the threshold, recharge-to amount, and the resulting threshold comm
432
+
433
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration#commit
434
+ class Commit < MetronomeSDK::Internal::Type::BaseModel
435
+ # @!attribute product_id
436
+ # The commit product that will be used to generate the line item for commit
437
+ # payment.
438
+ #
439
+ # @return [String]
440
+ required :product_id, String
441
+
442
+ # @!attribute applicable_product_ids
443
+ # Which products the threshold commit applies to. If applicable_product_ids,
444
+ # applicable_product_tags or specifiers are not provided, the commit applies to
445
+ # all products.
446
+ #
447
+ # @return [Array<String>, nil]
448
+ optional :applicable_product_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
449
+
450
+ # @!attribute applicable_product_tags
451
+ # Which tags the threshold commit applies to. If applicable_product_ids,
452
+ # applicable_product_tags or specifiers are not provided, the commit applies to
453
+ # all products.
454
+ #
455
+ # @return [Array<String>, nil]
456
+ optional :applicable_product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]
457
+
458
+ # @!attribute description
459
+ #
460
+ # @return [String, nil]
461
+ optional :description, String
462
+
463
+ # @!attribute name
464
+ # Specify the name of the line item for the threshold charge. If left blank, it
465
+ # will default to the commit product name.
466
+ #
467
+ # @return [String, nil]
468
+ optional :name, String
469
+
470
+ # @!attribute specifiers
471
+ # List of filters that determine what kind of customer usage draws down a commit
472
+ # or credit. A customer's usage needs to meet the condition of at least one of the
473
+ # specifiers to contribute to a commit's or credit's drawdown. This field cannot
474
+ # be used together with `applicable_product_ids` or `applicable_product_tags`.
475
+ #
476
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit::Specifier>, nil]
477
+ optional :specifiers,
478
+ -> {
479
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit::Specifier]
480
+ }
481
+
482
+ # @!method initialize(product_id:, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, name: nil, specifiers: nil)
483
+ # Some parameter documentations has been truncated, see
484
+ # {MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit}
485
+ # for more details.
486
+ #
487
+ # @param product_id [String] The commit product that will be used to generate the line item for commit paymen
488
+ #
489
+ # @param applicable_product_ids [Array<String>] Which products the threshold commit applies to. If applicable_product_ids, appli
490
+ #
491
+ # @param applicable_product_tags [Array<String>] Which tags the threshold commit applies to. If applicable_product_ids, applicabl
492
+ #
493
+ # @param description [String]
494
+ #
495
+ # @param name [String] Specify the name of the line item for the threshold charge. If left blank, it wi
496
+ #
497
+ # @param specifiers [Array<MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit::Specifier>] List of filters that determine what kind of customer usage draws down a commit o
498
+
499
+ class Specifier < MetronomeSDK::Internal::Type::BaseModel
500
+ # @!attribute presentation_group_values
501
+ #
502
+ # @return [Hash{Symbol=>String}, nil]
503
+ optional :presentation_group_values, MetronomeSDK::Internal::Type::HashOf[String]
504
+
505
+ # @!attribute pricing_group_values
506
+ #
507
+ # @return [Hash{Symbol=>String}, nil]
508
+ optional :pricing_group_values, MetronomeSDK::Internal::Type::HashOf[String]
509
+
510
+ # @!attribute product_id
511
+ # If provided, the specifier will only apply to the product with the specified ID.
512
+ #
513
+ # @return [String, nil]
514
+ optional :product_id, String
515
+
516
+ # @!attribute product_tags
517
+ # If provided, the specifier will only apply to products with all the specified
518
+ # tags.
519
+ #
520
+ # @return [Array<String>, nil]
521
+ optional :product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]
522
+
523
+ # @!method initialize(presentation_group_values: nil, pricing_group_values: nil, product_id: nil, product_tags: nil)
524
+ # Some parameter documentations has been truncated, see
525
+ # {MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::Commit::Specifier}
526
+ # for more details.
527
+ #
528
+ # @param presentation_group_values [Hash{Symbol=>String}]
529
+ #
530
+ # @param pricing_group_values [Hash{Symbol=>String}]
531
+ #
532
+ # @param product_id [String] If provided, the specifier will only apply to the product with the specified ID.
533
+ #
534
+ # @param product_tags [Array<String>] If provided, the specifier will only apply to products with all the specified ta
535
+ end
536
+ end
537
+
538
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration#payment_gate_config
539
+ class PaymentGateConfig < MetronomeSDK::Internal::Type::BaseModel
540
+ # @!attribute payment_gate_type
541
+ # Gate access to the commit balance based on successful collection of payment.
542
+ # Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
543
+ # facilitate payment using your own payment integration. Select NONE if you do not
544
+ # wish to payment gate the commit balance.
545
+ #
546
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::PaymentGateType]
547
+ required :payment_gate_type,
548
+ enum: -> {
549
+ MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::PaymentGateType
550
+ }
551
+
552
+ # @!attribute precalculated_tax_config
553
+ # Only applicable if using PRECALCULATED as your tax type.
554
+ #
555
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig, nil]
556
+ optional :precalculated_tax_config,
557
+ -> {
558
+ MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig
559
+ }
560
+
561
+ # @!attribute stripe_config
562
+ # Only applicable if using STRIPE as your payment gate type.
563
+ #
564
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig, nil]
565
+ optional :stripe_config,
566
+ -> {
567
+ MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig
568
+ }
569
+
570
+ # @!attribute tax_type
571
+ # Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
572
+ # not wish Metronome to calculate tax on your behalf. Leaving this field blank
573
+ # will default to NONE.
574
+ #
575
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::TaxType, nil]
576
+ optional :tax_type,
577
+ enum: -> {
578
+ MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::TaxType
579
+ }
580
+
581
+ # @!method initialize(payment_gate_type:, precalculated_tax_config: nil, stripe_config: nil, tax_type: nil)
582
+ # Some parameter documentations has been truncated, see
583
+ # {MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig}
584
+ # for more details.
585
+ #
586
+ # @param payment_gate_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::PaymentGateType] Gate access to the commit balance based on successful collection of payment. Sel
587
+ #
588
+ # @param precalculated_tax_config [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig] Only applicable if using PRECALCULATED as your tax type.
589
+ #
590
+ # @param stripe_config [MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig] Only applicable if using STRIPE as your payment gate type.
591
+ #
592
+ # @param tax_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::TaxType] Stripe tax is only supported for Stripe payment gateway. Select NONE if you do n
593
+
594
+ # Gate access to the commit balance based on successful collection of payment.
595
+ # Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
596
+ # facilitate payment using your own payment integration. Select NONE if you do not
597
+ # wish to payment gate the commit balance.
598
+ #
599
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig#payment_gate_type
600
+ module PaymentGateType
601
+ extend MetronomeSDK::Internal::Type::Enum
602
+
603
+ NONE = :NONE
604
+ STRIPE = :STRIPE
605
+ EXTERNAL = :EXTERNAL
606
+
607
+ # @!method self.values
608
+ # @return [Array<Symbol>]
609
+ end
610
+
611
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig#precalculated_tax_config
612
+ class PrecalculatedTaxConfig < MetronomeSDK::Internal::Type::BaseModel
613
+ # @!attribute tax_amount
614
+ # Amount of tax to be applied. This should be in the same currency and
615
+ # denomination as the commit's invoice schedule
616
+ #
617
+ # @return [Float]
618
+ required :tax_amount, Float
619
+
620
+ # @!attribute tax_name
621
+ # Name of the tax to be applied. This may be used in an invoice line item
622
+ # description.
623
+ #
624
+ # @return [String, nil]
625
+ optional :tax_name, String
626
+
627
+ # @!method initialize(tax_amount:, tax_name: nil)
628
+ # Some parameter documentations has been truncated, see
629
+ # {MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig}
630
+ # for more details.
631
+ #
632
+ # Only applicable if using PRECALCULATED as your tax type.
633
+ #
634
+ # @param tax_amount [Float] Amount of tax to be applied. This should be in the same currency and denominatio
635
+ #
636
+ # @param tax_name [String] Name of the tax to be applied. This may be used in an invoice line item descript
637
+ end
638
+
639
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig#stripe_config
640
+ class StripeConfig < MetronomeSDK::Internal::Type::BaseModel
641
+ # @!attribute payment_type
642
+ # If left blank, will default to INVOICE
643
+ #
644
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig::PaymentType]
645
+ required :payment_type,
646
+ enum: -> {
647
+ MetronomeSDK::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig::PaymentType
648
+ }
649
+
650
+ # @!attribute invoice_metadata
651
+ # Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
652
+ # your payment type.
653
+ #
654
+ # @return [Hash{Symbol=>String}, nil]
655
+ optional :invoice_metadata, MetronomeSDK::Internal::Type::HashOf[String]
656
+
657
+ # @!method initialize(payment_type:, invoice_metadata: nil)
658
+ # Some parameter documentations has been truncated, see
659
+ # {MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig}
660
+ # for more details.
661
+ #
662
+ # Only applicable if using STRIPE as your payment gate type.
663
+ #
664
+ # @param payment_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig::PaymentType] If left blank, will default to INVOICE
665
+ #
666
+ # @param invoice_metadata [Hash{Symbol=>String}] Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
667
+
668
+ # If left blank, will default to INVOICE
669
+ #
670
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig::StripeConfig#payment_type
671
+ module PaymentType
672
+ extend MetronomeSDK::Internal::Type::Enum
673
+
674
+ INVOICE = :INVOICE
675
+ PAYMENT_INTENT = :PAYMENT_INTENT
676
+
677
+ # @!method self.values
678
+ # @return [Array<Symbol>]
679
+ end
680
+ end
681
+
682
+ # Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
683
+ # not wish Metronome to calculate tax on your behalf. Leaving this field blank
684
+ # will default to NONE.
685
+ #
686
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::PrepaidBalanceThresholdConfiguration::PaymentGateConfig#tax_type
687
+ module TaxType
688
+ extend MetronomeSDK::Internal::Type::Enum
689
+
690
+ NONE = :NONE
691
+ STRIPE = :STRIPE
692
+ ANROK = :ANROK
693
+ PRECALCULATED = :PRECALCULATED
694
+
695
+ # @!method self.values
696
+ # @return [Array<Symbol>]
697
+ end
698
+ end
699
+ end
700
+
701
+ class RecurringCommit < MetronomeSDK::Internal::Type::BaseModel
702
+ # @!attribute id
703
+ #
704
+ # @return [String]
705
+ required :id, String
706
+
707
+ # @!attribute access_amount
708
+ # The amount of commit to grant.
709
+ #
710
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::AccessAmount]
711
+ required :access_amount, -> { MetronomeSDK::ContractWithoutAmendments::RecurringCommit::AccessAmount }
712
+
713
+ # @!attribute commit_duration
714
+ # The amount of time the created commits will be valid for
715
+ #
716
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::CommitDuration]
717
+ required :commit_duration,
718
+ -> {
719
+ MetronomeSDK::ContractWithoutAmendments::RecurringCommit::CommitDuration
720
+ }
721
+
722
+ # @!attribute priority
723
+ # Will be passed down to the individual commits
724
+ #
725
+ # @return [Float]
726
+ required :priority, Float
727
+
728
+ # @!attribute product
729
+ #
730
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Product]
731
+ required :product, -> { MetronomeSDK::ContractWithoutAmendments::RecurringCommit::Product }
732
+
733
+ # @!attribute rate_type
734
+ # Whether the created commits will use the commit rate or list rate
735
+ #
736
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::RateType]
737
+ required :rate_type, enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCommit::RateType }
738
+
739
+ # @!attribute starting_at
740
+ # Determines the start time for the first commit
741
+ #
742
+ # @return [Time]
743
+ required :starting_at, Time
744
+
745
+ # @!attribute applicable_product_ids
746
+ # Will be passed down to the individual commits
747
+ #
748
+ # @return [Array<String>, nil]
749
+ optional :applicable_product_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
750
+
751
+ # @!attribute applicable_product_tags
752
+ # Will be passed down to the individual commits
753
+ #
754
+ # @return [Array<String>, nil]
755
+ optional :applicable_product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]
756
+
757
+ # @!attribute contract
758
+ #
759
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Contract, nil]
760
+ optional :contract, -> { MetronomeSDK::ContractWithoutAmendments::RecurringCommit::Contract }
761
+
762
+ # @!attribute description
763
+ # Will be passed down to the individual commits
764
+ #
765
+ # @return [String, nil]
766
+ optional :description, String
767
+
768
+ # @!attribute ending_before
769
+ # Determines when the contract will stop creating recurring commits. Optional
770
+ #
771
+ # @return [Time, nil]
772
+ optional :ending_before, Time
773
+
774
+ # @!attribute invoice_amount
775
+ # The amount the customer should be billed for the commit. Not required.
776
+ #
777
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::InvoiceAmount, nil]
778
+ optional :invoice_amount,
779
+ -> {
780
+ MetronomeSDK::ContractWithoutAmendments::RecurringCommit::InvoiceAmount
781
+ }
782
+
783
+ # @!attribute name
784
+ # Displayed on invoices. Will be passed through to the individual commits
785
+ #
786
+ # @return [String, nil]
787
+ optional :name, String
788
+
789
+ # @!attribute netsuite_sales_order_id
790
+ # Will be passed down to the individual commits
791
+ #
792
+ # @return [String, nil]
793
+ optional :netsuite_sales_order_id, String
794
+
795
+ # @!attribute proration
796
+ # Determines whether the first and last commit will be prorated. If not provided,
797
+ # the default is FIRST_AND_LAST (i.e. prorate both the first and last commits).
798
+ #
799
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Proration, nil]
800
+ optional :proration, enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCommit::Proration }
801
+
802
+ # @!attribute recurrence_frequency
803
+ # The frequency at which the recurring commits will be created. If not provided: -
804
+ # The commits will be created on the usage invoice frequency. If provided: - The
805
+ # period defined in the duration will correspond to this frequency. - Commits will
806
+ # be created aligned with the recurring commit's starting_at rather than the usage
807
+ # invoice dates.
808
+ #
809
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::RecurrenceFrequency, nil]
810
+ optional :recurrence_frequency,
811
+ enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCommit::RecurrenceFrequency }
812
+
813
+ # @!attribute rollover_fraction
814
+ # Will be passed down to the individual commits. This controls how much of an
815
+ # individual unexpired commit will roll over upon contract transition. Must be
816
+ # between 0 and 1.
817
+ #
818
+ # @return [Float, nil]
819
+ optional :rollover_fraction, Float
820
+
821
+ # @!attribute specifiers
822
+ # List of filters that determine what kind of customer usage draws down a commit
823
+ # or credit. A customer's usage needs to meet the condition of at least one of the
824
+ # specifiers to contribute to a commit's or credit's drawdown.
825
+ #
826
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Specifier>, nil]
827
+ optional :specifiers,
828
+ -> {
829
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::RecurringCommit::Specifier]
830
+ }
831
+
832
+ # @!method initialize(id:, access_amount:, commit_duration:, priority:, product:, rate_type:, starting_at:, applicable_product_ids: nil, applicable_product_tags: nil, contract: nil, description: nil, ending_before: nil, invoice_amount: nil, name: nil, netsuite_sales_order_id: nil, proration: nil, recurrence_frequency: nil, rollover_fraction: nil, specifiers: nil)
833
+ # Some parameter documentations has been truncated, see
834
+ # {MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit} for more
835
+ # details.
836
+ #
837
+ # @param id [String]
838
+ #
839
+ # @param access_amount [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::AccessAmount] The amount of commit to grant.
840
+ #
841
+ # @param commit_duration [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::CommitDuration] The amount of time the created commits will be valid for
842
+ #
843
+ # @param priority [Float] Will be passed down to the individual commits
844
+ #
845
+ # @param product [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Product]
846
+ #
847
+ # @param rate_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::RateType] Whether the created commits will use the commit rate or list rate
848
+ #
849
+ # @param starting_at [Time] Determines the start time for the first commit
850
+ #
851
+ # @param applicable_product_ids [Array<String>] Will be passed down to the individual commits
852
+ #
853
+ # @param applicable_product_tags [Array<String>] Will be passed down to the individual commits
854
+ #
855
+ # @param contract [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Contract]
856
+ #
857
+ # @param description [String] Will be passed down to the individual commits
858
+ #
859
+ # @param ending_before [Time] Determines when the contract will stop creating recurring commits. Optional
860
+ #
861
+ # @param invoice_amount [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::InvoiceAmount] The amount the customer should be billed for the commit. Not required.
862
+ #
863
+ # @param name [String] Displayed on invoices. Will be passed through to the individual commits
864
+ #
865
+ # @param netsuite_sales_order_id [String] Will be passed down to the individual commits
866
+ #
867
+ # @param proration [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Proration] Determines whether the first and last commit will be prorated. If not provided,
868
+ #
869
+ # @param recurrence_frequency [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::RecurrenceFrequency] The frequency at which the recurring commits will be created. If not provided:
870
+ #
871
+ # @param rollover_fraction [Float] Will be passed down to the individual commits. This controls how much of an indi
872
+ #
873
+ # @param specifiers [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Specifier>] List of filters that determine what kind of customer usage draws down a commit o
874
+
875
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#access_amount
876
+ class AccessAmount < MetronomeSDK::Internal::Type::BaseModel
877
+ # @!attribute credit_type_id
878
+ #
879
+ # @return [String]
880
+ required :credit_type_id, String
881
+
882
+ # @!attribute unit_price
883
+ #
884
+ # @return [Float]
885
+ required :unit_price, Float
886
+
887
+ # @!attribute quantity
888
+ #
889
+ # @return [Float, nil]
890
+ optional :quantity, Float
891
+
892
+ # @!method initialize(credit_type_id:, unit_price:, quantity: nil)
893
+ # The amount of commit to grant.
894
+ #
895
+ # @param credit_type_id [String]
896
+ # @param unit_price [Float]
897
+ # @param quantity [Float]
898
+ end
899
+
900
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#commit_duration
901
+ class CommitDuration < MetronomeSDK::Internal::Type::BaseModel
902
+ # @!attribute value
903
+ #
904
+ # @return [Float]
905
+ required :value, Float
906
+
907
+ # @!attribute unit
908
+ #
909
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::CommitDuration::Unit, nil]
910
+ optional :unit,
911
+ enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCommit::CommitDuration::Unit }
912
+
913
+ # @!method initialize(value:, unit: nil)
914
+ # The amount of time the created commits will be valid for
915
+ #
916
+ # @param value [Float]
917
+ # @param unit [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::CommitDuration::Unit]
918
+
919
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::CommitDuration#unit
920
+ module Unit
921
+ extend MetronomeSDK::Internal::Type::Enum
922
+
923
+ PERIODS = :PERIODS
924
+
925
+ # @!method self.values
926
+ # @return [Array<Symbol>]
927
+ end
928
+ end
929
+
930
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#product
931
+ class Product < MetronomeSDK::Internal::Type::BaseModel
932
+ # @!attribute id
933
+ #
934
+ # @return [String]
935
+ required :id, String
936
+
937
+ # @!attribute name
938
+ #
939
+ # @return [String]
940
+ required :name, String
941
+
942
+ # @!method initialize(id:, name:)
943
+ # @param id [String]
944
+ # @param name [String]
945
+ end
946
+
947
+ # Whether the created commits will use the commit rate or list rate
948
+ #
949
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#rate_type
950
+ module RateType
951
+ extend MetronomeSDK::Internal::Type::Enum
952
+
953
+ COMMIT_RATE = :COMMIT_RATE
954
+ LIST_RATE = :LIST_RATE
955
+
956
+ # @!method self.values
957
+ # @return [Array<Symbol>]
958
+ end
959
+
960
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#contract
961
+ class Contract < MetronomeSDK::Internal::Type::BaseModel
962
+ # @!attribute id
963
+ #
964
+ # @return [String]
965
+ required :id, String
966
+
967
+ # @!method initialize(id:)
968
+ # @param id [String]
969
+ end
970
+
971
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#invoice_amount
972
+ class InvoiceAmount < MetronomeSDK::Internal::Type::BaseModel
973
+ # @!attribute credit_type_id
974
+ #
975
+ # @return [String]
976
+ required :credit_type_id, String
977
+
978
+ # @!attribute quantity
979
+ #
980
+ # @return [Float]
981
+ required :quantity, Float
982
+
983
+ # @!attribute unit_price
984
+ #
985
+ # @return [Float]
986
+ required :unit_price, Float
987
+
988
+ # @!method initialize(credit_type_id:, quantity:, unit_price:)
989
+ # The amount the customer should be billed for the commit. Not required.
990
+ #
991
+ # @param credit_type_id [String]
992
+ # @param quantity [Float]
993
+ # @param unit_price [Float]
994
+ end
995
+
996
+ # Determines whether the first and last commit will be prorated. If not provided,
997
+ # the default is FIRST_AND_LAST (i.e. prorate both the first and last commits).
998
+ #
999
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#proration
1000
+ module Proration
1001
+ extend MetronomeSDK::Internal::Type::Enum
1002
+
1003
+ NONE = :NONE
1004
+ FIRST = :FIRST
1005
+ LAST = :LAST
1006
+ FIRST_AND_LAST = :FIRST_AND_LAST
1007
+
1008
+ # @!method self.values
1009
+ # @return [Array<Symbol>]
1010
+ end
1011
+
1012
+ # The frequency at which the recurring commits will be created. If not provided: -
1013
+ # The commits will be created on the usage invoice frequency. If provided: - The
1014
+ # period defined in the duration will correspond to this frequency. - Commits will
1015
+ # be created aligned with the recurring commit's starting_at rather than the usage
1016
+ # invoice dates.
1017
+ #
1018
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit#recurrence_frequency
1019
+ module RecurrenceFrequency
1020
+ extend MetronomeSDK::Internal::Type::Enum
1021
+
1022
+ MONTHLY = :MONTHLY
1023
+ QUARTERLY = :QUARTERLY
1024
+ ANNUAL = :ANNUAL
1025
+ WEEKLY = :WEEKLY
1026
+
1027
+ # @!method self.values
1028
+ # @return [Array<Symbol>]
1029
+ end
1030
+
1031
+ class Specifier < MetronomeSDK::Internal::Type::BaseModel
1032
+ # @!attribute presentation_group_values
1033
+ #
1034
+ # @return [Hash{Symbol=>String}, nil]
1035
+ optional :presentation_group_values, MetronomeSDK::Internal::Type::HashOf[String]
1036
+
1037
+ # @!attribute pricing_group_values
1038
+ #
1039
+ # @return [Hash{Symbol=>String}, nil]
1040
+ optional :pricing_group_values, MetronomeSDK::Internal::Type::HashOf[String]
1041
+
1042
+ # @!attribute product_id
1043
+ # If provided, the specifier will only apply to the product with the specified ID.
1044
+ #
1045
+ # @return [String, nil]
1046
+ optional :product_id, String
1047
+
1048
+ # @!attribute product_tags
1049
+ # If provided, the specifier will only apply to products with all the specified
1050
+ # tags.
1051
+ #
1052
+ # @return [Array<String>, nil]
1053
+ optional :product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]
1054
+
1055
+ # @!method initialize(presentation_group_values: nil, pricing_group_values: nil, product_id: nil, product_tags: nil)
1056
+ # Some parameter documentations has been truncated, see
1057
+ # {MetronomeSDK::Models::ContractWithoutAmendments::RecurringCommit::Specifier}
1058
+ # for more details.
1059
+ #
1060
+ # @param presentation_group_values [Hash{Symbol=>String}]
1061
+ #
1062
+ # @param pricing_group_values [Hash{Symbol=>String}]
1063
+ #
1064
+ # @param product_id [String] If provided, the specifier will only apply to the product with the specified ID.
1065
+ #
1066
+ # @param product_tags [Array<String>] If provided, the specifier will only apply to products with all the specified ta
1067
+ end
1068
+ end
1069
+
1070
+ class RecurringCredit < MetronomeSDK::Internal::Type::BaseModel
1071
+ # @!attribute id
1072
+ #
1073
+ # @return [String]
1074
+ required :id, String
1075
+
1076
+ # @!attribute access_amount
1077
+ # The amount of commit to grant.
1078
+ #
1079
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::AccessAmount]
1080
+ required :access_amount, -> { MetronomeSDK::ContractWithoutAmendments::RecurringCredit::AccessAmount }
1081
+
1082
+ # @!attribute commit_duration
1083
+ # The amount of time the created commits will be valid for
1084
+ #
1085
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::CommitDuration]
1086
+ required :commit_duration,
1087
+ -> {
1088
+ MetronomeSDK::ContractWithoutAmendments::RecurringCredit::CommitDuration
1089
+ }
1090
+
1091
+ # @!attribute priority
1092
+ # Will be passed down to the individual commits
1093
+ #
1094
+ # @return [Float]
1095
+ required :priority, Float
1096
+
1097
+ # @!attribute product
1098
+ #
1099
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Product]
1100
+ required :product, -> { MetronomeSDK::ContractWithoutAmendments::RecurringCredit::Product }
1101
+
1102
+ # @!attribute rate_type
1103
+ # Whether the created commits will use the commit rate or list rate
1104
+ #
1105
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::RateType]
1106
+ required :rate_type, enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCredit::RateType }
1107
+
1108
+ # @!attribute starting_at
1109
+ # Determines the start time for the first commit
1110
+ #
1111
+ # @return [Time]
1112
+ required :starting_at, Time
1113
+
1114
+ # @!attribute applicable_product_ids
1115
+ # Will be passed down to the individual commits
1116
+ #
1117
+ # @return [Array<String>, nil]
1118
+ optional :applicable_product_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
1119
+
1120
+ # @!attribute applicable_product_tags
1121
+ # Will be passed down to the individual commits
1122
+ #
1123
+ # @return [Array<String>, nil]
1124
+ optional :applicable_product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]
1125
+
1126
+ # @!attribute contract
1127
+ #
1128
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Contract, nil]
1129
+ optional :contract, -> { MetronomeSDK::ContractWithoutAmendments::RecurringCredit::Contract }
1130
+
1131
+ # @!attribute description
1132
+ # Will be passed down to the individual commits
1133
+ #
1134
+ # @return [String, nil]
1135
+ optional :description, String
1136
+
1137
+ # @!attribute ending_before
1138
+ # Determines when the contract will stop creating recurring commits. Optional
1139
+ #
1140
+ # @return [Time, nil]
1141
+ optional :ending_before, Time
1142
+
1143
+ # @!attribute name
1144
+ # Displayed on invoices. Will be passed through to the individual commits
1145
+ #
1146
+ # @return [String, nil]
1147
+ optional :name, String
1148
+
1149
+ # @!attribute netsuite_sales_order_id
1150
+ # Will be passed down to the individual commits
1151
+ #
1152
+ # @return [String, nil]
1153
+ optional :netsuite_sales_order_id, String
1154
+
1155
+ # @!attribute proration
1156
+ # Determines whether the first and last commit will be prorated. If not provided,
1157
+ # the default is FIRST_AND_LAST (i.e. prorate both the first and last commits).
1158
+ #
1159
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Proration, nil]
1160
+ optional :proration, enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCredit::Proration }
1161
+
1162
+ # @!attribute recurrence_frequency
1163
+ # The frequency at which the recurring commits will be created. If not provided: -
1164
+ # The commits will be created on the usage invoice frequency. If provided: - The
1165
+ # period defined in the duration will correspond to this frequency. - Commits will
1166
+ # be created aligned with the recurring commit's starting_at rather than the usage
1167
+ # invoice dates.
1168
+ #
1169
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::RecurrenceFrequency, nil]
1170
+ optional :recurrence_frequency,
1171
+ enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCredit::RecurrenceFrequency }
1172
+
1173
+ # @!attribute rollover_fraction
1174
+ # Will be passed down to the individual commits. This controls how much of an
1175
+ # individual unexpired commit will roll over upon contract transition. Must be
1176
+ # between 0 and 1.
1177
+ #
1178
+ # @return [Float, nil]
1179
+ optional :rollover_fraction, Float
1180
+
1181
+ # @!attribute specifiers
1182
+ # List of filters that determine what kind of customer usage draws down a commit
1183
+ # or credit. A customer's usage needs to meet the condition of at least one of the
1184
+ # specifiers to contribute to a commit's or credit's drawdown.
1185
+ #
1186
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Specifier>, nil]
1187
+ optional :specifiers,
1188
+ -> {
1189
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::RecurringCredit::Specifier]
1190
+ }
1191
+
1192
+ # @!method initialize(id:, access_amount:, commit_duration:, priority:, product:, rate_type:, starting_at:, applicable_product_ids: nil, applicable_product_tags: nil, contract: nil, description: nil, ending_before: nil, name: nil, netsuite_sales_order_id: nil, proration: nil, recurrence_frequency: nil, rollover_fraction: nil, specifiers: nil)
1193
+ # Some parameter documentations has been truncated, see
1194
+ # {MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit} for more
1195
+ # details.
1196
+ #
1197
+ # @param id [String]
1198
+ #
1199
+ # @param access_amount [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::AccessAmount] The amount of commit to grant.
1200
+ #
1201
+ # @param commit_duration [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::CommitDuration] The amount of time the created commits will be valid for
1202
+ #
1203
+ # @param priority [Float] Will be passed down to the individual commits
1204
+ #
1205
+ # @param product [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Product]
1206
+ #
1207
+ # @param rate_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::RateType] Whether the created commits will use the commit rate or list rate
1208
+ #
1209
+ # @param starting_at [Time] Determines the start time for the first commit
1210
+ #
1211
+ # @param applicable_product_ids [Array<String>] Will be passed down to the individual commits
1212
+ #
1213
+ # @param applicable_product_tags [Array<String>] Will be passed down to the individual commits
1214
+ #
1215
+ # @param contract [MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Contract]
1216
+ #
1217
+ # @param description [String] Will be passed down to the individual commits
1218
+ #
1219
+ # @param ending_before [Time] Determines when the contract will stop creating recurring commits. Optional
1220
+ #
1221
+ # @param name [String] Displayed on invoices. Will be passed through to the individual commits
1222
+ #
1223
+ # @param netsuite_sales_order_id [String] Will be passed down to the individual commits
1224
+ #
1225
+ # @param proration [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Proration] Determines whether the first and last commit will be prorated. If not provided,
1226
+ #
1227
+ # @param recurrence_frequency [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::RecurrenceFrequency] The frequency at which the recurring commits will be created. If not provided:
1228
+ #
1229
+ # @param rollover_fraction [Float] Will be passed down to the individual commits. This controls how much of an indi
1230
+ #
1231
+ # @param specifiers [Array<MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Specifier>] List of filters that determine what kind of customer usage draws down a commit o
1232
+
1233
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit#access_amount
1234
+ class AccessAmount < MetronomeSDK::Internal::Type::BaseModel
1235
+ # @!attribute credit_type_id
1236
+ #
1237
+ # @return [String]
1238
+ required :credit_type_id, String
1239
+
1240
+ # @!attribute unit_price
1241
+ #
1242
+ # @return [Float]
1243
+ required :unit_price, Float
1244
+
1245
+ # @!attribute quantity
1246
+ #
1247
+ # @return [Float, nil]
1248
+ optional :quantity, Float
1249
+
1250
+ # @!method initialize(credit_type_id:, unit_price:, quantity: nil)
1251
+ # The amount of commit to grant.
1252
+ #
1253
+ # @param credit_type_id [String]
1254
+ # @param unit_price [Float]
1255
+ # @param quantity [Float]
1256
+ end
1257
+
1258
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit#commit_duration
1259
+ class CommitDuration < MetronomeSDK::Internal::Type::BaseModel
1260
+ # @!attribute value
1261
+ #
1262
+ # @return [Float]
1263
+ required :value, Float
1264
+
1265
+ # @!attribute unit
1266
+ #
1267
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::CommitDuration::Unit, nil]
1268
+ optional :unit,
1269
+ enum: -> { MetronomeSDK::ContractWithoutAmendments::RecurringCredit::CommitDuration::Unit }
1270
+
1271
+ # @!method initialize(value:, unit: nil)
1272
+ # The amount of time the created commits will be valid for
1273
+ #
1274
+ # @param value [Float]
1275
+ # @param unit [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::CommitDuration::Unit]
1276
+
1277
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::CommitDuration#unit
1278
+ module Unit
1279
+ extend MetronomeSDK::Internal::Type::Enum
1280
+
1281
+ PERIODS = :PERIODS
1282
+
1283
+ # @!method self.values
1284
+ # @return [Array<Symbol>]
1285
+ end
1286
+ end
1287
+
1288
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit#product
1289
+ class Product < MetronomeSDK::Internal::Type::BaseModel
1290
+ # @!attribute id
1291
+ #
1292
+ # @return [String]
1293
+ required :id, String
1294
+
1295
+ # @!attribute name
1296
+ #
1297
+ # @return [String]
1298
+ required :name, String
1299
+
1300
+ # @!method initialize(id:, name:)
1301
+ # @param id [String]
1302
+ # @param name [String]
1303
+ end
1304
+
1305
+ # Whether the created commits will use the commit rate or list rate
1306
+ #
1307
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit#rate_type
1308
+ module RateType
1309
+ extend MetronomeSDK::Internal::Type::Enum
1310
+
1311
+ COMMIT_RATE = :COMMIT_RATE
1312
+ LIST_RATE = :LIST_RATE
1313
+
1314
+ # @!method self.values
1315
+ # @return [Array<Symbol>]
1316
+ end
1317
+
1318
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit#contract
1319
+ class Contract < MetronomeSDK::Internal::Type::BaseModel
1320
+ # @!attribute id
1321
+ #
1322
+ # @return [String]
1323
+ required :id, String
1324
+
1325
+ # @!method initialize(id:)
1326
+ # @param id [String]
1327
+ end
1328
+
1329
+ # Determines whether the first and last commit will be prorated. If not provided,
1330
+ # the default is FIRST_AND_LAST (i.e. prorate both the first and last commits).
1331
+ #
1332
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit#proration
1333
+ module Proration
1334
+ extend MetronomeSDK::Internal::Type::Enum
1335
+
1336
+ NONE = :NONE
1337
+ FIRST = :FIRST
1338
+ LAST = :LAST
1339
+ FIRST_AND_LAST = :FIRST_AND_LAST
1340
+
1341
+ # @!method self.values
1342
+ # @return [Array<Symbol>]
1343
+ end
1344
+
1345
+ # The frequency at which the recurring commits will be created. If not provided: -
1346
+ # The commits will be created on the usage invoice frequency. If provided: - The
1347
+ # period defined in the duration will correspond to this frequency. - Commits will
1348
+ # be created aligned with the recurring commit's starting_at rather than the usage
1349
+ # invoice dates.
1350
+ #
1351
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit#recurrence_frequency
1352
+ module RecurrenceFrequency
1353
+ extend MetronomeSDK::Internal::Type::Enum
1354
+
1355
+ MONTHLY = :MONTHLY
1356
+ QUARTERLY = :QUARTERLY
1357
+ ANNUAL = :ANNUAL
1358
+ WEEKLY = :WEEKLY
1359
+
1360
+ # @!method self.values
1361
+ # @return [Array<Symbol>]
1362
+ end
1363
+
1364
+ class Specifier < MetronomeSDK::Internal::Type::BaseModel
1365
+ # @!attribute presentation_group_values
1366
+ #
1367
+ # @return [Hash{Symbol=>String}, nil]
1368
+ optional :presentation_group_values, MetronomeSDK::Internal::Type::HashOf[String]
1369
+
1370
+ # @!attribute pricing_group_values
1371
+ #
1372
+ # @return [Hash{Symbol=>String}, nil]
1373
+ optional :pricing_group_values, MetronomeSDK::Internal::Type::HashOf[String]
1374
+
1375
+ # @!attribute product_id
1376
+ # If provided, the specifier will only apply to the product with the specified ID.
1377
+ #
1378
+ # @return [String, nil]
1379
+ optional :product_id, String
1380
+
1381
+ # @!attribute product_tags
1382
+ # If provided, the specifier will only apply to products with all the specified
1383
+ # tags.
1384
+ #
1385
+ # @return [Array<String>, nil]
1386
+ optional :product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]
1387
+
1388
+ # @!method initialize(presentation_group_values: nil, pricing_group_values: nil, product_id: nil, product_tags: nil)
1389
+ # Some parameter documentations has been truncated, see
1390
+ # {MetronomeSDK::Models::ContractWithoutAmendments::RecurringCredit::Specifier}
1391
+ # for more details.
1392
+ #
1393
+ # @param presentation_group_values [Hash{Symbol=>String}]
1394
+ #
1395
+ # @param pricing_group_values [Hash{Symbol=>String}]
1396
+ #
1397
+ # @param product_id [String] If provided, the specifier will only apply to the product with the specified ID.
1398
+ #
1399
+ # @param product_tags [Array<String>] If provided, the specifier will only apply to products with all the specified ta
1400
+ end
1401
+ end
1402
+
1403
+ class ResellerRoyalty < MetronomeSDK::Internal::Type::BaseModel
1404
+ # @!attribute fraction
1405
+ #
1406
+ # @return [Float]
1407
+ required :fraction, Float
1408
+
1409
+ # @!attribute netsuite_reseller_id
1410
+ #
1411
+ # @return [String]
1412
+ required :netsuite_reseller_id, String
1413
+
1414
+ # @!attribute reseller_type
1415
+ #
1416
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::ResellerRoyalty::ResellerType]
1417
+ required :reseller_type,
1418
+ enum: -> { MetronomeSDK::ContractWithoutAmendments::ResellerRoyalty::ResellerType }
1419
+
1420
+ # @!attribute starting_at
1421
+ #
1422
+ # @return [Time]
1423
+ required :starting_at, Time
1424
+
1425
+ # @!attribute applicable_product_ids
1426
+ #
1427
+ # @return [Array<String>, nil]
1428
+ optional :applicable_product_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
1429
+
1430
+ # @!attribute applicable_product_tags
1431
+ #
1432
+ # @return [Array<String>, nil]
1433
+ optional :applicable_product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]
1434
+
1435
+ # @!attribute aws_account_number
1436
+ #
1437
+ # @return [String, nil]
1438
+ optional :aws_account_number, String
1439
+
1440
+ # @!attribute aws_offer_id
1441
+ #
1442
+ # @return [String, nil]
1443
+ optional :aws_offer_id, String
1444
+
1445
+ # @!attribute aws_payer_reference_id
1446
+ #
1447
+ # @return [String, nil]
1448
+ optional :aws_payer_reference_id, String
1449
+
1450
+ # @!attribute ending_before
1451
+ #
1452
+ # @return [Time, nil]
1453
+ optional :ending_before, Time
1454
+
1455
+ # @!attribute gcp_account_id
1456
+ #
1457
+ # @return [String, nil]
1458
+ optional :gcp_account_id, String
1459
+
1460
+ # @!attribute gcp_offer_id
1461
+ #
1462
+ # @return [String, nil]
1463
+ optional :gcp_offer_id, String
1464
+
1465
+ # @!attribute reseller_contract_value
1466
+ #
1467
+ # @return [Float, nil]
1468
+ optional :reseller_contract_value, Float
1469
+
1470
+ # @!method initialize(fraction:, netsuite_reseller_id:, reseller_type:, starting_at:, applicable_product_ids: nil, applicable_product_tags: nil, aws_account_number: nil, aws_offer_id: nil, aws_payer_reference_id: nil, ending_before: nil, gcp_account_id: nil, gcp_offer_id: nil, reseller_contract_value: nil)
1471
+ # @param fraction [Float]
1472
+ # @param netsuite_reseller_id [String]
1473
+ # @param reseller_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::ResellerRoyalty::ResellerType]
1474
+ # @param starting_at [Time]
1475
+ # @param applicable_product_ids [Array<String>]
1476
+ # @param applicable_product_tags [Array<String>]
1477
+ # @param aws_account_number [String]
1478
+ # @param aws_offer_id [String]
1479
+ # @param aws_payer_reference_id [String]
1480
+ # @param ending_before [Time]
1481
+ # @param gcp_account_id [String]
1482
+ # @param gcp_offer_id [String]
1483
+ # @param reseller_contract_value [Float]
1484
+
1485
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::ResellerRoyalty#reseller_type
1486
+ module ResellerType
1487
+ extend MetronomeSDK::Internal::Type::Enum
1488
+
1489
+ AWS = :AWS
1490
+ AWS_PRO_SERVICE = :AWS_PRO_SERVICE
1491
+ GCP = :GCP
1492
+ GCP_PRO_SERVICE = :GCP_PRO_SERVICE
1493
+
1494
+ # @!method self.values
1495
+ # @return [Array<Symbol>]
1496
+ end
1497
+ end
1498
+
1499
+ # Determines which scheduled and commit charges to consolidate onto the Contract's
1500
+ # usage invoice. The charge's `timestamp` must match the usage invoice's
1501
+ # `ending_before` date for consolidation to occur. This field cannot be modified
1502
+ # after a Contract has been created. If this field is omitted, charges will appear
1503
+ # on a separate invoice from usage charges.
1504
+ #
1505
+ # @see MetronomeSDK::Models::ContractWithoutAmendments#scheduled_charges_on_usage_invoices
1506
+ module ScheduledChargesOnUsageInvoices
1507
+ extend MetronomeSDK::Internal::Type::Enum
1508
+
1509
+ ALL = :ALL
1510
+
1511
+ # @!method self.values
1512
+ # @return [Array<Symbol>]
1513
+ end
1514
+
1515
+ # @see MetronomeSDK::Models::ContractWithoutAmendments#spend_threshold_configuration
1516
+ class SpendThresholdConfiguration < MetronomeSDK::Internal::Type::BaseModel
1517
+ # @!attribute commit
1518
+ #
1519
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::Commit]
1520
+ required :commit, -> { MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration::Commit }
1521
+
1522
+ # @!attribute is_enabled
1523
+ # When set to false, the contract will not be evaluated against the
1524
+ # threshold_amount. Toggling to true will result an immediate evaluation,
1525
+ # regardless of prior state.
1526
+ #
1527
+ # @return [Boolean]
1528
+ required :is_enabled, MetronomeSDK::Internal::Type::Boolean
1529
+
1530
+ # @!attribute payment_gate_config
1531
+ #
1532
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig]
1533
+ required :payment_gate_config,
1534
+ -> {
1535
+ MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig
1536
+ }
1537
+
1538
+ # @!attribute threshold_amount
1539
+ # Specify the threshold amount for the contract. Each time the contract's usage
1540
+ # hits this amount, a threshold charge will be initiated.
1541
+ #
1542
+ # @return [Float]
1543
+ required :threshold_amount, Float
1544
+
1545
+ # @!method initialize(commit:, is_enabled:, payment_gate_config:, threshold_amount:)
1546
+ # Some parameter documentations has been truncated, see
1547
+ # {MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration}
1548
+ # for more details.
1549
+ #
1550
+ # @param commit [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::Commit]
1551
+ #
1552
+ # @param is_enabled [Boolean] When set to false, the contract will not be evaluated against the threshold_amou
1553
+ #
1554
+ # @param payment_gate_config [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig]
1555
+ #
1556
+ # @param threshold_amount [Float] Specify the threshold amount for the contract. Each time the contract's usage hi
1557
+
1558
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration#commit
1559
+ class Commit < MetronomeSDK::Internal::Type::BaseModel
1560
+ # @!attribute product_id
1561
+ # The commit product that will be used to generate the line item for commit
1562
+ # payment.
1563
+ #
1564
+ # @return [String]
1565
+ required :product_id, String
1566
+
1567
+ # @!attribute description
1568
+ #
1569
+ # @return [String, nil]
1570
+ optional :description, String
1571
+
1572
+ # @!attribute name
1573
+ # Specify the name of the line item for the threshold charge. If left blank, it
1574
+ # will default to the commit product name.
1575
+ #
1576
+ # @return [String, nil]
1577
+ optional :name, String
1578
+
1579
+ # @!method initialize(product_id:, description: nil, name: nil)
1580
+ # Some parameter documentations has been truncated, see
1581
+ # {MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::Commit}
1582
+ # for more details.
1583
+ #
1584
+ # @param product_id [String] The commit product that will be used to generate the line item for commit paymen
1585
+ #
1586
+ # @param description [String]
1587
+ #
1588
+ # @param name [String] Specify the name of the line item for the threshold charge. If left blank, it wi
1589
+ end
1590
+
1591
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration#payment_gate_config
1592
+ class PaymentGateConfig < MetronomeSDK::Internal::Type::BaseModel
1593
+ # @!attribute payment_gate_type
1594
+ # Gate access to the commit balance based on successful collection of payment.
1595
+ # Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
1596
+ # facilitate payment using your own payment integration. Select NONE if you do not
1597
+ # wish to payment gate the commit balance.
1598
+ #
1599
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::PaymentGateType]
1600
+ required :payment_gate_type,
1601
+ enum: -> {
1602
+ MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::PaymentGateType
1603
+ }
1604
+
1605
+ # @!attribute precalculated_tax_config
1606
+ # Only applicable if using PRECALCULATED as your tax type.
1607
+ #
1608
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig, nil]
1609
+ optional :precalculated_tax_config,
1610
+ -> {
1611
+ MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig
1612
+ }
1613
+
1614
+ # @!attribute stripe_config
1615
+ # Only applicable if using STRIPE as your payment gate type.
1616
+ #
1617
+ # @return [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig, nil]
1618
+ optional :stripe_config,
1619
+ -> {
1620
+ MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig
1621
+ }
1622
+
1623
+ # @!attribute tax_type
1624
+ # Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
1625
+ # not wish Metronome to calculate tax on your behalf. Leaving this field blank
1626
+ # will default to NONE.
1627
+ #
1628
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::TaxType, nil]
1629
+ optional :tax_type,
1630
+ enum: -> {
1631
+ MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::TaxType
1632
+ }
1633
+
1634
+ # @!method initialize(payment_gate_type:, precalculated_tax_config: nil, stripe_config: nil, tax_type: nil)
1635
+ # Some parameter documentations has been truncated, see
1636
+ # {MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig}
1637
+ # for more details.
1638
+ #
1639
+ # @param payment_gate_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::PaymentGateType] Gate access to the commit balance based on successful collection of payment. Sel
1640
+ #
1641
+ # @param precalculated_tax_config [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig] Only applicable if using PRECALCULATED as your tax type.
1642
+ #
1643
+ # @param stripe_config [MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig] Only applicable if using STRIPE as your payment gate type.
1644
+ #
1645
+ # @param tax_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::TaxType] Stripe tax is only supported for Stripe payment gateway. Select NONE if you do n
1646
+
1647
+ # Gate access to the commit balance based on successful collection of payment.
1648
+ # Select STRIPE for Metronome to facilitate payment via Stripe. Select EXTERNAL to
1649
+ # facilitate payment using your own payment integration. Select NONE if you do not
1650
+ # wish to payment gate the commit balance.
1651
+ #
1652
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig#payment_gate_type
1653
+ module PaymentGateType
1654
+ extend MetronomeSDK::Internal::Type::Enum
1655
+
1656
+ NONE = :NONE
1657
+ STRIPE = :STRIPE
1658
+ EXTERNAL = :EXTERNAL
1659
+
1660
+ # @!method self.values
1661
+ # @return [Array<Symbol>]
1662
+ end
1663
+
1664
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig#precalculated_tax_config
1665
+ class PrecalculatedTaxConfig < MetronomeSDK::Internal::Type::BaseModel
1666
+ # @!attribute tax_amount
1667
+ # Amount of tax to be applied. This should be in the same currency and
1668
+ # denomination as the commit's invoice schedule
1669
+ #
1670
+ # @return [Float]
1671
+ required :tax_amount, Float
1672
+
1673
+ # @!attribute tax_name
1674
+ # Name of the tax to be applied. This may be used in an invoice line item
1675
+ # description.
1676
+ #
1677
+ # @return [String, nil]
1678
+ optional :tax_name, String
1679
+
1680
+ # @!method initialize(tax_amount:, tax_name: nil)
1681
+ # Some parameter documentations has been truncated, see
1682
+ # {MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::PrecalculatedTaxConfig}
1683
+ # for more details.
1684
+ #
1685
+ # Only applicable if using PRECALCULATED as your tax type.
1686
+ #
1687
+ # @param tax_amount [Float] Amount of tax to be applied. This should be in the same currency and denominatio
1688
+ #
1689
+ # @param tax_name [String] Name of the tax to be applied. This may be used in an invoice line item descript
1690
+ end
1691
+
1692
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig#stripe_config
1693
+ class StripeConfig < MetronomeSDK::Internal::Type::BaseModel
1694
+ # @!attribute payment_type
1695
+ # If left blank, will default to INVOICE
1696
+ #
1697
+ # @return [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig::PaymentType]
1698
+ required :payment_type,
1699
+ enum: -> {
1700
+ MetronomeSDK::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig::PaymentType
1701
+ }
1702
+
1703
+ # @!attribute invoice_metadata
1704
+ # Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
1705
+ # your payment type.
1706
+ #
1707
+ # @return [Hash{Symbol=>String}, nil]
1708
+ optional :invoice_metadata, MetronomeSDK::Internal::Type::HashOf[String]
1709
+
1710
+ # @!method initialize(payment_type:, invoice_metadata: nil)
1711
+ # Some parameter documentations has been truncated, see
1712
+ # {MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig}
1713
+ # for more details.
1714
+ #
1715
+ # Only applicable if using STRIPE as your payment gate type.
1716
+ #
1717
+ # @param payment_type [Symbol, MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig::PaymentType] If left blank, will default to INVOICE
1718
+ #
1719
+ # @param invoice_metadata [Hash{Symbol=>String}] Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
1720
+
1721
+ # If left blank, will default to INVOICE
1722
+ #
1723
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig::StripeConfig#payment_type
1724
+ module PaymentType
1725
+ extend MetronomeSDK::Internal::Type::Enum
1726
+
1727
+ INVOICE = :INVOICE
1728
+ PAYMENT_INTENT = :PAYMENT_INTENT
1729
+
1730
+ # @!method self.values
1731
+ # @return [Array<Symbol>]
1732
+ end
1733
+ end
1734
+
1735
+ # Stripe tax is only supported for Stripe payment gateway. Select NONE if you do
1736
+ # not wish Metronome to calculate tax on your behalf. Leaving this field blank
1737
+ # will default to NONE.
1738
+ #
1739
+ # @see MetronomeSDK::Models::ContractWithoutAmendments::SpendThresholdConfiguration::PaymentGateConfig#tax_type
1740
+ module TaxType
1741
+ extend MetronomeSDK::Internal::Type::Enum
1742
+
1743
+ NONE = :NONE
1744
+ STRIPE = :STRIPE
1745
+ ANROK = :ANROK
1746
+ PRECALCULATED = :PRECALCULATED
1747
+
1748
+ # @!method self.values
1749
+ # @return [Array<Symbol>]
1750
+ end
1751
+ end
1752
+ end
1753
+
1754
+ # @see MetronomeSDK::Models::ContractWithoutAmendments#usage_filter
1755
+ class UsageFilter < MetronomeSDK::Internal::Type::BaseModel
1756
+ # @!attribute current
1757
+ #
1758
+ # @return [MetronomeSDK::Models::BaseUsageFilter, nil]
1759
+ required :current, -> { MetronomeSDK::BaseUsageFilter }, nil?: true
1760
+
1761
+ # @!attribute initial
1762
+ #
1763
+ # @return [MetronomeSDK::Models::BaseUsageFilter]
1764
+ required :initial, -> { MetronomeSDK::BaseUsageFilter }
1765
+
1766
+ # @!attribute updates
1767
+ #
1768
+ # @return [Array<MetronomeSDK::Models::ContractWithoutAmendments::UsageFilter::Update>]
1769
+ required :updates,
1770
+ -> {
1771
+ MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::ContractWithoutAmendments::UsageFilter::Update]
1772
+ }
1773
+
1774
+ # @!method initialize(current:, initial:, updates:)
1775
+ # @param current [MetronomeSDK::Models::BaseUsageFilter, nil]
1776
+ # @param initial [MetronomeSDK::Models::BaseUsageFilter]
1777
+ # @param updates [Array<MetronomeSDK::Models::ContractWithoutAmendments::UsageFilter::Update>]
1778
+
1779
+ class Update < MetronomeSDK::Internal::Type::BaseModel
1780
+ # @!attribute group_key
1781
+ #
1782
+ # @return [String]
1783
+ required :group_key, String
1784
+
1785
+ # @!attribute group_values
1786
+ #
1787
+ # @return [Array<String>]
1788
+ required :group_values, MetronomeSDK::Internal::Type::ArrayOf[String]
1789
+
1790
+ # @!attribute starting_at
1791
+ #
1792
+ # @return [Time]
1793
+ required :starting_at, Time
1794
+
1795
+ # @!method initialize(group_key:, group_values:, starting_at:)
1796
+ # @param group_key [String]
1797
+ # @param group_values [Array<String>]
1798
+ # @param starting_at [Time]
1799
+ end
1800
+ end
1801
+ end
1802
+ end
1803
+ end