inttegro 1.0.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +6 -0
  3. data/Dockerfile +1 -1
  4. data/README.md +9 -7
  5. data/SECURITY.md +11 -0
  6. data/lib/inttegro/enums.rb +2 -2
  7. data/lib/inttegro/generated/enums.rb +220 -328
  8. data/lib/inttegro/generated/models.rb +3705 -3830
  9. data/lib/inttegro/generated/operations.rb +230 -230
  10. data/lib/inttegro/http_client.rb +7 -4
  11. data/lib/inttegro/models.rb +101 -104
  12. data/lib/inttegro/resources/apps.rb +3 -3
  13. data/lib/inttegro/resources/balance_transactions.rb +2 -2
  14. data/lib/inttegro/resources/balances.rb +1 -1
  15. data/lib/inttegro/resources/broadcasts.rb +2 -2
  16. data/lib/inttegro/resources/chimes.rb +5 -5
  17. data/lib/inttegro/resources/customers.rb +4 -4
  18. data/lib/inttegro/resources/file_links.rb +4 -4
  19. data/lib/inttegro/resources/file_references.rb +1 -1
  20. data/lib/inttegro/resources/files.rb +4 -4
  21. data/lib/inttegro/resources/financial_accounts.rb +11 -11
  22. data/lib/inttegro/resources/keys.rb +6 -6
  23. data/lib/inttegro/resources/message_templates.rb +7 -7
  24. data/lib/inttegro/resources/orders.rb +72 -69
  25. data/lib/inttegro/resources/otp.rb +4 -4
  26. data/lib/inttegro/resources/payment_methods.rb +18 -18
  27. data/lib/inttegro/resources/payouts.rb +17 -17
  28. data/lib/inttegro/resources/prices.rb +7 -7
  29. data/lib/inttegro/resources/products.rb +9 -9
  30. data/lib/inttegro/resources/purchase_intents.rb +5 -5
  31. data/lib/inttegro/resources/refunds.rb +4 -4
  32. data/lib/inttegro/resources/schedules.rb +2 -2
  33. data/lib/inttegro/resources/spec.rb +1 -1
  34. data/lib/inttegro/resources/upload_requests.rb +6 -6
  35. data/lib/inttegro/response_object.rb +1 -1
  36. data/lib/inttegro/version.rb +1 -1
  37. data/rbi/inttegro/generated.rbi +124 -124
  38. metadata +3 -2
@@ -23,7 +23,7 @@ module Inttegro
23
23
  #
24
24
  # @param destinations [Hash] Map of currency codes to financial account IDs (required)
25
25
  #
26
- # @return [Inttegro::Models::SetPayoutDestinationsResponse] Updated payout settings
26
+ # @return [Inttegro::SetPayoutDestinationsResponse] Updated payout settings
27
27
  #
28
28
  # @example Set payout destinations for multiple currencies
29
29
  # result = client.payouts.set_destinations(
@@ -39,7 +39,7 @@ module Inttegro
39
39
  def set_destinations(destinations:)
40
40
  @http.post_model(
41
41
  "/payouts/set_destinations",
42
- Inttegro::Models::SetPayoutDestinationsResponse,
42
+ Inttegro::SetPayoutDestinationsResponse,
43
43
  { destinations: destinations }
44
44
  )
45
45
  end
@@ -49,7 +49,7 @@ module Inttegro
49
49
  # Returns payout settings including configured payout destinations, schedule information,
50
50
  # and whether foreign exchange is enabled.
51
51
  #
52
- # @return [Inttegro::Models::GetPayoutSettingsResponse] Current payout settings
52
+ # @return [Inttegro::GetPayoutSettingsResponse] Current payout settings
53
53
  #
54
54
  # @example Get payout settings
55
55
  # result = client.payouts.settings
@@ -58,7 +58,7 @@ module Inttegro
58
58
  #
59
59
  # @see https://studio.inttegro.com/product-payouts for payouts overview
60
60
  def settings
61
- @http.post_model("/payouts/settings", Inttegro::Models::GetPayoutSettingsResponse, {})
61
+ @http.post_model("/payouts/settings", Inttegro::GetPayoutSettingsResponse, {})
62
62
  end
63
63
 
64
64
  # Disable automatic payouts by switching to manual payout mode.
