inttegro 7.0.0 → 8.1.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +16 -0
- data/lib/inttegro/checkout/invoice_view.rb +8 -0
- data/lib/inttegro/checkout/order_line_item_group.rb +23 -0
- data/lib/inttegro/chime/chime.rb +3 -2
- data/lib/inttegro/chime/send_request.rb +12 -2
- data/lib/inttegro/chime/send_request_cooldown.rb +35 -0
- data/lib/inttegro/chime/transport.rb +2 -1
- data/lib/inttegro/custom_data.rb +132 -0
- data/lib/inttegro/customer/create_request.rb +3 -2
- data/lib/inttegro/customer/customer.rb +3 -2
- data/lib/inttegro/customer/data.rb +3 -2
- data/lib/inttegro/customer/update_request.rb +3 -2
- data/lib/inttegro/file/file.rb +3 -2
- data/lib/inttegro/file_link/create_request.rb +3 -2
- data/lib/inttegro/file_link/file_link.rb +3 -2
- data/lib/inttegro/financial_account/bank_request.rb +3 -2
- data/lib/inttegro/financial_account/connected.rb +3 -2
- data/lib/inttegro/financial_account/created.rb +3 -2
- data/lib/inttegro/financial_account/details.rb +3 -2
- data/lib/inttegro/financial_account/dosh_request.rb +3 -2
- data/lib/inttegro/financial_account/financial_account.rb +3 -2
- data/lib/inttegro/financial_account/request_base.rb +3 -2
- data/lib/inttegro/financial_account/update_request.rb +3 -2
- data/lib/inttegro/financial_account/updated.rb +3 -2
- data/lib/inttegro/financial_account/wallet_request.rb +3 -2
- data/lib/inttegro/financial_account/wire_page_accounts_item.rb +3 -2
- data/lib/inttegro/generated/enums.rb +17 -1
- data/lib/inttegro/generated/models.rb +36 -0
- data/lib/inttegro/generated/operations.rb +18 -3
- data/lib/inttegro/http_client.rb +1 -1
- data/lib/inttegro/model_serialization.rb +30 -1
- data/lib/inttegro/order/create_existing_customer.rb +26 -2
- data/lib/inttegro/order/create_new_customer.rb +26 -2
- data/lib/inttegro/order/document_delivery_attempt.rb +7 -0
- data/lib/inttegro/order/document_delivery_channel_summary.rb +34 -0
- data/lib/inttegro/order/document_delivery_summary.rb +43 -0
- data/lib/inttegro/order/document_delivery_summary_channels.rb +36 -0
- data/lib/inttegro/order/invoice.rb +8 -0
- data/lib/inttegro/order/invoice_format.rb +3 -2
- data/lib/inttegro/order/line_item_group.rb +25 -0
- data/lib/inttegro/order/order.rb +3 -2
- data/lib/inttegro/order/product_line_item_product.rb +3 -2
- data/lib/inttegro/order/receipt_document_format.rb +35 -0
- data/lib/inttegro/order/update_request.rb +26 -2
- data/lib/inttegro/otp/initiate_request.rb +35 -8
- data/lib/inttegro/otp/purpose.rb +62 -0
- data/lib/inttegro/otp/transmission.rb +4 -4
- data/lib/inttegro/otp/transmission_status.rb +9 -0
- data/lib/inttegro/otp/verify_request.rb +2 -1
- data/lib/inttegro/payment_method/payment_method.rb +14 -2
- data/lib/inttegro/payment_method/tokenize_base.rb +3 -2
- data/lib/inttegro/payment_method/tokenize_mobile_money_request.rb +3 -2
- data/lib/inttegro/payment_method/update_request.rb +3 -2
- data/lib/inttegro/payout/payout.rb +3 -2
- data/lib/inttegro/price/embedded_product.rb +3 -2
- data/lib/inttegro/product/create_request.rb +3 -2
- data/lib/inttegro/product/inline_details.rb +3 -2
- data/lib/inttegro/product/product.rb +3 -2
- data/lib/inttegro/product/update_request.rb +3 -2
- data/lib/inttegro/product/updated.rb +3 -2
- data/lib/inttegro/purchase_intent/product.rb +3 -2
- data/lib/inttegro/refund/create_request.rb +3 -2
- data/lib/inttegro/refund/failure.rb +45 -0
- data/lib/inttegro/refund/failure_reason.rb +49 -0
- data/lib/inttegro/refund/line_item.rb +31 -1
- data/lib/inttegro/refund/offline_settlement.rb +28 -0
- data/lib/inttegro/{otp/transmission_sent_via.rb → refund/offline_settlement_type.rb} +6 -6
- data/lib/inttegro/refund/order_fee_line_item.rb +43 -0
- data/lib/inttegro/refund/order_fee_line_item_fee.rb +34 -0
- data/lib/inttegro/refund/order_fee_line_item_type.rb +25 -0
- data/lib/inttegro/refund/order_line_item.rb +20 -0
- data/lib/inttegro/refund/order_product_line_item.rb +50 -0
- data/lib/inttegro/refund/order_product_line_item_product.rb +34 -0
- data/lib/inttegro/refund/order_product_line_item_type.rb +25 -0
- data/lib/inttegro/refund/order_shipping_line_item.rb +43 -0
- data/lib/inttegro/refund/order_shipping_line_item_shipping.rb +34 -0
- data/lib/inttegro/refund/order_shipping_line_item_type.rb +25 -0
- data/lib/inttegro/refund/payment_method_settlement.rb +55 -0
- data/lib/inttegro/refund/payment_method_settlement_type.rb +24 -0
- data/lib/inttegro/refund/refund.rb +39 -2
- data/lib/inttegro/refund/settlement.rb +19 -0
- data/lib/inttegro/refund/settlement_bank_account_payment_method.rb +44 -0
- data/lib/inttegro/refund/settlement_bank_account_payment_method_bank_account.rb +37 -0
- data/lib/inttegro/refund/settlement_bank_account_payment_method_bank_account_ghana_bank_account.rb +35 -0
- data/lib/inttegro/refund/settlement_bank_account_payment_method_type.rb +25 -0
- data/lib/inttegro/refund/settlement_mobile_money_payment_method.rb +44 -0
- data/lib/inttegro/refund/settlement_mobile_money_payment_method_mobile_money.rb +43 -0
- data/lib/inttegro/refund/settlement_mobile_money_payment_method_type.rb +25 -0
- data/lib/inttegro/refund/settlement_payment_method.rb +19 -0
- data/lib/inttegro/resources/customers.rb +8 -0
- data/lib/inttegro/resources/financial_accounts.rb +12 -0
- data/lib/inttegro/resources/orders.rb +8 -0
- data/lib/inttegro/resources/payouts.rb +8 -0
- data/lib/inttegro/resources/products.rb +8 -0
- data/lib/inttegro/search/base.rb +17 -0
- data/lib/inttegro/search/facet.rb +34 -0
- data/lib/inttegro/search/facet_bucket.rb +34 -0
- data/lib/inttegro/search/facet_result.rb +35 -0
- data/lib/inttegro/search/filter.rb +42 -0
- data/lib/inttegro/search/filter_operator.rb +27 -0
- data/lib/inttegro/search/freshness.rb +43 -0
- data/lib/inttegro/search/freshness_state.rb +36 -0
- data/lib/inttegro/search/page.rb +104 -0
- data/lib/inttegro/search/request.rb +68 -0
- data/lib/inttegro/search/resource_freshness.rb +50 -0
- data/lib/inttegro/search/resource_freshness_state.rb +37 -0
- data/lib/inttegro/search/resource_reference.rb +35 -0
- data/lib/inttegro/search/resource_total.rb +43 -0
- data/lib/inttegro/search/resource_total_relation.rb +28 -0
- data/lib/inttegro/search/response.rb +28 -0
- data/lib/inttegro/search/result.rb +78 -0
- data/lib/inttegro/search/sort.rb +36 -0
- data/lib/inttegro/search/sort_direction.rb +27 -0
- data/lib/inttegro/search/sort_field.rb +30 -0
- data/lib/inttegro/search/total.rb +35 -0
- data/lib/inttegro/search/total_relation.rb +27 -0
- data/lib/inttegro/search/type.rb +36 -0
- data/lib/inttegro/shared/fee_details.rb +3 -2
- data/lib/inttegro/shared/invoice_settings.rb +3 -2
- data/lib/inttegro/shared/shipping_details.rb +3 -2
- data/lib/inttegro/telemetry.rb +1 -1
- data/lib/inttegro/upload_request/create_request.rb +3 -2
- data/lib/inttegro/upload_request/details.rb +3 -2
- data/lib/inttegro/upload_request/upload_request.rb +3 -2
- data/lib/inttegro/version.rb +1 -1
- data/lib/inttegro.rb +1 -0
- data/rbi/inttegro/generated.rbi +15 -0
- metadata +57 -3
|
@@ -31,6 +31,31 @@ module Inttegro
|
|
|
31
31
|
class LineItemGroup < T::Struct
|
|
32
32
|
const :line_items, T::Array[Inttegro::Order::LineItem]
|
|
33
33
|
const :total, Inttegro::Money::Amount
|
|
34
|
+
|
|
35
|
+
extend T::Sig
|
|
36
|
+
|
|
37
|
+
sig { params(hash: T::Hash[String, Object], strict: T::Boolean).returns(T.attached_class) }
|
|
38
|
+
def self.from_hash(hash, strict = false)
|
|
39
|
+
data = hash.dup
|
|
40
|
+
if (line_items_value = data["line_items"]).is_a?(Array)
|
|
41
|
+
data["line_items"] = line_items_value.map do |item|
|
|
42
|
+
next item unless item.is_a?(Hash)
|
|
43
|
+
case item["type"]
|
|
44
|
+
when "product"
|
|
45
|
+
Inttegro::Order::ProductLineItem.from_hash(item)
|
|
46
|
+
when "fee"
|
|
47
|
+
Inttegro::Order::FeeLineItem.from_hash(item)
|
|
48
|
+
when "shipping"
|
|
49
|
+
Inttegro::Order::ShippingLineItem.from_hash(item)
|
|
50
|
+
when "discount"
|
|
51
|
+
Inttegro::Order::DiscountLineItem.from_hash(item)
|
|
52
|
+
else
|
|
53
|
+
item
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
end
|
|
57
|
+
super(data, strict)
|
|
58
|
+
end
|
|
34
59
|
end
|
|
35
60
|
end
|
|
36
61
|
end
|
data/lib/inttegro/order/order.rb
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "../payment/payment"
|
|
8
9
|
require_relative "../refund/refund"
|
|
9
10
|
require_relative "../shared/invoice_settings"
|
|
@@ -53,7 +54,7 @@ module Inttegro
|
|
|
53
54
|
# collection rather than a raw map.
|
|
54
55
|
#
|
|
55
56
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
56
|
-
# @return [
|
|
57
|
+
# @return [Inttegro::CustomData, nil]
|
|
57
58
|
#
|
|
58
59
|
# @!attribute [r] customer
|
|
59
60
|
# Value of the `customer` field in the Inttegro API payload.
|
|
@@ -156,7 +157,7 @@ module Inttegro
|
|
|
156
157
|
const :checkout_settings, T.nilable(Inttegro::Order::CheckoutSettings), default: nil
|
|
157
158
|
const :completed_at, T.nilable(Time), default: nil
|
|
158
159
|
const :created_from, T.nilable(Inttegro::Order::CreatedFrom), default: nil
|
|
159
|
-
const :custom_data, T.nilable(
|
|
160
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
160
161
|
const :customer, Inttegro::Order::Customer
|
|
161
162
|
const :expires_at, T.nilable(Time), default: nil
|
|
162
163
|
const :id, String
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "../price/price"
|
|
8
9
|
|
|
9
10
|
module Inttegro
|
|
@@ -51,7 +52,7 @@ module Inttegro
|
|
|
51
52
|
# collection rather than a raw map.
|
|
52
53
|
#
|
|
53
54
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
54
|
-
# @return [
|
|
55
|
+
# @return [Inttegro::CustomData, nil]
|
|
55
56
|
#
|
|
56
57
|
# @!attribute [r] tax_code
|
|
57
58
|
# Value of the `tax_code` field in the Inttegro API payload.
|
|
@@ -94,7 +95,7 @@ module Inttegro
|
|
|
94
95
|
const :price_id, T.nilable(String), default: nil
|
|
95
96
|
const :reference, T.nilable(String), default: nil
|
|
96
97
|
const :about, T.nilable(String), default: nil
|
|
97
|
-
const :custom_data, T.nilable(
|
|
98
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
98
99
|
const :tax_code, T.nilable(String), default: nil
|
|
99
100
|
const :name, String
|
|
100
101
|
const :category, T.nilable(String), default: nil
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
# typed: strict
|
|
3
|
+
|
|
4
|
+
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
|
+
|
|
6
|
+
require_relative "base"
|
|
7
|
+
require_relative "document_delivery_summary"
|
|
8
|
+
|
|
9
|
+
module Inttegro
|
|
10
|
+
class Order
|
|
11
|
+
# Typed representation of the receipt document format object in the Inttegro API.
|
|
12
|
+
#
|
|
13
|
+
# This generated model is immutable. Construct it with `.new`, or decode a string-keyed API
|
|
14
|
+
# payload with `.from_hash`. `#serialize` produces a string-keyed hash using the original wire
|
|
15
|
+
# field names and serialized enum values.
|
|
16
|
+
#
|
|
17
|
+
# @api public
|
|
18
|
+
#
|
|
19
|
+
# @!attribute [r] delivery_summary
|
|
20
|
+
# Bounded aggregate of Chime-accepted sends for one generated order document.
|
|
21
|
+
#
|
|
22
|
+
# Optional in the API payload; omitted values default to `nil`. Wire name: `delivery_summary`.
|
|
23
|
+
# @return [Inttegro::Order::DocumentDeliverySummary, nil]
|
|
24
|
+
#
|
|
25
|
+
# @!attribute [r] url
|
|
26
|
+
# Value of the `url` field in the Inttegro API payload.
|
|
27
|
+
#
|
|
28
|
+
# Required in the API payload. Wire name: `url`.
|
|
29
|
+
# @return [String]
|
|
30
|
+
class ReceiptDocumentFormat < T::Struct
|
|
31
|
+
const :delivery_summary, T.nilable(Inttegro::Order::DocumentDeliverySummary), default: nil
|
|
32
|
+
const :url, String
|
|
33
|
+
end
|
|
34
|
+
end
|
|
35
|
+
end
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "../shared/invoice_settings"
|
|
8
9
|
require_relative "../shared/line_item"
|
|
9
10
|
require_relative "update_request_payment_method_data"
|
|
@@ -30,7 +31,7 @@ module Inttegro
|
|
|
30
31
|
# collection rather than a raw map.
|
|
31
32
|
#
|
|
32
33
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
33
|
-
# @return [
|
|
34
|
+
# @return [Inttegro::CustomData, nil]
|
|
34
35
|
#
|
|
35
36
|
# @!attribute [r] invoice_settings
|
|
36
37
|
# Order-level invoice rendering data. Pages uses this data when rendering invoice web and
|
|
@@ -101,7 +102,7 @@ module Inttegro
|
|
|
101
102
|
# @return [String, nil]
|
|
102
103
|
class UpdateRequest < T::Struct
|
|
103
104
|
const :clear_payment_method, T.nilable(T::Boolean), default: nil
|
|
104
|
-
const :custom_data, T.nilable(
|
|
105
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
105
106
|
const :invoice_settings, T.nilable(Inttegro::Shared::InvoiceSettings), default: nil
|
|
106
107
|
const :finalize, T.nilable(T::Boolean), default: nil
|
|
107
108
|
const :line_items, T.nilable(T::Array[Inttegro::Shared::LineItem]), default: nil
|
|
@@ -112,6 +113,29 @@ module Inttegro
|
|
|
112
113
|
const :payment_method_id, T.nilable(String), default: nil
|
|
113
114
|
const :statement_descriptor, T.nilable(String), default: nil
|
|
114
115
|
const :statement_descriptor_prefix, T.nilable(String), default: nil
|
|
116
|
+
|
|
117
|
+
extend T::Sig
|
|
118
|
+
|
|
119
|
+
sig { params(hash: T::Hash[String, Object], strict: T::Boolean).returns(T.attached_class) }
|
|
120
|
+
def self.from_hash(hash, strict = false)
|
|
121
|
+
data = hash.dup
|
|
122
|
+
if (line_items_value = data["line_items"]).is_a?(Array)
|
|
123
|
+
data["line_items"] = line_items_value.map do |item|
|
|
124
|
+
next item unless item.is_a?(Hash)
|
|
125
|
+
case item["type"]
|
|
126
|
+
when "product"
|
|
127
|
+
Inttegro::Product::LineItem.from_hash(item)
|
|
128
|
+
when "fee"
|
|
129
|
+
Inttegro::Shared::FeeLineItem.from_hash(item)
|
|
130
|
+
when "shipping"
|
|
131
|
+
Inttegro::Shared::ShippingLineItem.from_hash(item)
|
|
132
|
+
else
|
|
133
|
+
item
|
|
134
|
+
end
|
|
135
|
+
end
|
|
136
|
+
end
|
|
137
|
+
super(data, strict)
|
|
138
|
+
end
|
|
115
139
|
end
|
|
116
140
|
end
|
|
117
141
|
end
|
|
@@ -4,7 +4,9 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../chime/transport"
|
|
7
8
|
require_relative "alphabet_type"
|
|
9
|
+
require_relative "purpose"
|
|
8
10
|
|
|
9
11
|
module Inttegro
|
|
10
12
|
module OTP
|
|
@@ -17,31 +19,47 @@ module Inttegro
|
|
|
17
19
|
# @api public
|
|
18
20
|
#
|
|
19
21
|
# @!attribute [r] async_delivery
|
|
20
|
-
# Return after accepting the transaction while
|
|
22
|
+
# Return after accepting the transaction while delivery continues asynchronously.
|
|
21
23
|
#
|
|
22
24
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `async_delivery`.
|
|
23
25
|
# @return [Boolean, nil]
|
|
24
26
|
#
|
|
25
27
|
# @!attribute [r] message_template
|
|
26
|
-
# SMS
|
|
28
|
+
# SMS body or email copy containing the required `{token}` placeholder and optional
|
|
29
|
+
# `{service}` placeholder. Email templates must contain `{token}` exactly once. A custom
|
|
30
|
+
# template replaces the purpose-specific default body, while `purpose` still controls the
|
|
31
|
+
# email subject and heading. Email sends this as the plain-text fallback and renders the copy
|
|
32
|
+
# around a prominent code in the HTML version. Defaults are transport-specific.
|
|
27
33
|
#
|
|
28
34
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `message_template`.
|
|
29
35
|
# @return [String, nil]
|
|
30
36
|
#
|
|
31
|
-
# @!attribute [r]
|
|
32
|
-
#
|
|
37
|
+
# @!attribute [r] preferred_gateway
|
|
38
|
+
# Optional SMS gateway; not valid for email OTP delivery. Email uses the configured default
|
|
39
|
+
# provider.
|
|
33
40
|
#
|
|
34
|
-
# Optional in the API payload; omitted values default to `nil`. Wire name: `
|
|
41
|
+
# Optional in the API payload; omitted values default to `nil`. Wire name: `preferred_gateway`.
|
|
35
42
|
# @return [String, nil]
|
|
36
43
|
#
|
|
44
|
+
# @!attribute [r] purpose
|
|
45
|
+
# Customer action protected by the OTP. Controls safe, purpose-specific default email copy.
|
|
46
|
+
# Unknown values are rejected; use `unspecified` explicitly for a general verification
|
|
47
|
+
# request.
|
|
48
|
+
#
|
|
49
|
+
# Required in the API payload. Wire name: `purpose`.
|
|
50
|
+
# @return [Inttegro::OTP::Purpose]
|
|
51
|
+
#
|
|
37
52
|
# @!attribute [r] recipient
|
|
38
|
-
# Phone number in international format (E.164)
|
|
53
|
+
# Phone number in international format (E.164) or bare email address. Transport is inferred
|
|
54
|
+
# from the address unless specified.
|
|
39
55
|
#
|
|
40
56
|
# Required in the API payload. Wire name: `recipient`.
|
|
41
57
|
# @return [String]
|
|
42
58
|
#
|
|
43
59
|
# @!attribute [r] sender
|
|
44
|
-
# Optional sender identifier
|
|
60
|
+
# Optional SMS sender identifier (3-12 characters). Email OTP always uses `{service_name}
|
|
61
|
+
# <noreply@inttegro.com>`; omit this field for email or supply exactly the bare
|
|
62
|
+
# `noreply@inttegro.com` address.
|
|
45
63
|
#
|
|
46
64
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `sender`.
|
|
47
65
|
# @return [String, nil]
|
|
@@ -70,6 +88,13 @@ module Inttegro
|
|
|
70
88
|
# Required in the API payload. Wire name: `token_size`.
|
|
71
89
|
# @return [Integer]
|
|
72
90
|
#
|
|
91
|
+
# @!attribute [r] transport
|
|
92
|
+
# Optional delivery transport. When omitted, an email address selects email and a phone number
|
|
93
|
+
# selects SMS.
|
|
94
|
+
#
|
|
95
|
+
# Optional in the API payload; omitted values default to `nil`. Wire name: `transport`.
|
|
96
|
+
# @return [Inttegro::Chime::Transport, nil]
|
|
97
|
+
#
|
|
73
98
|
# @!attribute [r] validity_duration_in_minutes
|
|
74
99
|
# How long the token remains valid (3-10080 minutes)
|
|
75
100
|
#
|
|
@@ -78,13 +103,15 @@ module Inttegro
|
|
|
78
103
|
class InitiateRequest < T::Struct
|
|
79
104
|
const :async_delivery, T.nilable(T::Boolean), default: nil
|
|
80
105
|
const :message_template, T.nilable(String), default: nil
|
|
81
|
-
const :
|
|
106
|
+
const :preferred_gateway, T.nilable(String), default: nil
|
|
107
|
+
const :purpose, Inttegro::OTP::Purpose
|
|
82
108
|
const :recipient, String
|
|
83
109
|
const :sender, T.nilable(String), default: nil
|
|
84
110
|
const :service_name, String
|
|
85
111
|
const :token_alphabet, T.nilable(String), default: nil
|
|
86
112
|
const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil
|
|
87
113
|
const :token_size, Integer
|
|
114
|
+
const :transport, T.nilable(Inttegro::Chime::Transport), default: nil
|
|
88
115
|
const :validity_duration_in_minutes, T.nilable(Integer), default: nil
|
|
89
116
|
end
|
|
90
117
|
end
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
# typed: strict
|
|
3
|
+
|
|
4
|
+
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
|
+
|
|
6
|
+
require_relative "base"
|
|
7
|
+
|
|
8
|
+
module Inttegro
|
|
9
|
+
module OTP
|
|
10
|
+
# Customer action protected by the OTP. Controls safe, purpose-specific default email copy.
|
|
11
|
+
# Unknown values are rejected; use `unspecified` explicitly for a general verification
|
|
12
|
+
# request.
|
|
13
|
+
#
|
|
14
|
+
# Use the constants below when constructing a request. `#serialize` returns the documented
|
|
15
|
+
# string wire value received from or sent to the API.
|
|
16
|
+
#
|
|
17
|
+
# @api public
|
|
18
|
+
class Purpose < T::Enum
|
|
19
|
+
enums do
|
|
20
|
+
# Serialized wire value: `account_creation`.
|
|
21
|
+
# @return [Inttegro::OTP::Purpose]
|
|
22
|
+
ACCOUNT_CREATION = new("account_creation")
|
|
23
|
+
# Serialized wire value: `account_recovery`.
|
|
24
|
+
# @return [Inttegro::OTP::Purpose]
|
|
25
|
+
ACCOUNT_RECOVERY = new("account_recovery")
|
|
26
|
+
# Serialized wire value: `email_verification`.
|
|
27
|
+
# @return [Inttegro::OTP::Purpose]
|
|
28
|
+
EMAIL_VERIFICATION = new("email_verification")
|
|
29
|
+
# Serialized wire value: `financial_account_verification`.
|
|
30
|
+
# @return [Inttegro::OTP::Purpose]
|
|
31
|
+
FINANCIAL_ACCOUNT_VERIFICATION = new("financial_account_verification")
|
|
32
|
+
# Serialized wire value: `password_reset`.
|
|
33
|
+
# @return [Inttegro::OTP::Purpose]
|
|
34
|
+
PASSWORD_RESET = new("password_reset")
|
|
35
|
+
# Serialized wire value: `payment_confirmation`.
|
|
36
|
+
# @return [Inttegro::OTP::Purpose]
|
|
37
|
+
PAYMENT_CONFIRMATION = new("payment_confirmation")
|
|
38
|
+
# Serialized wire value: `payment_method_verification`.
|
|
39
|
+
# @return [Inttegro::OTP::Purpose]
|
|
40
|
+
PAYMENT_METHOD_VERIFICATION = new("payment_method_verification")
|
|
41
|
+
# Serialized wire value: `payout_confirmation`.
|
|
42
|
+
# @return [Inttegro::OTP::Purpose]
|
|
43
|
+
PAYOUT_CONFIRMATION = new("payout_confirmation")
|
|
44
|
+
# Serialized wire value: `phone_verification`.
|
|
45
|
+
# @return [Inttegro::OTP::Purpose]
|
|
46
|
+
PHONE_VERIFICATION = new("phone_verification")
|
|
47
|
+
# Serialized wire value: `sensitive_action`.
|
|
48
|
+
# @return [Inttegro::OTP::Purpose]
|
|
49
|
+
SENSITIVE_ACTION = new("sensitive_action")
|
|
50
|
+
# Serialized wire value: `sign_in`.
|
|
51
|
+
# @return [Inttegro::OTP::Purpose]
|
|
52
|
+
SIGN_IN = new("sign_in")
|
|
53
|
+
# Serialized wire value: `transaction_confirmation`.
|
|
54
|
+
# @return [Inttegro::OTP::Purpose]
|
|
55
|
+
TRANSACTION_CONFIRMATION = new("transaction_confirmation")
|
|
56
|
+
# Serialized wire value: `unspecified`.
|
|
57
|
+
# @return [Inttegro::OTP::Purpose]
|
|
58
|
+
UNSPECIFIED = new("unspecified")
|
|
59
|
+
end
|
|
60
|
+
end
|
|
61
|
+
end
|
|
62
|
+
end
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
-
require_relative "
|
|
7
|
+
require_relative "../chime/transport"
|
|
8
8
|
require_relative "transmission_status"
|
|
9
9
|
|
|
10
10
|
module Inttegro
|
|
@@ -24,7 +24,7 @@ module Inttegro
|
|
|
24
24
|
# @return [String]
|
|
25
25
|
#
|
|
26
26
|
# @!attribute [r] sender_id
|
|
27
|
-
#
|
|
27
|
+
# SMS sender identifier or approved email From address.
|
|
28
28
|
#
|
|
29
29
|
# Required in the API payload. Wire name: `sender_id`.
|
|
30
30
|
# @return [String]
|
|
@@ -39,7 +39,7 @@ module Inttegro
|
|
|
39
39
|
# Value of the `sent_via` field in the Inttegro API payload.
|
|
40
40
|
#
|
|
41
41
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `sent_via`.
|
|
42
|
-
# @return [Inttegro::
|
|
42
|
+
# @return [Inttegro::Chime::Transport, nil]
|
|
43
43
|
#
|
|
44
44
|
# @!attribute [r] status
|
|
45
45
|
# Value of the `status` field in the Inttegro API payload.
|
|
@@ -50,7 +50,7 @@ module Inttegro
|
|
|
50
50
|
const :recipient, String
|
|
51
51
|
const :sender_id, String
|
|
52
52
|
const :sent_at, T.nilable(Time), default: nil
|
|
53
|
-
const :sent_via, T.nilable(Inttegro::
|
|
53
|
+
const :sent_via, T.nilable(Inttegro::Chime::Transport), default: nil
|
|
54
54
|
const :status, T.nilable(Inttegro::OTP::TransmissionStatus), default: nil
|
|
55
55
|
end
|
|
56
56
|
end
|
|
@@ -15,12 +15,21 @@ module Inttegro
|
|
|
15
15
|
# @api public
|
|
16
16
|
class TransmissionStatus < T::Enum
|
|
17
17
|
enums do
|
|
18
|
+
# Serialized wire value: `accepted`.
|
|
19
|
+
# @return [Inttegro::OTP::TransmissionStatus]
|
|
20
|
+
ACCEPTED = new("accepted")
|
|
18
21
|
# Serialized wire value: `delivered`.
|
|
19
22
|
# @return [Inttegro::OTP::TransmissionStatus]
|
|
20
23
|
DELIVERED = new("delivered")
|
|
21
24
|
# Serialized wire value: `failed`.
|
|
22
25
|
# @return [Inttegro::OTP::TransmissionStatus]
|
|
23
26
|
FAILED = new("failed")
|
|
27
|
+
# Serialized wire value: `queued`.
|
|
28
|
+
# @return [Inttegro::OTP::TransmissionStatus]
|
|
29
|
+
QUEUED = new("queued")
|
|
30
|
+
# Serialized wire value: `sent`.
|
|
31
|
+
# @return [Inttegro::OTP::TransmissionStatus]
|
|
32
|
+
SENT = new("sent")
|
|
24
33
|
# Serialized wire value: `submitted`.
|
|
25
34
|
# @return [Inttegro::OTP::TransmissionStatus]
|
|
26
35
|
SUBMITTED = new("submitted")
|
|
@@ -22,7 +22,8 @@ module Inttegro
|
|
|
22
22
|
# @return [String]
|
|
23
23
|
#
|
|
24
24
|
# @!attribute [r] recipient
|
|
25
|
-
# Phone number that received the OTP
|
|
25
|
+
# Phone number or bare email address that received the OTP; must match the stored transaction
|
|
26
|
+
# transport.
|
|
26
27
|
#
|
|
27
28
|
# Required in the API payload. Wire name: `recipient`.
|
|
28
29
|
# @return [String]
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "bank_account"
|
|
8
9
|
require_relative "card"
|
|
9
10
|
require_relative "mobile_money"
|
|
@@ -56,7 +57,7 @@ module Inttegro
|
|
|
56
57
|
# collection rather than a raw map.
|
|
57
58
|
#
|
|
58
59
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
59
|
-
# @return [
|
|
60
|
+
# @return [Inttegro::CustomData, nil]
|
|
60
61
|
#
|
|
61
62
|
# @!attribute [r] customer_id
|
|
62
63
|
# Customer who owns this payment method
|
|
@@ -76,6 +77,16 @@ module Inttegro
|
|
|
76
77
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `expires_on`.
|
|
77
78
|
# @return [Time, nil]
|
|
78
79
|
#
|
|
80
|
+
# @!attribute [r] fingerprint
|
|
81
|
+
# Customer-scoped fingerprint for this payment method within the merchant application.
|
|
82
|
+
# Matching nonempty values for the same customer indicate the same underlying method was added
|
|
83
|
+
# more than once. May be empty for records awaiting fingerprint backfill or methods lacking
|
|
84
|
+
# reliable fingerprint material. It does not identify the method across customers or
|
|
85
|
+
# applications.
|
|
86
|
+
#
|
|
87
|
+
# Required in the API payload. Wire name: `fingerprint`.
|
|
88
|
+
# @return [String]
|
|
89
|
+
#
|
|
79
90
|
# @!attribute [r] id
|
|
80
91
|
# Unique identifier for this payment method
|
|
81
92
|
#
|
|
@@ -123,10 +134,11 @@ module Inttegro
|
|
|
123
134
|
const :bank_account, T.nilable(Inttegro::PaymentMethod::BankAccount), default: nil
|
|
124
135
|
const :card, T.nilable(Inttegro::PaymentMethod::Card), default: nil
|
|
125
136
|
const :created_at, Time
|
|
126
|
-
const :custom_data, T.nilable(
|
|
137
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
127
138
|
const :customer_id, String
|
|
128
139
|
const :ephemeral, T.nilable(T::Boolean), default: nil
|
|
129
140
|
const :expires_on, T.nilable(Time), default: nil
|
|
141
|
+
const :fingerprint, String
|
|
130
142
|
const :id, String
|
|
131
143
|
const :mobile_money, T.nilable(Inttegro::PaymentMethod::MobileMoney), default: nil
|
|
132
144
|
const :owner, T.nilable(Inttegro::PaymentMethod::Owner), default: nil
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "tokenize_base_type"
|
|
8
9
|
|
|
9
10
|
module Inttegro
|
|
@@ -27,7 +28,7 @@ module Inttegro
|
|
|
27
28
|
# collection rather than a raw map.
|
|
28
29
|
#
|
|
29
30
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
30
|
-
# @return [
|
|
31
|
+
# @return [Inttegro::CustomData, nil]
|
|
31
32
|
#
|
|
32
33
|
# @!attribute [r] type
|
|
33
34
|
# Value of the `type` field in the Inttegro API payload.
|
|
@@ -36,7 +37,7 @@ module Inttegro
|
|
|
36
37
|
# @return [Inttegro::PaymentMethod::TokenizeBaseType]
|
|
37
38
|
class TokenizeBase < T::Struct
|
|
38
39
|
const :customer_id, String
|
|
39
|
-
const :custom_data, T.nilable(
|
|
40
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
40
41
|
const :type, Inttegro::PaymentMethod::TokenizeBaseType
|
|
41
42
|
end
|
|
42
43
|
end
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "owner_input"
|
|
8
9
|
require_relative "tokenize_mobile_money_request_mobile_money"
|
|
9
10
|
require_relative "tokenize_mobile_money_request_type"
|
|
@@ -29,7 +30,7 @@ module Inttegro
|
|
|
29
30
|
# collection rather than a raw map.
|
|
30
31
|
#
|
|
31
32
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
32
|
-
# @return [
|
|
33
|
+
# @return [Inttegro::CustomData, nil]
|
|
33
34
|
#
|
|
34
35
|
# @!attribute [r] type
|
|
35
36
|
# Value of the `type` field in the Inttegro API payload.
|
|
@@ -50,7 +51,7 @@ module Inttegro
|
|
|
50
51
|
# @return [Inttegro::PaymentMethod::OwnerInput]
|
|
51
52
|
class TokenizeMobileMoneyRequest < T::Struct
|
|
52
53
|
const :customer_id, String
|
|
53
|
-
const :custom_data, T.nilable(
|
|
54
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
54
55
|
const :type, Inttegro::PaymentMethod::TokenizeMobileMoneyRequestType
|
|
55
56
|
const :mobile_money, Inttegro::PaymentMethod::TokenizeMobileMoneyRequestMobileMoney
|
|
56
57
|
const :owner, Inttegro::PaymentMethod::OwnerInput
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "update_request_owner"
|
|
8
9
|
|
|
9
10
|
module Inttegro
|
|
@@ -27,7 +28,7 @@ module Inttegro
|
|
|
27
28
|
# serialized to a string.
|
|
28
29
|
#
|
|
29
30
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
30
|
-
# @return [
|
|
31
|
+
# @return [Inttegro::CustomDataPatch, nil]
|
|
31
32
|
#
|
|
32
33
|
# @!attribute [r] active
|
|
33
34
|
# Set to `true` to activate the payment method or `false` to mark it inactive.
|
|
@@ -48,7 +49,7 @@ module Inttegro
|
|
|
48
49
|
# @return [Inttegro::PaymentMethod::UpdateRequestOwner, nil]
|
|
49
50
|
class UpdateRequest < T::Struct
|
|
50
51
|
const :payment_method_id, String
|
|
51
|
-
const :custom_data, T.nilable(
|
|
52
|
+
const :custom_data, T.nilable(Inttegro::CustomDataPatch), default: nil
|
|
52
53
|
const :active, T.nilable(T::Boolean), default: nil
|
|
53
54
|
const :archived, T.nilable(T::Boolean), default: nil
|
|
54
55
|
const :owner, T.nilable(Inttegro::PaymentMethod::UpdateRequestOwner), default: nil
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "../money/amount"
|
|
8
9
|
require_relative "error"
|
|
9
10
|
require_relative "status"
|
|
@@ -40,7 +41,7 @@ module Inttegro
|
|
|
40
41
|
# collection rather than a raw map.
|
|
41
42
|
#
|
|
42
43
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
43
|
-
# @return [
|
|
44
|
+
# @return [Inttegro::CustomData, nil]
|
|
44
45
|
#
|
|
45
46
|
# @!attribute [r] destination_id
|
|
46
47
|
# Financial account receiving the funds
|
|
@@ -153,7 +154,7 @@ module Inttegro
|
|
|
153
154
|
const :amount, T.nilable(Inttegro::Money::Amount), default: nil
|
|
154
155
|
const :balance_transactions, T.nilable(T::Array[String]), default: nil
|
|
155
156
|
const :canceled_at, T.nilable(Time), default: nil
|
|
156
|
-
const :custom_data, T.nilable(
|
|
157
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
157
158
|
const :destination_id, String
|
|
158
159
|
const :error, T.nilable(Inttegro::Payout::Error), default: nil
|
|
159
160
|
const :execute_after, Time
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "../product/dimensions"
|
|
8
9
|
require_relative "../product/media"
|
|
9
10
|
require_relative "../product/shipment"
|
|
@@ -67,7 +68,7 @@ module Inttegro
|
|
|
67
68
|
# collection rather than a raw map.
|
|
68
69
|
#
|
|
69
70
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
70
|
-
# @return [
|
|
71
|
+
# @return [Inttegro::CustomData, nil]
|
|
71
72
|
#
|
|
72
73
|
# @!attribute [r] description
|
|
73
74
|
# Short description
|
|
@@ -142,7 +143,7 @@ module Inttegro
|
|
|
142
143
|
const :attributes, T.nilable(T::Array[Inttegro::PurchaseIntent::ProductAttributesItem]), default: nil
|
|
143
144
|
const :category, T.nilable(String), default: nil
|
|
144
145
|
const :created_at, Time
|
|
145
|
-
const :custom_data, T.nilable(
|
|
146
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
146
147
|
const :description, T.nilable(String), default: nil
|
|
147
148
|
const :dimensions, T.nilable(Inttegro::Product::Dimensions), default: nil
|
|
148
149
|
const :media, T.nilable(Inttegro::Product::Media), default: nil
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "attribute"
|
|
8
9
|
require_relative "dimensions"
|
|
9
10
|
require_relative "media"
|
|
@@ -103,7 +104,7 @@ module Inttegro
|
|
|
103
104
|
# collection rather than a raw map.
|
|
104
105
|
#
|
|
105
106
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
106
|
-
# @return [
|
|
107
|
+
# @return [Inttegro::CustomData, nil]
|
|
107
108
|
class CreateRequest < T::Struct
|
|
108
109
|
const :type, Inttegro::Product::Type
|
|
109
110
|
const :reference, T.nilable(String), default: nil
|
|
@@ -118,7 +119,7 @@ module Inttegro
|
|
|
118
119
|
const :media, T.nilable(Inttegro::Product::Media), default: nil
|
|
119
120
|
const :attributes, T.nilable(T::Array[Inttegro::Product::Attribute]), default: nil
|
|
120
121
|
const :publish, T.nilable(T::Boolean), default: nil
|
|
121
|
-
const :custom_data, T.nilable(
|
|
122
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
122
123
|
end
|
|
123
124
|
end
|
|
124
125
|
end
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "../price/price_params"
|
|
8
9
|
require_relative "type"
|
|
9
10
|
|
|
@@ -28,7 +29,7 @@ module Inttegro
|
|
|
28
29
|
# collection rather than a raw map.
|
|
29
30
|
#
|
|
30
31
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
31
|
-
# @return [
|
|
32
|
+
# @return [Inttegro::CustomData, nil]
|
|
32
33
|
#
|
|
33
34
|
# @!attribute [r] name
|
|
34
35
|
# Product name shown to the customer
|
|
@@ -67,7 +68,7 @@ module Inttegro
|
|
|
67
68
|
# @return [Inttegro::Product::Type]
|
|
68
69
|
class InlineDetails < T::Struct
|
|
69
70
|
const :about, T.nilable(String), default: nil
|
|
70
|
-
const :custom_data, T.nilable(
|
|
71
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
71
72
|
const :name, String
|
|
72
73
|
const :price, Inttegro::Price::PriceParams
|
|
73
74
|
const :quantity, Integer
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
# Generated from openapi/commerce.yml by bin/generate-openapi-types. Do not edit.
|
|
5
5
|
|
|
6
6
|
require_relative "base"
|
|
7
|
+
require_relative "../custom_data"
|
|
7
8
|
require_relative "attribute"
|
|
8
9
|
require_relative "dimensions"
|
|
9
10
|
require_relative "media"
|
|
@@ -103,7 +104,7 @@ module Inttegro
|
|
|
103
104
|
# collection rather than a raw map.
|
|
104
105
|
#
|
|
105
106
|
# Optional in the API payload; omitted values default to `nil`. Wire name: `custom_data`.
|
|
106
|
-
# @return [
|
|
107
|
+
# @return [Inttegro::CustomData, nil]
|
|
107
108
|
#
|
|
108
109
|
# @!attribute [r] active
|
|
109
110
|
# Whether product is published and available
|
|
@@ -154,7 +155,7 @@ module Inttegro
|
|
|
154
155
|
const :media, T.nilable(Inttegro::Product::Media), default: nil
|
|
155
156
|
const :attributes, T.nilable(T::Array[Inttegro::Product::Attribute]), default: nil
|
|
156
157
|
const :dimensions, T.nilable(Inttegro::Product::Dimensions), default: nil
|
|
157
|
-
const :custom_data, T.nilable(
|
|
158
|
+
const :custom_data, T.nilable(Inttegro::CustomData), default: nil
|
|
158
159
|
const :active, T::Boolean
|
|
159
160
|
const :created_at, Time
|
|
160
161
|
const :updated_at, T.nilable(Time), default: nil
|