@@ -68,7 +68,7 @@ module Inttegro
68
68
  # still be at least 7 days old before they can be paid out, but the payout will only occur when you
69
69
  # explicitly request it.
70
70
  #
71
- # @return [Inttegro::Models::DisableAutomaticPayoutsResponse] Updated payout settings
71
+ # @return [Inttegro::DisableAutomaticPayoutsResponse] Updated payout settings
72
72
  #
73
73
  # @example Disable automatic payouts
74
74
  # result = client.payouts.disable_automatic
@@ -79,7 +79,7 @@ module Inttegro
79
79
  def disable_automatic
80
80
  @http.post_model(
81
81
  "/payouts/disable",
82
- Inttegro::Models::DisableAutomaticPayoutsResponse,
82
+ Inttegro::DisableAutomaticPayoutsResponse,
83
83
  {}
84
84
  )
85
85
  end
@@ -87,7 +87,7 @@ module Inttegro
87
87
  def enable_automatic
88
88
  @http.post_model(
89
89
  "/payouts/enable",
90
- Inttegro::Models::EnableAutomaticPayoutsResponse,
90
+ Inttegro::EnableAutomaticPayoutsResponse,
91
91
  {}
92
92
  )
93
93
  end
@@ -106,7 +106,7 @@ module Inttegro
106
106
  # Important: FX conversion incurs additional fees beyond standard payout fees, and exchange rates are
107
107
  # determined at payout execution time. FX-enabled payouts require approval and special configuration.
108
108
  #
109
- # @return [Inttegro::Models::PayoutSettingsResponse] Updated payout settings
109
+ # @return [Inttegro::PayoutSettingsResponse] Updated payout settings
110
110
  #
111
111
  # @example Enable foreign exchange for payouts
112
112
  # result = client.payouts.enable_fx
@@ -115,7 +115,7 @@ module Inttegro
115
115
  #
116
116
  # @see https://studio.inttegro.com/enable-fx-payouts for FX payout guide
117
117
  def enable_fx
118
- @http.post_model("/payouts/enable_fx", Inttegro::Models::PayoutSettingsResponse, {})
118
+ @http.post_model("/payouts/enable_fx", Inttegro::PayoutSettingsResponse, {})
119
119
  end
120
120
 
121
121
  # Disable foreign exchange conversion for payouts.
@@ -123,7 +123,7 @@ module Inttegro
123
123
  # Disables FX conversion, restricting payouts to accounts that match the transaction currency.
124
124
  # After disabling FX, GHS balance can only be paid out to GHS accounts, USD balance only to USD accounts, etc.
125
125
  #
126
- # @return [Inttegro::Models::PayoutSettingsResponse] Updated payout settings
126
+ # @return [Inttegro::PayoutSettingsResponse] Updated payout settings
127
127
  #
128
128
  # @example Disable foreign exchange for payouts
129
129
  # result = client.payouts.disable_fx
@@ -132,7 +132,7 @@ module Inttegro
132
132
  #
133
133
  # @see https://studio.inttegro.com/disable-fx-payouts for FX payout guide
134
134
  def disable_fx
135
- @http.post_model("/payouts/disable_fx", Inttegro::Models::PayoutSettingsResponse, {})
135
+ @http.post_model("/payouts/disable_fx", Inttegro::PayoutSettingsResponse, {})
136
136
  end
137
137
 
138
138
  # Retrieve a paginated list of payouts.
@@ -147,7 +147,7 @@ module Inttegro
147
147
  # @option payload [String] :created_after Filter payouts created after this timestamp (ISO 8601)
148
148
  # @option payload [String] :created_before Filter payouts created before this timestamp (ISO 8601)
149
149
  #
150
- # @return [Inttegro::Models::PagePayoutsResponse] Paginated list of payouts
150
+ # @return [Inttegro::PagePayoutsResponse] Paginated list of payouts
151
151
  #
152
152
  # @example Get first page of payouts
153
153
  # result = client.payouts.page(
@@ -166,17 +166,17 @@ module Inttegro
166
166
  # @see https://studio.inttegro.com/pagination for pagination guide
167
167
  # @see https://studio.inttegro.com/product-payouts for payouts overview
168
168
  def page(payload = {})
169
- @http.post_model("/payouts/page", Inttegro::Models::PagePayoutsResponse, payload || {})
169
+ @http.post_model("/payouts/page", Inttegro::PagePayoutsResponse, payload || {})
170
170
  end
171
171
 
172
172
  def schedule(payload)
173
- @http.post_model("/payouts/schedule", Inttegro::Models::SchedulePayoutResponse, payload)
173
+ @http.post_model("/payouts/schedule", Inttegro::SchedulePayoutResponse, payload)
174
174
  end
175
175
 
176
176
  def lookup(payout_id:)
177
177
  @http.post_model(
178
178
  "/payouts/lookup",
179
- Inttegro::Models::LookupPayoutResponse,
179
+ Inttegro::LookupPayoutResponse,
180
180
  { payout_id: payout_id }
181
181
  )
182
182
  end
@@ -187,11 +187,11 @@ module Inttegro
187
187
  #
188
188
  # @param payout_id [String] Scheduled payout ID
189
189
  #
190
- # @return [Inttegro::Models::CancelPayoutResponse] Canceled payout
190
+ # @return [Inttegro::CancelPayoutResponse] Canceled payout
191
191
  def cancel(payout_id:)
192
192
  @http.post_model(
193
193
  "/payouts/cancel",
194
- Inttegro::Models::CancelPayoutResponse,
194
+ Inttegro::CancelPayoutResponse,
195
195
  { payout_id: payout_id }
196
196
  )
197
197
  end
@@ -9,31 +9,31 @@ module Inttegro
9
9
  end
10
10
 
11
11
  def create(payload)
12
- @http.post_model("/prices/create", Inttegro::Models::PriceResponse, payload)
12
+ @http.post_model("/prices/create", Inttegro::PriceResponse, payload)
13
13
  end
14
14
 
15
15
  def lookup(price_id:)
16
- @http.post_model("/prices/lookup", Inttegro::Models::PriceResponse, { price_id: price_id })
16
+ @http.post_model("/prices/lookup", Inttegro::PriceResponse, { price_id: price_id })
17
17
  end
18
18
 
19
19
  def page(payload = {})
20
- @http.post_model("/prices/page", Inttegro::Models::PricePageResponse, payload || {})
20
+ @http.post_model("/prices/page", Inttegro::PricePageResponse, payload || {})
21
21
  end
22
22
 
23
23
  def update(payload)
24
- @http.post_model("/prices/update", Inttegro::Models::PriceResponse, payload)
24
+ @http.post_model("/prices/update", Inttegro::PriceResponse, payload)
25
25
  end
26
26
 
27
27
  def activate(price_id:)
28
- @http.post_model("/prices/activate", Inttegro::Models::PriceResponse, { price_id: price_id })
28
+ @http.post_model("/prices/activate", Inttegro::PriceResponse, { price_id: price_id })
29
29
  end
30
30
 
31
31
  def deactivate(price_id:)
32
- @http.post_model("/prices/deactivate", Inttegro::Models::PriceResponse, { price_id: price_id })
32
+ @http.post_model("/prices/deactivate", Inttegro::PriceResponse, { price_id: price_id })
33
33
  end
34
34
 
35
35
  def archive(price_id:)
36
- @http.post_model("/prices/archive", Inttegro::Models::PriceResponse, { price_id: price_id })
36
+ @http.post_model("/prices/archive", Inttegro::PriceResponse, { price_id: price_id })
37
37
  end
38
38
  end
39
39
  end
@@ -9,39 +9,39 @@ module Inttegro
9
9
  end
10
10
 
11
11
  def create(payload)
12
- @http.post_model("/products/create", Inttegro::Models::ProductResponse, payload)
12
+ @http.post_model("/products/create", Inttegro::ProductResponse, payload)
13
13
  end
14
14
 
15
15
  def add_price(payload)
16
- @http.post_model("/products/add_price", Inttegro::Models::AddProductPriceResponse, payload)
16
+ @http.post_model("/products/add_price", Inttegro::AddProductPriceResponse, payload)
17
17
  end
18
18
 
19
19
  def set_default_unit_price(payload)
20
- @http.post_model("/products/set_default_unit_price", Inttegro::Models::ProductResponse, payload)
20
+ @http.post_model("/products/set_default_unit_price", Inttegro::ProductResponse, payload)
21
21
  end
22
22
 
23
23
  def lookup(product_id:)
24
- @http.post_model("/products/lookup", Inttegro::Models::ProductResponse, { product_id: product_id })
24
+ @http.post_model("/products/lookup", Inttegro::ProductResponse, { product_id: product_id })
25
25
  end
26
26
 
27
27
  def update(payload)
28
- @http.post_model("/products/update", Inttegro::Models::UpdateProductResponse, payload)
28
+ @http.post_model("/products/update", Inttegro::UpdateProductResponse, payload)
29
29
  end
30
30
 
31
31
  def publish(product_id:)
32
- @http.post_model("/products/publish", Inttegro::Models::ProductResponse, { product_id: product_id })
32
+ @http.post_model("/products/publish", Inttegro::ProductResponse, { product_id: product_id })
33
33
  end
34
34
 
35
35
  def unpublish(product_id:)
36
- @http.post_model("/products/unpublish", Inttegro::Models::ProductResponse, { product_id: product_id })
36
+ @http.post_model("/products/unpublish", Inttegro::ProductResponse, { product_id: product_id })
37
37
  end
38
38
 
39
39
  def archive(product_id:)
40
- @http.post_model("/products/archive", Inttegro::Models::ProductResponse, { product_id: product_id })
40
+ @http.post_model("/products/archive", Inttegro::ProductResponse, { product_id: product_id })
41
41
  end
42
42
 
43
43
  def page(payload = {})
44
- @http.post_model("/products/page", Inttegro::Models::PageProductsResponse, payload || {})
44
+ @http.post_model("/products/page", Inttegro::PageProductsResponse, payload || {})
45
45
  end
46
46
  end
47
47
  end
@@ -9,17 +9,17 @@ module Inttegro
9
9
  end
10
10
 
11
11
  def create(payload)
12
- @http.post_model("/purchase_intents/create", Inttegro::Models::PurchaseIntentResponse, payload)
12
+ @http.post_model("/purchase_intents/create", Inttegro::PurchaseIntentResponse, payload)
13
13
  end
14
14
 
15
15
  def update(payload)
16
- @http.post_model("/purchase_intents/update", Inttegro::Models::PurchaseIntentResponse, payload)
16
+ @http.post_model("/purchase_intents/update", Inttegro::PurchaseIntentResponse, payload)
17
17
  end
18
18
 
19
19
  def cancel(id:)
20
20
  @http.post_model(
21
21
  "/purchase_intents/cancel",
22
- Inttegro::Models::PurchaseIntentResponse,
22
+ Inttegro::PurchaseIntentResponse,
23
23
  { id: id }
24
24
  )
25
25
  end
@@ -27,7 +27,7 @@ module Inttegro
27
27
  def lookup(id:)
28
28
  @http.post_model(
29
29
  "/purchase_intents/lookup",
30
- Inttegro::Models::PurchaseIntentResponse,
30
+ Inttegro::PurchaseIntentResponse,
31
31
  { id: id }
32
32
  )
33
33
  end
@@ -35,7 +35,7 @@ module Inttegro
35
35
  def page(payload = {})
36
36
  @http.post_model(
37
37
  "/purchase_intents/page",
38
- Inttegro::Models::PagePurchaseIntentsResponse,
38
+ Inttegro::PagePurchaseIntentsResponse,
39
39
  payload || {}
40
40
  )
41
41
  end
@@ -9,13 +9,13 @@ module Inttegro
9
9
  end
10
10
 
11
11
  def create(payload)
12
- @http.post_model("/refunds/create", Inttegro::Models::RefundResponse, payload)
12
+ @http.post_model("/refunds/create", Inttegro::RefundResponse, payload)
13
13
  end
14
14
 
15
15
  def cancel(refund_id:)
16
16
  @http.post_model(
17
17
  "/refunds/cancel",
18
- Inttegro::Models::RefundResponse,
18
+ Inttegro::RefundResponse,
19
19
  { refund_id: refund_id }
20
20
  )
21
21
  end
@@ -23,13 +23,13 @@ module Inttegro
23
23
  def lookup(refund_id:)
24
24
  @http.post_model(
25
25
  "/refunds/lookup",
26
- Inttegro::Models::RefundResponse,
26
+ Inttegro::RefundResponse,
27
27
  { refund_id: refund_id }
28
28
  )
29
29
  end
30
30
 
31
31
  def page(payload)
32
- @http.post_model("/refunds/page", Inttegro::Models::RefundPageResponse, payload)
32
+ @http.post_model("/refunds/page", Inttegro::RefundPageResponse, payload)
33
33
  end
34
34
  end
35
35
  end
@@ -11,7 +11,7 @@ module Inttegro
11
11
  def lookup(schedule_id:)
12
12
  @http.post_model(
13
13
  "/schedules/lookup",
14
- Inttegro::Models::ScheduleLookupResponse,
14
+ Inttegro::ScheduleLookupResponse,
15
15
  { schedule_id: schedule_id }
16
16
  )
17
17
  end
@@ -19,7 +19,7 @@ module Inttegro
19
19
  def cancel(schedule_id:)
20
20
  @http.post_model(
21
21
  "/schedules/cancel",
22
- Inttegro::Models::ScheduleCancelResponse,
22
+ Inttegro::ScheduleCancelResponse,
23
23
  { schedule_id: schedule_id }
24
24
  )
25
25
  end
@@ -9,7 +9,7 @@ module Inttegro
9
9
  end
10
10
 
11
11
  def countries
12
- @http.post_model("/spec/countries", Inttegro::Models::ListCountrySpecsResponse, {})
12
+ @http.post_model("/spec/countries", Inttegro::ListCountrySpecsResponse, {})
13
13
  end
14
14
  end
15
15
  end
@@ -11,7 +11,7 @@ module Inttegro
11
11
  def create(payload, idempotency_key: nil)
12
12
  @http.post_model(
13
13
  "/upload_requests/create",
14
- Inttegro::Models::UploadRequestResponse,
14
+ Inttegro::UploadRequestResponse,
15
15
  payload,
16
16
  headers: headers(idempotency_key)
17
17
  )
@@ -20,19 +20,19 @@ module Inttegro
20
20
  def lookup(id:)
21
21
  @http.post_model(
22
22
  "/upload_requests/lookup",
23
- Inttegro::Models::UploadRequestWithAttemptResponse,
23
+ Inttegro::UploadRequestWithAttemptResponse,
24
24
  { id: id }
25
25
  )
26
26
  end
27
27
 
28
28
  def page(payload = {})
29
- @http.post_model("/upload_requests/page", Inttegro::Models::UploadRequestPageResponse, payload || {})
29
+ @http.post_model("/upload_requests/page", Inttegro::UploadRequestPageResponse, payload || {})
30
30
  end
31
31
 
32
32
  def cancel(payload, idempotency_key: nil)
33
33
  @http.post_model(
34
34
  "/upload_requests/cancel",
35
- Inttegro::Models::UploadRequestResponse,
35
+ Inttegro::UploadRequestResponse,
36
36
  payload,
37
37
  headers: headers(idempotency_key)
38
38
  )
@@ -41,7 +41,7 @@ module Inttegro
41
41
  def review(payload, idempotency_key: nil)
42
42
  @http.post_model(
43
43
  "/upload_requests/review",
44
- Inttegro::Models::UploadRequestWithAttemptResponse,
44
+ Inttegro::UploadRequestWithAttemptResponse,
45
45
  payload,
46
46
  headers: headers(idempotency_key)
47
47
  )
@@ -50,7 +50,7 @@ module Inttegro
50
50
  def fulfill(upload_url:, file:)
51
51
  @http.post_multipart_model(
52
52
  upload_url,
53
- Inttegro::Models::FulfillUploadRequestResponse,
53
+ Inttegro::FulfillUploadRequestResponse,
54
54
  files: { file: file },
55
55
  authenticated: false
56
56
  )
@@ -30,7 +30,7 @@ module Inttegro
30
30
 
31
31
  sig { params(klass: T::Class[T::Struct]).returns(T::Struct) }
32
32
  def deserialize(klass)
33
- Inttegro::Models.deserialize(to_h, klass)
33
+ Inttegro.deserialize(to_h, klass)
34
34
  end
35
35
 
36
36
  sig { params(name: Symbol, include_private: T::Boolean).returns(T::Boolean) }
@@ -2,5 +2,5 @@
2
2
  # typed: strict
3
3
 
4
4
  module Inttegro
5
- VERSION = "1.0.0"
5
+ VERSION = "2.0.0"
6
6
  end