sumup 0.0.1
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 +7 -0
- data/CHANGELOG.md +18 -0
- data/LICENSE +201 -0
- data/README.md +188 -0
- data/lib/sumup/client.rb +213 -0
- data/lib/sumup/errors.rb +45 -0
- data/lib/sumup/event_types.rb +115 -0
- data/lib/sumup/events.rb +168 -0
- data/lib/sumup/model.rb +109 -0
- data/lib/sumup/pagination.rb +92 -0
- data/lib/sumup/resource.rb +36 -0
- data/lib/sumup/resources/checkouts.rb +155 -0
- data/lib/sumup/resources/customers.rb +89 -0
- data/lib/sumup/resources/members.rb +93 -0
- data/lib/sumup/resources/memberships.rb +23 -0
- data/lib/sumup/resources/merchants.rb +51 -0
- data/lib/sumup/resources/payouts.rb +29 -0
- data/lib/sumup/resources/readers.rb +264 -0
- data/lib/sumup/resources/receipts.rb +23 -0
- data/lib/sumup/resources/roles.rb +89 -0
- data/lib/sumup/resources/sales.rb +66 -0
- data/lib/sumup/resources/tokens.rb +31 -0
- data/lib/sumup/resources/transactions.rb +61 -0
- data/lib/sumup/resources.rb +83 -0
- data/lib/sumup/transport.rb +40 -0
- data/lib/sumup/types.rb +4720 -0
- data/lib/sumup/version.rb +5 -0
- data/lib/sumup.rb +13 -0
- data/sig/sumup/events.rbs +64 -0
- data/sig/sumup/resources/checkouts.rbs +35 -0
- data/sig/sumup/resources/customers.rbs +25 -0
- data/sig/sumup/resources/members.rbs +25 -0
- data/sig/sumup/resources/memberships.rbs +13 -0
- data/sig/sumup/resources/merchants.rbs +17 -0
- data/sig/sumup/resources/payouts.rbs +13 -0
- data/sig/sumup/resources/readers.rbs +45 -0
- data/sig/sumup/resources/receipts.rbs +13 -0
- data/sig/sumup/resources/roles.rbs +25 -0
- data/sig/sumup/resources/sales.rbs +19 -0
- data/sig/sumup/resources/tokens.rbs +15 -0
- data/sig/sumup/resources/transactions.rbs +19 -0
- data/sig/sumup/types.rbs +1635 -0
- data/sig/sumup.rbs +183 -0
- metadata +149 -0
data/lib/sumup/types.rb
ADDED
|
@@ -0,0 +1,4720 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Generated by codegen. DO NOT EDIT.
|
|
4
|
+
|
|
5
|
+
module SumUp
|
|
6
|
+
module Types
|
|
7
|
+
# Profile's personal address information.
|
|
8
|
+
class AddressLegacy < Model
|
|
9
|
+
##
|
|
10
|
+
# :attr_reader: city
|
|
11
|
+
# City name from the address.
|
|
12
|
+
field :city, :string, wire: "city", required: false
|
|
13
|
+
##
|
|
14
|
+
# :attr_reader: country
|
|
15
|
+
# Two letter country code formatted according to [ISO3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
|
|
16
|
+
field :country, :string, wire: "country", required: false
|
|
17
|
+
##
|
|
18
|
+
# :attr_reader: line_1
|
|
19
|
+
# First line of the address with details of the street name and number.
|
|
20
|
+
field :line_1, :string, wire: "line_1", required: false
|
|
21
|
+
##
|
|
22
|
+
# :attr_reader: line_2
|
|
23
|
+
# Second line of the address with details of the building, unit, apartment, and floor numbers.
|
|
24
|
+
field :line_2, :string, wire: "line_2", required: false
|
|
25
|
+
##
|
|
26
|
+
# :attr_reader: postal_code
|
|
27
|
+
# Postal code from the address.
|
|
28
|
+
field :postal_code, :string, wire: "postal_code", required: false
|
|
29
|
+
##
|
|
30
|
+
# :attr_reader: state
|
|
31
|
+
# State name or abbreviation from the address.
|
|
32
|
+
field :state, :string, wire: "state", required: false
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
class Affiliate < Model
|
|
36
|
+
##
|
|
37
|
+
# :attr_reader: app_id
|
|
38
|
+
field :app_id, :string, wire: "app_id", required: true
|
|
39
|
+
##
|
|
40
|
+
# :attr_reader: key
|
|
41
|
+
field :key, :string, wire: "key", required: true
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
class Amount < Model
|
|
45
|
+
##
|
|
46
|
+
# :attr_reader: currency
|
|
47
|
+
# Currency ISO 4217 code
|
|
48
|
+
field :currency, :string, wire: "currency", required: true
|
|
49
|
+
##
|
|
50
|
+
# :attr_reader: value
|
|
51
|
+
# Amount in minor units (e.g. cents).
|
|
52
|
+
field :value, :integer, wire: "value", required: true
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
# 400 Bad Request
|
|
56
|
+
class BadRequest < Model
|
|
57
|
+
##
|
|
58
|
+
# :attr_reader: errors
|
|
59
|
+
field :errors, [:model, "BadRequestErrors"], wire: "errors", required: true
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
class BadRequestErrors < Model
|
|
63
|
+
##
|
|
64
|
+
# :attr_reader: detail
|
|
65
|
+
# Fuller message giving context to error
|
|
66
|
+
field :detail, :string, wire: "detail", required: false
|
|
67
|
+
##
|
|
68
|
+
# :attr_reader: type
|
|
69
|
+
# Key indicating type of error
|
|
70
|
+
field :type, :string, wire: "type", required: true
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# Base schema for a Person associated with a Merchant. This can be a legal representative, business owner (ultimate beneficial owner), or an officer. A legal representative is the Person who registered the Merchant with SumUp. They should always have a `user_id`.
|
|
74
|
+
class BasePerson < Model
|
|
75
|
+
##
|
|
76
|
+
# :attr_reader: id
|
|
77
|
+
# The unique identifier for the Person. This is a [typeid](https://github.com/sumup/typeid).
|
|
78
|
+
field :id, :string, wire: "id", required: true
|
|
79
|
+
##
|
|
80
|
+
# :attr_reader: user_id
|
|
81
|
+
# A corresponding identity user ID for the Person, if they have a user account.
|
|
82
|
+
field :user_id, :string, wire: "user_id", required: false
|
|
83
|
+
##
|
|
84
|
+
# :attr_reader: birthdate
|
|
85
|
+
# The date of birth of the individual, represented as an ISO 8601:2004 [ISO8601‑2004] YYYY-MM-DD format.
|
|
86
|
+
field :birthdate, :string, wire: "birthdate", required: false
|
|
87
|
+
##
|
|
88
|
+
# :attr_reader: given_name
|
|
89
|
+
# The first name(s) of the individual.
|
|
90
|
+
field :given_name, :string, wire: "given_name", required: false
|
|
91
|
+
##
|
|
92
|
+
# :attr_reader: family_name
|
|
93
|
+
# The last name(s) of the individual.
|
|
94
|
+
field :family_name, :string, wire: "family_name", required: false
|
|
95
|
+
##
|
|
96
|
+
# :attr_reader: phone_number
|
|
97
|
+
# The (mobile) phone number of the individual (used for verification) in [E.164](https://en.wikipedia.org/wiki/E.164) format.
|
|
98
|
+
field :phone_number, :string, wire: "phone_number", required: false
|
|
99
|
+
##
|
|
100
|
+
# :attr_reader: relationships
|
|
101
|
+
# A list of roles the Person has in the Merchant or towards SumUp. A Merchant must have at least one Person with the relationship `representative`.
|
|
102
|
+
field :relationships, [:array, :string], wire: "relationships", required: false
|
|
103
|
+
##
|
|
104
|
+
# :attr_reader: ownership
|
|
105
|
+
field :ownership, [:model, "Ownership"], wire: "ownership", required: false
|
|
106
|
+
##
|
|
107
|
+
# :attr_reader: address
|
|
108
|
+
field :address, [:model, "MerchantsAddress"], wire: "address", required: false
|
|
109
|
+
##
|
|
110
|
+
# :attr_reader: identifiers
|
|
111
|
+
field :identifiers, [:array, [:model, "MerchantsPersonalIdentifiersItem"]], wire: "identifiers", required: false
|
|
112
|
+
##
|
|
113
|
+
# :attr_reader: citizenship
|
|
114
|
+
# The Alpha-2 ISO code of the country where the Person is a citizen.
|
|
115
|
+
field :citizenship, :string, wire: "citizenship", required: false
|
|
116
|
+
##
|
|
117
|
+
# :attr_reader: nationality
|
|
118
|
+
# The Person's nationality. May be an [ISO3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code, but legacy data may not conform to this standard.
|
|
119
|
+
field :nationality, [:union, [:string, :nil]], wire: "nationality", required: false
|
|
120
|
+
##
|
|
121
|
+
# :attr_reader: country_of_residence
|
|
122
|
+
# An [ISO3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code representing the country where the Person resides.
|
|
123
|
+
field :country_of_residence, [:union, [:string, :nil]], wire: "country_of_residence", required: false
|
|
124
|
+
##
|
|
125
|
+
# :attr_reader: version
|
|
126
|
+
# The version of the resource. The version reflects a specific change submitted to the API via one of the `PATCH` endpoints.
|
|
127
|
+
field :version, :string, wire: "version", required: false
|
|
128
|
+
##
|
|
129
|
+
# :attr_reader: change_status
|
|
130
|
+
# Reflects the status of changes submitted through the `PATCH` endpoints for the Merchant or Persons. If some changes have not been applied yet, the status will be `pending`. If all changes have been applied, the status `done`.
|
|
131
|
+
# The status is only returned after write operations or on read endpoints when the `version` query parameter is provided.
|
|
132
|
+
field :change_status, :string, wire: "change_status", required: false
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Settings used to apply the Merchant's branding to email receipts, invoices, checkouts, and other products.
|
|
136
|
+
class Branding < Model
|
|
137
|
+
##
|
|
138
|
+
# :attr_reader: footer_text
|
|
139
|
+
# Footer text rendered on receipts and other customer-facing products.
|
|
140
|
+
field :footer_text, :string, wire: "footer_text", required: false
|
|
141
|
+
##
|
|
142
|
+
# :attr_reader: icon
|
|
143
|
+
# An icon for the merchant. Must be square.
|
|
144
|
+
field :icon, :string, wire: "icon", required: false
|
|
145
|
+
##
|
|
146
|
+
# :attr_reader: logo
|
|
147
|
+
# A logo for the merchant that will be used in place of the icon and without the merchant's name next to it if there's sufficient space.
|
|
148
|
+
field :logo, :string, wire: "logo", required: false
|
|
149
|
+
##
|
|
150
|
+
# :attr_reader: hero
|
|
151
|
+
# Data-URL encoded hero image for the merchant business.
|
|
152
|
+
field :hero, :string, wire: "hero", required: false
|
|
153
|
+
##
|
|
154
|
+
# :attr_reader: primary_color
|
|
155
|
+
# A hex color value representing the primary branding color of this merchant (your brand color).
|
|
156
|
+
field :primary_color, :string, wire: "primary_color", required: false
|
|
157
|
+
##
|
|
158
|
+
# :attr_reader: primary_color_fg
|
|
159
|
+
# A hex color value representing the color of the text displayed on branding color of this merchant.
|
|
160
|
+
field :primary_color_fg, :string, wire: "primary_color_fg", required: false
|
|
161
|
+
##
|
|
162
|
+
# :attr_reader: secondary_color
|
|
163
|
+
# A hex color value representing the secondary branding color of this merchant (accent color used for buttons).
|
|
164
|
+
field :secondary_color, :string, wire: "secondary_color", required: false
|
|
165
|
+
##
|
|
166
|
+
# :attr_reader: secondary_color_fg
|
|
167
|
+
# A hex color value representing the color of the text displayed on secondary branding color of this merchant.
|
|
168
|
+
field :secondary_color_fg, :string, wire: "secondary_color_fg", required: false
|
|
169
|
+
##
|
|
170
|
+
# :attr_reader: background_color
|
|
171
|
+
# A hex color value representing the preferred background color of this merchant.
|
|
172
|
+
field :background_color, :string, wire: "background_color", required: false
|
|
173
|
+
end
|
|
174
|
+
|
|
175
|
+
# Business information about the merchant. This information will be visible to the merchant's customers.
|
|
176
|
+
class BusinessProfile < Model
|
|
177
|
+
##
|
|
178
|
+
# :attr_reader: name
|
|
179
|
+
# The customer-facing business name.
|
|
180
|
+
field :name, :string, wire: "name", required: false
|
|
181
|
+
##
|
|
182
|
+
# :attr_reader: dynamic_descriptor
|
|
183
|
+
# The descriptor is the text that your customer sees on their bank account statement.
|
|
184
|
+
# The more recognisable your descriptor is, the less risk you have of receiving disputes (e.g. chargebacks).
|
|
185
|
+
field :dynamic_descriptor, :string, wire: "dynamic_descriptor", required: false
|
|
186
|
+
##
|
|
187
|
+
# :attr_reader: website
|
|
188
|
+
# The business's publicly available website.
|
|
189
|
+
field :website, :string, wire: "website", required: false
|
|
190
|
+
##
|
|
191
|
+
# :attr_reader: email
|
|
192
|
+
# A publicly available email address.
|
|
193
|
+
field :email, :string, wire: "email", required: false
|
|
194
|
+
##
|
|
195
|
+
# :attr_reader: phone_number
|
|
196
|
+
# A public phone number that customers can call.
|
|
197
|
+
field :phone_number, :string, wire: "phone_number", required: false
|
|
198
|
+
##
|
|
199
|
+
# :attr_reader: address
|
|
200
|
+
field :address, [:model, "MerchantsAddress"], wire: "address", required: false
|
|
201
|
+
##
|
|
202
|
+
# :attr_reader: branding
|
|
203
|
+
field :branding, [:model, "Branding"], wire: "branding", required: false
|
|
204
|
+
end
|
|
205
|
+
|
|
206
|
+
# __Required when payment type is `card`.__ Details of the payment card.
|
|
207
|
+
class Card < Model
|
|
208
|
+
##
|
|
209
|
+
# :attr_reader: name
|
|
210
|
+
# Name of the cardholder as it appears on the payment card.
|
|
211
|
+
field :name, :string, wire: "name", required: true
|
|
212
|
+
##
|
|
213
|
+
# :attr_reader: number
|
|
214
|
+
# Number of the payment card (without spaces).
|
|
215
|
+
field :number, :string, wire: "number", required: true
|
|
216
|
+
##
|
|
217
|
+
# :attr_reader: expiry_year
|
|
218
|
+
# Two- or four-digit expiration year in `YY` or `YYYY` format.
|
|
219
|
+
field :expiry_year, :string, wire: "expiry_year", required: true
|
|
220
|
+
##
|
|
221
|
+
# :attr_reader: expiry_month
|
|
222
|
+
# Two-digit expiration month, from `01` through `12`.
|
|
223
|
+
field :expiry_month, :string, wire: "expiry_month", required: true
|
|
224
|
+
##
|
|
225
|
+
# :attr_reader: cvv
|
|
226
|
+
# Three or four-digit card verification value (security code) of the payment card.
|
|
227
|
+
field :cvv, :string, wire: "cvv", required: true
|
|
228
|
+
##
|
|
229
|
+
# :attr_reader: zip_code
|
|
230
|
+
# Required five-digit ZIP code. Applicable only to merchant users in the USA.
|
|
231
|
+
field :zip_code, :string, wire: "zip_code", required: false
|
|
232
|
+
##
|
|
233
|
+
# :attr_reader: type
|
|
234
|
+
field :type, :string, wire: "type", required: true
|
|
235
|
+
end
|
|
236
|
+
|
|
237
|
+
# Details of the payment card.
|
|
238
|
+
class CardResponse < Model
|
|
239
|
+
##
|
|
240
|
+
# :attr_reader: last_4_digits
|
|
241
|
+
# Last 4 digits of the payment card number.
|
|
242
|
+
field :last_4_digits, :string, wire: "last_4_digits", required: false
|
|
243
|
+
##
|
|
244
|
+
# :attr_reader: type
|
|
245
|
+
field :type, :string, wire: "type", required: false
|
|
246
|
+
##
|
|
247
|
+
# :attr_reader: payment_account_reference
|
|
248
|
+
# Payment Account Reference (PAR) defined by [EMVCo](https://www.emvco.com/emv-technologies/payment-tokenisation/). It links a card's primary account number (PAN) with its affiliated payment tokens, allowing transactions made with the physical card and tokenized versions of that card, such as digital wallets, to be correlated when PAR is available.
|
|
249
|
+
#
|
|
250
|
+
# This reference cannot be used to initiate a payment and is separate from the saved payment instrument `token` used to process checkouts. Returned only when available for the card; integrations must handle its absence.
|
|
251
|
+
field :payment_account_reference, :string, wire: "payment_account_reference", required: false
|
|
252
|
+
end
|
|
253
|
+
|
|
254
|
+
# Core checkout resource returned by the Checkouts API. A checkout is created before payment processing and then updated as payment attempts, redirects, and resulting transactions are attached to it.
|
|
255
|
+
class Checkout < Model
|
|
256
|
+
##
|
|
257
|
+
# :attr_reader: checkout_reference
|
|
258
|
+
# Merchant-defined reference for the checkout. Use it to correlate the SumUp checkout with your own order, cart, subscription, or payment attempt in your systems.
|
|
259
|
+
field :checkout_reference, :string, wire: "checkout_reference", required: false
|
|
260
|
+
##
|
|
261
|
+
# :attr_reader: amount
|
|
262
|
+
# Amount to be charged to the payer, expressed in major units.
|
|
263
|
+
field :amount, :number, wire: "amount", required: false
|
|
264
|
+
##
|
|
265
|
+
# :attr_reader: currency
|
|
266
|
+
field :currency, :string, wire: "currency", required: false
|
|
267
|
+
##
|
|
268
|
+
# :attr_reader: merchant_code
|
|
269
|
+
# Short unique identifier for the merchant that receives the payment.
|
|
270
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
271
|
+
##
|
|
272
|
+
# :attr_reader: description
|
|
273
|
+
# Short merchant-defined description shown in SumUp tools and reporting. Use it to make the checkout easier to recognize in dashboards, support workflows, and reconciliation.
|
|
274
|
+
field :description, :string, wire: "description", required: false
|
|
275
|
+
##
|
|
276
|
+
# :attr_reader: return_url
|
|
277
|
+
# Optional backend callback URL for checkout status notifications. SumUp sends an HTTP POST with `event_type` and the checkout `id`. Retrieve the checkout to verify its current status before updating your order. See the [webhook guide](https://developer.sumup.com/online-payments/webhooks/) for the payload and response requirements.
|
|
278
|
+
field :return_url, :string, wire: "return_url", required: false
|
|
279
|
+
##
|
|
280
|
+
# :attr_reader: id
|
|
281
|
+
# Unique SumUp identifier of the checkout resource.
|
|
282
|
+
field :id, :string, wire: "id", required: false
|
|
283
|
+
##
|
|
284
|
+
# :attr_reader: status
|
|
285
|
+
# Current high-level state of the checkout. `PENDING` means the checkout exists but is not yet completed, `PAID` means a payment succeeded, `FAILED` means the latest processing attempt failed, and `EXPIRED` means the checkout can no longer be processed.
|
|
286
|
+
field :status, :string, wire: "status", required: false
|
|
287
|
+
##
|
|
288
|
+
# :attr_reader: date
|
|
289
|
+
# The timestamp of when the checkout was created.
|
|
290
|
+
field :date, :string, wire: "date", required: false
|
|
291
|
+
##
|
|
292
|
+
# :attr_reader: valid_until
|
|
293
|
+
# Optional expiration timestamp. The checkout must be processed before this moment, otherwise it becomes unusable. If omitted, the checkout does not have an explicit expiry time.
|
|
294
|
+
field :valid_until, [:union, [:string, :nil]], wire: "valid_until", required: false
|
|
295
|
+
##
|
|
296
|
+
# :attr_reader: customer_id
|
|
297
|
+
# Merchant-scoped identifier of the customer associated with the checkout. Use it when storing payment instruments or reusing saved customer context for recurring and returning-payer flows.
|
|
298
|
+
field :customer_id, :string, wire: "customer_id", required: false
|
|
299
|
+
##
|
|
300
|
+
# :attr_reader: mandate
|
|
301
|
+
field :mandate, [:model, "MandateResponse"], wire: "mandate", required: false
|
|
302
|
+
##
|
|
303
|
+
# :attr_reader: hosted_checkout_url
|
|
304
|
+
# URL of the SumUp-hosted payment page that handles the payment flow. Returned when Hosted Checkout is enabled for the checkout.
|
|
305
|
+
field :hosted_checkout_url, :string, wire: "hosted_checkout_url", required: false
|
|
306
|
+
##
|
|
307
|
+
# :attr_reader: transactions
|
|
308
|
+
# Payment attempts and resulting transaction records linked to this checkout. Use the Transactions endpoints when you need the authoritative payment result and event history.
|
|
309
|
+
field :transactions, [:array, [:model, "CheckoutTransactionsItem"]], wire: "transactions", required: false
|
|
310
|
+
end
|
|
311
|
+
|
|
312
|
+
# Response returned when checkout processing requires an additional payer action, such as a 3DS challenge or a redirect to an external payment method page.
|
|
313
|
+
class CheckoutAccepted < Model
|
|
314
|
+
##
|
|
315
|
+
# :attr_reader: next_step
|
|
316
|
+
# Instructions for the next action the payer or client must take.
|
|
317
|
+
field :next_step, [:model, "CheckoutAcceptedNextStep"], wire: "next_step", required: false
|
|
318
|
+
end
|
|
319
|
+
|
|
320
|
+
# Instructions for the next action the payer or client must take.
|
|
321
|
+
class CheckoutAcceptedNextStep < Model
|
|
322
|
+
##
|
|
323
|
+
# :attr_reader: url
|
|
324
|
+
# URL to open or submit in order to continue processing.
|
|
325
|
+
field :url, :string, wire: "url", required: false
|
|
326
|
+
##
|
|
327
|
+
# :attr_reader: method_value
|
|
328
|
+
# HTTP method to use when following the next step.
|
|
329
|
+
field :method_value, :string, wire: "method", required: false
|
|
330
|
+
##
|
|
331
|
+
# :attr_reader: redirect_url
|
|
332
|
+
# Merchant URL where the payer returns after the external flow finishes.
|
|
333
|
+
field :redirect_url, :string, wire: "redirect_url", required: false
|
|
334
|
+
##
|
|
335
|
+
# :attr_reader: mechanism
|
|
336
|
+
# Allowed presentation mechanisms for the next step. `iframe` means the flow can be embedded, while `browser` means it can be completed through a full-page redirect.
|
|
337
|
+
field :mechanism, [:array, :string], wire: "mechanism", required: false
|
|
338
|
+
##
|
|
339
|
+
# :attr_reader: payload
|
|
340
|
+
# Parameters required to complete the next step. The exact keys depend on the payment provider and flow type.
|
|
341
|
+
field :payload, [:map, :string], wire: "payload", required: false
|
|
342
|
+
end
|
|
343
|
+
|
|
344
|
+
# Request body for creating a checkout before processing payment. Define the payment amount, currency, merchant, and optional customer or redirect behavior here.
|
|
345
|
+
class CheckoutCreateRequest < Model
|
|
346
|
+
##
|
|
347
|
+
# :attr_reader: checkout_reference
|
|
348
|
+
# Merchant-defined reference for the new checkout, up to 64 characters. Use it to correlate the checkout with an order or payment attempt in your own system. If a checkout already exists for the supplied unique parameters, creation returns `409` with `DUPLICATED_CHECKOUT`; see the conflict response.
|
|
349
|
+
field :checkout_reference, :string, wire: "checkout_reference", required: true
|
|
350
|
+
##
|
|
351
|
+
# :attr_reader: amount
|
|
352
|
+
# Amount to be charged to the payer, expressed in major units.
|
|
353
|
+
field :amount, :number, wire: "amount", required: true
|
|
354
|
+
##
|
|
355
|
+
# :attr_reader: currency
|
|
356
|
+
field :currency, :string, wire: "currency", required: true
|
|
357
|
+
##
|
|
358
|
+
# :attr_reader: merchant_code
|
|
359
|
+
# Short unique identifier for the merchant that should receive the payment.
|
|
360
|
+
field :merchant_code, :string, wire: "merchant_code", required: true
|
|
361
|
+
##
|
|
362
|
+
# :attr_reader: description
|
|
363
|
+
# Short merchant-defined description shown in SumUp tools and reporting for easier identification of the checkout.
|
|
364
|
+
field :description, :string, wire: "description", required: false
|
|
365
|
+
##
|
|
366
|
+
# :attr_reader: return_url
|
|
367
|
+
# Optional backend callback URL for checkout status notifications. SumUp sends an HTTP POST with `event_type` and the checkout `id`. Retrieve the checkout to verify its current status before updating your order. See the [webhook guide](https://developer.sumup.com/online-payments/webhooks/) for the payload and response requirements.
|
|
368
|
+
field :return_url, :string, wire: "return_url", required: false
|
|
369
|
+
##
|
|
370
|
+
# :attr_reader: customer_id
|
|
371
|
+
# Merchant-scoped customer identifier. Required when setting up recurring payments and useful when the checkout should be linked to a returning payer.
|
|
372
|
+
field :customer_id, :string, wire: "customer_id", required: false
|
|
373
|
+
##
|
|
374
|
+
# :attr_reader: purpose
|
|
375
|
+
# Business purpose of the checkout. Use `CHECKOUT` for a standard payment and `SETUP_RECURRING_PAYMENT` when collecting consent and payment details for future recurring charges.
|
|
376
|
+
field :purpose, :string, wire: "purpose", required: false
|
|
377
|
+
##
|
|
378
|
+
# :attr_reader: valid_until
|
|
379
|
+
# Optional expiration timestamp. The checkout must be processed before this moment, otherwise it becomes unusable. If omitted, the checkout does not have an explicit expiry time.
|
|
380
|
+
field :valid_until, [:union, [:string, :nil]], wire: "valid_until", required: false
|
|
381
|
+
##
|
|
382
|
+
# :attr_reader: redirect_url
|
|
383
|
+
# URL where the payer should be sent after a redirect-based payment or SCA flow completes. This is required for [APMs](https://developer.sumup.com/online-payments/apm/introduction) and recommended for card checkouts that may require [3DS](https://developer.sumup.com/online-payments/features/3ds). If it is omitted, the [Payment Widget](https://developer.sumup.com/online-payments/checkouts) can render the challenge in an iframe instead of using a full-page redirect.
|
|
384
|
+
field :redirect_url, :string, wire: "redirect_url", required: false
|
|
385
|
+
##
|
|
386
|
+
# :attr_reader: hosted_checkout
|
|
387
|
+
field :hosted_checkout, [:model, "HostedCheckout"], wire: "hosted_checkout", required: false
|
|
388
|
+
end
|
|
389
|
+
|
|
390
|
+
# Checkout resource returned after a synchronous processing attempt. In addition to the base checkout fields, it can include the resulting transaction identifiers and any newly created payment instrument token.
|
|
391
|
+
class CheckoutSuccess < Model
|
|
392
|
+
##
|
|
393
|
+
# :attr_reader: transaction_code
|
|
394
|
+
# Transaction code of the successful transaction with which the payment for the checkout is completed.
|
|
395
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
396
|
+
##
|
|
397
|
+
# :attr_reader: transaction_id
|
|
398
|
+
# Unique identifier of the successful transaction that completed payment for the checkout.
|
|
399
|
+
field :transaction_id, :string, wire: "transaction_id", required: false
|
|
400
|
+
##
|
|
401
|
+
# :attr_reader: merchant_name
|
|
402
|
+
# Name of the merchant.
|
|
403
|
+
field :merchant_name, :string, wire: "merchant_name", required: false
|
|
404
|
+
##
|
|
405
|
+
# :attr_reader: redirect_url
|
|
406
|
+
# URL where the payer is redirected after a redirect-based payment or SCA flow completes.
|
|
407
|
+
field :redirect_url, :string, wire: "redirect_url", required: false
|
|
408
|
+
##
|
|
409
|
+
# :attr_reader: payment_instrument
|
|
410
|
+
# Details of the saved payment instrument created or reused during checkout processing.
|
|
411
|
+
field :payment_instrument, [:model, "CheckoutSuccessPaymentInstrument"], wire: "payment_instrument", required: false
|
|
412
|
+
##
|
|
413
|
+
# :attr_reader: checkout_reference
|
|
414
|
+
# Merchant-defined reference for the checkout. Use it to correlate the SumUp checkout with your own order, cart, subscription, or payment attempt in your systems.
|
|
415
|
+
field :checkout_reference, :string, wire: "checkout_reference", required: false
|
|
416
|
+
##
|
|
417
|
+
# :attr_reader: amount
|
|
418
|
+
# Amount to be charged to the payer, expressed in major units.
|
|
419
|
+
field :amount, :number, wire: "amount", required: false
|
|
420
|
+
##
|
|
421
|
+
# :attr_reader: currency
|
|
422
|
+
field :currency, :string, wire: "currency", required: false
|
|
423
|
+
##
|
|
424
|
+
# :attr_reader: merchant_code
|
|
425
|
+
# Short unique identifier for the merchant that receives the payment.
|
|
426
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
427
|
+
##
|
|
428
|
+
# :attr_reader: description
|
|
429
|
+
# Short merchant-defined description shown in SumUp tools and reporting. Use it to make the checkout easier to recognize in dashboards, support workflows, and reconciliation.
|
|
430
|
+
field :description, :string, wire: "description", required: false
|
|
431
|
+
##
|
|
432
|
+
# :attr_reader: return_url
|
|
433
|
+
# Optional backend callback URL for checkout status notifications. SumUp sends an HTTP POST with `event_type` and the checkout `id`. Retrieve the checkout to verify its current status before updating your order. See the [webhook guide](https://developer.sumup.com/online-payments/webhooks/) for the payload and response requirements.
|
|
434
|
+
field :return_url, :string, wire: "return_url", required: false
|
|
435
|
+
##
|
|
436
|
+
# :attr_reader: id
|
|
437
|
+
# Unique SumUp identifier of the checkout resource.
|
|
438
|
+
field :id, :string, wire: "id", required: false
|
|
439
|
+
##
|
|
440
|
+
# :attr_reader: status
|
|
441
|
+
# Current high-level state of the checkout. `PENDING` means the checkout exists but is not yet completed, `PAID` means a payment succeeded, `FAILED` means the latest processing attempt failed, and `EXPIRED` means the checkout can no longer be processed.
|
|
442
|
+
field :status, :string, wire: "status", required: false
|
|
443
|
+
##
|
|
444
|
+
# :attr_reader: date
|
|
445
|
+
# The timestamp of when the checkout was created.
|
|
446
|
+
field :date, :string, wire: "date", required: false
|
|
447
|
+
##
|
|
448
|
+
# :attr_reader: valid_until
|
|
449
|
+
# Optional expiration timestamp. The checkout must be processed before this moment, otherwise it becomes unusable. If omitted, the checkout does not have an explicit expiry time.
|
|
450
|
+
field :valid_until, [:union, [:string, :nil]], wire: "valid_until", required: false
|
|
451
|
+
##
|
|
452
|
+
# :attr_reader: customer_id
|
|
453
|
+
# Merchant-scoped identifier of the customer associated with the checkout. Use it when storing payment instruments or reusing saved customer context for recurring and returning-payer flows.
|
|
454
|
+
field :customer_id, :string, wire: "customer_id", required: false
|
|
455
|
+
##
|
|
456
|
+
# :attr_reader: mandate
|
|
457
|
+
field :mandate, [:model, "MandateResponse"], wire: "mandate", required: false
|
|
458
|
+
##
|
|
459
|
+
# :attr_reader: hosted_checkout_url
|
|
460
|
+
# URL of the SumUp-hosted payment page that handles the payment flow. Returned when Hosted Checkout is enabled for the checkout.
|
|
461
|
+
field :hosted_checkout_url, :string, wire: "hosted_checkout_url", required: false
|
|
462
|
+
##
|
|
463
|
+
# :attr_reader: transactions
|
|
464
|
+
# Payment attempts and resulting transaction records linked to this checkout. Use the Transactions endpoints when you need the authoritative payment result and event history.
|
|
465
|
+
field :transactions, [:array, [:model, "CheckoutSuccessTransactionsItem"]], wire: "transactions", required: false
|
|
466
|
+
end
|
|
467
|
+
|
|
468
|
+
# Details of the saved payment instrument created or reused during checkout processing.
|
|
469
|
+
class CheckoutSuccessPaymentInstrument < Model
|
|
470
|
+
##
|
|
471
|
+
# :attr_reader: token
|
|
472
|
+
# Unique token of the saved payment instrument.
|
|
473
|
+
field :token, :string, wire: "token", required: false
|
|
474
|
+
end
|
|
475
|
+
|
|
476
|
+
# Core details shared by transaction resources.
|
|
477
|
+
class CheckoutSuccessTransactionsItem < Model
|
|
478
|
+
##
|
|
479
|
+
# :attr_reader: entry_mode
|
|
480
|
+
field :entry_mode, :string, wire: "entry_mode", required: false
|
|
481
|
+
##
|
|
482
|
+
# :attr_reader: merchant_code
|
|
483
|
+
# Unique code of the registered merchant to whom the payment is made.
|
|
484
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
485
|
+
##
|
|
486
|
+
# :attr_reader: vat_amount
|
|
487
|
+
# VAT included in the total transaction amount, in major units of the transaction's currency.
|
|
488
|
+
field :vat_amount, :number, wire: "vat_amount", required: false
|
|
489
|
+
##
|
|
490
|
+
# :attr_reader: tip_amount
|
|
491
|
+
# Tip included in the total transaction amount, in major units of the transaction's currency.
|
|
492
|
+
field :tip_amount, :number, wire: "tip_amount", required: false
|
|
493
|
+
##
|
|
494
|
+
# :attr_reader: auth_code
|
|
495
|
+
# Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments.
|
|
496
|
+
field :auth_code, :string, wire: "auth_code", required: false
|
|
497
|
+
##
|
|
498
|
+
# :attr_reader: id
|
|
499
|
+
# Unique identifier of the transaction.
|
|
500
|
+
field :id, :string, wire: "id", required: false
|
|
501
|
+
##
|
|
502
|
+
# :attr_reader: transaction_code
|
|
503
|
+
# SumUp transaction code, for example `TEENSK4W2K`. Use it to look up the transaction with the `transaction_code` query parameter. This is separate from the transaction's `id` and the card issuer's `auth_code`.
|
|
504
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
505
|
+
##
|
|
506
|
+
# :attr_reader: amount
|
|
507
|
+
# Total amount of the transaction in major units of `currency`, for example `10.1` for EUR 10.10.
|
|
508
|
+
field :amount, :number, wire: "amount", required: false
|
|
509
|
+
##
|
|
510
|
+
# :attr_reader: currency
|
|
511
|
+
field :currency, :string, wire: "currency", required: false
|
|
512
|
+
##
|
|
513
|
+
# :attr_reader: timestamp
|
|
514
|
+
# The timestamp of when the transaction was created.
|
|
515
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
516
|
+
##
|
|
517
|
+
# :attr_reader: status
|
|
518
|
+
field :status, :string, wire: "status", required: false
|
|
519
|
+
##
|
|
520
|
+
# :attr_reader: payment_type
|
|
521
|
+
field :payment_type, :string, wire: "payment_type", required: false
|
|
522
|
+
##
|
|
523
|
+
# :attr_reader: installments_count
|
|
524
|
+
# Number of installments for a deferred payment.
|
|
525
|
+
field :installments_count, :integer, wire: "installments_count", required: false
|
|
526
|
+
end
|
|
527
|
+
|
|
528
|
+
# Core details shared by transaction resources.
|
|
529
|
+
class CheckoutTransactionsItem < Model
|
|
530
|
+
##
|
|
531
|
+
# :attr_reader: entry_mode
|
|
532
|
+
field :entry_mode, :string, wire: "entry_mode", required: false
|
|
533
|
+
##
|
|
534
|
+
# :attr_reader: merchant_code
|
|
535
|
+
# Unique code of the registered merchant to whom the payment is made.
|
|
536
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
537
|
+
##
|
|
538
|
+
# :attr_reader: vat_amount
|
|
539
|
+
# VAT included in the total transaction amount, in major units of the transaction's currency.
|
|
540
|
+
field :vat_amount, :number, wire: "vat_amount", required: false
|
|
541
|
+
##
|
|
542
|
+
# :attr_reader: tip_amount
|
|
543
|
+
# Tip included in the total transaction amount, in major units of the transaction's currency.
|
|
544
|
+
field :tip_amount, :number, wire: "tip_amount", required: false
|
|
545
|
+
##
|
|
546
|
+
# :attr_reader: auth_code
|
|
547
|
+
# Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments.
|
|
548
|
+
field :auth_code, :string, wire: "auth_code", required: false
|
|
549
|
+
##
|
|
550
|
+
# :attr_reader: id
|
|
551
|
+
# Unique identifier of the transaction.
|
|
552
|
+
field :id, :string, wire: "id", required: false
|
|
553
|
+
##
|
|
554
|
+
# :attr_reader: transaction_code
|
|
555
|
+
# SumUp transaction code, for example `TEENSK4W2K`. Use it to look up the transaction with the `transaction_code` query parameter. This is separate from the transaction's `id` and the card issuer's `auth_code`.
|
|
556
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
557
|
+
##
|
|
558
|
+
# :attr_reader: amount
|
|
559
|
+
# Total amount of the transaction in major units of `currency`, for example `10.1` for EUR 10.10.
|
|
560
|
+
field :amount, :number, wire: "amount", required: false
|
|
561
|
+
##
|
|
562
|
+
# :attr_reader: currency
|
|
563
|
+
field :currency, :string, wire: "currency", required: false
|
|
564
|
+
##
|
|
565
|
+
# :attr_reader: timestamp
|
|
566
|
+
# The timestamp of when the transaction was created.
|
|
567
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
568
|
+
##
|
|
569
|
+
# :attr_reader: status
|
|
570
|
+
field :status, :string, wire: "status", required: false
|
|
571
|
+
##
|
|
572
|
+
# :attr_reader: payment_type
|
|
573
|
+
field :payment_type, :string, wire: "payment_type", required: false
|
|
574
|
+
##
|
|
575
|
+
# :attr_reader: installments_count
|
|
576
|
+
# Number of installments for a deferred payment.
|
|
577
|
+
field :installments_count, :integer, wire: "installments_count", required: false
|
|
578
|
+
end
|
|
579
|
+
|
|
580
|
+
# Request body for updating an existing checkout. Include only the fields that should be changed.
|
|
581
|
+
class CheckoutUpdateRequest < Model
|
|
582
|
+
##
|
|
583
|
+
# :attr_reader: amount
|
|
584
|
+
# Updated amount to be charged to the payer, expressed in major units.
|
|
585
|
+
field :amount, :number, wire: "amount", required: false
|
|
586
|
+
##
|
|
587
|
+
# :attr_reader: currency
|
|
588
|
+
field :currency, :string, wire: "currency", required: false
|
|
589
|
+
##
|
|
590
|
+
# :attr_reader: description
|
|
591
|
+
# Updated short merchant-defined description shown in SumUp tools and reporting.
|
|
592
|
+
field :description, :string, wire: "description", required: false
|
|
593
|
+
##
|
|
594
|
+
# :attr_reader: checkout_reference
|
|
595
|
+
# Updated merchant-defined reference for the checkout.
|
|
596
|
+
field :checkout_reference, :string, wire: "checkout_reference", required: false
|
|
597
|
+
##
|
|
598
|
+
# :attr_reader: valid_until
|
|
599
|
+
# Updated expiration timestamp. The checkout must be processed before this moment, otherwise it becomes unusable.
|
|
600
|
+
field :valid_until, [:union, [:string, :nil]], wire: "valid_until", required: false
|
|
601
|
+
##
|
|
602
|
+
# :attr_reader: customer_id
|
|
603
|
+
# Updated merchant-scoped customer identifier associated with the checkout.
|
|
604
|
+
field :customer_id, :string, wire: "customer_id", required: false
|
|
605
|
+
end
|
|
606
|
+
|
|
607
|
+
class ClassicMerchantIdentifiers < Model
|
|
608
|
+
##
|
|
609
|
+
# :attr_reader: id
|
|
610
|
+
# Classic (serial) merchant ID.
|
|
611
|
+
field :id, :integer, wire: "id", required: true
|
|
612
|
+
end
|
|
613
|
+
|
|
614
|
+
# Information about the company or business. This is legal information that is used for verification.
|
|
615
|
+
class Company < Model
|
|
616
|
+
##
|
|
617
|
+
# :attr_reader: name
|
|
618
|
+
# The company's legal name.
|
|
619
|
+
field :name, :string, wire: "name", required: false
|
|
620
|
+
##
|
|
621
|
+
# :attr_reader: merchant_category_code
|
|
622
|
+
# The merchant category code for the account as specified by [ISO18245](https://www.iso.org/standard/33365.html). MCCs are used to classify businesses based on the goods or services they provide.
|
|
623
|
+
field :merchant_category_code, :string, wire: "merchant_category_code", required: false
|
|
624
|
+
##
|
|
625
|
+
# :attr_reader: legal_type
|
|
626
|
+
# The category identifying the legal structure of the company or legal entity.
|
|
627
|
+
field :legal_type, :string, wire: "legal_type", required: false
|
|
628
|
+
##
|
|
629
|
+
# :attr_reader: address
|
|
630
|
+
# The company's primary address.
|
|
631
|
+
field :address, [:model, "MerchantsAddress"], wire: "address", required: false
|
|
632
|
+
##
|
|
633
|
+
# :attr_reader: trading_address
|
|
634
|
+
# A trading address is where your suppliers, banks or customers send you correspondence to. Trading address can be different to the company's registered address (`address`).
|
|
635
|
+
field :trading_address, [:model, "MerchantsAddress"], wire: "trading_address", required: false
|
|
636
|
+
##
|
|
637
|
+
# :attr_reader: identifiers
|
|
638
|
+
field :identifiers, [:array, [:model, "CompanyIdentifier"]], wire: "identifiers", required: false
|
|
639
|
+
##
|
|
640
|
+
# :attr_reader: phone_number
|
|
641
|
+
# The company's phone number (used for verification) in [E.164](https://en.wikipedia.org/wiki/E.164) format.
|
|
642
|
+
field :phone_number, :string, wire: "phone_number", required: false
|
|
643
|
+
##
|
|
644
|
+
# :attr_reader: website
|
|
645
|
+
# HTTP(S) URL of the company's website.
|
|
646
|
+
field :website, :string, wire: "website", required: false
|
|
647
|
+
##
|
|
648
|
+
# :attr_reader: attributes
|
|
649
|
+
field :attributes, [:map, :string], wire: "attributes", required: false
|
|
650
|
+
end
|
|
651
|
+
|
|
652
|
+
class CompanyIdentifier < Model
|
|
653
|
+
##
|
|
654
|
+
# :attr_reader: ref
|
|
655
|
+
# The unique reference for the company identifier type as defined in the country SDK.
|
|
656
|
+
field :ref, :string, wire: "ref", required: true
|
|
657
|
+
##
|
|
658
|
+
# :attr_reader: value
|
|
659
|
+
# The company identifier value.
|
|
660
|
+
field :value, :string, wire: "value", required: true
|
|
661
|
+
end
|
|
662
|
+
|
|
663
|
+
class CreateApplePaySessionRequest < Model
|
|
664
|
+
##
|
|
665
|
+
# :attr_reader: context
|
|
666
|
+
# Hostname of the website displaying the Apple Pay payment sheet, without a URL scheme or path. Use the domain registered for Apple Pay.
|
|
667
|
+
field :context, :string, wire: "context", required: true
|
|
668
|
+
##
|
|
669
|
+
# :attr_reader: target
|
|
670
|
+
# Apple Pay validation URL received as `validationURL` in the browser's `onvalidatemerchant` event.
|
|
671
|
+
field :target, :string, wire: "target", required: true
|
|
672
|
+
end
|
|
673
|
+
|
|
674
|
+
class CreateMerchantMemberRequest < Model
|
|
675
|
+
##
|
|
676
|
+
# :attr_reader: is_managed_user
|
|
677
|
+
# True if the user is managed by the merchant. In this case, we'll created a virtual user with the provided password and nickname.
|
|
678
|
+
field :is_managed_user, :boolean, wire: "is_managed_user", required: false
|
|
679
|
+
##
|
|
680
|
+
# :attr_reader: email
|
|
681
|
+
# Email address of the member to add.
|
|
682
|
+
field :email, :string, wire: "email", required: true
|
|
683
|
+
##
|
|
684
|
+
# :attr_reader: password
|
|
685
|
+
# Password of the member to add. Only used if `is_managed_user` is true. In the case of service accounts, the password is not used and can not be defined by the caller.
|
|
686
|
+
field :password, :string, wire: "password", required: false
|
|
687
|
+
##
|
|
688
|
+
# :attr_reader: nickname
|
|
689
|
+
# Nickname of the member to add. Only used if `is_managed_user` is true. Used for display purposes only.
|
|
690
|
+
field :nickname, :string, wire: "nickname", required: false
|
|
691
|
+
##
|
|
692
|
+
# :attr_reader: roles
|
|
693
|
+
# List of roles to assign to the new member.
|
|
694
|
+
field :roles, [:array, :string], wire: "roles", required: true
|
|
695
|
+
##
|
|
696
|
+
# :attr_reader: metadata
|
|
697
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
698
|
+
##
|
|
699
|
+
# :attr_reader: attributes
|
|
700
|
+
field :attributes, [:map, :any], wire: "attributes", required: false
|
|
701
|
+
end
|
|
702
|
+
|
|
703
|
+
class CreateMerchantRoleRequest < Model
|
|
704
|
+
##
|
|
705
|
+
# :attr_reader: name
|
|
706
|
+
# User-defined name of the role.
|
|
707
|
+
field :name, :string, wire: "name", required: true
|
|
708
|
+
##
|
|
709
|
+
# :attr_reader: permissions
|
|
710
|
+
# User's permissions.
|
|
711
|
+
field :permissions, [:array, :string], wire: "permissions", required: true
|
|
712
|
+
##
|
|
713
|
+
# :attr_reader: metadata
|
|
714
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
715
|
+
##
|
|
716
|
+
# :attr_reader: description
|
|
717
|
+
# User-defined description of the role.
|
|
718
|
+
field :description, :string, wire: "description", required: false
|
|
719
|
+
end
|
|
720
|
+
|
|
721
|
+
class CreateMerchantTokenRequest < Model
|
|
722
|
+
##
|
|
723
|
+
# :attr_reader: actions
|
|
724
|
+
# Actions the token allows for this merchant account.
|
|
725
|
+
field :actions, [:array, :string], wire: "actions", required: true
|
|
726
|
+
end
|
|
727
|
+
|
|
728
|
+
# Error description
|
|
729
|
+
class CreateReaderCheckoutError < Model
|
|
730
|
+
##
|
|
731
|
+
# :attr_reader: errors
|
|
732
|
+
field :errors, [:model, "CreateReaderCheckoutErrorErrors"], wire: "errors", required: true
|
|
733
|
+
end
|
|
734
|
+
|
|
735
|
+
class CreateReaderCheckoutErrorErrors < Model
|
|
736
|
+
##
|
|
737
|
+
# :attr_reader: detail
|
|
738
|
+
# Error message
|
|
739
|
+
field :detail, :string, wire: "detail", required: false
|
|
740
|
+
##
|
|
741
|
+
# :attr_reader: type
|
|
742
|
+
# Error code
|
|
743
|
+
field :type, :string, wire: "type", required: true
|
|
744
|
+
end
|
|
745
|
+
|
|
746
|
+
# Payment details for a Reader Checkout.
|
|
747
|
+
class CreateReaderCheckoutRequest < Model
|
|
748
|
+
##
|
|
749
|
+
# :attr_reader: aade
|
|
750
|
+
# Optional object containing data for transactions from ERP integrators in Greece that comply with the AADE 1155 protocol.
|
|
751
|
+
# When such regulatory/business requirements apply, this object must be provided and contains the data needed to validate the transaction with the AADE signature provider.
|
|
752
|
+
field :aade, [:model, "CreateReaderCheckoutRequestAade"], wire: "aade", required: false
|
|
753
|
+
##
|
|
754
|
+
# :attr_reader: affiliate
|
|
755
|
+
# Optional affiliate metadata associated with the checkout's payment.
|
|
756
|
+
# Provide both `app_id` and `key` when including this object.
|
|
757
|
+
field :affiliate, [:union, [[:model, "CreateReaderCheckoutRequestAffiliate"], :nil]], wire: "affiliate", required: false
|
|
758
|
+
##
|
|
759
|
+
# :attr_reader: card_type
|
|
760
|
+
# The card type of the card used for the transaction.
|
|
761
|
+
# It is required only for some countries (e.g: Brazil).
|
|
762
|
+
field :card_type, :string, wire: "card_type", required: false
|
|
763
|
+
##
|
|
764
|
+
# :attr_reader: description
|
|
765
|
+
# Description of the checkout to be shown in the Merchant Sales
|
|
766
|
+
field :description, :string, wire: "description", required: false
|
|
767
|
+
##
|
|
768
|
+
# :attr_reader: installments
|
|
769
|
+
# Number of installments for the transaction.
|
|
770
|
+
# It may vary according to the merchant country.
|
|
771
|
+
# For example, in Brazil, the maximum number of installments is 12.
|
|
772
|
+
#
|
|
773
|
+
# Omit if the merchant country does not support installments.
|
|
774
|
+
# Otherwise, the checkout will be rejected.
|
|
775
|
+
field :installments, [:union, [:integer, :nil]], wire: "installments", required: false
|
|
776
|
+
##
|
|
777
|
+
# :attr_reader: payment_type
|
|
778
|
+
# The payment method type for the transaction. Defaults to `card`.
|
|
779
|
+
#
|
|
780
|
+
# Use `pix` to initiate a Pix QR-code payment flow on the device.
|
|
781
|
+
# Pix is only supported for Brazilian merchants; other merchants will receive a 422 error.
|
|
782
|
+
field :payment_type, :string, wire: "payment_type", required: false
|
|
783
|
+
##
|
|
784
|
+
# :attr_reader: return_url
|
|
785
|
+
# Webhook URL to which the payment result will be sent.
|
|
786
|
+
# It must be a HTTPS url.
|
|
787
|
+
field :return_url, :string, wire: "return_url", required: false
|
|
788
|
+
##
|
|
789
|
+
# :attr_reader: tip_rates
|
|
790
|
+
# Exactly three distinct tipping rates to be displayed to the cardholder.
|
|
791
|
+
# Each rate is a fraction between 0.01 and 1.00 in increments of 0.01.
|
|
792
|
+
# The rates are sorted in ascending order by the server.
|
|
793
|
+
field :tip_rates, [:array, :number], wire: "tip_rates", required: false
|
|
794
|
+
##
|
|
795
|
+
# :attr_reader: tip_timeout
|
|
796
|
+
# Time in seconds the cardholder has to select a tip rate.
|
|
797
|
+
# If not provided, the default value is 30 seconds.
|
|
798
|
+
#
|
|
799
|
+
# It can only be set if `tip_rates` is provided.
|
|
800
|
+
#
|
|
801
|
+
# **Note**: If the target device is a Solo, it must be in version 3.3.38.0 or higher.
|
|
802
|
+
field :tip_timeout, :integer, wire: "tip_timeout", required: false
|
|
803
|
+
##
|
|
804
|
+
# :attr_reader: total_amount
|
|
805
|
+
# Amount structure.
|
|
806
|
+
#
|
|
807
|
+
# The amount is represented as an integer value altogether with the currency and the minor unit.
|
|
808
|
+
#
|
|
809
|
+
# For example, EUR 1.00 is represented as value 100 with minor unit of 2.
|
|
810
|
+
field :total_amount, [:model, "CreateReaderCheckoutRequestTotalAmount"], wire: "total_amount", required: true
|
|
811
|
+
end
|
|
812
|
+
|
|
813
|
+
# Optional object containing data for transactions from ERP integrators in Greece that comply with the AADE 1155 protocol.
|
|
814
|
+
# When such regulatory/business requirements apply, this object must be provided and contains the data needed to validate the transaction with the AADE signature provider.
|
|
815
|
+
class CreateReaderCheckoutRequestAade < Model
|
|
816
|
+
##
|
|
817
|
+
# :attr_reader: provider_id
|
|
818
|
+
# The identifier of the AADE signature provider.
|
|
819
|
+
field :provider_id, :string, wire: "provider_id", required: true
|
|
820
|
+
##
|
|
821
|
+
# :attr_reader: signature
|
|
822
|
+
# The base64 encoded signature of the transaction data.
|
|
823
|
+
field :signature, :string, wire: "signature", required: true
|
|
824
|
+
##
|
|
825
|
+
# :attr_reader: signature_data
|
|
826
|
+
# The string containing the signed transaction data.
|
|
827
|
+
field :signature_data, :string, wire: "signature_data", required: true
|
|
828
|
+
end
|
|
829
|
+
|
|
830
|
+
# Optional affiliate metadata associated with the checkout's payment.
|
|
831
|
+
# Provide both `app_id` and `key` when including this object.
|
|
832
|
+
class CreateReaderCheckoutRequestAffiliate < Model
|
|
833
|
+
##
|
|
834
|
+
# :attr_reader: app_id
|
|
835
|
+
# Integrator application identifier from the [Affiliate Keys](https://developer.sumup.com/affiliate-keys) page.
|
|
836
|
+
# Required when the affiliate object is provided.
|
|
837
|
+
field :app_id, :string, wire: "app_id", required: true
|
|
838
|
+
##
|
|
839
|
+
# :attr_reader: foreign_transaction_id
|
|
840
|
+
# Integrator-owned transaction reference. Optional.
|
|
841
|
+
# Can be used to retrieve the transaction via the [Transactions API](https://developer.sumup.com/api/transactions/get).
|
|
842
|
+
field :foreign_transaction_id, :string, wire: "foreign_transaction_id", required: false
|
|
843
|
+
##
|
|
844
|
+
# :attr_reader: key
|
|
845
|
+
# Affiliate key generated in the [Affiliate Keys](https://developer.sumup.com/affiliate-keys) page.
|
|
846
|
+
# Required when the affiliate object is provided.
|
|
847
|
+
field :key, :string, wire: "key", required: true
|
|
848
|
+
##
|
|
849
|
+
# :attr_reader: tags
|
|
850
|
+
# Optional key-value metadata associated with the transaction.
|
|
851
|
+
field :tags, [:map, :any], wire: "tags", required: false
|
|
852
|
+
end
|
|
853
|
+
|
|
854
|
+
# Amount structure.
|
|
855
|
+
#
|
|
856
|
+
# The amount is represented as an integer value altogether with the currency and the minor unit.
|
|
857
|
+
#
|
|
858
|
+
# For example, EUR 1.00 is represented as value 100 with minor unit of 2.
|
|
859
|
+
class CreateReaderCheckoutRequestTotalAmount < Model
|
|
860
|
+
##
|
|
861
|
+
# :attr_reader: currency
|
|
862
|
+
# Currency ISO 4217 code
|
|
863
|
+
field :currency, :string, wire: "currency", required: true
|
|
864
|
+
##
|
|
865
|
+
# :attr_reader: minor_unit
|
|
866
|
+
# The minor units of the currency.
|
|
867
|
+
# It represents the number of decimals of the currency. For the currencies CLP, COP and HUF, the minor unit is 0.
|
|
868
|
+
field :minor_unit, :integer, wire: "minor_unit", required: true
|
|
869
|
+
##
|
|
870
|
+
# :attr_reader: value
|
|
871
|
+
# Integer value of the amount.
|
|
872
|
+
field :value, :integer, wire: "value", required: true
|
|
873
|
+
end
|
|
874
|
+
|
|
875
|
+
class CreateReaderCheckoutResponse < Model
|
|
876
|
+
##
|
|
877
|
+
# :attr_reader: data
|
|
878
|
+
field :data, [:model, "CreateReaderCheckoutResponseData"], wire: "data", required: true
|
|
879
|
+
end
|
|
880
|
+
|
|
881
|
+
class CreateReaderCheckoutResponseData < Model
|
|
882
|
+
##
|
|
883
|
+
# :attr_reader: checkout_id
|
|
884
|
+
# The checkout ID is a unique identifier for the checkout.
|
|
885
|
+
field :checkout_id, :string, wire: "checkout_id", required: false
|
|
886
|
+
##
|
|
887
|
+
# :attr_reader: client_transaction_id
|
|
888
|
+
# Unique identifier for the transaction associated with this checkout.
|
|
889
|
+
# Use this value to match the checkout with payment events and transaction records.
|
|
890
|
+
field :client_transaction_id, :string, wire: "client_transaction_id", required: true
|
|
891
|
+
end
|
|
892
|
+
|
|
893
|
+
# Unprocessable entity
|
|
894
|
+
class CreateReaderCheckoutUnprocessableEntity < Model
|
|
895
|
+
##
|
|
896
|
+
# :attr_reader: errors
|
|
897
|
+
field :errors, [:map, :any], wire: "errors", required: true
|
|
898
|
+
end
|
|
899
|
+
|
|
900
|
+
class CreateReaderRequest < Model
|
|
901
|
+
##
|
|
902
|
+
# :attr_reader: pairing_code
|
|
903
|
+
# The pairing code is a 8 or 9 character alphanumeric string that is displayed on a SumUp Device after initiating the pairing. It is used to link the physical device to the created pairing.
|
|
904
|
+
field :pairing_code, :string, wire: "pairing_code", required: true
|
|
905
|
+
##
|
|
906
|
+
# :attr_reader: name
|
|
907
|
+
# Custom human-readable, user-defined name for easier identification of the reader.
|
|
908
|
+
field :name, :string, wire: "name", required: true
|
|
909
|
+
##
|
|
910
|
+
# :attr_reader: metadata
|
|
911
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
912
|
+
end
|
|
913
|
+
|
|
914
|
+
# Error description
|
|
915
|
+
class CreateReaderTerminateError < Model
|
|
916
|
+
##
|
|
917
|
+
# :attr_reader: errors
|
|
918
|
+
field :errors, [:model, "CreateReaderCheckoutErrorErrors"], wire: "errors", required: true
|
|
919
|
+
end
|
|
920
|
+
|
|
921
|
+
# Unprocessable entity
|
|
922
|
+
class CreateReaderTerminateUnprocessableEntity < Model
|
|
923
|
+
##
|
|
924
|
+
# :attr_reader: errors
|
|
925
|
+
field :errors, [:map, :any], wire: "errors", required: true
|
|
926
|
+
end
|
|
927
|
+
|
|
928
|
+
# Saved payer details identified by the `customer_id` supplied by your integration. A customer can have saved payment instruments for subsequent payments.
|
|
929
|
+
class Customer < Model
|
|
930
|
+
##
|
|
931
|
+
# :attr_reader: customer_id
|
|
932
|
+
# Identifier you supply when creating the customer. Use an ID from your own system and retain it for subsequent customer, checkout, and saved-payment-instrument requests.
|
|
933
|
+
field :customer_id, :string, wire: "customer_id", required: true
|
|
934
|
+
##
|
|
935
|
+
# :attr_reader: personal_details
|
|
936
|
+
field :personal_details, [:model, "PersonalDetails"], wire: "personal_details", required: false
|
|
937
|
+
end
|
|
938
|
+
|
|
939
|
+
# Details of a customer validation error.
|
|
940
|
+
class CustomerValidationError < Model
|
|
941
|
+
##
|
|
942
|
+
# :attr_reader: instance
|
|
943
|
+
# Unique identifier of this error occurrence.
|
|
944
|
+
field :instance, :string, wire: "instance", required: true
|
|
945
|
+
##
|
|
946
|
+
# :attr_reader: error_code
|
|
947
|
+
# Platform code for the error.
|
|
948
|
+
field :error_code, :string, wire: "error_code", required: true
|
|
949
|
+
##
|
|
950
|
+
# :attr_reader: error_message
|
|
951
|
+
# Short description of the error.
|
|
952
|
+
field :error_message, :string, wire: "error_message", required: true
|
|
953
|
+
end
|
|
954
|
+
|
|
955
|
+
# Details of a request validation error.
|
|
956
|
+
class DetailsError < Model
|
|
957
|
+
##
|
|
958
|
+
# :attr_reader: title
|
|
959
|
+
# Short title of the error.
|
|
960
|
+
field :title, :string, wire: "title", required: false
|
|
961
|
+
##
|
|
962
|
+
# :attr_reader: details
|
|
963
|
+
# Details of the error.
|
|
964
|
+
field :details, :string, wire: "details", required: false
|
|
965
|
+
##
|
|
966
|
+
# :attr_reader: status
|
|
967
|
+
# HTTP status code for the error.
|
|
968
|
+
field :status, :number, wire: "status", required: false
|
|
969
|
+
##
|
|
970
|
+
# :attr_reader: failed_constraints
|
|
971
|
+
# List of violated validation constraints.
|
|
972
|
+
field :failed_constraints, [:array, [:model, "DetailsErrorFailedConstraintsItem"]], wire: "failed_constraints", required: false
|
|
973
|
+
end
|
|
974
|
+
|
|
975
|
+
class DetailsErrorFailedConstraintsItem < Model
|
|
976
|
+
##
|
|
977
|
+
# :attr_reader: message
|
|
978
|
+
# Human-readable description of the violated constraint.
|
|
979
|
+
field :message, :string, wire: "message", required: false
|
|
980
|
+
##
|
|
981
|
+
# :attr_reader: reference
|
|
982
|
+
# Name of the field that violated the constraint.
|
|
983
|
+
field :reference, :string, wire: "reference", required: false
|
|
984
|
+
end
|
|
985
|
+
|
|
986
|
+
# Details of the device used to create the transaction.
|
|
987
|
+
class Device < Model
|
|
988
|
+
##
|
|
989
|
+
# :attr_reader: name
|
|
990
|
+
# Device name.
|
|
991
|
+
field :name, :string, wire: "name", required: false
|
|
992
|
+
##
|
|
993
|
+
# :attr_reader: system_name
|
|
994
|
+
# Device OS.
|
|
995
|
+
field :system_name, :string, wire: "system_name", required: false
|
|
996
|
+
##
|
|
997
|
+
# :attr_reader: model
|
|
998
|
+
# Device model.
|
|
999
|
+
field :model, :string, wire: "model", required: false
|
|
1000
|
+
##
|
|
1001
|
+
# :attr_reader: system_version
|
|
1002
|
+
# Device OS version.
|
|
1003
|
+
field :system_version, :string, wire: "system_version", required: false
|
|
1004
|
+
##
|
|
1005
|
+
# :attr_reader: uuid
|
|
1006
|
+
# Device UUID.
|
|
1007
|
+
field :uuid, :string, wire: "uuid", required: false
|
|
1008
|
+
end
|
|
1009
|
+
|
|
1010
|
+
# Object representing information about single discount line.
|
|
1011
|
+
class DiscountLine < Model
|
|
1012
|
+
##
|
|
1013
|
+
# :attr_reader: id
|
|
1014
|
+
# An id used to associate a discount line with a specific discount.
|
|
1015
|
+
# Since we can apply multiple discounts (e.g. 2x 10% whole cart off)
|
|
1016
|
+
# we need to be able to identify which discount line belongs to which cart discount.
|
|
1017
|
+
# Recommended to use UUID identifiers.
|
|
1018
|
+
field :id, :string, wire: "id", required: false
|
|
1019
|
+
##
|
|
1020
|
+
# :attr_reader: description
|
|
1021
|
+
# A description or reason of the discount.
|
|
1022
|
+
field :description, :string, wire: "description", required: false
|
|
1023
|
+
##
|
|
1024
|
+
# :attr_reader: level
|
|
1025
|
+
# Specifies where discount was applied by user (either merchant or consumer):
|
|
1026
|
+
# - CART: Applied to the whole cart (calculated and distributed per sale item)
|
|
1027
|
+
# - ITEM: Applied to specific sale item
|
|
1028
|
+
#
|
|
1029
|
+
# *Accepted values:* ["ITEM", "CART"].
|
|
1030
|
+
field :level, :string, wire: "level", required: true
|
|
1031
|
+
##
|
|
1032
|
+
# :attr_reader: source
|
|
1033
|
+
field :source, [:model, "DiscountSource"], wire: "source", required: true
|
|
1034
|
+
##
|
|
1035
|
+
# :attr_reader: value
|
|
1036
|
+
field :value, [:model, "DiscountValue"], wire: "value", required: true
|
|
1037
|
+
##
|
|
1038
|
+
# :attr_reader: net_amount
|
|
1039
|
+
# The net amount of the discount.
|
|
1040
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
1041
|
+
field :net_amount, :integer, wire: "net_amount", required: true
|
|
1042
|
+
##
|
|
1043
|
+
# :attr_reader: gross_amount
|
|
1044
|
+
# The gross amount of the discount.
|
|
1045
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
1046
|
+
field :gross_amount, :integer, wire: "gross_amount", required: true
|
|
1047
|
+
##
|
|
1048
|
+
# :attr_reader: tax_amount
|
|
1049
|
+
# The tax amount of the discount.
|
|
1050
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
1051
|
+
field :tax_amount, :integer, wire: "tax_amount", required: true
|
|
1052
|
+
end
|
|
1053
|
+
|
|
1054
|
+
# The source of discount. Exactly one property must be set.
|
|
1055
|
+
class DiscountSource < Model
|
|
1056
|
+
##
|
|
1057
|
+
# :attr_reader: ad_hoc
|
|
1058
|
+
field :ad_hoc, [:model, "DiscountSourceAdHoc"], wire: "ad_hoc", required: false
|
|
1059
|
+
##
|
|
1060
|
+
# :attr_reader: basic
|
|
1061
|
+
field :basic, [:model, "DiscountSourceBasic"], wire: "basic", required: false
|
|
1062
|
+
##
|
|
1063
|
+
# :attr_reader: coupon
|
|
1064
|
+
field :coupon, [:model, "DiscountSourceCoupon"], wire: "coupon", required: false
|
|
1065
|
+
##
|
|
1066
|
+
# :attr_reader: offer
|
|
1067
|
+
field :offer, [:model, "DiscountSourceOffer"], wire: "offer", required: false
|
|
1068
|
+
##
|
|
1069
|
+
# :attr_reader: loyalty
|
|
1070
|
+
field :loyalty, [:model, "DiscountSourceLoyalty"], wire: "loyalty", required: false
|
|
1071
|
+
end
|
|
1072
|
+
|
|
1073
|
+
# Discount created ad-hoc on device during checkout.
|
|
1074
|
+
class DiscountSourceAdHoc < Model
|
|
1075
|
+
##
|
|
1076
|
+
# :attr_reader: id
|
|
1077
|
+
# The unique identifier of the ad-hoc discount.
|
|
1078
|
+
field :id, :string, wire: "id", required: false
|
|
1079
|
+
##
|
|
1080
|
+
# :attr_reader: name
|
|
1081
|
+
# The name of the ad-hoc discount.
|
|
1082
|
+
field :name, :string, wire: "name", required: false
|
|
1083
|
+
##
|
|
1084
|
+
# :attr_reader: description
|
|
1085
|
+
# The description of the ad-hoc discount.
|
|
1086
|
+
field :description, :string, wire: "description", required: false
|
|
1087
|
+
end
|
|
1088
|
+
|
|
1089
|
+
# Preset discount applied manually on the POS.
|
|
1090
|
+
class DiscountSourceBasic < Model
|
|
1091
|
+
##
|
|
1092
|
+
# :attr_reader: id
|
|
1093
|
+
# The unique identifier of the basic discount.
|
|
1094
|
+
field :id, :string, wire: "id", required: true
|
|
1095
|
+
##
|
|
1096
|
+
# :attr_reader: name
|
|
1097
|
+
# The name of the basic discount.
|
|
1098
|
+
field :name, :string, wire: "name", required: true
|
|
1099
|
+
##
|
|
1100
|
+
# :attr_reader: description
|
|
1101
|
+
# The description of the loyalty discount.
|
|
1102
|
+
field :description, [:union, [:string, :nil]], wire: "description", required: false
|
|
1103
|
+
##
|
|
1104
|
+
# :attr_reader: application_mode
|
|
1105
|
+
field :application_mode, :string, wire: "application_mode", required: true
|
|
1106
|
+
end
|
|
1107
|
+
|
|
1108
|
+
# Discount applied manually when entering a coupon code at checkout.
|
|
1109
|
+
class DiscountSourceCoupon < Model
|
|
1110
|
+
##
|
|
1111
|
+
# :attr_reader: id
|
|
1112
|
+
# The unique identifier of the coupon discount.
|
|
1113
|
+
field :id, :string, wire: "id", required: true
|
|
1114
|
+
##
|
|
1115
|
+
# :attr_reader: code
|
|
1116
|
+
# The coupon code.
|
|
1117
|
+
field :code, :string, wire: "code", required: true
|
|
1118
|
+
##
|
|
1119
|
+
# :attr_reader: name
|
|
1120
|
+
# The name of the coupon discount.
|
|
1121
|
+
field :name, :string, wire: "name", required: true
|
|
1122
|
+
##
|
|
1123
|
+
# :attr_reader: description
|
|
1124
|
+
# The description of the coupon discount.
|
|
1125
|
+
field :description, [:union, [:string, :nil]], wire: "description", required: false
|
|
1126
|
+
##
|
|
1127
|
+
# :attr_reader: discount_class
|
|
1128
|
+
field :discount_class, [:union, [:string, :nil]], wire: "discount_class", required: false
|
|
1129
|
+
##
|
|
1130
|
+
# :attr_reader: application_mode
|
|
1131
|
+
field :application_mode, :string, wire: "application_mode", required: true
|
|
1132
|
+
end
|
|
1133
|
+
|
|
1134
|
+
# Discount applied when redeeming a reward from the merchant's loyalty scheme.
|
|
1135
|
+
class DiscountSourceLoyalty < Model
|
|
1136
|
+
##
|
|
1137
|
+
# :attr_reader: id
|
|
1138
|
+
# The unique identifier of the promotion or reward.
|
|
1139
|
+
field :id, :string, wire: "id", required: true
|
|
1140
|
+
##
|
|
1141
|
+
# :attr_reader: loyalty_type
|
|
1142
|
+
field :loyalty_type, :string, wire: "loyalty_type", required: true
|
|
1143
|
+
##
|
|
1144
|
+
# :attr_reader: scheme_type
|
|
1145
|
+
field :scheme_type, :string, wire: "scheme_type", required: true
|
|
1146
|
+
##
|
|
1147
|
+
# :attr_reader: points
|
|
1148
|
+
# The number of points used for this loyalty discount.
|
|
1149
|
+
# Must be a positive integer if the scheme type is POINTS.
|
|
1150
|
+
# Must not be populated if the scheme type is STAMPS.
|
|
1151
|
+
field :points, [:union, [:integer, :nil]], wire: "points", required: false
|
|
1152
|
+
##
|
|
1153
|
+
# :attr_reader: name
|
|
1154
|
+
# The name of the loyalty discount.
|
|
1155
|
+
field :name, :string, wire: "name", required: true
|
|
1156
|
+
##
|
|
1157
|
+
# :attr_reader: description
|
|
1158
|
+
# The description of the loyalty discount.
|
|
1159
|
+
field :description, [:union, [:string, :nil]], wire: "description", required: false
|
|
1160
|
+
##
|
|
1161
|
+
# :attr_reader: discount_class
|
|
1162
|
+
field :discount_class, [:union, [:string, :nil]], wire: "discount_class", required: false
|
|
1163
|
+
##
|
|
1164
|
+
# :attr_reader: application_mode
|
|
1165
|
+
field :application_mode, :string, wire: "application_mode", required: true
|
|
1166
|
+
end
|
|
1167
|
+
|
|
1168
|
+
# Discount applied automatically when cart is updated based on preset promotions.
|
|
1169
|
+
class DiscountSourceOffer < Model
|
|
1170
|
+
##
|
|
1171
|
+
# :attr_reader: id
|
|
1172
|
+
# The unique identifier of the offer discount.
|
|
1173
|
+
field :id, :string, wire: "id", required: true
|
|
1174
|
+
##
|
|
1175
|
+
# :attr_reader: name
|
|
1176
|
+
# The name of the offer discount.
|
|
1177
|
+
field :name, :string, wire: "name", required: true
|
|
1178
|
+
##
|
|
1179
|
+
# :attr_reader: description
|
|
1180
|
+
# The description of the offer discount.
|
|
1181
|
+
field :description, [:union, [:string, :nil]], wire: "description", required: false
|
|
1182
|
+
##
|
|
1183
|
+
# :attr_reader: discount_class
|
|
1184
|
+
field :discount_class, [:union, [:string, :nil]], wire: "discount_class", required: false
|
|
1185
|
+
##
|
|
1186
|
+
# :attr_reader: application_mode
|
|
1187
|
+
field :application_mode, :string, wire: "application_mode", required: true
|
|
1188
|
+
end
|
|
1189
|
+
|
|
1190
|
+
# The value type of the discount, either a percentage based or absolute monetary value.
|
|
1191
|
+
#
|
|
1192
|
+
# It is required that only one of the following is set:
|
|
1193
|
+
# - absolute
|
|
1194
|
+
# - percentage.
|
|
1195
|
+
class DiscountValue < Model
|
|
1196
|
+
##
|
|
1197
|
+
# :attr_reader: absolute
|
|
1198
|
+
# The absolute value in minor units of the currency according to the Sale.currency.scale.
|
|
1199
|
+
# Example: 10000 = 10.00
|
|
1200
|
+
field :absolute, :integer, wire: "absolute", required: false
|
|
1201
|
+
##
|
|
1202
|
+
# :attr_reader: percentage
|
|
1203
|
+
# The percentage in minor units (1/100000).
|
|
1204
|
+
#
|
|
1205
|
+
# Examples:
|
|
1206
|
+
# - 10% -> 0.10 (decimal) = 10000 (minor units)
|
|
1207
|
+
# - 15.5% -> 0.155 (decimal) = 15500 (minor units)
|
|
1208
|
+
# - 0.001% -> 0.00001 (decimal) = 1 (minor units)
|
|
1209
|
+
field :percentage, :integer, wire: "percentage", required: false
|
|
1210
|
+
end
|
|
1211
|
+
|
|
1212
|
+
# Details of the ELV card account associated with the transaction.
|
|
1213
|
+
class ElvCardAccount < Model
|
|
1214
|
+
##
|
|
1215
|
+
# :attr_reader: sort_code
|
|
1216
|
+
# ELV card sort code.
|
|
1217
|
+
field :sort_code, :string, wire: "sort_code", required: false
|
|
1218
|
+
##
|
|
1219
|
+
# :attr_reader: last_4_digits
|
|
1220
|
+
# ELV card account number last 4 digits.
|
|
1221
|
+
field :last_4_digits, :string, wire: "last_4_digits", required: false
|
|
1222
|
+
##
|
|
1223
|
+
# :attr_reader: sequence_no
|
|
1224
|
+
# ELV card sequence number.
|
|
1225
|
+
field :sequence_no, :integer, wire: "sequence_no", required: false
|
|
1226
|
+
##
|
|
1227
|
+
# :attr_reader: iban
|
|
1228
|
+
# ELV IBAN.
|
|
1229
|
+
field :iban, :string, wire: "iban", required: false
|
|
1230
|
+
end
|
|
1231
|
+
|
|
1232
|
+
# Details of an API error.
|
|
1233
|
+
class Error < Model
|
|
1234
|
+
##
|
|
1235
|
+
# :attr_reader: message
|
|
1236
|
+
# Short description of the error.
|
|
1237
|
+
field :message, :string, wire: "message", required: false
|
|
1238
|
+
##
|
|
1239
|
+
# :attr_reader: error_code
|
|
1240
|
+
# Platform code for the error.
|
|
1241
|
+
field :error_code, :string, wire: "error_code", required: false
|
|
1242
|
+
end
|
|
1243
|
+
|
|
1244
|
+
# Error payload with the invalid parameter reference.
|
|
1245
|
+
class ErrorExtended < Model
|
|
1246
|
+
##
|
|
1247
|
+
# :attr_reader: param
|
|
1248
|
+
# Parameter name (with relative location) to which the error applies. Parameters from embedded resources are displayed using dot notation. For example, `card.name` refers to the `name` parameter embedded in the `card` object.
|
|
1249
|
+
field :param, :string, wire: "param", required: false
|
|
1250
|
+
##
|
|
1251
|
+
# :attr_reader: message
|
|
1252
|
+
# Short description of the error.
|
|
1253
|
+
field :message, :string, wire: "message", required: false
|
|
1254
|
+
##
|
|
1255
|
+
# :attr_reader: error_code
|
|
1256
|
+
# Platform code for the error.
|
|
1257
|
+
field :error_code, :string, wire: "error_code", required: false
|
|
1258
|
+
end
|
|
1259
|
+
|
|
1260
|
+
# Details of an error returned for a forbidden request.
|
|
1261
|
+
class ErrorForbidden < Model
|
|
1262
|
+
##
|
|
1263
|
+
# :attr_reader: error_message
|
|
1264
|
+
# Short description of the error.
|
|
1265
|
+
field :error_message, :string, wire: "error_message", required: false
|
|
1266
|
+
##
|
|
1267
|
+
# :attr_reader: error_code
|
|
1268
|
+
# Platform code for the error.
|
|
1269
|
+
field :error_code, :string, wire: "error_code", required: false
|
|
1270
|
+
##
|
|
1271
|
+
# :attr_reader: status_code
|
|
1272
|
+
# HTTP status code for the error.
|
|
1273
|
+
field :status_code, :string, wire: "status_code", required: false
|
|
1274
|
+
end
|
|
1275
|
+
|
|
1276
|
+
class Event < Model
|
|
1277
|
+
##
|
|
1278
|
+
# :attr_reader: id
|
|
1279
|
+
# Unique id for this event
|
|
1280
|
+
field :id, :string, wire: "id", required: true
|
|
1281
|
+
##
|
|
1282
|
+
# :attr_reader: type
|
|
1283
|
+
field :type, :string, wire: "type", required: true
|
|
1284
|
+
##
|
|
1285
|
+
# :attr_reader: created_at
|
|
1286
|
+
# UTC timestamp when the event was created
|
|
1287
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
1288
|
+
##
|
|
1289
|
+
# :attr_reader: object
|
|
1290
|
+
field :object, [:model, "EventObject"], wire: "object", required: true
|
|
1291
|
+
end
|
|
1292
|
+
|
|
1293
|
+
class EventObject < Model
|
|
1294
|
+
##
|
|
1295
|
+
# :attr_reader: id
|
|
1296
|
+
# Identifier of the resource associated with the event
|
|
1297
|
+
field :id, :string, wire: "id", required: true
|
|
1298
|
+
##
|
|
1299
|
+
# :attr_reader: type
|
|
1300
|
+
# Type of the resource associated with the event
|
|
1301
|
+
field :type, :string, wire: "type", required: true
|
|
1302
|
+
##
|
|
1303
|
+
# :attr_reader: url
|
|
1304
|
+
# URL pointing to the resource or relevant documentation
|
|
1305
|
+
field :url, :string, wire: "url", required: true
|
|
1306
|
+
end
|
|
1307
|
+
|
|
1308
|
+
# Final price amounts after all calculations and adjustments.
|
|
1309
|
+
class FinalPriceAmounts < Model
|
|
1310
|
+
##
|
|
1311
|
+
# :attr_reader: discounts
|
|
1312
|
+
# Discounts applied.
|
|
1313
|
+
#
|
|
1314
|
+
# Important:
|
|
1315
|
+
# Discount amounts shouldn't take effect on net and gross amounts.
|
|
1316
|
+
#
|
|
1317
|
+
# Discount money amounts depend on where discount was applied:
|
|
1318
|
+
# - for item level discount: whole discount money amount is applied
|
|
1319
|
+
# - for cart level discount: only part of the whole amount is applied
|
|
1320
|
+
# (discount money value is split on each line item)
|
|
1321
|
+
field :discounts, [:array, [:model, "DiscountLine"]], wire: "discounts", required: false
|
|
1322
|
+
##
|
|
1323
|
+
# :attr_reader: total_net_amount_final
|
|
1324
|
+
# The final net amount includes discounts and modifiers. It does NOT include taxes. If no discounts are applied, it should be equal to total_net_amount.
|
|
1325
|
+
field :total_net_amount_final, :integer, wire: "total_net_amount_final", required: true
|
|
1326
|
+
##
|
|
1327
|
+
# :attr_reader: total_gross_amount_final
|
|
1328
|
+
# The final gross amount includes discounts, modifiers, and taxes. If no discounts are applied, it should be equal to total_gross_amount.
|
|
1329
|
+
field :total_gross_amount_final, :integer, wire: "total_gross_amount_final", required: true
|
|
1330
|
+
##
|
|
1331
|
+
# :attr_reader: taxes_final
|
|
1332
|
+
# Taxes applied on top of `total_net_amount_final` amount resulting in `total_gross_amount_final` amount.
|
|
1333
|
+
# If no discounts are applied, it should be equal to `taxes`.
|
|
1334
|
+
field :taxes_final, [:array, [:model, "PositiveTaxLine"]], wire: "taxes_final", required: true
|
|
1335
|
+
end
|
|
1336
|
+
|
|
1337
|
+
# A single payout-related record.
|
|
1338
|
+
#
|
|
1339
|
+
# A record can represent either:
|
|
1340
|
+
# - an actual payout sent to the merchant (`type = PAYOUT`)
|
|
1341
|
+
# - a deduction applied against merchant funds for a refund, chargeback, direct debit return, or balance adjustment
|
|
1342
|
+
class FinancialPayout < Model
|
|
1343
|
+
##
|
|
1344
|
+
# :attr_reader: id
|
|
1345
|
+
# Unique identifier of the payout-related record.
|
|
1346
|
+
field :id, :integer, wire: "id", required: true
|
|
1347
|
+
##
|
|
1348
|
+
# :attr_reader: type
|
|
1349
|
+
# High-level payout record category.
|
|
1350
|
+
field :type, :string, wire: "type", required: true
|
|
1351
|
+
##
|
|
1352
|
+
# :attr_reader: amount
|
|
1353
|
+
# Amount of the payout or deduction in major units.
|
|
1354
|
+
field :amount, :number, wire: "amount", required: true
|
|
1355
|
+
##
|
|
1356
|
+
# :attr_reader: date
|
|
1357
|
+
# Payout date associated with the record, in `YYYY-MM-DD` format.
|
|
1358
|
+
field :date, :string, wire: "date", required: true
|
|
1359
|
+
##
|
|
1360
|
+
# :attr_reader: currency
|
|
1361
|
+
# Three-letter ISO 4217 currency code of the payout.
|
|
1362
|
+
field :currency, :string, wire: "currency", required: true
|
|
1363
|
+
##
|
|
1364
|
+
# :attr_reader: fee
|
|
1365
|
+
# Fee amount associated with the payout record, in major units.
|
|
1366
|
+
field :fee, :number, wire: "fee", required: true
|
|
1367
|
+
##
|
|
1368
|
+
# :attr_reader: status
|
|
1369
|
+
# Merchant-facing outcome of the payout record.
|
|
1370
|
+
field :status, :string, wire: "status", required: true
|
|
1371
|
+
##
|
|
1372
|
+
# :attr_reader: reference
|
|
1373
|
+
# Processor or payout reference associated with the record.
|
|
1374
|
+
field :reference, :string, wire: "reference", required: true
|
|
1375
|
+
##
|
|
1376
|
+
# :attr_reader: transaction_code
|
|
1377
|
+
# Transaction code of the original sale associated with the payout or deduction.
|
|
1378
|
+
field :transaction_code, :string, wire: "transaction_code", required: true
|
|
1379
|
+
end
|
|
1380
|
+
|
|
1381
|
+
class GetPaymentMethodsResponse < Model
|
|
1382
|
+
##
|
|
1383
|
+
# :attr_reader: available_payment_methods
|
|
1384
|
+
# Payment methods available to the merchant for the checkout.
|
|
1385
|
+
field :available_payment_methods, [:array, [:model, "GetPaymentMethodsResponseAvailablePaymentMethodsItem"]], wire: "available_payment_methods", required: false
|
|
1386
|
+
end
|
|
1387
|
+
|
|
1388
|
+
class GetPaymentMethodsResponseAvailablePaymentMethodsItem < Model
|
|
1389
|
+
##
|
|
1390
|
+
# :attr_reader: id
|
|
1391
|
+
# Unique identifier of the payment method.
|
|
1392
|
+
field :id, :string, wire: "id", required: true
|
|
1393
|
+
end
|
|
1394
|
+
|
|
1395
|
+
class GetReaderCheckoutResponse < Model
|
|
1396
|
+
##
|
|
1397
|
+
# :attr_reader: data
|
|
1398
|
+
field :data, [:model, "GetReaderCheckoutResponseData"], wire: "data", required: true
|
|
1399
|
+
end
|
|
1400
|
+
|
|
1401
|
+
class GetReaderCheckoutResponseData < Model
|
|
1402
|
+
##
|
|
1403
|
+
# :attr_reader: card_type
|
|
1404
|
+
# Type of the card, or null when no card type was specified.
|
|
1405
|
+
field :card_type, [:union, [:string, :nil]], wire: "card_type", required: true
|
|
1406
|
+
##
|
|
1407
|
+
# :attr_reader: checkout_id
|
|
1408
|
+
# Unique identifier for the checkout
|
|
1409
|
+
field :checkout_id, :string, wire: "checkout_id", required: true
|
|
1410
|
+
##
|
|
1411
|
+
# :attr_reader: client_transaction_id
|
|
1412
|
+
# Client transaction identifier associated with the checkout
|
|
1413
|
+
field :client_transaction_id, :string, wire: "client_transaction_id", required: true
|
|
1414
|
+
##
|
|
1415
|
+
# :attr_reader: created_at
|
|
1416
|
+
# Checkout creation timestamp
|
|
1417
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
1418
|
+
##
|
|
1419
|
+
# :attr_reader: installments
|
|
1420
|
+
# Number of installments for the transaction. Required for some countries.
|
|
1421
|
+
field :installments, [:union, [:integer, :nil]], wire: "installments", required: true
|
|
1422
|
+
##
|
|
1423
|
+
# :attr_reader: payment_failure_reason
|
|
1424
|
+
# Reason for the payment failure, or null when no failure reason is available.
|
|
1425
|
+
field :payment_failure_reason, [:union, [:string, :nil]], wire: "payment_failure_reason", required: true
|
|
1426
|
+
##
|
|
1427
|
+
# :attr_reader: payment_status
|
|
1428
|
+
# Status of the payment, or null when no payment status is available.
|
|
1429
|
+
field :payment_status, [:union, [:string, :nil]], wire: "payment_status", required: true
|
|
1430
|
+
##
|
|
1431
|
+
# :attr_reader: payment_type
|
|
1432
|
+
# Type of the payment. Required for some countries
|
|
1433
|
+
field :payment_type, :string, wire: "payment_type", required: true
|
|
1434
|
+
##
|
|
1435
|
+
# :attr_reader: reader_firmware_version
|
|
1436
|
+
# Reader firmware version
|
|
1437
|
+
field :reader_firmware_version, :string, wire: "reader_firmware_version", required: true
|
|
1438
|
+
##
|
|
1439
|
+
# :attr_reader: reader_serial_number
|
|
1440
|
+
# Device serial number
|
|
1441
|
+
field :reader_serial_number, :string, wire: "reader_serial_number", required: true
|
|
1442
|
+
##
|
|
1443
|
+
# :attr_reader: status
|
|
1444
|
+
# Current status of the checkout
|
|
1445
|
+
field :status, :string, wire: "status", required: true
|
|
1446
|
+
##
|
|
1447
|
+
# :attr_reader: total_amount
|
|
1448
|
+
# Amount structure.
|
|
1449
|
+
#
|
|
1450
|
+
# The amount is represented as an integer value altogether with the currency and the minor unit.
|
|
1451
|
+
#
|
|
1452
|
+
# For example, EUR 1.00 is represented as value 100 with minor unit of 2.
|
|
1453
|
+
field :total_amount, [:model, "CreateReaderCheckoutRequestTotalAmount"], wire: "total_amount", required: true
|
|
1454
|
+
##
|
|
1455
|
+
# :attr_reader: updated_at
|
|
1456
|
+
# Checkout last update timestamp
|
|
1457
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
1458
|
+
##
|
|
1459
|
+
# :attr_reader: valid_until
|
|
1460
|
+
# Checkout expiration timestamp. After this time, the checkout will be automatically cancelled.
|
|
1461
|
+
field :valid_until, [:union, [:string, :nil]], wire: "valid_until", required: true
|
|
1462
|
+
end
|
|
1463
|
+
|
|
1464
|
+
# Menu lock settings reported by the reader, or the last saved settings when offline.
|
|
1465
|
+
class GetReaderSettingsResponse < Model
|
|
1466
|
+
##
|
|
1467
|
+
# :attr_reader: data
|
|
1468
|
+
field :data, [:model, "GetReaderSettingsResponseData"], wire: "data", required: true
|
|
1469
|
+
end
|
|
1470
|
+
|
|
1471
|
+
class GetReaderSettingsResponseData < Model
|
|
1472
|
+
##
|
|
1473
|
+
# :attr_reader: menu_lock
|
|
1474
|
+
# Menu lock configuration. Fields may be absent if no value is available.
|
|
1475
|
+
field :menu_lock, [:model, "GetReaderSettingsResponseDataMenuLock"], wire: "menu_lock", required: true
|
|
1476
|
+
end
|
|
1477
|
+
|
|
1478
|
+
# Menu lock configuration. Fields may be absent if no value is available.
|
|
1479
|
+
class GetReaderSettingsResponseDataMenuLock < Model
|
|
1480
|
+
##
|
|
1481
|
+
# :attr_reader: enabled
|
|
1482
|
+
# Whether menu lock is enabled.
|
|
1483
|
+
field :enabled, :boolean, wire: "enabled", required: false
|
|
1484
|
+
##
|
|
1485
|
+
# :attr_reader: passcode
|
|
1486
|
+
# Four-digit PIN used to unlock the reader's menu.
|
|
1487
|
+
field :passcode, :string, wire: "passcode", required: false
|
|
1488
|
+
end
|
|
1489
|
+
|
|
1490
|
+
# Hosted Checkout configuration. Enable it to receive a SumUp-hosted payment page URL in the checkout response.
|
|
1491
|
+
class HostedCheckout < Model
|
|
1492
|
+
##
|
|
1493
|
+
# :attr_reader: enabled
|
|
1494
|
+
# Whether the checkout should include a SumUp-hosted payment page.
|
|
1495
|
+
field :enabled, :boolean, wire: "enabled", required: true
|
|
1496
|
+
end
|
|
1497
|
+
|
|
1498
|
+
# Pending invitation for membership.
|
|
1499
|
+
class Invite < Model
|
|
1500
|
+
##
|
|
1501
|
+
# :attr_reader: email
|
|
1502
|
+
# Email address of the invited user.
|
|
1503
|
+
field :email, :string, wire: "email", required: true
|
|
1504
|
+
##
|
|
1505
|
+
# :attr_reader: expires_at
|
|
1506
|
+
field :expires_at, :string, wire: "expires_at", required: true
|
|
1507
|
+
end
|
|
1508
|
+
|
|
1509
|
+
# Details of a link to a related resource.
|
|
1510
|
+
class Link < Model
|
|
1511
|
+
##
|
|
1512
|
+
# :attr_reader: rel
|
|
1513
|
+
# Relation of the linked resource to the current resource.
|
|
1514
|
+
field :rel, :string, wire: "rel", required: false
|
|
1515
|
+
##
|
|
1516
|
+
# :attr_reader: href
|
|
1517
|
+
# URL for accessing the related resource.
|
|
1518
|
+
field :href, :string, wire: "href", required: false
|
|
1519
|
+
##
|
|
1520
|
+
# :attr_reader: type
|
|
1521
|
+
# Media type of the linked resource.
|
|
1522
|
+
field :type, :string, wire: "type", required: false
|
|
1523
|
+
##
|
|
1524
|
+
# :attr_reader: min_amount
|
|
1525
|
+
# Minimum amount allowed for a refund, in major units.
|
|
1526
|
+
field :min_amount, :number, wire: "min_amount", required: false
|
|
1527
|
+
##
|
|
1528
|
+
# :attr_reader: max_amount
|
|
1529
|
+
# Maximum amount allowed for a refund, in major units.
|
|
1530
|
+
field :max_amount, :number, wire: "max_amount", required: false
|
|
1531
|
+
end
|
|
1532
|
+
|
|
1533
|
+
class ListMembershipsResponse < Model
|
|
1534
|
+
##
|
|
1535
|
+
# :attr_reader: items
|
|
1536
|
+
field :items, [:array, [:model, "Membership"]], wire: "items", required: true
|
|
1537
|
+
##
|
|
1538
|
+
# :attr_reader: total_count
|
|
1539
|
+
field :total_count, :integer, wire: "total_count", required: true
|
|
1540
|
+
end
|
|
1541
|
+
|
|
1542
|
+
class ListMerchantMembersResponse < Model
|
|
1543
|
+
##
|
|
1544
|
+
# :attr_reader: items
|
|
1545
|
+
field :items, [:array, [:model, "Member"]], wire: "items", required: true
|
|
1546
|
+
##
|
|
1547
|
+
# :attr_reader: total_count
|
|
1548
|
+
field :total_count, :integer, wire: "total_count", required: false
|
|
1549
|
+
end
|
|
1550
|
+
|
|
1551
|
+
class ListMerchantRolesResponse < Model
|
|
1552
|
+
##
|
|
1553
|
+
# :attr_reader: items
|
|
1554
|
+
field :items, [:array, [:model, "Role"]], wire: "items", required: true
|
|
1555
|
+
end
|
|
1556
|
+
|
|
1557
|
+
class ListPersonsResponseBody < Model
|
|
1558
|
+
##
|
|
1559
|
+
# :attr_reader: items
|
|
1560
|
+
field :items, [:array, [:model, "Person"]], wire: "items", required: true
|
|
1561
|
+
end
|
|
1562
|
+
|
|
1563
|
+
class ListReadersResponse < Model
|
|
1564
|
+
##
|
|
1565
|
+
# :attr_reader: items
|
|
1566
|
+
field :items, [:array, [:model, "Reader"]], wire: "items", required: true
|
|
1567
|
+
end
|
|
1568
|
+
|
|
1569
|
+
class ListTransactionsV21Response < Model
|
|
1570
|
+
##
|
|
1571
|
+
# :attr_reader: items
|
|
1572
|
+
# Transactions in the current result page.
|
|
1573
|
+
field :items, [:array, [:model, "TransactionHistory"]], wire: "items", required: false
|
|
1574
|
+
##
|
|
1575
|
+
# :attr_reader: links
|
|
1576
|
+
# Pagination links for navigating the transaction history.
|
|
1577
|
+
field :links, [:array, [:model, "TransactionsHistoryLink"]], wire: "links", required: false
|
|
1578
|
+
end
|
|
1579
|
+
|
|
1580
|
+
# Physical Merchant Location with a customer-facing name and address.
|
|
1581
|
+
class Location < Model
|
|
1582
|
+
##
|
|
1583
|
+
# :attr_reader: id
|
|
1584
|
+
field :id, :string, wire: "id", required: true
|
|
1585
|
+
##
|
|
1586
|
+
# :attr_reader: name
|
|
1587
|
+
# Customer-facing Location name.
|
|
1588
|
+
field :name, :string, wire: "name", required: true
|
|
1589
|
+
##
|
|
1590
|
+
# :attr_reader: business_name
|
|
1591
|
+
# Customer-facing business name used at the Location.
|
|
1592
|
+
field :business_name, :string, wire: "business_name", required: false
|
|
1593
|
+
##
|
|
1594
|
+
# :attr_reader: email
|
|
1595
|
+
# Public email address for the Location.
|
|
1596
|
+
field :email, :string, wire: "email", required: false
|
|
1597
|
+
##
|
|
1598
|
+
# :attr_reader: phone_number
|
|
1599
|
+
# Public phone number for the Location in E.164 format.
|
|
1600
|
+
field :phone_number, :string, wire: "phone_number", required: false
|
|
1601
|
+
##
|
|
1602
|
+
# :attr_reader: website
|
|
1603
|
+
# Public website for the Location.
|
|
1604
|
+
field :website, :string, wire: "website", required: false
|
|
1605
|
+
##
|
|
1606
|
+
# :attr_reader: is_default
|
|
1607
|
+
# Whether this is the default Location for the Merchant.
|
|
1608
|
+
field :is_default, :boolean, wire: "is_default", required: true
|
|
1609
|
+
##
|
|
1610
|
+
# :attr_reader: address
|
|
1611
|
+
# Physical address of the Location.
|
|
1612
|
+
field :address, [:model, "MerchantsAddress"], wire: "address", required: true
|
|
1613
|
+
##
|
|
1614
|
+
# :attr_reader: created_at
|
|
1615
|
+
# Time when the Location was created.
|
|
1616
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
1617
|
+
##
|
|
1618
|
+
# :attr_reader: updated_at
|
|
1619
|
+
# Time when the Location was last updated.
|
|
1620
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
1621
|
+
end
|
|
1622
|
+
|
|
1623
|
+
# Mandate details used when a checkout should create a reusable card token for future recurring or merchant-initiated payments.
|
|
1624
|
+
class MandatePayload < Model
|
|
1625
|
+
##
|
|
1626
|
+
# :attr_reader: type
|
|
1627
|
+
# Type of mandate to create for the saved payment instrument.
|
|
1628
|
+
field :type, :string, wire: "type", required: true
|
|
1629
|
+
##
|
|
1630
|
+
# :attr_reader: user_agent
|
|
1631
|
+
# Browser or client user agent observed when consent was collected.
|
|
1632
|
+
field :user_agent, :string, wire: "user_agent", required: true
|
|
1633
|
+
##
|
|
1634
|
+
# :attr_reader: user_ip
|
|
1635
|
+
# IP address of the payer when the mandate was accepted.
|
|
1636
|
+
field :user_ip, :string, wire: "user_ip", required: false
|
|
1637
|
+
end
|
|
1638
|
+
|
|
1639
|
+
# Details of the mandate linked to the saved payment instrument.
|
|
1640
|
+
class MandateResponse < Model
|
|
1641
|
+
##
|
|
1642
|
+
# :attr_reader: type
|
|
1643
|
+
# Type of mandate stored for the checkout or payment instrument.
|
|
1644
|
+
field :type, :string, wire: "type", required: false
|
|
1645
|
+
##
|
|
1646
|
+
# :attr_reader: status
|
|
1647
|
+
# Current lifecycle status of the mandate.
|
|
1648
|
+
field :status, :string, wire: "status", required: false
|
|
1649
|
+
##
|
|
1650
|
+
# :attr_reader: merchant_code
|
|
1651
|
+
# Short unique identifier for the merchant for which the mandate is valid.
|
|
1652
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
1653
|
+
end
|
|
1654
|
+
|
|
1655
|
+
# A member is user within specific resource identified by resource id, resource type, and associated roles.
|
|
1656
|
+
class Member < Model
|
|
1657
|
+
##
|
|
1658
|
+
# :attr_reader: id
|
|
1659
|
+
# ID of the member.
|
|
1660
|
+
field :id, :string, wire: "id", required: true
|
|
1661
|
+
##
|
|
1662
|
+
# :attr_reader: roles
|
|
1663
|
+
# User's roles.
|
|
1664
|
+
field :roles, [:array, :string], wire: "roles", required: true
|
|
1665
|
+
##
|
|
1666
|
+
# :attr_reader: permissions
|
|
1667
|
+
# User's permissions.
|
|
1668
|
+
field :permissions, [:array, :string], wire: "permissions", required: true
|
|
1669
|
+
##
|
|
1670
|
+
# :attr_reader: created_at
|
|
1671
|
+
# The timestamp of when the member was created.
|
|
1672
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
1673
|
+
##
|
|
1674
|
+
# :attr_reader: updated_at
|
|
1675
|
+
# The timestamp of when the member was last updated.
|
|
1676
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
1677
|
+
##
|
|
1678
|
+
# :attr_reader: user
|
|
1679
|
+
field :user, [:model, "MembershipUser"], wire: "user", required: false
|
|
1680
|
+
##
|
|
1681
|
+
# :attr_reader: invite
|
|
1682
|
+
field :invite, [:model, "Invite"], wire: "invite", required: false
|
|
1683
|
+
##
|
|
1684
|
+
# :attr_reader: status
|
|
1685
|
+
field :status, :string, wire: "status", required: true
|
|
1686
|
+
##
|
|
1687
|
+
# :attr_reader: metadata
|
|
1688
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
1689
|
+
##
|
|
1690
|
+
# :attr_reader: attributes
|
|
1691
|
+
field :attributes, [:map, :any], wire: "attributes", required: false
|
|
1692
|
+
end
|
|
1693
|
+
|
|
1694
|
+
# A membership associates a user with a resource, memberships is defined by user, resource, resource type, and associated roles.
|
|
1695
|
+
class Membership < Model
|
|
1696
|
+
##
|
|
1697
|
+
# :attr_reader: id
|
|
1698
|
+
# ID of the membership.
|
|
1699
|
+
field :id, :string, wire: "id", required: true
|
|
1700
|
+
##
|
|
1701
|
+
# :attr_reader: resource_id
|
|
1702
|
+
# ID of the resource the membership is in.
|
|
1703
|
+
field :resource_id, :string, wire: "resource_id", required: true
|
|
1704
|
+
##
|
|
1705
|
+
# :attr_reader: type
|
|
1706
|
+
# The type of the membership resource.
|
|
1707
|
+
# Possible values are:
|
|
1708
|
+
# * `merchant` - merchant account(s)
|
|
1709
|
+
# * `organization` - organization(s)
|
|
1710
|
+
field :type, :string, wire: "type", required: true
|
|
1711
|
+
##
|
|
1712
|
+
# :attr_reader: roles
|
|
1713
|
+
# User's roles.
|
|
1714
|
+
field :roles, [:array, :string], wire: "roles", required: true
|
|
1715
|
+
##
|
|
1716
|
+
# :attr_reader: permissions
|
|
1717
|
+
# User's permissions.
|
|
1718
|
+
field :permissions, [:array, :string], wire: "permissions", required: true
|
|
1719
|
+
##
|
|
1720
|
+
# :attr_reader: created_at
|
|
1721
|
+
# The timestamp of when the membership was created.
|
|
1722
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
1723
|
+
##
|
|
1724
|
+
# :attr_reader: updated_at
|
|
1725
|
+
# The timestamp of when the membership was last updated.
|
|
1726
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
1727
|
+
##
|
|
1728
|
+
# :attr_reader: invite
|
|
1729
|
+
field :invite, [:model, "Invite"], wire: "invite", required: false
|
|
1730
|
+
##
|
|
1731
|
+
# :attr_reader: status
|
|
1732
|
+
field :status, :string, wire: "status", required: true
|
|
1733
|
+
##
|
|
1734
|
+
# :attr_reader: metadata
|
|
1735
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
1736
|
+
##
|
|
1737
|
+
# :attr_reader: attributes
|
|
1738
|
+
field :attributes, [:map, :any], wire: "attributes", required: false
|
|
1739
|
+
##
|
|
1740
|
+
# :attr_reader: resource
|
|
1741
|
+
field :resource, [:model, "MembershipResource"], wire: "resource", required: true
|
|
1742
|
+
end
|
|
1743
|
+
|
|
1744
|
+
# Information about the resource the membership is in.
|
|
1745
|
+
class MembershipResource < Model
|
|
1746
|
+
##
|
|
1747
|
+
# :attr_reader: id
|
|
1748
|
+
# ID of the resource the membership is in.
|
|
1749
|
+
field :id, :string, wire: "id", required: true
|
|
1750
|
+
##
|
|
1751
|
+
# :attr_reader: type
|
|
1752
|
+
# The type of the membership resource.
|
|
1753
|
+
# Possible values are:
|
|
1754
|
+
# * `merchant` - merchant account(s)
|
|
1755
|
+
# * `organization` - organization(s)
|
|
1756
|
+
field :type, :string, wire: "type", required: true
|
|
1757
|
+
##
|
|
1758
|
+
# :attr_reader: name
|
|
1759
|
+
# Display name of the resource.
|
|
1760
|
+
field :name, :string, wire: "name", required: true
|
|
1761
|
+
##
|
|
1762
|
+
# :attr_reader: logo
|
|
1763
|
+
# Logo fo the resource.
|
|
1764
|
+
field :logo, :string, wire: "logo", required: false
|
|
1765
|
+
##
|
|
1766
|
+
# :attr_reader: created_at
|
|
1767
|
+
# The timestamp of when the membership resource was created.
|
|
1768
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
1769
|
+
##
|
|
1770
|
+
# :attr_reader: updated_at
|
|
1771
|
+
# The timestamp of when the membership resource was last updated.
|
|
1772
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
1773
|
+
##
|
|
1774
|
+
# :attr_reader: attributes
|
|
1775
|
+
field :attributes, [:map, :any], wire: "attributes", required: false
|
|
1776
|
+
end
|
|
1777
|
+
|
|
1778
|
+
# Information about the user associated with the membership.
|
|
1779
|
+
class MembershipUser < Model
|
|
1780
|
+
##
|
|
1781
|
+
# :attr_reader: id
|
|
1782
|
+
# Identifier for the End-User (also called Subject).
|
|
1783
|
+
field :id, :string, wire: "id", required: true
|
|
1784
|
+
##
|
|
1785
|
+
# :attr_reader: type
|
|
1786
|
+
field :type, :string, wire: "type", required: true
|
|
1787
|
+
##
|
|
1788
|
+
# :attr_reader: email
|
|
1789
|
+
# End-User's preferred e-mail address. Its value MUST conform to the RFC 5322 [RFC5322] addr-spec syntax. The RP MUST NOT rely upon this value being unique, for unique identification use ID instead.
|
|
1790
|
+
field :email, :string, wire: "email", required: true
|
|
1791
|
+
##
|
|
1792
|
+
# :attr_reader: mfa_on_login_enabled
|
|
1793
|
+
# True if the user has enabled MFA on login.
|
|
1794
|
+
field :mfa_on_login_enabled, :boolean, wire: "mfa_on_login_enabled", required: true
|
|
1795
|
+
##
|
|
1796
|
+
# :attr_reader: virtual_user
|
|
1797
|
+
# True if the user is a virtual user (operator).
|
|
1798
|
+
field :virtual_user, :boolean, wire: "virtual_user", required: true
|
|
1799
|
+
##
|
|
1800
|
+
# :attr_reader: service_account_user
|
|
1801
|
+
# True if the user is a service account.
|
|
1802
|
+
field :service_account_user, :boolean, wire: "service_account_user", required: true
|
|
1803
|
+
##
|
|
1804
|
+
# :attr_reader: disabled_at
|
|
1805
|
+
# Time when the user has been disabled. Applies only to virtual users (`virtual_user: true`).
|
|
1806
|
+
field :disabled_at, :string, wire: "disabled_at", required: false
|
|
1807
|
+
##
|
|
1808
|
+
# :attr_reader: nickname
|
|
1809
|
+
# User's nickname. Used for display purposes only.
|
|
1810
|
+
field :nickname, :string, wire: "nickname", required: false
|
|
1811
|
+
##
|
|
1812
|
+
# :attr_reader: picture
|
|
1813
|
+
# URL of the End-User's profile picture. This URL refers to an image file (for example, a PNG, JPEG, or GIF image file), rather than to a Web page containing an image.
|
|
1814
|
+
field :picture, :string, wire: "picture", required: false
|
|
1815
|
+
##
|
|
1816
|
+
# :attr_reader: classic
|
|
1817
|
+
field :classic, [:model, "MembershipUserClassic"], wire: "classic", required: false
|
|
1818
|
+
end
|
|
1819
|
+
|
|
1820
|
+
# Classic identifiers of the user.
|
|
1821
|
+
class MembershipUserClassic < Model
|
|
1822
|
+
##
|
|
1823
|
+
# :attr_reader: user_id
|
|
1824
|
+
field :user_id, :integer, wire: "user_id", required: true
|
|
1825
|
+
end
|
|
1826
|
+
|
|
1827
|
+
class Merchant < Model
|
|
1828
|
+
##
|
|
1829
|
+
# :attr_reader: created_at
|
|
1830
|
+
# The date and time when the resource was created. This is a string as defined in [RFC 3339, section 5.6](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6).
|
|
1831
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
1832
|
+
##
|
|
1833
|
+
# :attr_reader: updated_at
|
|
1834
|
+
# The date and time when the resource was last updated. This is a string as defined in [RFC 3339, section 5.6](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6).
|
|
1835
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
1836
|
+
##
|
|
1837
|
+
# :attr_reader: merchant_code
|
|
1838
|
+
# Short unique identifier for the merchant.
|
|
1839
|
+
field :merchant_code, :string, wire: "merchant_code", required: true
|
|
1840
|
+
##
|
|
1841
|
+
# :attr_reader: organization_id
|
|
1842
|
+
# ID of the organization the merchant belongs to (if any).
|
|
1843
|
+
field :organization_id, :string, wire: "organization_id", required: false
|
|
1844
|
+
##
|
|
1845
|
+
# :attr_reader: business_type
|
|
1846
|
+
# The business type.
|
|
1847
|
+
# * `sole_trader`: The business is run by an self-employed individual.
|
|
1848
|
+
# * `company`: The business is run as a company with one or more shareholders
|
|
1849
|
+
# * `partnership`: The business is run as a company with two or more shareholders that can be also other legal entities
|
|
1850
|
+
# * `non_profit`: The business is run as a nonprofit organization that operates for public or social benefit
|
|
1851
|
+
# * `government_entity`: The business is state owned and operated
|
|
1852
|
+
field :business_type, :string, wire: "business_type", required: false
|
|
1853
|
+
##
|
|
1854
|
+
# :attr_reader: company
|
|
1855
|
+
field :company, [:model, "Company"], wire: "company", required: false
|
|
1856
|
+
##
|
|
1857
|
+
# :attr_reader: country
|
|
1858
|
+
# The [https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2](ISO3166-1 alpha-2) country code of the country the merchant is registered and operates in.
|
|
1859
|
+
field :country, :string, wire: "country", required: true
|
|
1860
|
+
##
|
|
1861
|
+
# :attr_reader: business_profile
|
|
1862
|
+
field :business_profile, [:model, "BusinessProfile"], wire: "business_profile", required: false
|
|
1863
|
+
##
|
|
1864
|
+
# :attr_reader: avatar
|
|
1865
|
+
# A user-facing small-format logo for use in dashboards and other user-facing applications. For customer-facing branding see `merchant.business_profile.branding`.
|
|
1866
|
+
field :avatar, :string, wire: "avatar", required: false
|
|
1867
|
+
##
|
|
1868
|
+
# :attr_reader: alias_value
|
|
1869
|
+
# A user-facing name of the merchant account for use in dashboards and other user-facing applications. For customer-facing business name see `merchant.business_profile`.
|
|
1870
|
+
field :alias_value, :string, wire: "alias", required: false
|
|
1871
|
+
##
|
|
1872
|
+
# :attr_reader: default_currency
|
|
1873
|
+
# Three-letter [ISO currency code](https://en.wikipedia.org/wiki/ISO_4217) representing the default currency for the account.
|
|
1874
|
+
field :default_currency, :string, wire: "default_currency", required: true
|
|
1875
|
+
##
|
|
1876
|
+
# :attr_reader: default_locale
|
|
1877
|
+
# Merchant's default locale, represented as a BCP47 [RFC5646](https://datatracker.ietf.org/doc/html/rfc5646) language tag. This is typically an ISO 639-1 Alpha-2 [ISO639‑1](https://www.iso.org/iso-639-language-code) language code in lowercase and an ISO 3166-1 Alpha-2 [ISO3166‑1](https://www.iso.org/iso-3166-country-codes.html) country code in uppercase, separated by a dash. For example, en-US or fr-CA.
|
|
1878
|
+
# In multilingual countries this is the merchant's preferred locale out of those, that are officially spoken in the country. In a countries with a single official language this will match the official language.
|
|
1879
|
+
field :default_locale, :string, wire: "default_locale", required: true
|
|
1880
|
+
##
|
|
1881
|
+
# :attr_reader: sandbox
|
|
1882
|
+
# True if the merchant is a sandbox for testing.
|
|
1883
|
+
field :sandbox, :boolean, wire: "sandbox", required: false
|
|
1884
|
+
##
|
|
1885
|
+
# :attr_reader: meta
|
|
1886
|
+
field :meta, [:map, :string], wire: "meta", required: false
|
|
1887
|
+
##
|
|
1888
|
+
# :attr_reader: classic
|
|
1889
|
+
field :classic, [:model, "ClassicMerchantIdentifiers"], wire: "classic", required: false
|
|
1890
|
+
##
|
|
1891
|
+
# :attr_reader: version
|
|
1892
|
+
# The version of the resource. The version reflects a specific change submitted to the API via one of the `PATCH` endpoints.
|
|
1893
|
+
field :version, :string, wire: "version", required: false
|
|
1894
|
+
##
|
|
1895
|
+
# :attr_reader: change_status
|
|
1896
|
+
# Reflects the status of changes submitted through the `PATCH` endpoints for the Merchant or Persons. If some changes have not been applied yet, the status will be `pending`. If all changes have been applied, the status `done`.
|
|
1897
|
+
# The status is only returned after write operations or on read endpoints when the `version` query parameter is provided.
|
|
1898
|
+
field :change_status, :string, wire: "change_status", required: false
|
|
1899
|
+
end
|
|
1900
|
+
|
|
1901
|
+
# An address somewhere in the world. The address fields used depend on the country conventions. For example, in Great Britain, `city` is `post_town`. In the United States, the top-level administrative unit used in addresses is `state`, whereas in Chile it's `region`.
|
|
1902
|
+
# Whether an address is valid or not depends on whether the locally required fields are present. Fields not supported in a country will be ignored.
|
|
1903
|
+
class MerchantsAddress < Model
|
|
1904
|
+
##
|
|
1905
|
+
# :attr_reader: street_address
|
|
1906
|
+
field :street_address, [:array, :string], wire: "street_address", required: false
|
|
1907
|
+
##
|
|
1908
|
+
# :attr_reader: post_code
|
|
1909
|
+
# The postal code (aka. zip code) of the address.
|
|
1910
|
+
field :post_code, :string, wire: "post_code", required: false
|
|
1911
|
+
##
|
|
1912
|
+
# :attr_reader: country
|
|
1913
|
+
# The ISO3166-1 Alpha-2 code of the address country.
|
|
1914
|
+
field :country, :string, wire: "country", required: true
|
|
1915
|
+
##
|
|
1916
|
+
# :attr_reader: city
|
|
1917
|
+
# The city of the address.
|
|
1918
|
+
field :city, :string, wire: "city", required: false
|
|
1919
|
+
##
|
|
1920
|
+
# :attr_reader: province
|
|
1921
|
+
# The province where the address is located. This may not be relevant in some countries.
|
|
1922
|
+
field :province, :string, wire: "province", required: false
|
|
1923
|
+
##
|
|
1924
|
+
# :attr_reader: region
|
|
1925
|
+
# The region where the address is located. This may not be relevant in some countries.
|
|
1926
|
+
field :region, :string, wire: "region", required: false
|
|
1927
|
+
##
|
|
1928
|
+
# :attr_reader: county
|
|
1929
|
+
# A county is a geographic region of a country used for administrative or other purposes in some nations. Used in countries such as Ireland, Romania, etc.
|
|
1930
|
+
field :county, :string, wire: "county", required: false
|
|
1931
|
+
##
|
|
1932
|
+
# :attr_reader: autonomous_community
|
|
1933
|
+
# In Spain, an autonomous community is the first sub-national level of political and administrative division.
|
|
1934
|
+
field :autonomous_community, :string, wire: "autonomous_community", required: false
|
|
1935
|
+
##
|
|
1936
|
+
# :attr_reader: post_town
|
|
1937
|
+
# A post town is a required part of all postal addresses in the United Kingdom and Ireland, and a basic unit of the postal delivery system.
|
|
1938
|
+
field :post_town, :string, wire: "post_town", required: false
|
|
1939
|
+
##
|
|
1940
|
+
# :attr_reader: state
|
|
1941
|
+
# Most often, a country has a single state, with various administrative divisions. The term "state" is sometimes used to refer to the federated polities that make up the federation. Used in countries such as the United States and Brazil.
|
|
1942
|
+
field :state, :string, wire: "state", required: false
|
|
1943
|
+
##
|
|
1944
|
+
# :attr_reader: neighborhood
|
|
1945
|
+
# Locality level of the address. Used in countries such as Brazil or Chile.
|
|
1946
|
+
field :neighborhood, :string, wire: "neighborhood", required: false
|
|
1947
|
+
##
|
|
1948
|
+
# :attr_reader: commune
|
|
1949
|
+
# In many countries, terms cognate with "commune" are used, referring to the community living in the area and the common interest. Used in countries such as Chile.
|
|
1950
|
+
field :commune, :string, wire: "commune", required: false
|
|
1951
|
+
##
|
|
1952
|
+
# :attr_reader: department
|
|
1953
|
+
# A department (French: département, Spanish: departamento) is an administrative or political division in several countries. Used in countries such as Colombia.
|
|
1954
|
+
field :department, :string, wire: "department", required: false
|
|
1955
|
+
##
|
|
1956
|
+
# :attr_reader: municipality
|
|
1957
|
+
# A municipality is usually a single administrative division having corporate status and powers of self-government or jurisdiction as granted by national and regional laws to which it is subordinate. Used in countries such as Colombia.
|
|
1958
|
+
field :municipality, :string, wire: "municipality", required: false
|
|
1959
|
+
##
|
|
1960
|
+
# :attr_reader: district
|
|
1961
|
+
# A district is a type of administrative division that in some countries is managed by the local government. Used in countries such as Portugal.
|
|
1962
|
+
field :district, :string, wire: "district", required: false
|
|
1963
|
+
##
|
|
1964
|
+
# :attr_reader: zip_code
|
|
1965
|
+
# A US system of postal codes used by the United States Postal Service (USPS).
|
|
1966
|
+
field :zip_code, :string, wire: "zip_code", required: false
|
|
1967
|
+
##
|
|
1968
|
+
# :attr_reader: eircode
|
|
1969
|
+
# A postal address in Ireland.
|
|
1970
|
+
field :eircode, :string, wire: "eircode", required: false
|
|
1971
|
+
end
|
|
1972
|
+
|
|
1973
|
+
class MerchantsPersonalIdentifiersItem < Model
|
|
1974
|
+
##
|
|
1975
|
+
# :attr_reader: ref
|
|
1976
|
+
# The unique reference for the personal identifier type as defined in the country SDK.
|
|
1977
|
+
field :ref, :string, wire: "ref", required: true
|
|
1978
|
+
##
|
|
1979
|
+
# :attr_reader: value
|
|
1980
|
+
# The value of the personal identifier.
|
|
1981
|
+
field :value, :string, wire: "value", required: true
|
|
1982
|
+
end
|
|
1983
|
+
|
|
1984
|
+
# Modifiers are reported under line items and can be build from Item Catalog objects.
|
|
1985
|
+
# Modifiers has to be attached to an item and can't be sold and refunded alone.
|
|
1986
|
+
class ModifierItem < Model
|
|
1987
|
+
##
|
|
1988
|
+
# :attr_reader: id
|
|
1989
|
+
# Modifier id, coming from the Item Catalog
|
|
1990
|
+
field :id, :string, wire: "id", required: true
|
|
1991
|
+
##
|
|
1992
|
+
# :attr_reader: name
|
|
1993
|
+
# Modifier name, coming from the Item Catalog
|
|
1994
|
+
field :name, :string, wire: "name", required: true
|
|
1995
|
+
##
|
|
1996
|
+
# :attr_reader: set
|
|
1997
|
+
field :set, [:model, "ModifierSet"], wire: "set", required: true
|
|
1998
|
+
##
|
|
1999
|
+
# :attr_reader: quantity
|
|
2000
|
+
# The numerical value representing the quantity in the specified unit.
|
|
2001
|
+
field :quantity, :number, wire: "quantity", required: true
|
|
2002
|
+
##
|
|
2003
|
+
# :attr_reader: discounts
|
|
2004
|
+
# Discounts applied.
|
|
2005
|
+
#
|
|
2006
|
+
# Important:
|
|
2007
|
+
# Discount amounts shouldn't take effect on net and gross amounts.
|
|
2008
|
+
#
|
|
2009
|
+
# Discount money amounts depend on where discount was applied:
|
|
2010
|
+
# - for item level discount: whole discount money amount is applied
|
|
2011
|
+
# - for cart level discount: only part of the whole amount is applied
|
|
2012
|
+
# (discount money value is split on each line item)
|
|
2013
|
+
field :discounts, [:array, [:model, "DiscountLine"]], wire: "discounts", required: false
|
|
2014
|
+
##
|
|
2015
|
+
# :attr_reader: total_net_amount_final
|
|
2016
|
+
# The final net amount includes discounts and modifiers. It does NOT include taxes. If no discounts are applied, it should be equal to total_net_amount.
|
|
2017
|
+
field :total_net_amount_final, :integer, wire: "total_net_amount_final", required: true
|
|
2018
|
+
##
|
|
2019
|
+
# :attr_reader: total_gross_amount_final
|
|
2020
|
+
# The final gross amount includes discounts, modifiers, and taxes. If no discounts are applied, it should be equal to total_gross_amount.
|
|
2021
|
+
field :total_gross_amount_final, :integer, wire: "total_gross_amount_final", required: true
|
|
2022
|
+
##
|
|
2023
|
+
# :attr_reader: taxes_final
|
|
2024
|
+
# Taxes applied on top of `total_net_amount_final` amount resulting in `total_gross_amount_final` amount.
|
|
2025
|
+
# If no discounts are applied, it should be equal to `taxes`.
|
|
2026
|
+
field :taxes_final, [:array, [:model, "PositiveTaxLine"]], wire: "taxes_final", required: true
|
|
2027
|
+
##
|
|
2028
|
+
# :attr_reader: taxes
|
|
2029
|
+
# Taxes applied on top of net amount resulting in gross amount.
|
|
2030
|
+
field :taxes, [:array, [:model, "PositiveTaxLine"]], wire: "taxes", required: true
|
|
2031
|
+
##
|
|
2032
|
+
# :attr_reader: total_net_amount
|
|
2033
|
+
# The net amount (including modifiers if applied). It does NOT include discounts.
|
|
2034
|
+
field :total_net_amount, :integer, wire: "total_net_amount", required: true
|
|
2035
|
+
##
|
|
2036
|
+
# :attr_reader: total_gross_amount
|
|
2037
|
+
# The gross amount (including modifiers if applied). It does NOT include discounts.
|
|
2038
|
+
field :total_gross_amount, :integer, wire: "total_gross_amount", required: true
|
|
2039
|
+
##
|
|
2040
|
+
# :attr_reader: unit_amount
|
|
2041
|
+
# The price of a single unit.
|
|
2042
|
+
# If the tax_mode is GROSS, it includes taxes, otherwise no tax included.
|
|
2043
|
+
# It doesn't include discounts.
|
|
2044
|
+
field :unit_amount, :integer, wire: "unit_amount", required: true
|
|
2045
|
+
end
|
|
2046
|
+
|
|
2047
|
+
# Modifier set attached to an item.
|
|
2048
|
+
class ModifierSet < Model
|
|
2049
|
+
##
|
|
2050
|
+
# :attr_reader: id
|
|
2051
|
+
# The id of the modifier set that modifier belongs to.
|
|
2052
|
+
field :id, :string, wire: "id", required: true
|
|
2053
|
+
##
|
|
2054
|
+
# :attr_reader: name
|
|
2055
|
+
# The name of the modifier set that the modifier belongs to.
|
|
2056
|
+
field :name, :string, wire: "name", required: true
|
|
2057
|
+
end
|
|
2058
|
+
|
|
2059
|
+
# 404 Not Found
|
|
2060
|
+
class NotFound < Model
|
|
2061
|
+
##
|
|
2062
|
+
# :attr_reader: errors
|
|
2063
|
+
field :errors, [:model, "NotFoundErrors"], wire: "errors", required: true
|
|
2064
|
+
end
|
|
2065
|
+
|
|
2066
|
+
class NotFoundErrors < Model
|
|
2067
|
+
##
|
|
2068
|
+
# :attr_reader: detail
|
|
2069
|
+
# Fuller message giving context to error
|
|
2070
|
+
field :detail, :string, wire: "detail", required: true
|
|
2071
|
+
end
|
|
2072
|
+
|
|
2073
|
+
class Ownership < Model
|
|
2074
|
+
##
|
|
2075
|
+
# :attr_reader: share
|
|
2076
|
+
# The percent of ownership shares held by the Person expressed in percent mille (1/100000). Only Persons with the relationship `owner` can have ownership.
|
|
2077
|
+
field :share, :integer, wire: "share", required: true
|
|
2078
|
+
end
|
|
2079
|
+
|
|
2080
|
+
# Details of a saved payment instrument.
|
|
2081
|
+
class PaymentInstrumentResponse < Model
|
|
2082
|
+
##
|
|
2083
|
+
# :attr_reader: token
|
|
2084
|
+
# Token identifying the customer's saved payment card. Pass it as `token`, together with the associated `customer_id` and `payment_type = card`, when processing a checkout with this instrument.
|
|
2085
|
+
field :token, :string, wire: "token", required: false
|
|
2086
|
+
##
|
|
2087
|
+
# :attr_reader: active
|
|
2088
|
+
# Indicates whether the payment instrument is active and can be used for payments. To deactivate it, send a `DELETE` request to the resource endpoint.
|
|
2089
|
+
field :active, :boolean, wire: "active", required: false
|
|
2090
|
+
##
|
|
2091
|
+
# :attr_reader: type
|
|
2092
|
+
# Type of the payment instrument.
|
|
2093
|
+
field :type, :string, wire: "type", required: false
|
|
2094
|
+
##
|
|
2095
|
+
# :attr_reader: card
|
|
2096
|
+
# Details of the payment card.
|
|
2097
|
+
field :card, [:model, "PaymentInstrumentResponseCard"], wire: "card", required: false
|
|
2098
|
+
##
|
|
2099
|
+
# :attr_reader: mandate
|
|
2100
|
+
field :mandate, [:model, "MandateResponse"], wire: "mandate", required: false
|
|
2101
|
+
##
|
|
2102
|
+
# :attr_reader: created_at
|
|
2103
|
+
# The timestamp of when the payment instrument was created.
|
|
2104
|
+
field :created_at, :string, wire: "created_at", required: false
|
|
2105
|
+
end
|
|
2106
|
+
|
|
2107
|
+
# Details of the payment card.
|
|
2108
|
+
class PaymentInstrumentResponseCard < Model
|
|
2109
|
+
##
|
|
2110
|
+
# :attr_reader: last_4_digits
|
|
2111
|
+
# Last 4 digits of the payment card number.
|
|
2112
|
+
field :last_4_digits, :string, wire: "last_4_digits", required: false
|
|
2113
|
+
##
|
|
2114
|
+
# :attr_reader: type
|
|
2115
|
+
field :type, :string, wire: "type", required: false
|
|
2116
|
+
end
|
|
2117
|
+
|
|
2118
|
+
class Person < Model
|
|
2119
|
+
##
|
|
2120
|
+
# :attr_reader: id
|
|
2121
|
+
# The unique identifier for the Person. This is a [typeid](https://github.com/sumup/typeid).
|
|
2122
|
+
field :id, :string, wire: "id", required: true
|
|
2123
|
+
##
|
|
2124
|
+
# :attr_reader: user_id
|
|
2125
|
+
# A corresponding identity user ID for the Person, if they have a user account.
|
|
2126
|
+
field :user_id, :string, wire: "user_id", required: false
|
|
2127
|
+
##
|
|
2128
|
+
# :attr_reader: birthdate
|
|
2129
|
+
# The date of birth of the individual, represented as an ISO 8601:2004 [ISO8601‑2004] YYYY-MM-DD format.
|
|
2130
|
+
field :birthdate, :string, wire: "birthdate", required: false
|
|
2131
|
+
##
|
|
2132
|
+
# :attr_reader: given_name
|
|
2133
|
+
# The first name(s) of the individual.
|
|
2134
|
+
field :given_name, :string, wire: "given_name", required: false
|
|
2135
|
+
##
|
|
2136
|
+
# :attr_reader: family_name
|
|
2137
|
+
# The last name(s) of the individual.
|
|
2138
|
+
field :family_name, :string, wire: "family_name", required: false
|
|
2139
|
+
##
|
|
2140
|
+
# :attr_reader: phone_number
|
|
2141
|
+
# The (mobile) phone number of the individual (used for verification) in [E.164](https://en.wikipedia.org/wiki/E.164) format.
|
|
2142
|
+
field :phone_number, :string, wire: "phone_number", required: false
|
|
2143
|
+
##
|
|
2144
|
+
# :attr_reader: relationships
|
|
2145
|
+
# A list of roles the Person has in the Merchant or towards SumUp. A Merchant must have at least one Person with the relationship `representative`.
|
|
2146
|
+
field :relationships, [:array, :string], wire: "relationships", required: false
|
|
2147
|
+
##
|
|
2148
|
+
# :attr_reader: ownership
|
|
2149
|
+
field :ownership, [:model, "Ownership"], wire: "ownership", required: false
|
|
2150
|
+
##
|
|
2151
|
+
# :attr_reader: address
|
|
2152
|
+
field :address, [:model, "MerchantsAddress"], wire: "address", required: false
|
|
2153
|
+
##
|
|
2154
|
+
# :attr_reader: identifiers
|
|
2155
|
+
field :identifiers, [:array, [:model, "MerchantsPersonalIdentifiersItem"]], wire: "identifiers", required: false
|
|
2156
|
+
##
|
|
2157
|
+
# :attr_reader: citizenship
|
|
2158
|
+
# The Alpha-2 ISO code of the country where the Person is a citizen.
|
|
2159
|
+
field :citizenship, :string, wire: "citizenship", required: false
|
|
2160
|
+
##
|
|
2161
|
+
# :attr_reader: nationality
|
|
2162
|
+
# The Person's nationality. May be an [ISO3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code, but legacy data may not conform to this standard.
|
|
2163
|
+
field :nationality, [:union, [:string, :nil]], wire: "nationality", required: false
|
|
2164
|
+
##
|
|
2165
|
+
# :attr_reader: country_of_residence
|
|
2166
|
+
# An [ISO3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code representing the country where the Person resides.
|
|
2167
|
+
field :country_of_residence, [:union, [:string, :nil]], wire: "country_of_residence", required: false
|
|
2168
|
+
##
|
|
2169
|
+
# :attr_reader: version
|
|
2170
|
+
# The version of the resource. The version reflects a specific change submitted to the API via one of the `PATCH` endpoints.
|
|
2171
|
+
field :version, :string, wire: "version", required: false
|
|
2172
|
+
##
|
|
2173
|
+
# :attr_reader: change_status
|
|
2174
|
+
# Reflects the status of changes submitted through the `PATCH` endpoints for the Merchant or Persons. If some changes have not been applied yet, the status will be `pending`. If all changes have been applied, the status `done`.
|
|
2175
|
+
# The status is only returned after write operations or on read endpoints when the `version` query parameter is provided.
|
|
2176
|
+
field :change_status, :string, wire: "change_status", required: false
|
|
2177
|
+
end
|
|
2178
|
+
|
|
2179
|
+
# Personal details for the customer.
|
|
2180
|
+
class PersonalDetails < Model
|
|
2181
|
+
##
|
|
2182
|
+
# :attr_reader: first_name
|
|
2183
|
+
# First name of the customer.
|
|
2184
|
+
field :first_name, :string, wire: "first_name", required: false
|
|
2185
|
+
##
|
|
2186
|
+
# :attr_reader: last_name
|
|
2187
|
+
# Last name of the customer.
|
|
2188
|
+
field :last_name, :string, wire: "last_name", required: false
|
|
2189
|
+
##
|
|
2190
|
+
# :attr_reader: email
|
|
2191
|
+
# Email address of the customer.
|
|
2192
|
+
field :email, :string, wire: "email", required: false
|
|
2193
|
+
##
|
|
2194
|
+
# :attr_reader: phone
|
|
2195
|
+
# Phone number of the customer.
|
|
2196
|
+
field :phone, :string, wire: "phone", required: false
|
|
2197
|
+
##
|
|
2198
|
+
# :attr_reader: birth_date
|
|
2199
|
+
# Date of birth of the customer in `YYYY-MM-DD` format, without a time or timezone.
|
|
2200
|
+
field :birth_date, :string, wire: "birth_date", required: false
|
|
2201
|
+
##
|
|
2202
|
+
# :attr_reader: tax_id
|
|
2203
|
+
# Identification number used for tax purposes, such as a CPF in Brazil.
|
|
2204
|
+
field :tax_id, :string, wire: "tax_id", required: false
|
|
2205
|
+
##
|
|
2206
|
+
# :attr_reader: address
|
|
2207
|
+
field :address, [:model, "AddressLegacy"], wire: "address", required: false
|
|
2208
|
+
end
|
|
2209
|
+
|
|
2210
|
+
# Price information for items with positive amounts only.
|
|
2211
|
+
class PositivePriceAmounts < Model
|
|
2212
|
+
##
|
|
2213
|
+
# :attr_reader: total_net_amount
|
|
2214
|
+
# The net amount (including modifiers if applied). It does NOT include discounts.
|
|
2215
|
+
field :total_net_amount, :integer, wire: "total_net_amount", required: true
|
|
2216
|
+
##
|
|
2217
|
+
# :attr_reader: total_gross_amount
|
|
2218
|
+
# The gross amount (including modifiers if applied). It does NOT include discounts.
|
|
2219
|
+
field :total_gross_amount, :integer, wire: "total_gross_amount", required: true
|
|
2220
|
+
##
|
|
2221
|
+
# :attr_reader: unit_amount
|
|
2222
|
+
# The price of a single unit.
|
|
2223
|
+
# If the tax_mode is GROSS, it includes taxes, otherwise no tax included.
|
|
2224
|
+
# It doesn't include discounts.
|
|
2225
|
+
field :unit_amount, :integer, wire: "unit_amount", required: true
|
|
2226
|
+
end
|
|
2227
|
+
|
|
2228
|
+
# Price information with positive amounts and detailed tax breakdown.
|
|
2229
|
+
class PositivePriceWithTaxes < Model
|
|
2230
|
+
##
|
|
2231
|
+
# :attr_reader: taxes
|
|
2232
|
+
# Taxes applied on top of net amount resulting in gross amount.
|
|
2233
|
+
field :taxes, [:array, [:model, "PositiveTaxLine"]], wire: "taxes", required: true
|
|
2234
|
+
##
|
|
2235
|
+
# :attr_reader: total_net_amount
|
|
2236
|
+
# The net amount (including modifiers if applied). It does NOT include discounts.
|
|
2237
|
+
field :total_net_amount, :integer, wire: "total_net_amount", required: true
|
|
2238
|
+
##
|
|
2239
|
+
# :attr_reader: total_gross_amount
|
|
2240
|
+
# The gross amount (including modifiers if applied). It does NOT include discounts.
|
|
2241
|
+
field :total_gross_amount, :integer, wire: "total_gross_amount", required: true
|
|
2242
|
+
##
|
|
2243
|
+
# :attr_reader: unit_amount
|
|
2244
|
+
# The price of a single unit.
|
|
2245
|
+
# If the tax_mode is GROSS, it includes taxes, otherwise no tax included.
|
|
2246
|
+
# It doesn't include discounts.
|
|
2247
|
+
field :unit_amount, :integer, wire: "unit_amount", required: true
|
|
2248
|
+
end
|
|
2249
|
+
|
|
2250
|
+
# Tax line with positive amounts only.
|
|
2251
|
+
# Information about tax together with amounts before and after its application such as:
|
|
2252
|
+
# - net amount: taxable net amount, scoped by this tax
|
|
2253
|
+
# - gross amount: amount after applying the tax
|
|
2254
|
+
# The numbers here can't be negative.
|
|
2255
|
+
class PositiveTaxLine < Model
|
|
2256
|
+
##
|
|
2257
|
+
# :attr_reader: net_amount
|
|
2258
|
+
# Net amount before applying the tax.
|
|
2259
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
2260
|
+
field :net_amount, :integer, wire: "net_amount", required: true
|
|
2261
|
+
##
|
|
2262
|
+
# :attr_reader: gross_amount
|
|
2263
|
+
# Gross amount after applying the tax.
|
|
2264
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
2265
|
+
field :gross_amount, :integer, wire: "gross_amount", required: true
|
|
2266
|
+
##
|
|
2267
|
+
# :attr_reader: tax_amount
|
|
2268
|
+
# Amount of tax.
|
|
2269
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
2270
|
+
field :tax_amount, :integer, wire: "tax_amount", required: true
|
|
2271
|
+
##
|
|
2272
|
+
# :attr_reader: id
|
|
2273
|
+
# Tax ID from the Tax Service (External Id)
|
|
2274
|
+
field :id, :string, wire: "id", required: true
|
|
2275
|
+
##
|
|
2276
|
+
# :attr_reader: name
|
|
2277
|
+
# Tax name, e.g. "MwSt."
|
|
2278
|
+
field :name, :string, wire: "name", required: false
|
|
2279
|
+
##
|
|
2280
|
+
# :attr_reader: percentage
|
|
2281
|
+
# The tax rate percentage in minor units (1/100000). For example 19000 = 19%.
|
|
2282
|
+
field :percentage, :integer, wire: "percentage", required: false
|
|
2283
|
+
end
|
|
2284
|
+
|
|
2285
|
+
# Base price information for items including unit amount and totals.
|
|
2286
|
+
class PriceAmounts < Model
|
|
2287
|
+
##
|
|
2288
|
+
# :attr_reader: unit_amount
|
|
2289
|
+
# The price of a single unit.
|
|
2290
|
+
# If the tax_mode is GROSS, it includes taxes, otherwise no tax included.
|
|
2291
|
+
# It doesn't include discounts.
|
|
2292
|
+
field :unit_amount, :integer, wire: "unit_amount", required: true
|
|
2293
|
+
##
|
|
2294
|
+
# :attr_reader: total_net_amount
|
|
2295
|
+
# The net amount (including modifiers if applied). It does NOT include discounts.
|
|
2296
|
+
field :total_net_amount, :integer, wire: "total_net_amount", required: true
|
|
2297
|
+
##
|
|
2298
|
+
# :attr_reader: total_gross_amount
|
|
2299
|
+
# The gross amount (including modifiers if applied). It does NOT include discounts.
|
|
2300
|
+
field :total_gross_amount, :integer, wire: "total_gross_amount", required: true
|
|
2301
|
+
end
|
|
2302
|
+
|
|
2303
|
+
# A RFC 9457 problem details object.
|
|
2304
|
+
#
|
|
2305
|
+
# Additional properties specific to the problem type may be present.
|
|
2306
|
+
class Problem < Model
|
|
2307
|
+
##
|
|
2308
|
+
# :attr_reader: type
|
|
2309
|
+
# A URI reference that identifies the problem type.
|
|
2310
|
+
field :type, :string, wire: "type", required: true
|
|
2311
|
+
##
|
|
2312
|
+
# :attr_reader: title
|
|
2313
|
+
# A short, human-readable summary of the problem type.
|
|
2314
|
+
field :title, :string, wire: "title", required: false
|
|
2315
|
+
##
|
|
2316
|
+
# :attr_reader: status
|
|
2317
|
+
# The HTTP status code generated by the origin server for this occurrence of the problem.
|
|
2318
|
+
field :status, :integer, wire: "status", required: false
|
|
2319
|
+
##
|
|
2320
|
+
# :attr_reader: detail
|
|
2321
|
+
# A human-readable explanation specific to this occurrence of the problem.
|
|
2322
|
+
field :detail, :string, wire: "detail", required: false
|
|
2323
|
+
##
|
|
2324
|
+
# :attr_reader: instance
|
|
2325
|
+
# A URI reference that identifies the specific occurrence of the problem.
|
|
2326
|
+
field :instance, :string, wire: "instance", required: false
|
|
2327
|
+
end
|
|
2328
|
+
|
|
2329
|
+
# Request body for attempting payment on an existing checkout. The required companion fields depend on the selected `payment_type`, for example card details, saved-card data, or payer information required by a specific payment method.
|
|
2330
|
+
class ProcessCheckout < Model
|
|
2331
|
+
##
|
|
2332
|
+
# :attr_reader: payment_type
|
|
2333
|
+
# Payment method used for this processing attempt. It determines which additional request fields are required.
|
|
2334
|
+
field :payment_type, :string, wire: "payment_type", required: true
|
|
2335
|
+
##
|
|
2336
|
+
# :attr_reader: installments
|
|
2337
|
+
# Number of installments for deferred payments. Available only to merchant users in Brazil.
|
|
2338
|
+
field :installments, :integer, wire: "installments", required: false
|
|
2339
|
+
##
|
|
2340
|
+
# :attr_reader: mandate
|
|
2341
|
+
field :mandate, [:model, "MandatePayload"], wire: "mandate", required: false
|
|
2342
|
+
##
|
|
2343
|
+
# :attr_reader: card
|
|
2344
|
+
field :card, [:model, "Card"], wire: "card", required: false
|
|
2345
|
+
##
|
|
2346
|
+
# :attr_reader: google_pay
|
|
2347
|
+
# Raw `PaymentData` object received from Google Pay. Send the Google Pay response payload as-is.
|
|
2348
|
+
field :google_pay, [:map, :any], wire: "google_pay", required: false
|
|
2349
|
+
##
|
|
2350
|
+
# :attr_reader: apple_pay
|
|
2351
|
+
# Raw payment token object received from Apple Pay. Send the Apple Pay response payload as-is.
|
|
2352
|
+
field :apple_pay, [:map, :any], wire: "apple_pay", required: false
|
|
2353
|
+
##
|
|
2354
|
+
# :attr_reader: token
|
|
2355
|
+
# Token of a saved payment instrument returned by checkout processing or the customer's payment-instruments endpoint. To charge a saved card, set `payment_type` to `card` and provide both this `token` and the associated `customer_id` instead of raw card details.
|
|
2356
|
+
field :token, :string, wire: "token", required: false
|
|
2357
|
+
##
|
|
2358
|
+
# :attr_reader: customer_id
|
|
2359
|
+
# Customer identifier associated with the saved payment instrument. Required when `token` is provided.
|
|
2360
|
+
field :customer_id, :string, wire: "customer_id", required: false
|
|
2361
|
+
##
|
|
2362
|
+
# :attr_reader: personal_details
|
|
2363
|
+
field :personal_details, [:model, "PersonalDetails"], wire: "personal_details", required: false
|
|
2364
|
+
end
|
|
2365
|
+
|
|
2366
|
+
# Product details associated with a transaction.
|
|
2367
|
+
class Product < Model
|
|
2368
|
+
##
|
|
2369
|
+
# :attr_reader: name
|
|
2370
|
+
# Product name.
|
|
2371
|
+
field :name, :string, wire: "name", required: false
|
|
2372
|
+
##
|
|
2373
|
+
# :attr_reader: price_label
|
|
2374
|
+
# Human-readable label for the product price.
|
|
2375
|
+
field :price_label, :string, wire: "price_label", required: false
|
|
2376
|
+
##
|
|
2377
|
+
# :attr_reader: price
|
|
2378
|
+
# Product price.
|
|
2379
|
+
field :price, :number, wire: "price", required: false
|
|
2380
|
+
##
|
|
2381
|
+
# :attr_reader: vat_rate
|
|
2382
|
+
# VAT rate as a decimal fraction, for example `0.19` for 19%.
|
|
2383
|
+
field :vat_rate, :number, wire: "vat_rate", required: false
|
|
2384
|
+
##
|
|
2385
|
+
# :attr_reader: single_vat_amount
|
|
2386
|
+
# VAT amount for a single product.
|
|
2387
|
+
field :single_vat_amount, :number, wire: "single_vat_amount", required: false
|
|
2388
|
+
##
|
|
2389
|
+
# :attr_reader: price_with_vat
|
|
2390
|
+
# Product price including VAT.
|
|
2391
|
+
field :price_with_vat, :number, wire: "price_with_vat", required: false
|
|
2392
|
+
##
|
|
2393
|
+
# :attr_reader: vat_amount
|
|
2394
|
+
# Total VAT amount for the product quantity.
|
|
2395
|
+
field :vat_amount, :number, wire: "vat_amount", required: false
|
|
2396
|
+
##
|
|
2397
|
+
# :attr_reader: quantity
|
|
2398
|
+
# Product quantity.
|
|
2399
|
+
field :quantity, :integer, wire: "quantity", required: false
|
|
2400
|
+
##
|
|
2401
|
+
# :attr_reader: total_price
|
|
2402
|
+
# Total price calculated as the product price multiplied by the quantity.
|
|
2403
|
+
field :total_price, :number, wire: "total_price", required: false
|
|
2404
|
+
##
|
|
2405
|
+
# :attr_reader: total_with_vat
|
|
2406
|
+
# Total product price including VAT.
|
|
2407
|
+
field :total_with_vat, :number, wire: "total_with_vat", required: false
|
|
2408
|
+
end
|
|
2409
|
+
|
|
2410
|
+
# A physical card reader device that can accept in-person payments.
|
|
2411
|
+
class Reader < Model
|
|
2412
|
+
##
|
|
2413
|
+
# :attr_reader: id
|
|
2414
|
+
# Unique identifier of the object.
|
|
2415
|
+
#
|
|
2416
|
+
# Note that this identifies the instance of the physical devices pairing with your SumUp account. If you [delete](https://developer.sumup.com/api/readers/delete-reader) a reader, and pair the device again, the ID will be different. Do not use this ID to refer to a physical device.
|
|
2417
|
+
field :id, :string, wire: "id", required: true
|
|
2418
|
+
##
|
|
2419
|
+
# :attr_reader: name
|
|
2420
|
+
# Custom human-readable, user-defined name for easier identification of the reader.
|
|
2421
|
+
field :name, :string, wire: "name", required: true
|
|
2422
|
+
##
|
|
2423
|
+
# :attr_reader: status
|
|
2424
|
+
field :status, :string, wire: "status", required: true
|
|
2425
|
+
##
|
|
2426
|
+
# :attr_reader: device
|
|
2427
|
+
field :device, [:model, "ReaderDevice"], wire: "device", required: true
|
|
2428
|
+
##
|
|
2429
|
+
# :attr_reader: metadata
|
|
2430
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
2431
|
+
##
|
|
2432
|
+
# :attr_reader: service_account_id
|
|
2433
|
+
# Identifier of the system-managed service account associated with this reader.
|
|
2434
|
+
# Present only for readers that are already paired.
|
|
2435
|
+
# This field is currently in beta and may change.
|
|
2436
|
+
field :service_account_id, :string, wire: "service_account_id", required: false
|
|
2437
|
+
##
|
|
2438
|
+
# :attr_reader: created_at
|
|
2439
|
+
# The timestamp of when the reader was created.
|
|
2440
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
2441
|
+
##
|
|
2442
|
+
# :attr_reader: updated_at
|
|
2443
|
+
# The timestamp of when the reader was last updated.
|
|
2444
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
2445
|
+
end
|
|
2446
|
+
|
|
2447
|
+
# The callback payload containing the status change of the Reader Checkout.
|
|
2448
|
+
class ReaderCheckoutStatusChange < Model
|
|
2449
|
+
##
|
|
2450
|
+
# :attr_reader: event_type
|
|
2451
|
+
# Type of event.
|
|
2452
|
+
field :event_type, :string, wire: "event_type", required: true
|
|
2453
|
+
##
|
|
2454
|
+
# :attr_reader: id
|
|
2455
|
+
# Unique identifier for the event.
|
|
2456
|
+
field :id, :string, wire: "id", required: true
|
|
2457
|
+
##
|
|
2458
|
+
# :attr_reader: payload
|
|
2459
|
+
# The event payload.
|
|
2460
|
+
field :payload, [:model, "ReaderCheckoutStatusChangePayload"], wire: "payload", required: true
|
|
2461
|
+
##
|
|
2462
|
+
# :attr_reader: timestamp
|
|
2463
|
+
# Timestamp of the event.
|
|
2464
|
+
field :timestamp, :string, wire: "timestamp", required: true
|
|
2465
|
+
end
|
|
2466
|
+
|
|
2467
|
+
# The event payload.
|
|
2468
|
+
class ReaderCheckoutStatusChangePayload < Model
|
|
2469
|
+
##
|
|
2470
|
+
# :attr_reader: client_transaction_id
|
|
2471
|
+
# The unique client transaction id. It is the same returned by the Checkout.
|
|
2472
|
+
field :client_transaction_id, :string, wire: "client_transaction_id", required: true
|
|
2473
|
+
##
|
|
2474
|
+
# :attr_reader: merchant_code
|
|
2475
|
+
# The merchant code associated with the transaction.
|
|
2476
|
+
field :merchant_code, :string, wire: "merchant_code", required: true
|
|
2477
|
+
##
|
|
2478
|
+
# :attr_reader: status
|
|
2479
|
+
# The current status of the transaction.
|
|
2480
|
+
field :status, :string, wire: "status", required: true
|
|
2481
|
+
##
|
|
2482
|
+
# :attr_reader: transaction_id
|
|
2483
|
+
# The transaction id. Deprecated: use `client_transaction_id` instead.
|
|
2484
|
+
field :transaction_id, :string, wire: "transaction_id", required: false
|
|
2485
|
+
end
|
|
2486
|
+
|
|
2487
|
+
# Information about the underlying physical device.
|
|
2488
|
+
class ReaderDevice < Model
|
|
2489
|
+
##
|
|
2490
|
+
# :attr_reader: identifier
|
|
2491
|
+
# A unique identifier of the physical device (e.g. serial number).
|
|
2492
|
+
field :identifier, :string, wire: "identifier", required: true
|
|
2493
|
+
##
|
|
2494
|
+
# :attr_reader: model
|
|
2495
|
+
# Identifier of the model of the device.
|
|
2496
|
+
field :model, :string, wire: "model", required: true
|
|
2497
|
+
end
|
|
2498
|
+
|
|
2499
|
+
class ReaderPaymentRequestParams < Model
|
|
2500
|
+
##
|
|
2501
|
+
# :attr_reader: affiliate
|
|
2502
|
+
field :affiliate, [:model, "ReaderPaymentRequestParamsAffiliate"], wire: "affiliate", required: false
|
|
2503
|
+
##
|
|
2504
|
+
# :attr_reader: client_transaction_id
|
|
2505
|
+
# Caller-supplied correlation identifier, used as the idempotency key.
|
|
2506
|
+
field :client_transaction_id, :string, wire: "client_transaction_id", required: true
|
|
2507
|
+
##
|
|
2508
|
+
# :attr_reader: tip_amount
|
|
2509
|
+
# Portion of total_amount that is a tip, in minor units.
|
|
2510
|
+
field :tip_amount, :integer, wire: "tip_amount", required: false
|
|
2511
|
+
##
|
|
2512
|
+
# :attr_reader: total_amount
|
|
2513
|
+
field :total_amount, [:model, "ReaderPaymentRequestParamsTotalAmount"], wire: "total_amount", required: true
|
|
2514
|
+
end
|
|
2515
|
+
|
|
2516
|
+
# Optional caller-supplied context about the integration initiating the payment.
|
|
2517
|
+
class ReaderPaymentRequestParamsAffiliate < Model
|
|
2518
|
+
##
|
|
2519
|
+
# :attr_reader: app_id
|
|
2520
|
+
field :app_id, :string, wire: "app_id", required: true
|
|
2521
|
+
##
|
|
2522
|
+
# :attr_reader: key
|
|
2523
|
+
field :key, :string, wire: "key", required: true
|
|
2524
|
+
end
|
|
2525
|
+
|
|
2526
|
+
# Amount charged on the reader, including any tip. The amount is represented as an integer value altogether with the currency and the minor unit. For example, MXN 10.00 is represented as value 1000 with minor unit of 2.
|
|
2527
|
+
class ReaderPaymentRequestParamsTotalAmount < Model
|
|
2528
|
+
##
|
|
2529
|
+
# :attr_reader: currency
|
|
2530
|
+
# Currency ISO 4217 code
|
|
2531
|
+
field :currency, :string, wire: "currency", required: true
|
|
2532
|
+
##
|
|
2533
|
+
# :attr_reader: value
|
|
2534
|
+
# Amount in minor units (e.g. cents).
|
|
2535
|
+
field :value, :integer, wire: "value", required: true
|
|
2536
|
+
end
|
|
2537
|
+
|
|
2538
|
+
class ReaderPaymentResponse < Model
|
|
2539
|
+
##
|
|
2540
|
+
# :attr_reader: data
|
|
2541
|
+
field :data, [:model, "ReaderPaymentResponseData"], wire: "data", required: false
|
|
2542
|
+
end
|
|
2543
|
+
|
|
2544
|
+
class ReaderPaymentResponseData < Model
|
|
2545
|
+
##
|
|
2546
|
+
# :attr_reader: client_transaction_id
|
|
2547
|
+
# Caller-supplied correlation identifier that was provided in the request.
|
|
2548
|
+
field :client_transaction_id, :string, wire: "client_transaction_id", required: false
|
|
2549
|
+
##
|
|
2550
|
+
# :attr_reader: transaction_code
|
|
2551
|
+
# Transaction code returned by the acquirer/processing entity after processing the transaction.
|
|
2552
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
2553
|
+
end
|
|
2554
|
+
|
|
2555
|
+
# Structured receipt details for a transaction. The transaction's `amount`, `vat_amount`, and `tip_amount`, as well as event amounts, are returned as decimal strings in major currency units, for example `"10.10"` for EUR 10.10.
|
|
2556
|
+
class Receipt < Model
|
|
2557
|
+
##
|
|
2558
|
+
# :attr_reader: transaction_data
|
|
2559
|
+
field :transaction_data, [:model, "ReceiptTransaction"], wire: "transaction_data", required: false
|
|
2560
|
+
##
|
|
2561
|
+
# :attr_reader: merchant_data
|
|
2562
|
+
field :merchant_data, [:model, "ReceiptMerchantData"], wire: "merchant_data", required: false
|
|
2563
|
+
##
|
|
2564
|
+
# :attr_reader: emv_data
|
|
2565
|
+
# EMV-specific metadata returned for card-present payments.
|
|
2566
|
+
field :emv_data, [:map, :any], wire: "emv_data", required: false
|
|
2567
|
+
##
|
|
2568
|
+
# :attr_reader: acquirer_data
|
|
2569
|
+
# Acquirer-specific metadata related to the card authorization.
|
|
2570
|
+
field :acquirer_data, [:model, "ReceiptAcquirerData"], wire: "acquirer_data", required: false
|
|
2571
|
+
end
|
|
2572
|
+
|
|
2573
|
+
# Acquirer-specific metadata related to the card authorization.
|
|
2574
|
+
class ReceiptAcquirerData < Model
|
|
2575
|
+
##
|
|
2576
|
+
# :attr_reader: tid
|
|
2577
|
+
# Identifier of the terminal used for the authorization.
|
|
2578
|
+
field :tid, :string, wire: "tid", required: false
|
|
2579
|
+
##
|
|
2580
|
+
# :attr_reader: authorization_code
|
|
2581
|
+
# Authorization code returned by the acquirer.
|
|
2582
|
+
field :authorization_code, :string, wire: "authorization_code", required: false
|
|
2583
|
+
##
|
|
2584
|
+
# :attr_reader: return_code
|
|
2585
|
+
# Return code reported by the acquirer.
|
|
2586
|
+
field :return_code, :string, wire: "return_code", required: false
|
|
2587
|
+
##
|
|
2588
|
+
# :attr_reader: local_time
|
|
2589
|
+
# Local timestamp of the card authorization.
|
|
2590
|
+
field :local_time, :string, wire: "local_time", required: false
|
|
2591
|
+
end
|
|
2592
|
+
|
|
2593
|
+
# Payment card details displayed on the receipt.
|
|
2594
|
+
class ReceiptCard < Model
|
|
2595
|
+
##
|
|
2596
|
+
# :attr_reader: last_4_digits
|
|
2597
|
+
# Last four digits of the payment card number.
|
|
2598
|
+
field :last_4_digits, :string, wire: "last_4_digits", required: false
|
|
2599
|
+
##
|
|
2600
|
+
# :attr_reader: type
|
|
2601
|
+
# Issuing card network of the payment card.
|
|
2602
|
+
field :type, :string, wire: "type", required: false
|
|
2603
|
+
end
|
|
2604
|
+
|
|
2605
|
+
# Transaction event details as rendered on the receipt.
|
|
2606
|
+
class ReceiptEvent < Model
|
|
2607
|
+
##
|
|
2608
|
+
# :attr_reader: id
|
|
2609
|
+
# Numeric identifier of a transaction event. Use it as `tx_event_id` when requesting receipt details for a specific event. This is separate from the transaction ID and the transaction history pagination references.
|
|
2610
|
+
field :id, :integer, wire: "id", required: false
|
|
2611
|
+
##
|
|
2612
|
+
# :attr_reader: transaction_id
|
|
2613
|
+
# Unique identifier of the transaction.
|
|
2614
|
+
field :transaction_id, :string, wire: "transaction_id", required: false
|
|
2615
|
+
##
|
|
2616
|
+
# :attr_reader: type
|
|
2617
|
+
field :type, :string, wire: "type", required: false
|
|
2618
|
+
##
|
|
2619
|
+
# :attr_reader: status
|
|
2620
|
+
field :status, :string, wire: "status", required: false
|
|
2621
|
+
##
|
|
2622
|
+
# :attr_reader: amount
|
|
2623
|
+
# Amount associated with the transaction event, in major units.
|
|
2624
|
+
field :amount, :string, wire: "amount", required: false
|
|
2625
|
+
##
|
|
2626
|
+
# :attr_reader: timestamp
|
|
2627
|
+
# The timestamp of when the transaction event occurred.
|
|
2628
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
2629
|
+
##
|
|
2630
|
+
# :attr_reader: receipt_no
|
|
2631
|
+
# Receipt number associated with the event.
|
|
2632
|
+
field :receipt_no, :string, wire: "receipt_no", required: false
|
|
2633
|
+
end
|
|
2634
|
+
|
|
2635
|
+
# Merchant details displayed on a transaction receipt.
|
|
2636
|
+
class ReceiptMerchantData < Model
|
|
2637
|
+
##
|
|
2638
|
+
# :attr_reader: merchant_profile
|
|
2639
|
+
# Merchant profile details displayed on the receipt.
|
|
2640
|
+
field :merchant_profile, [:model, "ReceiptMerchantDataMerchantProfile"], wire: "merchant_profile", required: false
|
|
2641
|
+
##
|
|
2642
|
+
# :attr_reader: locale
|
|
2643
|
+
# Locale used for rendering localized receipt fields.
|
|
2644
|
+
field :locale, :string, wire: "locale", required: false
|
|
2645
|
+
end
|
|
2646
|
+
|
|
2647
|
+
# Merchant profile details displayed on the receipt.
|
|
2648
|
+
class ReceiptMerchantDataMerchantProfile < Model
|
|
2649
|
+
##
|
|
2650
|
+
# :attr_reader: merchant_code
|
|
2651
|
+
# Short unique identifier for the merchant.
|
|
2652
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
2653
|
+
##
|
|
2654
|
+
# :attr_reader: business_name
|
|
2655
|
+
# Business name of the merchant.
|
|
2656
|
+
field :business_name, :string, wire: "business_name", required: false
|
|
2657
|
+
##
|
|
2658
|
+
# :attr_reader: company_registration_number
|
|
2659
|
+
# Company registration number of the merchant.
|
|
2660
|
+
field :company_registration_number, :string, wire: "company_registration_number", required: false
|
|
2661
|
+
##
|
|
2662
|
+
# :attr_reader: vat_id
|
|
2663
|
+
# VAT identification number of the merchant.
|
|
2664
|
+
field :vat_id, :string, wire: "vat_id", required: false
|
|
2665
|
+
##
|
|
2666
|
+
# :attr_reader: website
|
|
2667
|
+
# Website of the merchant.
|
|
2668
|
+
field :website, :string, wire: "website", required: false
|
|
2669
|
+
##
|
|
2670
|
+
# :attr_reader: email
|
|
2671
|
+
# Email address of the merchant.
|
|
2672
|
+
field :email, :string, wire: "email", required: false
|
|
2673
|
+
##
|
|
2674
|
+
# :attr_reader: language
|
|
2675
|
+
# Language configured for the merchant profile.
|
|
2676
|
+
field :language, :string, wire: "language", required: false
|
|
2677
|
+
##
|
|
2678
|
+
# :attr_reader: address
|
|
2679
|
+
# Business address of the merchant.
|
|
2680
|
+
field :address, [:model, "ReceiptMerchantDataMerchantProfileAddress"], wire: "address", required: false
|
|
2681
|
+
end
|
|
2682
|
+
|
|
2683
|
+
# Business address of the merchant.
|
|
2684
|
+
class ReceiptMerchantDataMerchantProfileAddress < Model
|
|
2685
|
+
##
|
|
2686
|
+
# :attr_reader: address_line1
|
|
2687
|
+
# First line of the merchant address.
|
|
2688
|
+
field :address_line1, :string, wire: "address_line1", required: false
|
|
2689
|
+
##
|
|
2690
|
+
# :attr_reader: address_line2
|
|
2691
|
+
# Second line of the merchant address.
|
|
2692
|
+
field :address_line2, :string, wire: "address_line2", required: false
|
|
2693
|
+
##
|
|
2694
|
+
# :attr_reader: city
|
|
2695
|
+
# City of the merchant address.
|
|
2696
|
+
field :city, :string, wire: "city", required: false
|
|
2697
|
+
##
|
|
2698
|
+
# :attr_reader: country
|
|
2699
|
+
# Two-letter ISO 3166-1 alpha-2 country code of the merchant address.
|
|
2700
|
+
field :country, :string, wire: "country", required: false
|
|
2701
|
+
##
|
|
2702
|
+
# :attr_reader: country_en_name
|
|
2703
|
+
# English name of the country in the merchant address.
|
|
2704
|
+
field :country_en_name, :string, wire: "country_en_name", required: false
|
|
2705
|
+
##
|
|
2706
|
+
# :attr_reader: country_native_name
|
|
2707
|
+
# Localized name of the country in the merchant address.
|
|
2708
|
+
field :country_native_name, :string, wire: "country_native_name", required: false
|
|
2709
|
+
##
|
|
2710
|
+
# :attr_reader: region_name
|
|
2711
|
+
# Region or state of the merchant address.
|
|
2712
|
+
field :region_name, :string, wire: "region_name", required: false
|
|
2713
|
+
##
|
|
2714
|
+
# :attr_reader: post_code
|
|
2715
|
+
# Postal code of the merchant address.
|
|
2716
|
+
field :post_code, :string, wire: "post_code", required: false
|
|
2717
|
+
##
|
|
2718
|
+
# :attr_reader: landline
|
|
2719
|
+
# Landline phone number of the merchant.
|
|
2720
|
+
field :landline, :string, wire: "landline", required: false
|
|
2721
|
+
end
|
|
2722
|
+
|
|
2723
|
+
# Card reader details displayed on the receipt.
|
|
2724
|
+
class ReceiptReader < Model
|
|
2725
|
+
##
|
|
2726
|
+
# :attr_reader: code
|
|
2727
|
+
# Unique identifier of the physical card reader.
|
|
2728
|
+
field :code, :string, wire: "code", required: false
|
|
2729
|
+
##
|
|
2730
|
+
# :attr_reader: type
|
|
2731
|
+
# Model of the physical card reader.
|
|
2732
|
+
field :type, :string, wire: "type", required: false
|
|
2733
|
+
end
|
|
2734
|
+
|
|
2735
|
+
# Transaction details displayed on a receipt.
|
|
2736
|
+
class ReceiptTransaction < Model
|
|
2737
|
+
##
|
|
2738
|
+
# :attr_reader: transaction_code
|
|
2739
|
+
# Transaction code returned after processing the transaction.
|
|
2740
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
2741
|
+
##
|
|
2742
|
+
# :attr_reader: transaction_id
|
|
2743
|
+
# Unique identifier of the transaction.
|
|
2744
|
+
field :transaction_id, :string, wire: "transaction_id", required: false
|
|
2745
|
+
##
|
|
2746
|
+
# :attr_reader: merchant_code
|
|
2747
|
+
# Short unique identifier for the merchant.
|
|
2748
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
2749
|
+
##
|
|
2750
|
+
# :attr_reader: amount
|
|
2751
|
+
# Total transaction amount, in major units.
|
|
2752
|
+
field :amount, :string, wire: "amount", required: false
|
|
2753
|
+
##
|
|
2754
|
+
# :attr_reader: vat_amount
|
|
2755
|
+
# VAT included in the transaction amount, in major units.
|
|
2756
|
+
field :vat_amount, :string, wire: "vat_amount", required: false
|
|
2757
|
+
##
|
|
2758
|
+
# :attr_reader: tip_amount
|
|
2759
|
+
# Tip included in the transaction amount, in major units.
|
|
2760
|
+
field :tip_amount, :string, wire: "tip_amount", required: false
|
|
2761
|
+
##
|
|
2762
|
+
# :attr_reader: currency
|
|
2763
|
+
# Three-letter ISO 4217 currency code of the transaction.
|
|
2764
|
+
field :currency, :string, wire: "currency", required: false
|
|
2765
|
+
##
|
|
2766
|
+
# :attr_reader: timestamp
|
|
2767
|
+
# The timestamp of when the transaction was created.
|
|
2768
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
2769
|
+
##
|
|
2770
|
+
# :attr_reader: status
|
|
2771
|
+
# Current processing status of the transaction.
|
|
2772
|
+
field :status, :string, wire: "status", required: false
|
|
2773
|
+
##
|
|
2774
|
+
# :attr_reader: payment_type
|
|
2775
|
+
# Payment type used for the transaction.
|
|
2776
|
+
field :payment_type, :string, wire: "payment_type", required: false
|
|
2777
|
+
##
|
|
2778
|
+
# :attr_reader: entry_mode
|
|
2779
|
+
# Entry mode of the payment details.
|
|
2780
|
+
field :entry_mode, :string, wire: "entry_mode", required: false
|
|
2781
|
+
##
|
|
2782
|
+
# :attr_reader: verification_method
|
|
2783
|
+
# Cardholder verification method.
|
|
2784
|
+
field :verification_method, :string, wire: "verification_method", required: false
|
|
2785
|
+
##
|
|
2786
|
+
# :attr_reader: card_reader
|
|
2787
|
+
field :card_reader, [:model, "ReceiptReader"], wire: "card_reader", required: false
|
|
2788
|
+
##
|
|
2789
|
+
# :attr_reader: card
|
|
2790
|
+
field :card, [:model, "ReceiptCard"], wire: "card", required: false
|
|
2791
|
+
##
|
|
2792
|
+
# :attr_reader: installments_count
|
|
2793
|
+
# Number of installments.
|
|
2794
|
+
field :installments_count, :integer, wire: "installments_count", required: false
|
|
2795
|
+
##
|
|
2796
|
+
# :attr_reader: process_as
|
|
2797
|
+
# Whether the transaction was processed as credit or debit.
|
|
2798
|
+
field :process_as, :string, wire: "process_as", required: false
|
|
2799
|
+
##
|
|
2800
|
+
# :attr_reader: products
|
|
2801
|
+
# Products associated with the transaction.
|
|
2802
|
+
field :products, [:array, [:model, "ReceiptTransactionProductsItem"]], wire: "products", required: false
|
|
2803
|
+
##
|
|
2804
|
+
# :attr_reader: vat_rates
|
|
2805
|
+
# VAT breakdown for the transaction.
|
|
2806
|
+
field :vat_rates, [:array, [:model, "ReceiptTransactionVatRatesItem"]], wire: "vat_rates", required: false
|
|
2807
|
+
##
|
|
2808
|
+
# :attr_reader: events
|
|
2809
|
+
# Transaction events displayed on the receipt.
|
|
2810
|
+
field :events, [:array, [:model, "ReceiptEvent"]], wire: "events", required: false
|
|
2811
|
+
##
|
|
2812
|
+
# :attr_reader: receipt_no
|
|
2813
|
+
# Receipt number associated with the transaction.
|
|
2814
|
+
field :receipt_no, :string, wire: "receipt_no", required: false
|
|
2815
|
+
end
|
|
2816
|
+
|
|
2817
|
+
class ReceiptTransactionProductsItem < Model
|
|
2818
|
+
##
|
|
2819
|
+
# :attr_reader: name
|
|
2820
|
+
# Product name.
|
|
2821
|
+
field :name, :string, wire: "name", required: false
|
|
2822
|
+
##
|
|
2823
|
+
# :attr_reader: description
|
|
2824
|
+
# Product description.
|
|
2825
|
+
field :description, :string, wire: "description", required: false
|
|
2826
|
+
##
|
|
2827
|
+
# :attr_reader: price
|
|
2828
|
+
# Product price.
|
|
2829
|
+
field :price, :string, wire: "price", required: false
|
|
2830
|
+
##
|
|
2831
|
+
# :attr_reader: vat_rate
|
|
2832
|
+
# VAT rate.
|
|
2833
|
+
field :vat_rate, :string, wire: "vat_rate", required: false
|
|
2834
|
+
##
|
|
2835
|
+
# :attr_reader: single_vat_amount
|
|
2836
|
+
# VAT amount for a single product.
|
|
2837
|
+
field :single_vat_amount, :string, wire: "single_vat_amount", required: false
|
|
2838
|
+
##
|
|
2839
|
+
# :attr_reader: price_with_vat
|
|
2840
|
+
# Product price including VAT.
|
|
2841
|
+
field :price_with_vat, :string, wire: "price_with_vat", required: false
|
|
2842
|
+
##
|
|
2843
|
+
# :attr_reader: vat_amount
|
|
2844
|
+
# Total VAT amount for the product quantity.
|
|
2845
|
+
field :vat_amount, :string, wire: "vat_amount", required: false
|
|
2846
|
+
##
|
|
2847
|
+
# :attr_reader: quantity
|
|
2848
|
+
# Product quantity.
|
|
2849
|
+
field :quantity, :integer, wire: "quantity", required: false
|
|
2850
|
+
##
|
|
2851
|
+
# :attr_reader: total_price
|
|
2852
|
+
# Total price calculated as the product price multiplied by the quantity.
|
|
2853
|
+
field :total_price, :string, wire: "total_price", required: false
|
|
2854
|
+
##
|
|
2855
|
+
# :attr_reader: total_with_vat
|
|
2856
|
+
# Total product price including VAT.
|
|
2857
|
+
field :total_with_vat, :string, wire: "total_with_vat", required: false
|
|
2858
|
+
end
|
|
2859
|
+
|
|
2860
|
+
class ReceiptTransactionVatRatesItem < Model
|
|
2861
|
+
##
|
|
2862
|
+
# :attr_reader: gross
|
|
2863
|
+
# Gross amount to which the VAT rate applies.
|
|
2864
|
+
field :gross, :number, wire: "gross", required: false
|
|
2865
|
+
##
|
|
2866
|
+
# :attr_reader: net
|
|
2867
|
+
# Net amount to which the VAT rate applies.
|
|
2868
|
+
field :net, :number, wire: "net", required: false
|
|
2869
|
+
##
|
|
2870
|
+
# :attr_reader: rate
|
|
2871
|
+
# VAT rate applied to the transaction amount.
|
|
2872
|
+
field :rate, :number, wire: "rate", required: false
|
|
2873
|
+
##
|
|
2874
|
+
# :attr_reader: vat
|
|
2875
|
+
# VAT amount included in the gross amount.
|
|
2876
|
+
field :vat, :number, wire: "vat", required: false
|
|
2877
|
+
end
|
|
2878
|
+
|
|
2879
|
+
# Optional amount for partial refunds of transactions.
|
|
2880
|
+
class RefundTransactionRequest < Model
|
|
2881
|
+
##
|
|
2882
|
+
# :attr_reader: amount
|
|
2883
|
+
# Amount to refund in major units of the transaction's currency, for example `5` for EUR 5.00. It must be greater than zero and cannot exceed the amount eligible for a refund. Eligibility depends on the transaction and country/currency rules. If omitted, the system requests a full refund.
|
|
2884
|
+
field :amount, :number, wire: "amount", required: false
|
|
2885
|
+
end
|
|
2886
|
+
|
|
2887
|
+
class RefundTransactionResponse < Model
|
|
2888
|
+
end
|
|
2889
|
+
|
|
2890
|
+
# A custom role that can be used to assign set of permissions to members.
|
|
2891
|
+
class Role < Model
|
|
2892
|
+
##
|
|
2893
|
+
# :attr_reader: id
|
|
2894
|
+
# Unique identifier of the role.
|
|
2895
|
+
field :id, :string, wire: "id", required: true
|
|
2896
|
+
##
|
|
2897
|
+
# :attr_reader: name
|
|
2898
|
+
# User-defined name of the role.
|
|
2899
|
+
field :name, :string, wire: "name", required: true
|
|
2900
|
+
##
|
|
2901
|
+
# :attr_reader: description
|
|
2902
|
+
# User-defined description of the role.
|
|
2903
|
+
field :description, :string, wire: "description", required: false
|
|
2904
|
+
##
|
|
2905
|
+
# :attr_reader: permissions
|
|
2906
|
+
# List of permission granted by this role.
|
|
2907
|
+
field :permissions, [:array, :string], wire: "permissions", required: true
|
|
2908
|
+
##
|
|
2909
|
+
# :attr_reader: is_predefined
|
|
2910
|
+
# True if the role is provided by SumUp.
|
|
2911
|
+
field :is_predefined, :boolean, wire: "is_predefined", required: true
|
|
2912
|
+
##
|
|
2913
|
+
# :attr_reader: metadata
|
|
2914
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
2915
|
+
##
|
|
2916
|
+
# :attr_reader: created_at
|
|
2917
|
+
# The timestamp of when the role was created.
|
|
2918
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
2919
|
+
##
|
|
2920
|
+
# :attr_reader: updated_at
|
|
2921
|
+
# The timestamp of when the role was last updated.
|
|
2922
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
2923
|
+
end
|
|
2924
|
+
|
|
2925
|
+
# Core model of the Sales API. Returned by `GET /sales` and `GET /sales/{sale_id}`.
|
|
2926
|
+
#
|
|
2927
|
+
# Non-finalised sales are never returned; only fully-paid sales.
|
|
2928
|
+
#
|
|
2929
|
+
# Item lines are `SaleItem`. Merchant fees appear as `type: "FEE"` lines; extra fee data
|
|
2930
|
+
# is in `features`.
|
|
2931
|
+
class Sale < Model
|
|
2932
|
+
##
|
|
2933
|
+
# :attr_reader: id
|
|
2934
|
+
# The ID of the sale.
|
|
2935
|
+
field :id, :string, wire: "id", required: true
|
|
2936
|
+
##
|
|
2937
|
+
# :attr_reader: user_id
|
|
2938
|
+
# Identity UUID of the cashier who processed the sale. Omitted when the cashier
|
|
2939
|
+
# identity is unknown.
|
|
2940
|
+
field :user_id, :string, wire: "user_id", required: false
|
|
2941
|
+
##
|
|
2942
|
+
# :attr_reader: currency
|
|
2943
|
+
field :currency, [:model, "SalesActivityCurrency"], wire: "currency", required: true
|
|
2944
|
+
##
|
|
2945
|
+
# :attr_reader: name
|
|
2946
|
+
# Human-readable name of the sale (not unique, not the sale id).
|
|
2947
|
+
field :name, :string, wire: "name", required: false
|
|
2948
|
+
##
|
|
2949
|
+
# :attr_reader: note
|
|
2950
|
+
# Optional note attached to the sale, visible on receipts and the UI.
|
|
2951
|
+
field :note, :string, wire: "note", required: false
|
|
2952
|
+
##
|
|
2953
|
+
# :attr_reader: items
|
|
2954
|
+
# The lines sold in this sale, in the order they were added to the cart.
|
|
2955
|
+
# Includes merchant fees (`type: "FEE"`) when present; fee details are in `features`.
|
|
2956
|
+
field :items, [:array, [:model, "SaleItem"]], wire: "items", required: true
|
|
2957
|
+
##
|
|
2958
|
+
# :attr_reader: price
|
|
2959
|
+
field :price, [:model, "SaleTotals"], wire: "price", required: true
|
|
2960
|
+
##
|
|
2961
|
+
# :attr_reader: tax_mode
|
|
2962
|
+
field :tax_mode, :string, wire: "tax_mode", required: true
|
|
2963
|
+
##
|
|
2964
|
+
# :attr_reader: source
|
|
2965
|
+
field :source, [:model, "SaleSource"], wire: "source", required: true
|
|
2966
|
+
##
|
|
2967
|
+
# :attr_reader: payments
|
|
2968
|
+
# Payments on this sale, in the order they were recorded.
|
|
2969
|
+
field :payments, [:array, [:model, "SalePayment"]], wire: "payments", required: true
|
|
2970
|
+
##
|
|
2971
|
+
# :attr_reader: created_at
|
|
2972
|
+
# Instant when the sale was created.
|
|
2973
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
2974
|
+
##
|
|
2975
|
+
# :attr_reader: closed_at
|
|
2976
|
+
# Instant when the sale was closed. Always present: non-finalised sales are never returned.
|
|
2977
|
+
field :closed_at, :string, wire: "closed_at", required: true
|
|
2978
|
+
##
|
|
2979
|
+
# :attr_reader: state
|
|
2980
|
+
field :state, :string, wire: "state", required: true
|
|
2981
|
+
end
|
|
2982
|
+
|
|
2983
|
+
# Gift card used for this payment. Present when `method` is `gift_card` and the gift card
|
|
2984
|
+
# id is known.
|
|
2985
|
+
# Gift card IDs use the format "GC" followed by 9 alphanumeric characters
|
|
2986
|
+
# (e.g. GCZ3NTMB1V).
|
|
2987
|
+
class SaleGiftCardPayment < Model
|
|
2988
|
+
##
|
|
2989
|
+
# :attr_reader: id
|
|
2990
|
+
# Gift card identifier. Format "GC" followed by 9 alphanumeric characters
|
|
2991
|
+
# (e.g. GCZ3NTMB1V).
|
|
2992
|
+
field :id, :string, wire: "id", required: true
|
|
2993
|
+
end
|
|
2994
|
+
|
|
2995
|
+
# A single line of a sale.
|
|
2996
|
+
#
|
|
2997
|
+
# The envelope (id, type, name, quantity, unit_of_measure, price) is stable and
|
|
2998
|
+
# type-agnostic: any consumer can render and total a line from these fields alone.
|
|
2999
|
+
# Type-specific data is in `features`. There is no per-type object and no discriminator,
|
|
3000
|
+
# so a new item type does not change this schema.
|
|
3001
|
+
class SaleItem < Model
|
|
3002
|
+
##
|
|
3003
|
+
# :attr_reader: id
|
|
3004
|
+
# Stable identifier of the line within the sale. Used for linking (e.g. deposits).
|
|
3005
|
+
field :id, :string, wire: "id", required: true
|
|
3006
|
+
##
|
|
3007
|
+
# :attr_reader: type
|
|
3008
|
+
# Classifies a sale line. Not a schema subclass.
|
|
3009
|
+
#
|
|
3010
|
+
# Known values: `CATALOG`, `DEPOSIT`, `GIFT_CARD`, `CUSTOM`, `FEE`.
|
|
3011
|
+
#
|
|
3012
|
+
# `FEE` lines represent merchant-charged fees on the sale (e.g. shipping, service
|
|
3013
|
+
# charge, surcharge, cancellation). They participate in sale totals like any other
|
|
3014
|
+
# line; type-specific data is carried in `features` (see `SaleItemFeature` for the
|
|
3015
|
+
# conventional feature keys).
|
|
3016
|
+
#
|
|
3017
|
+
# This is intentionally an open string, NOT a closed enum: new values are added
|
|
3018
|
+
# over time as pure data and consumers MUST tolerate unknown values, rendering the
|
|
3019
|
+
# line from the generic envelope (name, quantity, price, taxes) and reading any
|
|
3020
|
+
# extra information from `features`.
|
|
3021
|
+
field :type, :string, wire: "type", required: true
|
|
3022
|
+
##
|
|
3023
|
+
# :attr_reader: name
|
|
3024
|
+
# Display name of the line.
|
|
3025
|
+
field :name, :string, wire: "name", required: true
|
|
3026
|
+
##
|
|
3027
|
+
# :attr_reader: quantity
|
|
3028
|
+
# The numerical value representing the quantity in the specified unit.
|
|
3029
|
+
field :quantity, :number, wire: "quantity", required: true
|
|
3030
|
+
##
|
|
3031
|
+
# :attr_reader: unit_of_measure
|
|
3032
|
+
field :unit_of_measure, [:model, "UnitOfMeasure"], wire: "unit_of_measure", required: true
|
|
3033
|
+
##
|
|
3034
|
+
# :attr_reader: service_type
|
|
3035
|
+
# The type of service for this line.
|
|
3036
|
+
field :service_type, :string, wire: "service_type", required: false
|
|
3037
|
+
##
|
|
3038
|
+
# :attr_reader: note
|
|
3039
|
+
# Optional free-text note attached to the line, visible on receipts.
|
|
3040
|
+
field :note, :string, wire: "note", required: false
|
|
3041
|
+
##
|
|
3042
|
+
# :attr_reader: price
|
|
3043
|
+
field :price, [:model, "SaleItemPrice"], wire: "price", required: true
|
|
3044
|
+
##
|
|
3045
|
+
# :attr_reader: categories
|
|
3046
|
+
# Categories the line belongs to. A shared optional structure available to any
|
|
3047
|
+
# line; not a per-type field.
|
|
3048
|
+
field :categories, [:array, [:model, "SaleItemCategory"]], wire: "categories", required: false
|
|
3049
|
+
##
|
|
3050
|
+
# :attr_reader: modifiers
|
|
3051
|
+
# Modifiers customise a line (e.g. "oat milk" on a cappuccino). A shared
|
|
3052
|
+
# optional structure available to any line; not a per-type field.
|
|
3053
|
+
field :modifiers, [:array, [:model, "ModifierItem"]], wire: "modifiers", required: false
|
|
3054
|
+
##
|
|
3055
|
+
# :attr_reader: references
|
|
3056
|
+
field :references, [:model, "SaleItemReferences"], wire: "references", required: false
|
|
3057
|
+
##
|
|
3058
|
+
# :attr_reader: features
|
|
3059
|
+
# Named, typed, type-specific data. New item types add their data here as
|
|
3060
|
+
# features instead of new schema variants. See `SaleItemFeature` for per-type examples.
|
|
3061
|
+
field :features, [:array, [:model, "SaleItemFeature"]], wire: "features", required: false
|
|
3062
|
+
end
|
|
3063
|
+
|
|
3064
|
+
# A category a line belongs to.
|
|
3065
|
+
class SaleItemCategory < Model
|
|
3066
|
+
##
|
|
3067
|
+
# :attr_reader: id
|
|
3068
|
+
# The category id. Usually a UUID, but not always (legacy cases).
|
|
3069
|
+
field :id, :string, wire: "id", required: true
|
|
3070
|
+
##
|
|
3071
|
+
# :attr_reader: name
|
|
3072
|
+
# The category name.
|
|
3073
|
+
field :name, :string, wire: "name", required: true
|
|
3074
|
+
end
|
|
3075
|
+
|
|
3076
|
+
# A named, typed characteristic of a line. New item types add data here instead of
|
|
3077
|
+
# a typed sub-object per type.
|
|
3078
|
+
#
|
|
3079
|
+
# Examples by item type (illustrative, not exhaustive):
|
|
3080
|
+
# - DEPOSIT: `operation_type` = "SALE", `linked_line_id` = "line-1"
|
|
3081
|
+
# - GIFT_CARD: `gift_card_reference` = "GCMINGXPC5"
|
|
3082
|
+
# - CATALOG: `variant_name` = "Large", `item_id` / `variant_id` (TEXT),
|
|
3083
|
+
# `reporting_category_id` = "cat-..."
|
|
3084
|
+
# - FEE: `fee_type` = "SHIPPING" (required); optional `fee_id`,
|
|
3085
|
+
# `value_absolute` or `value_percentage`, and per-type metadata
|
|
3086
|
+
# features such as `delivery_name` / `tracking_reference` (shipping),
|
|
3087
|
+
# `card_type` / `scheme` (surcharge), or `policy_id` (cancellation)
|
|
3088
|
+
# - (future) SUBSCRIPTION: `billing_period` = "P1M", `renews_at` = "2026-07-02"
|
|
3089
|
+
#
|
|
3090
|
+
# Conventional `FEE` feature keys:
|
|
3091
|
+
# - `fee_type` (TEXT, required): `SHIPPING`, `SURCHARGE`, `SERVICE_CHARGE`, or
|
|
3092
|
+
# `CANCELLATION`
|
|
3093
|
+
# - `fee_id` (TEXT, optional): identifier of the fee definition
|
|
3094
|
+
# - `value_absolute` (INTEGER, optional): configured absolute value in minor units
|
|
3095
|
+
# of the sale currency (the charged amount is on `price`)
|
|
3096
|
+
# - `value_percentage` (INTEGER, optional): configured percentage in minor units
|
|
3097
|
+
# (1/100000; e.g. 10000 = 10%)
|
|
3098
|
+
# - Per-type metadata (optional, TEXT unless noted): `delivery_name`,
|
|
3099
|
+
# `tracking_reference` (shipping); `card_type`, `scheme` (surcharge);
|
|
3100
|
+
# `policy_id` (cancellation)
|
|
3101
|
+
class SaleItemFeature < Model
|
|
3102
|
+
##
|
|
3103
|
+
# :attr_reader: name
|
|
3104
|
+
# The feature name/key.
|
|
3105
|
+
field :name, :string, wire: "name", required: true
|
|
3106
|
+
##
|
|
3107
|
+
# :attr_reader: value_type
|
|
3108
|
+
field :value_type, :string, wire: "value_type", required: true
|
|
3109
|
+
##
|
|
3110
|
+
# :attr_reader: value
|
|
3111
|
+
# The feature value in canonical string form, to be parsed per `value_type`
|
|
3112
|
+
# (e.g. INTEGER -> "3", DECIMAL -> "1.50", DATE -> "2026-07-02",
|
|
3113
|
+
# BOOLEAN -> "true"). Carrying it as a string keeps the wire format stable as
|
|
3114
|
+
# new feature names and value types are introduced.
|
|
3115
|
+
field :value, :string, wire: "value", required: true
|
|
3116
|
+
end
|
|
3117
|
+
|
|
3118
|
+
# Pricing for a single line, valid for every item type.
|
|
3119
|
+
#
|
|
3120
|
+
# Merges the standard amounts (with tax breakdown) and the final amounts (after
|
|
3121
|
+
# discounts/modifiers).
|
|
3122
|
+
#
|
|
3123
|
+
# Totals and tax amounts can be negative for return-like operations (for example
|
|
3124
|
+
# a deposit with `operation_type` = `RETURN`).
|
|
3125
|
+
class SaleItemPrice < Model
|
|
3126
|
+
##
|
|
3127
|
+
# :attr_reader: unit_amount
|
|
3128
|
+
# The price of a single unit. If the tax_mode is GROSS it includes taxes,
|
|
3129
|
+
# otherwise no tax is included. It does NOT include discounts.
|
|
3130
|
+
field :unit_amount, :integer, wire: "unit_amount", required: true
|
|
3131
|
+
##
|
|
3132
|
+
# :attr_reader: total_net_amount
|
|
3133
|
+
# The net amount (including modifiers if applied). It does NOT include discounts.
|
|
3134
|
+
field :total_net_amount, :integer, wire: "total_net_amount", required: true
|
|
3135
|
+
##
|
|
3136
|
+
# :attr_reader: total_gross_amount
|
|
3137
|
+
# The gross amount (including modifiers if applied). It does NOT include discounts.
|
|
3138
|
+
field :total_gross_amount, :integer, wire: "total_gross_amount", required: true
|
|
3139
|
+
##
|
|
3140
|
+
# :attr_reader: taxes
|
|
3141
|
+
# Taxes applied on top of the net amount resulting in the gross amount.
|
|
3142
|
+
field :taxes, [:array, [:model, "TaxLine"]], wire: "taxes", required: true
|
|
3143
|
+
##
|
|
3144
|
+
# :attr_reader: discounts
|
|
3145
|
+
# Discounts applied. Discount amounts do not affect `total_net_amount` /
|
|
3146
|
+
# `total_gross_amount`; they are reflected in the `*_final` amounts.
|
|
3147
|
+
field :discounts, [:array, [:model, "DiscountLine"]], wire: "discounts", required: false
|
|
3148
|
+
##
|
|
3149
|
+
# :attr_reader: total_net_amount_final
|
|
3150
|
+
# The final net amount including discounts and modifiers. Equals `total_net_amount` if no discounts apply.
|
|
3151
|
+
field :total_net_amount_final, :integer, wire: "total_net_amount_final", required: true
|
|
3152
|
+
##
|
|
3153
|
+
# :attr_reader: total_gross_amount_final
|
|
3154
|
+
# The final gross amount including discounts, modifiers and taxes. Equals `total_gross_amount` if no discounts apply.
|
|
3155
|
+
field :total_gross_amount_final, :integer, wire: "total_gross_amount_final", required: true
|
|
3156
|
+
##
|
|
3157
|
+
# :attr_reader: taxes_final
|
|
3158
|
+
# Taxes applied on top of `total_net_amount_final` resulting in `total_gross_amount_final`. Equals `taxes` if no discounts apply.
|
|
3159
|
+
field :taxes_final, [:array, [:model, "TaxLine"]], wire: "taxes_final", required: true
|
|
3160
|
+
end
|
|
3161
|
+
|
|
3162
|
+
# Outward identifiers and links for a line, kept in one place rather than scattered
|
|
3163
|
+
# per item type.
|
|
3164
|
+
class SaleItemReferences < Model
|
|
3165
|
+
##
|
|
3166
|
+
# :attr_reader: catalog_source
|
|
3167
|
+
# The source of the catalog the line originates from.
|
|
3168
|
+
field :catalog_source, :string, wire: "catalog_source", required: false
|
|
3169
|
+
##
|
|
3170
|
+
# :attr_reader: catalog_reference
|
|
3171
|
+
# Reference to the backing catalog entity (item variant, deposit, ...),
|
|
3172
|
+
# typically a URN such as
|
|
3173
|
+
# `urn:sumup:pos:variant:${MERCHANT_CODE}:${ITEM_ID}:${VARIANT_ID}` or
|
|
3174
|
+
# `urn:sumup:pos:deposit:${MERCHANT_CODE}:${DEPOSIT_ID}`.
|
|
3175
|
+
# Empty for ad-hoc / manual lines. Type-agnostic on purpose: a new item type
|
|
3176
|
+
# backed by a catalog entity reuses this field instead of adding its own.
|
|
3177
|
+
field :catalog_reference, :string, wire: "catalog_reference", required: false
|
|
3178
|
+
##
|
|
3179
|
+
# :attr_reader: external_id
|
|
3180
|
+
# An external reference id connecting this line to another system.
|
|
3181
|
+
field :external_id, :string, wire: "external_id", required: false
|
|
3182
|
+
##
|
|
3183
|
+
# :attr_reader: sku
|
|
3184
|
+
# Stock keeping unit, enriched from the Catalog when available.
|
|
3185
|
+
field :sku, :string, wire: "sku", required: false
|
|
3186
|
+
end
|
|
3187
|
+
|
|
3188
|
+
# Paginated list of `Sale` objects. Results are ordered **newest first** by the newest
|
|
3189
|
+
# activity recorded for each sale.
|
|
3190
|
+
class SalePage < Model
|
|
3191
|
+
##
|
|
3192
|
+
# :attr_reader: items
|
|
3193
|
+
field :items, [:array, [:model, "Sale"]], wire: "items", required: true
|
|
3194
|
+
##
|
|
3195
|
+
# :attr_reader: pagination_token
|
|
3196
|
+
# Opaque token for the next page. Pass it as the `pagination_token` query parameter
|
|
3197
|
+
# on the next list request. Omitted when no further page is available.
|
|
3198
|
+
field :pagination_token, :string, wire: "pagination_token", required: false
|
|
3199
|
+
end
|
|
3200
|
+
|
|
3201
|
+
# Payment on a closed sale, for bookkeeping and reconciliation.
|
|
3202
|
+
#
|
|
3203
|
+
# Acquirer/processing cost is not on this object. Merchant-charged fees (shipping, service
|
|
3204
|
+
# charge, etc.) appear as `type: "FEE"` item lines in `Sale.items`.
|
|
3205
|
+
class SalePayment < Model
|
|
3206
|
+
##
|
|
3207
|
+
# :attr_reader: method_value
|
|
3208
|
+
# Payment method on public sales read API v1.0.
|
|
3209
|
+
# Digital wallets are first-class methods. Gift card payments use `gift_card`, not `apm`.
|
|
3210
|
+
# Values use lowercase snake_case. Known values are `card`, `cash`, `apm`, `external`,
|
|
3211
|
+
# `apple_pay`, `google_pay`, `whatsapp_pay`, and `gift_card`.
|
|
3212
|
+
# Additional values may be returned as new payment methods become available.
|
|
3213
|
+
field :method_value, :string, wire: "method", required: true
|
|
3214
|
+
##
|
|
3215
|
+
# :attr_reader: reference
|
|
3216
|
+
# The reference to the actual payment used for this sale, e.g. the sumup transaction code.
|
|
3217
|
+
field :reference, :string, wire: "reference", required: true
|
|
3218
|
+
##
|
|
3219
|
+
# :attr_reader: type
|
|
3220
|
+
# Payment operation type.
|
|
3221
|
+
# This is distinct from the payment instrument in `method`.
|
|
3222
|
+
# Values use lowercase snake_case. Known values are `purchase` for a normal purchase
|
|
3223
|
+
# and `unreferenced_refund` for negative sales such as deposit returns.
|
|
3224
|
+
field :type, :string, wire: "type", required: true
|
|
3225
|
+
##
|
|
3226
|
+
# :attr_reader: amount
|
|
3227
|
+
# The amount of the payment including tips.
|
|
3228
|
+
# The value of the amount in minor units of `Sale.currency`.
|
|
3229
|
+
field :amount, :integer, wire: "amount", required: true
|
|
3230
|
+
##
|
|
3231
|
+
# :attr_reader: status
|
|
3232
|
+
# The status of the payment.
|
|
3233
|
+
field :status, :string, wire: "status", required: true
|
|
3234
|
+
##
|
|
3235
|
+
# :attr_reader: apm_type
|
|
3236
|
+
# Alternative payment method type when `method` is `apm`.
|
|
3237
|
+
# Gift card is not an APM on this API.
|
|
3238
|
+
# Values use lowercase snake_case. Known values are `qr_code_pix`, `sepa_dd`, `paypal`,
|
|
3239
|
+
# `sumup_pay`, `twint`, and `iris`.
|
|
3240
|
+
# Additional values may be returned as new alternative payment methods become available.
|
|
3241
|
+
field :apm_type, :string, wire: "apm_type", required: false
|
|
3242
|
+
##
|
|
3243
|
+
# :attr_reader: card
|
|
3244
|
+
field :card, [:model, "SalePaymentCard"], wire: "card", required: false
|
|
3245
|
+
##
|
|
3246
|
+
# :attr_reader: gift_card
|
|
3247
|
+
field :gift_card, [:model, "SaleGiftCardPayment"], wire: "gift_card", required: false
|
|
3248
|
+
##
|
|
3249
|
+
# :attr_reader: processed_at
|
|
3250
|
+
# UTC date-time when SumUp recorded this payment’s exposed `status` (successful, failed,
|
|
3251
|
+
# or canceled). Server processed time when available; otherwise the payment provider’s
|
|
3252
|
+
# transaction time. Not the device clock.
|
|
3253
|
+
field :processed_at, :string, wire: "processed_at", required: true
|
|
3254
|
+
end
|
|
3255
|
+
|
|
3256
|
+
# Card brand, credit/debit processing type, and last four digits.
|
|
3257
|
+
class SalePaymentCard < Model
|
|
3258
|
+
##
|
|
3259
|
+
# :attr_reader: brand
|
|
3260
|
+
# The brand of the card.
|
|
3261
|
+
# Input is case-insensitive; the canonical form is lowercase snake_case.
|
|
3262
|
+
# **VALUES**: [amex, cup, diners, discover, elo, elv, hipercard, jcb, maestro, mastercard, visa, visa_electron,
|
|
3263
|
+
# visa_vpay, vr, eftpos, conecs, swile, girocard, interac, sumup, bancomat].
|
|
3264
|
+
field :brand, :string, wire: "brand", required: true
|
|
3265
|
+
##
|
|
3266
|
+
# :attr_reader: type
|
|
3267
|
+
# Credit or debit processing choice, not brand or funding.
|
|
3268
|
+
# `unknown` when unavailable; prepaid/voucher are not processing types.
|
|
3269
|
+
field :type, :string, wire: "type", required: true
|
|
3270
|
+
##
|
|
3271
|
+
# :attr_reader: last_4_digits
|
|
3272
|
+
# The last 4 digits of the card used for the payment.
|
|
3273
|
+
field :last_4_digits, :string, wire: "last_4_digits", required: true
|
|
3274
|
+
end
|
|
3275
|
+
|
|
3276
|
+
# Summary row for a sale in search results. Use `GET /sales/{sale_id}` for the full `Sale`.
|
|
3277
|
+
class SaleSearchItem < Model
|
|
3278
|
+
##
|
|
3279
|
+
# :attr_reader: id
|
|
3280
|
+
# Sale identifier.
|
|
3281
|
+
field :id, :string, wire: "id", required: true
|
|
3282
|
+
##
|
|
3283
|
+
# :attr_reader: user_id
|
|
3284
|
+
# Identity UUID of the cashier who processed the sale. Omitted when the cashier
|
|
3285
|
+
# identity is unknown.
|
|
3286
|
+
field :user_id, :string, wire: "user_id", required: false
|
|
3287
|
+
##
|
|
3288
|
+
# :attr_reader: state
|
|
3289
|
+
field :state, :string, wire: "state", required: true
|
|
3290
|
+
##
|
|
3291
|
+
# :attr_reader: name
|
|
3292
|
+
# Display name of the sale when set; otherwise a concatenation of item names with
|
|
3293
|
+
# quantities. Omitted when neither is available.
|
|
3294
|
+
field :name, :string, wire: "name", required: false
|
|
3295
|
+
##
|
|
3296
|
+
# :attr_reader: tax_mode
|
|
3297
|
+
# Checkout tax mode for the sale. Same values as `Sale.tax_mode`.
|
|
3298
|
+
field :tax_mode, :string, wire: "tax_mode", required: true
|
|
3299
|
+
##
|
|
3300
|
+
# :attr_reader: currency
|
|
3301
|
+
field :currency, [:model, "SalesActivityCurrency"], wire: "currency", required: true
|
|
3302
|
+
##
|
|
3303
|
+
# :attr_reader: total_amount
|
|
3304
|
+
# Final sale gross total after discounts and taxes, excluding tips.
|
|
3305
|
+
# Same value as `Sale.price.gross_amount`, in minor units according to `currency.scale`.
|
|
3306
|
+
# Payment amounts include tips and can therefore differ from this total.
|
|
3307
|
+
field :total_amount, :integer, wire: "total_amount", required: true
|
|
3308
|
+
##
|
|
3309
|
+
# :attr_reader: created_at
|
|
3310
|
+
# Instant when the sale was created.
|
|
3311
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
3312
|
+
##
|
|
3313
|
+
# :attr_reader: closed_at
|
|
3314
|
+
# Instant when the sale was closed. Always present: non-finalised sales are never returned.
|
|
3315
|
+
field :closed_at, :string, wire: "closed_at", required: true
|
|
3316
|
+
end
|
|
3317
|
+
|
|
3318
|
+
# Filter and pagination criteria for `POST /sales/search`. Filters from different categories
|
|
3319
|
+
# stack with **logical AND**; multiple values in one array field stack with **logical OR**.
|
|
3320
|
+
# Results cover the merchant’s **last two years** of sales (narrow further with `start_date` /
|
|
3321
|
+
# `end_date`). Results are sorted **newest first** by sale close date.
|
|
3322
|
+
class SaleSearchRequest < Model
|
|
3323
|
+
##
|
|
3324
|
+
# :attr_reader: start_date
|
|
3325
|
+
# Sale created **on or after** this instant (inclusive).
|
|
3326
|
+
field :start_date, :string, wire: "start_date", required: false
|
|
3327
|
+
##
|
|
3328
|
+
# :attr_reader: end_date
|
|
3329
|
+
# Sale created **on or before** this instant (inclusive).
|
|
3330
|
+
field :end_date, :string, wire: "end_date", required: false
|
|
3331
|
+
##
|
|
3332
|
+
# :attr_reader: sale_statuses
|
|
3333
|
+
# Filters rows by sale lifecycle (`state`). Multiple values match any of them (**OR**).
|
|
3334
|
+
# Uses the same values as `Sale.state`. Non-finalised sales are never returned; only
|
|
3335
|
+
# fully-paid sales.
|
|
3336
|
+
field :sale_statuses, [:array, :string], wire: "sale_statuses", required: false
|
|
3337
|
+
##
|
|
3338
|
+
# :attr_reader: payment_statuses
|
|
3339
|
+
# Filters rows by payment outcome. Multiple values match any of them (**OR**). The search
|
|
3340
|
+
# row does not echo this value.
|
|
3341
|
+
field :payment_statuses, [:array, :string], wire: "payment_statuses", required: false
|
|
3342
|
+
##
|
|
3343
|
+
# :attr_reader: sales_channels
|
|
3344
|
+
# Sales channel filter. Multiple values match any of them (**OR**).
|
|
3345
|
+
field :sales_channels, [:array, :string], wire: "sales_channels", required: false
|
|
3346
|
+
##
|
|
3347
|
+
# :attr_reader: pagination_token
|
|
3348
|
+
# Opaque token from the previous search response. To load the next page, send it with
|
|
3349
|
+
# the same filters. Not interchangeable with tokens from `GET /sales`.
|
|
3350
|
+
field :pagination_token, :string, wire: "pagination_token", required: false
|
|
3351
|
+
##
|
|
3352
|
+
# :attr_reader: pagination_limit
|
|
3353
|
+
# Maximum number of results per page.
|
|
3354
|
+
field :pagination_limit, :integer, wire: "pagination_limit", required: false
|
|
3355
|
+
end
|
|
3356
|
+
|
|
3357
|
+
# Search hits and an optional pagination token. Results are ordered **newest first** by sale close date.
|
|
3358
|
+
class SaleSearchResponse < Model
|
|
3359
|
+
##
|
|
3360
|
+
# :attr_reader: items
|
|
3361
|
+
field :items, [:array, [:model, "SaleSearchItem"]], wire: "items", required: true
|
|
3362
|
+
##
|
|
3363
|
+
# :attr_reader: pagination_token
|
|
3364
|
+
# Opaque token for the next page. Pass it as `pagination_token` in the next search
|
|
3365
|
+
# request body with the same filters. Omitted when no further page is available.
|
|
3366
|
+
field :pagination_token, :string, wire: "pagination_token", required: false
|
|
3367
|
+
end
|
|
3368
|
+
|
|
3369
|
+
# Information about the source of the sale.
|
|
3370
|
+
class SaleSource < Model
|
|
3371
|
+
##
|
|
3372
|
+
# :attr_reader: channel
|
|
3373
|
+
# The sale_channel is field that indicates the channel through
|
|
3374
|
+
# which the sale was made. For example, if the sale was made in the merchant app,
|
|
3375
|
+
# the sale_channel could be POS. If the sale was made on a kiosk, the
|
|
3376
|
+
# sale_channel is KIOSK.
|
|
3377
|
+
#
|
|
3378
|
+
# *Accepted values:* ["POS", "KIOSK", "ONLINE_STORE", "SOLO", "ORDER_AND_PAY", "INVOICE", "BOOKINGS", "ORDER_AGGREGATOR", "SUBSCRIPTIONS", "UNKNOWN"].
|
|
3379
|
+
field :channel, :string, wire: "channel", required: true
|
|
3380
|
+
##
|
|
3381
|
+
# :attr_reader: sub_channel
|
|
3382
|
+
# The sub_channel is an optional field that can be used to provide more
|
|
3383
|
+
# information about the sale_channel. For example, if the sale_channel is
|
|
3384
|
+
# ONLINE_PAYMENTS, the sub_channel could be "WIX" or "QR_CODE" or "WOOCOMMERCE".
|
|
3385
|
+
field :sub_channel, :string, wire: "sub_channel", required: false
|
|
3386
|
+
##
|
|
3387
|
+
# :attr_reader: external_id
|
|
3388
|
+
# An external reference ID for connecting orders/sales between products
|
|
3389
|
+
field :external_id, :string, wire: "external_id", required: false
|
|
3390
|
+
##
|
|
3391
|
+
# :attr_reader: external_sub_channel_id
|
|
3392
|
+
# An external reference ID for the sub-channel.
|
|
3393
|
+
# For example, when channel is BOOKINGS and sub_channel is POS,
|
|
3394
|
+
# this can hold the OMS order ID while external_id holds the appointment ID.
|
|
3395
|
+
field :external_sub_channel_id, :string, wire: "external_sub_channel_id", required: false
|
|
3396
|
+
end
|
|
3397
|
+
|
|
3398
|
+
# Sale-level pricing aggregate, parallel to `SaleItemPrice` on each `SaleItem`.
|
|
3399
|
+
#
|
|
3400
|
+
# Line-level breakdown (unit price, line discounts, per-line taxes) lives on
|
|
3401
|
+
# `items[].price`. This object holds the rolled-up totals and cart-level
|
|
3402
|
+
# adjustments that consumers use for receipts and payment reconciliation.
|
|
3403
|
+
class SaleTotals < Model
|
|
3404
|
+
##
|
|
3405
|
+
# :attr_reader: net_amount
|
|
3406
|
+
# Final net total for the sale: sum of `items[].price.total_net_amount_final`
|
|
3407
|
+
# after cart-level discounts (tips excluded).
|
|
3408
|
+
# In minor units according to `Sale.currency.scale`.
|
|
3409
|
+
field :net_amount, :integer, wire: "net_amount", required: true
|
|
3410
|
+
##
|
|
3411
|
+
# :attr_reader: gross_amount
|
|
3412
|
+
# Final gross total for the sale: sum of `items[].price.total_gross_amount_final`
|
|
3413
|
+
# after cart-level discounts (tips excluded).
|
|
3414
|
+
# Same value as search `total_amount`, in minor units according to `Sale.currency.scale`.
|
|
3415
|
+
# Payment amounts include tips and can therefore differ from this gross total.
|
|
3416
|
+
field :gross_amount, :integer, wire: "gross_amount", required: true
|
|
3417
|
+
##
|
|
3418
|
+
# :attr_reader: cart_discounts
|
|
3419
|
+
# Discounts applied at cart level. Item-level discounts remain on
|
|
3420
|
+
# `items[].price.discounts`.
|
|
3421
|
+
field :cart_discounts, [:array, [:model, "DiscountLine"]], wire: "cart_discounts", required: false
|
|
3422
|
+
##
|
|
3423
|
+
# :attr_reader: taxes
|
|
3424
|
+
# Tax lines aggregated across the sale (after cart-level discounts).
|
|
3425
|
+
# Per-line tax detail remains on `items[].price.taxes` / `taxes_final`.
|
|
3426
|
+
field :taxes, [:array, [:model, "TaxLine"]], wire: "taxes", required: true
|
|
3427
|
+
end
|
|
3428
|
+
|
|
3429
|
+
# The currency of the sale.
|
|
3430
|
+
class SalesActivityCurrency < Model
|
|
3431
|
+
##
|
|
3432
|
+
# :attr_reader: code
|
|
3433
|
+
# 3-letter currency code as defined by ISO-4217.
|
|
3434
|
+
field :code, :string, wire: "code", required: true
|
|
3435
|
+
##
|
|
3436
|
+
# :attr_reader: scale
|
|
3437
|
+
# The scaling factor to apply to the value to arrive at the currency's major unit. Providing a scale mitigates changes to the minor unit over time, for example due to inflation. For example, if `scale` is denoted by `s` and `value` is denoted by `v` is the value, then one arrives at the major currency value by calculating `v / 10^s`.
|
|
3438
|
+
field :scale, :integer, wire: "scale", required: true
|
|
3439
|
+
end
|
|
3440
|
+
|
|
3441
|
+
# Status of a device
|
|
3442
|
+
class StatusResponse < Model
|
|
3443
|
+
##
|
|
3444
|
+
# :attr_reader: data
|
|
3445
|
+
field :data, [:model, "StatusResponseData"], wire: "data", required: true
|
|
3446
|
+
end
|
|
3447
|
+
|
|
3448
|
+
class StatusResponseData < Model
|
|
3449
|
+
##
|
|
3450
|
+
# :attr_reader: battery_level
|
|
3451
|
+
# Battery level percentage
|
|
3452
|
+
field :battery_level, :number, wire: "battery_level", required: false
|
|
3453
|
+
##
|
|
3454
|
+
# :attr_reader: battery_temperature
|
|
3455
|
+
# Battery temperature in Celsius
|
|
3456
|
+
field :battery_temperature, :integer, wire: "battery_temperature", required: false
|
|
3457
|
+
##
|
|
3458
|
+
# :attr_reader: connection_type
|
|
3459
|
+
# Type of connection used by the device
|
|
3460
|
+
field :connection_type, :string, wire: "connection_type", required: false
|
|
3461
|
+
##
|
|
3462
|
+
# :attr_reader: firmware_version
|
|
3463
|
+
# Firmware version of the device
|
|
3464
|
+
field :firmware_version, :string, wire: "firmware_version", required: false
|
|
3465
|
+
##
|
|
3466
|
+
# :attr_reader: last_activity
|
|
3467
|
+
# Timestamp of the last activity from the device
|
|
3468
|
+
field :last_activity, :string, wire: "last_activity", required: false
|
|
3469
|
+
##
|
|
3470
|
+
# :attr_reader: state
|
|
3471
|
+
# Latest state of the device
|
|
3472
|
+
field :state, :string, wire: "state", required: false
|
|
3473
|
+
##
|
|
3474
|
+
# :attr_reader: status
|
|
3475
|
+
# Status of a device
|
|
3476
|
+
field :status, :string, wire: "status", required: true
|
|
3477
|
+
end
|
|
3478
|
+
|
|
3479
|
+
# Information about tax together with amounts before and after its application such as:
|
|
3480
|
+
# - net amount: taxable net amount, scoped by this tax
|
|
3481
|
+
# - gross amount: amount after applying the tax.
|
|
3482
|
+
class TaxLine < Model
|
|
3483
|
+
##
|
|
3484
|
+
# :attr_reader: id
|
|
3485
|
+
# Tax ID from the Tax Service (External Id)
|
|
3486
|
+
field :id, :string, wire: "id", required: true
|
|
3487
|
+
##
|
|
3488
|
+
# :attr_reader: name
|
|
3489
|
+
# Tax name, e.g. "MwSt."
|
|
3490
|
+
field :name, :string, wire: "name", required: false
|
|
3491
|
+
##
|
|
3492
|
+
# :attr_reader: percentage
|
|
3493
|
+
# The tax rate percentage in minor units (1/100000). For example 19000 = 19%.
|
|
3494
|
+
field :percentage, :integer, wire: "percentage", required: false
|
|
3495
|
+
##
|
|
3496
|
+
# :attr_reader: net_amount
|
|
3497
|
+
# Net amount before applying the tax.
|
|
3498
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
3499
|
+
field :net_amount, :integer, wire: "net_amount", required: true
|
|
3500
|
+
##
|
|
3501
|
+
# :attr_reader: gross_amount
|
|
3502
|
+
# Gross amount after applying the tax.
|
|
3503
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
3504
|
+
field :gross_amount, :integer, wire: "gross_amount", required: true
|
|
3505
|
+
##
|
|
3506
|
+
# :attr_reader: tax_amount
|
|
3507
|
+
# Amount of tax.
|
|
3508
|
+
# The value of the amount in minor units of the currency according to the Sale.currency.scale.
|
|
3509
|
+
field :tax_amount, :integer, wire: "tax_amount", required: true
|
|
3510
|
+
end
|
|
3511
|
+
|
|
3512
|
+
class Timestamps < Model
|
|
3513
|
+
##
|
|
3514
|
+
# :attr_reader: created_at
|
|
3515
|
+
# The date and time when the resource was created. This is a string as defined in [RFC 3339, section 5.6](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6).
|
|
3516
|
+
field :created_at, :string, wire: "created_at", required: true
|
|
3517
|
+
##
|
|
3518
|
+
# :attr_reader: updated_at
|
|
3519
|
+
# The date and time when the resource was last updated. This is a string as defined in [RFC 3339, section 5.6](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6).
|
|
3520
|
+
field :updated_at, :string, wire: "updated_at", required: true
|
|
3521
|
+
end
|
|
3522
|
+
|
|
3523
|
+
# A short-lived credential for the requested merchant account and actions. Pass access_token to a SumUp SDK that supports merchant tokens.
|
|
3524
|
+
class Token < Model
|
|
3525
|
+
##
|
|
3526
|
+
# :attr_reader: access_token
|
|
3527
|
+
# Secret token to pass to the SDK. Treat this value as an opaque string; do not parse it or depend on its format.
|
|
3528
|
+
field :access_token, :string, wire: "access_token", required: true
|
|
3529
|
+
##
|
|
3530
|
+
# :attr_reader: token_type
|
|
3531
|
+
# Authentication scheme used by the token. Always Bearer.
|
|
3532
|
+
field :token_type, :string, wire: "token_type", required: true
|
|
3533
|
+
##
|
|
3534
|
+
# :attr_reader: expires_in
|
|
3535
|
+
# Remaining lifetime of the token in seconds when the response is created. Tokens expire 15 minutes after creation. Request a new token when needed.
|
|
3536
|
+
field :expires_in, :integer, wire: "expires_in", required: true
|
|
3537
|
+
end
|
|
3538
|
+
|
|
3539
|
+
# Core details shared by transaction resources.
|
|
3540
|
+
class TransactionBase < Model
|
|
3541
|
+
##
|
|
3542
|
+
# :attr_reader: id
|
|
3543
|
+
# Unique identifier of the transaction.
|
|
3544
|
+
field :id, :string, wire: "id", required: false
|
|
3545
|
+
##
|
|
3546
|
+
# :attr_reader: transaction_code
|
|
3547
|
+
# SumUp transaction code, for example `TEENSK4W2K`. Use it to look up the transaction with the `transaction_code` query parameter. This is separate from the transaction's `id` and the card issuer's `auth_code`.
|
|
3548
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
3549
|
+
##
|
|
3550
|
+
# :attr_reader: amount
|
|
3551
|
+
# Total amount of the transaction in major units of `currency`, for example `10.1` for EUR 10.10.
|
|
3552
|
+
field :amount, :number, wire: "amount", required: false
|
|
3553
|
+
##
|
|
3554
|
+
# :attr_reader: currency
|
|
3555
|
+
field :currency, :string, wire: "currency", required: false
|
|
3556
|
+
##
|
|
3557
|
+
# :attr_reader: timestamp
|
|
3558
|
+
# The timestamp of when the transaction was created.
|
|
3559
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
3560
|
+
##
|
|
3561
|
+
# :attr_reader: status
|
|
3562
|
+
field :status, :string, wire: "status", required: false
|
|
3563
|
+
##
|
|
3564
|
+
# :attr_reader: payment_type
|
|
3565
|
+
field :payment_type, :string, wire: "payment_type", required: false
|
|
3566
|
+
##
|
|
3567
|
+
# :attr_reader: installments_count
|
|
3568
|
+
# Number of installments for a deferred payment.
|
|
3569
|
+
field :installments_count, :integer, wire: "installments_count", required: false
|
|
3570
|
+
end
|
|
3571
|
+
|
|
3572
|
+
# Checkout-specific fields associated with a transaction.
|
|
3573
|
+
class TransactionCheckoutInfo < Model
|
|
3574
|
+
##
|
|
3575
|
+
# :attr_reader: merchant_code
|
|
3576
|
+
# Unique code of the registered merchant to whom the payment is made.
|
|
3577
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
3578
|
+
##
|
|
3579
|
+
# :attr_reader: vat_amount
|
|
3580
|
+
# VAT included in the total transaction amount, in major units of the transaction's currency.
|
|
3581
|
+
field :vat_amount, :number, wire: "vat_amount", required: false
|
|
3582
|
+
##
|
|
3583
|
+
# :attr_reader: tip_amount
|
|
3584
|
+
# Tip included in the total transaction amount, in major units of the transaction's currency.
|
|
3585
|
+
field :tip_amount, :number, wire: "tip_amount", required: false
|
|
3586
|
+
##
|
|
3587
|
+
# :attr_reader: auth_code
|
|
3588
|
+
# Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments.
|
|
3589
|
+
field :auth_code, :string, wire: "auth_code", required: false
|
|
3590
|
+
end
|
|
3591
|
+
|
|
3592
|
+
# High-level transaction event details.
|
|
3593
|
+
class TransactionEvent < Model
|
|
3594
|
+
##
|
|
3595
|
+
# :attr_reader: id
|
|
3596
|
+
# Numeric identifier of a transaction event. Use it as `tx_event_id` when requesting receipt details for a specific event. This is separate from the transaction ID and the transaction history pagination references.
|
|
3597
|
+
field :id, :integer, wire: "id", required: false
|
|
3598
|
+
##
|
|
3599
|
+
# :attr_reader: transaction_id
|
|
3600
|
+
# Unique identifier of the transaction.
|
|
3601
|
+
field :transaction_id, :string, wire: "transaction_id", required: false
|
|
3602
|
+
##
|
|
3603
|
+
# :attr_reader: type
|
|
3604
|
+
field :type, :string, wire: "type", required: false
|
|
3605
|
+
##
|
|
3606
|
+
# :attr_reader: status
|
|
3607
|
+
field :status, :string, wire: "status", required: false
|
|
3608
|
+
##
|
|
3609
|
+
# :attr_reader: amount
|
|
3610
|
+
# Amount associated with the transaction event, in major units.
|
|
3611
|
+
field :amount, :number, wire: "amount", required: false
|
|
3612
|
+
##
|
|
3613
|
+
# :attr_reader: timestamp
|
|
3614
|
+
# The timestamp of when the transaction event occurred.
|
|
3615
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
3616
|
+
##
|
|
3617
|
+
# :attr_reader: fee_amount
|
|
3618
|
+
# Fee associated with the transaction event, in major units.
|
|
3619
|
+
field :fee_amount, :number, wire: "fee_amount", required: false
|
|
3620
|
+
##
|
|
3621
|
+
# :attr_reader: installment_number
|
|
3622
|
+
# Consecutive number of the installment associated with the event.
|
|
3623
|
+
field :installment_number, :integer, wire: "installment_number", required: false
|
|
3624
|
+
##
|
|
3625
|
+
# :attr_reader: deducted_amount
|
|
3626
|
+
# Amount deducted from the merchant for the event, in major units.
|
|
3627
|
+
field :deducted_amount, :number, wire: "deducted_amount", required: false
|
|
3628
|
+
##
|
|
3629
|
+
# :attr_reader: deducted_fee_amount
|
|
3630
|
+
# Fee deducted from the merchant for the event, in major units.
|
|
3631
|
+
field :deducted_fee_amount, :number, wire: "deducted_fee_amount", required: false
|
|
3632
|
+
end
|
|
3633
|
+
|
|
3634
|
+
# Detailed information about a transaction event.
|
|
3635
|
+
class TransactionEventDetails < Model
|
|
3636
|
+
##
|
|
3637
|
+
# :attr_reader: id
|
|
3638
|
+
# Numeric identifier of a transaction event. Use it as `tx_event_id` when requesting receipt details for a specific event. This is separate from the transaction ID and the transaction history pagination references.
|
|
3639
|
+
field :id, :integer, wire: "id", required: false
|
|
3640
|
+
##
|
|
3641
|
+
# :attr_reader: event_type
|
|
3642
|
+
field :event_type, :string, wire: "event_type", required: false
|
|
3643
|
+
##
|
|
3644
|
+
# :attr_reader: status
|
|
3645
|
+
field :status, :string, wire: "status", required: false
|
|
3646
|
+
##
|
|
3647
|
+
# :attr_reader: amount
|
|
3648
|
+
# Amount of the event in major units of the associated transaction's currency.
|
|
3649
|
+
field :amount, :number, wire: "amount", required: false
|
|
3650
|
+
##
|
|
3651
|
+
# :attr_reader: due_date
|
|
3652
|
+
# Date when the transaction event is due to occur.
|
|
3653
|
+
field :due_date, :string, wire: "due_date", required: false
|
|
3654
|
+
##
|
|
3655
|
+
# :attr_reader: date
|
|
3656
|
+
# Date when the transaction event occurred.
|
|
3657
|
+
field :date, :string, wire: "date", required: false
|
|
3658
|
+
##
|
|
3659
|
+
# :attr_reader: installment_number
|
|
3660
|
+
# Consecutive number of the installment that is paid. Applicable only to payout events, i.e. `event_type = PAYOUT`.
|
|
3661
|
+
field :installment_number, :integer, wire: "installment_number", required: false
|
|
3662
|
+
##
|
|
3663
|
+
# :attr_reader: timestamp
|
|
3664
|
+
# Date and time of the transaction event.
|
|
3665
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
3666
|
+
end
|
|
3667
|
+
|
|
3668
|
+
# Full transaction resource with checkout, payout, and event details.
|
|
3669
|
+
class TransactionFull < Model
|
|
3670
|
+
##
|
|
3671
|
+
# :attr_reader: foreign_transaction_id
|
|
3672
|
+
# External transaction identifier supplied by the client.
|
|
3673
|
+
field :foreign_transaction_id, :string, wire: "foreign_transaction_id", required: false
|
|
3674
|
+
##
|
|
3675
|
+
# :attr_reader: client_transaction_id
|
|
3676
|
+
# Client-supplied identifier of the transaction.
|
|
3677
|
+
field :client_transaction_id, :string, wire: "client_transaction_id", required: false
|
|
3678
|
+
##
|
|
3679
|
+
# :attr_reader: username
|
|
3680
|
+
# Email address of the registered user (merchant) to whom the payment is made.
|
|
3681
|
+
field :username, :string, wire: "username", required: false
|
|
3682
|
+
##
|
|
3683
|
+
# :attr_reader: fee_amount
|
|
3684
|
+
# Total SumUp transaction fee in major units of the transaction's currency.
|
|
3685
|
+
field :fee_amount, :number, wire: "fee_amount", required: false
|
|
3686
|
+
##
|
|
3687
|
+
# :attr_reader: lat
|
|
3688
|
+
# Latitude value from the coordinates of the payment location (as received from the payment terminal reader).
|
|
3689
|
+
field :lat, :number, wire: "lat", required: false
|
|
3690
|
+
##
|
|
3691
|
+
# :attr_reader: lon
|
|
3692
|
+
# Longitude value from the coordinates of the payment location (as received from the payment terminal reader).
|
|
3693
|
+
field :lon, :number, wire: "lon", required: false
|
|
3694
|
+
##
|
|
3695
|
+
# :attr_reader: horizontal_accuracy
|
|
3696
|
+
# Indication of the precision of the geographical position received from the payment terminal.
|
|
3697
|
+
field :horizontal_accuracy, :number, wire: "horizontal_accuracy", required: false
|
|
3698
|
+
##
|
|
3699
|
+
# :attr_reader: merchant_id
|
|
3700
|
+
# Internal SumUp identifier of the merchant.
|
|
3701
|
+
field :merchant_id, :integer, wire: "merchant_id", required: false
|
|
3702
|
+
##
|
|
3703
|
+
# :attr_reader: device_info
|
|
3704
|
+
field :device_info, [:model, "Device"], wire: "device_info", required: false
|
|
3705
|
+
##
|
|
3706
|
+
# :attr_reader: simple_payment_type
|
|
3707
|
+
# Simple name of the payment type.
|
|
3708
|
+
field :simple_payment_type, :string, wire: "simple_payment_type", required: false
|
|
3709
|
+
##
|
|
3710
|
+
# :attr_reader: verification_method
|
|
3711
|
+
# Verification method used for the transaction.
|
|
3712
|
+
field :verification_method, :string, wire: "verification_method", required: false
|
|
3713
|
+
##
|
|
3714
|
+
# :attr_reader: card
|
|
3715
|
+
field :card, [:model, "CardResponse"], wire: "card", required: false
|
|
3716
|
+
##
|
|
3717
|
+
# :attr_reader: elv_account
|
|
3718
|
+
field :elv_account, [:model, "ElvCardAccount"], wire: "elv_account", required: false
|
|
3719
|
+
##
|
|
3720
|
+
# :attr_reader: local_time
|
|
3721
|
+
# Local timestamp of when the transaction was created.
|
|
3722
|
+
field :local_time, :string, wire: "local_time", required: false
|
|
3723
|
+
##
|
|
3724
|
+
# :attr_reader: payout_date
|
|
3725
|
+
# The date of the payout.
|
|
3726
|
+
field :payout_date, :string, wire: "payout_date", required: false
|
|
3727
|
+
##
|
|
3728
|
+
# :attr_reader: payout_type
|
|
3729
|
+
# Payout type for the transaction.
|
|
3730
|
+
field :payout_type, :string, wire: "payout_type", required: false
|
|
3731
|
+
##
|
|
3732
|
+
# :attr_reader: process_as
|
|
3733
|
+
# Whether the transaction was processed as credit or debit.
|
|
3734
|
+
field :process_as, :string, wire: "process_as", required: false
|
|
3735
|
+
##
|
|
3736
|
+
# :attr_reader: products
|
|
3737
|
+
# List of products from the merchant's catalogue for which the transaction serves as a payment.
|
|
3738
|
+
field :products, [:array, [:model, "Product"]], wire: "products", required: false
|
|
3739
|
+
##
|
|
3740
|
+
# :attr_reader: vat_rates
|
|
3741
|
+
# List of VAT rates applicable to the transaction.
|
|
3742
|
+
field :vat_rates, [:array, [:model, "TransactionFullVatRatesItem"]], wire: "vat_rates", required: false
|
|
3743
|
+
##
|
|
3744
|
+
# :attr_reader: transaction_events
|
|
3745
|
+
# Detailed list of events related to the transaction.
|
|
3746
|
+
field :transaction_events, [:array, [:model, "TransactionEventDetails"]], wire: "transaction_events", required: false
|
|
3747
|
+
##
|
|
3748
|
+
# :attr_reader: simple_status
|
|
3749
|
+
# High-level status of the transaction from the merchant's perspective.
|
|
3750
|
+
#
|
|
3751
|
+
# - `PENDING`: The payment has been initiated and is still being processed. A final outcome is not available yet.
|
|
3752
|
+
# - `SUCCESSFUL`: The payment was completed successfully.
|
|
3753
|
+
# - `PAID_OUT`: The payment was completed successfully and the funds have already been included in a payout to the merchant.
|
|
3754
|
+
# - `FAILED`: The payment did not complete successfully.
|
|
3755
|
+
# - `CANCELLED`: The payment was cancelled or reversed and is no longer payable or payable to the merchant.
|
|
3756
|
+
# - `CANCEL_FAILED`: An attempt to cancel or reverse the payment was not completed successfully.
|
|
3757
|
+
# - `REFUNDED`: The payment was refunded in full or in part.
|
|
3758
|
+
# - `REFUND_FAILED`: An attempt to refund the payment was not completed successfully.
|
|
3759
|
+
# - `CHARGEBACK`: The payment was subject to a chargeback.
|
|
3760
|
+
# - `NON_COLLECTION`: The amount could not be collected from the merchant after a chargeback or related adjustment.
|
|
3761
|
+
field :simple_status, :string, wire: "simple_status", required: false
|
|
3762
|
+
##
|
|
3763
|
+
# :attr_reader: links
|
|
3764
|
+
# List of hyperlinks for accessing related resources.
|
|
3765
|
+
field :links, [:array, [:model, "Link"]], wire: "links", required: false
|
|
3766
|
+
##
|
|
3767
|
+
# :attr_reader: events
|
|
3768
|
+
# Compact list of events related to the transaction.
|
|
3769
|
+
field :events, [:array, [:model, "TransactionEvent"]], wire: "events", required: false
|
|
3770
|
+
##
|
|
3771
|
+
# :attr_reader: location
|
|
3772
|
+
# Details of the payment location as received from the payment terminal.
|
|
3773
|
+
field :location, [:model, "TransactionFullLocation"], wire: "location", required: false
|
|
3774
|
+
##
|
|
3775
|
+
# :attr_reader: tax_enabled
|
|
3776
|
+
# Indicates whether tax deduction is enabled for the transaction.
|
|
3777
|
+
field :tax_enabled, :boolean, wire: "tax_enabled", required: false
|
|
3778
|
+
##
|
|
3779
|
+
# :attr_reader: entry_mode
|
|
3780
|
+
field :entry_mode, :string, wire: "entry_mode", required: false
|
|
3781
|
+
##
|
|
3782
|
+
# :attr_reader: product_summary
|
|
3783
|
+
# Short description of the payment. The value is taken from the `description` property of the related checkout resource.
|
|
3784
|
+
field :product_summary, :string, wire: "product_summary", required: false
|
|
3785
|
+
##
|
|
3786
|
+
# :attr_reader: payouts_total
|
|
3787
|
+
# Total number of payouts to the registered user specified in the `user` property.
|
|
3788
|
+
field :payouts_total, :integer, wire: "payouts_total", required: false
|
|
3789
|
+
##
|
|
3790
|
+
# :attr_reader: payouts_received
|
|
3791
|
+
# Number of payouts that are made to the registered user specified in the `user` property.
|
|
3792
|
+
field :payouts_received, :integer, wire: "payouts_received", required: false
|
|
3793
|
+
##
|
|
3794
|
+
# :attr_reader: payout_plan
|
|
3795
|
+
# Payout plan of the registered user at the time when the transaction was made.
|
|
3796
|
+
field :payout_plan, :string, wire: "payout_plan", required: false
|
|
3797
|
+
##
|
|
3798
|
+
# :attr_reader: merchant_code
|
|
3799
|
+
# Unique code of the registered merchant to whom the payment is made.
|
|
3800
|
+
field :merchant_code, :string, wire: "merchant_code", required: false
|
|
3801
|
+
##
|
|
3802
|
+
# :attr_reader: vat_amount
|
|
3803
|
+
# VAT included in the total transaction amount, in major units of the transaction's currency.
|
|
3804
|
+
field :vat_amount, :number, wire: "vat_amount", required: false
|
|
3805
|
+
##
|
|
3806
|
+
# :attr_reader: tip_amount
|
|
3807
|
+
# Tip included in the total transaction amount, in major units of the transaction's currency.
|
|
3808
|
+
field :tip_amount, :number, wire: "tip_amount", required: false
|
|
3809
|
+
##
|
|
3810
|
+
# :attr_reader: auth_code
|
|
3811
|
+
# Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments.
|
|
3812
|
+
field :auth_code, :string, wire: "auth_code", required: false
|
|
3813
|
+
##
|
|
3814
|
+
# :attr_reader: id
|
|
3815
|
+
# Unique identifier of the transaction.
|
|
3816
|
+
field :id, :string, wire: "id", required: false
|
|
3817
|
+
##
|
|
3818
|
+
# :attr_reader: transaction_code
|
|
3819
|
+
# SumUp transaction code, for example `TEENSK4W2K`. Use it to look up the transaction with the `transaction_code` query parameter. This is separate from the transaction's `id` and the card issuer's `auth_code`.
|
|
3820
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
3821
|
+
##
|
|
3822
|
+
# :attr_reader: amount
|
|
3823
|
+
# Total amount of the transaction in major units of `currency`, for example `10.1` for EUR 10.10.
|
|
3824
|
+
field :amount, :number, wire: "amount", required: false
|
|
3825
|
+
##
|
|
3826
|
+
# :attr_reader: currency
|
|
3827
|
+
field :currency, :string, wire: "currency", required: false
|
|
3828
|
+
##
|
|
3829
|
+
# :attr_reader: timestamp
|
|
3830
|
+
# The timestamp of when the transaction was created.
|
|
3831
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
3832
|
+
##
|
|
3833
|
+
# :attr_reader: status
|
|
3834
|
+
field :status, :string, wire: "status", required: false
|
|
3835
|
+
##
|
|
3836
|
+
# :attr_reader: payment_type
|
|
3837
|
+
field :payment_type, :string, wire: "payment_type", required: false
|
|
3838
|
+
##
|
|
3839
|
+
# :attr_reader: installments_count
|
|
3840
|
+
# Number of installments for a deferred payment.
|
|
3841
|
+
field :installments_count, :integer, wire: "installments_count", required: false
|
|
3842
|
+
end
|
|
3843
|
+
|
|
3844
|
+
# Details of the payment location as received from the payment terminal.
|
|
3845
|
+
class TransactionFullLocation < Model
|
|
3846
|
+
##
|
|
3847
|
+
# :attr_reader: lat
|
|
3848
|
+
# Latitude value from the coordinates of the payment location (as received from the payment terminal reader).
|
|
3849
|
+
field :lat, :number, wire: "lat", required: false
|
|
3850
|
+
##
|
|
3851
|
+
# :attr_reader: lon
|
|
3852
|
+
# Longitude value from the coordinates of the payment location (as received from the payment terminal reader).
|
|
3853
|
+
field :lon, :number, wire: "lon", required: false
|
|
3854
|
+
##
|
|
3855
|
+
# :attr_reader: horizontal_accuracy
|
|
3856
|
+
# Indication of the precision of the geographical position received from the payment terminal.
|
|
3857
|
+
field :horizontal_accuracy, :number, wire: "horizontal_accuracy", required: false
|
|
3858
|
+
end
|
|
3859
|
+
|
|
3860
|
+
class TransactionFullVatRatesItem < Model
|
|
3861
|
+
##
|
|
3862
|
+
# :attr_reader: rate
|
|
3863
|
+
# VAT rate.
|
|
3864
|
+
field :rate, :number, wire: "rate", required: false
|
|
3865
|
+
##
|
|
3866
|
+
# :attr_reader: net
|
|
3867
|
+
# NET amount of products having this VAT rate applied.
|
|
3868
|
+
field :net, :number, wire: "net", required: false
|
|
3869
|
+
##
|
|
3870
|
+
# :attr_reader: vat
|
|
3871
|
+
# VAT amount of this rate applied.
|
|
3872
|
+
field :vat, :number, wire: "vat", required: false
|
|
3873
|
+
##
|
|
3874
|
+
# :attr_reader: gross
|
|
3875
|
+
# Gross amount of products having this VAT rate applied.
|
|
3876
|
+
field :gross, :number, wire: "gross", required: false
|
|
3877
|
+
end
|
|
3878
|
+
|
|
3879
|
+
# Transaction entry returned in history listing responses.
|
|
3880
|
+
class TransactionHistory < Model
|
|
3881
|
+
##
|
|
3882
|
+
# :attr_reader: transaction_id
|
|
3883
|
+
# Unique identifier of the transaction.
|
|
3884
|
+
field :transaction_id, :string, wire: "transaction_id", required: false
|
|
3885
|
+
##
|
|
3886
|
+
# :attr_reader: client_transaction_id
|
|
3887
|
+
# Client-supplied identifier of the transaction.
|
|
3888
|
+
field :client_transaction_id, :string, wire: "client_transaction_id", required: false
|
|
3889
|
+
##
|
|
3890
|
+
# :attr_reader: user
|
|
3891
|
+
# Email address of the registered user (merchant) to whom the payment is made.
|
|
3892
|
+
field :user, :string, wire: "user", required: false
|
|
3893
|
+
##
|
|
3894
|
+
# :attr_reader: type
|
|
3895
|
+
# Type of the transaction for the registered user specified in the `user` property.
|
|
3896
|
+
field :type, :string, wire: "type", required: false
|
|
3897
|
+
##
|
|
3898
|
+
# :attr_reader: card_type
|
|
3899
|
+
field :card_type, :string, wire: "card_type", required: false
|
|
3900
|
+
##
|
|
3901
|
+
# :attr_reader: payout_date
|
|
3902
|
+
# Payout date (if paid out at once).
|
|
3903
|
+
field :payout_date, :string, wire: "payout_date", required: false
|
|
3904
|
+
##
|
|
3905
|
+
# :attr_reader: payout_type
|
|
3906
|
+
# Payout type.
|
|
3907
|
+
field :payout_type, :string, wire: "payout_type", required: false
|
|
3908
|
+
##
|
|
3909
|
+
# :attr_reader: refunded_amount
|
|
3910
|
+
# Total amount refunded for this transaction, in major units of the transaction's currency.
|
|
3911
|
+
field :refunded_amount, :number, wire: "refunded_amount", required: false
|
|
3912
|
+
##
|
|
3913
|
+
# :attr_reader: entry_mode
|
|
3914
|
+
field :entry_mode, :string, wire: "entry_mode", required: false
|
|
3915
|
+
##
|
|
3916
|
+
# :attr_reader: product_summary
|
|
3917
|
+
# Short description of the payment. The value is taken from the `description` property of the related checkout resource.
|
|
3918
|
+
field :product_summary, :string, wire: "product_summary", required: false
|
|
3919
|
+
##
|
|
3920
|
+
# :attr_reader: payouts_total
|
|
3921
|
+
# Total number of payouts to the registered user specified in the `user` property.
|
|
3922
|
+
field :payouts_total, :integer, wire: "payouts_total", required: false
|
|
3923
|
+
##
|
|
3924
|
+
# :attr_reader: payouts_received
|
|
3925
|
+
# Number of payouts that are made to the registered user specified in the `user` property.
|
|
3926
|
+
field :payouts_received, :integer, wire: "payouts_received", required: false
|
|
3927
|
+
##
|
|
3928
|
+
# :attr_reader: payout_plan
|
|
3929
|
+
# Payout plan of the registered user at the time when the transaction was made.
|
|
3930
|
+
field :payout_plan, :string, wire: "payout_plan", required: false
|
|
3931
|
+
##
|
|
3932
|
+
# :attr_reader: id
|
|
3933
|
+
# Unique identifier of the transaction.
|
|
3934
|
+
field :id, :string, wire: "id", required: false
|
|
3935
|
+
##
|
|
3936
|
+
# :attr_reader: transaction_code
|
|
3937
|
+
# SumUp transaction code, for example `TEENSK4W2K`. Use it to look up the transaction with the `transaction_code` query parameter. This is separate from the transaction's `id` and the card issuer's `auth_code`.
|
|
3938
|
+
field :transaction_code, :string, wire: "transaction_code", required: false
|
|
3939
|
+
##
|
|
3940
|
+
# :attr_reader: amount
|
|
3941
|
+
# Total amount of the transaction in major units of `currency`, for example `10.1` for EUR 10.10.
|
|
3942
|
+
field :amount, :number, wire: "amount", required: false
|
|
3943
|
+
##
|
|
3944
|
+
# :attr_reader: currency
|
|
3945
|
+
field :currency, :string, wire: "currency", required: false
|
|
3946
|
+
##
|
|
3947
|
+
# :attr_reader: timestamp
|
|
3948
|
+
# The timestamp of when the transaction was created.
|
|
3949
|
+
field :timestamp, :string, wire: "timestamp", required: false
|
|
3950
|
+
##
|
|
3951
|
+
# :attr_reader: status
|
|
3952
|
+
field :status, :string, wire: "status", required: false
|
|
3953
|
+
##
|
|
3954
|
+
# :attr_reader: payment_type
|
|
3955
|
+
field :payment_type, :string, wire: "payment_type", required: false
|
|
3956
|
+
##
|
|
3957
|
+
# :attr_reader: installments_count
|
|
3958
|
+
# Number of installments for a deferred payment.
|
|
3959
|
+
field :installments_count, :integer, wire: "installments_count", required: false
|
|
3960
|
+
end
|
|
3961
|
+
|
|
3962
|
+
# Additional transaction fields used by history and detailed views.
|
|
3963
|
+
class TransactionMixinHistory < Model
|
|
3964
|
+
##
|
|
3965
|
+
# :attr_reader: entry_mode
|
|
3966
|
+
field :entry_mode, :string, wire: "entry_mode", required: false
|
|
3967
|
+
##
|
|
3968
|
+
# :attr_reader: product_summary
|
|
3969
|
+
# Short description of the payment. The value is taken from the `description` property of the related checkout resource.
|
|
3970
|
+
field :product_summary, :string, wire: "product_summary", required: false
|
|
3971
|
+
##
|
|
3972
|
+
# :attr_reader: payouts_total
|
|
3973
|
+
# Total number of payouts to the registered user specified in the `user` property.
|
|
3974
|
+
field :payouts_total, :integer, wire: "payouts_total", required: false
|
|
3975
|
+
##
|
|
3976
|
+
# :attr_reader: payouts_received
|
|
3977
|
+
# Number of payouts that are made to the registered user specified in the `user` property.
|
|
3978
|
+
field :payouts_received, :integer, wire: "payouts_received", required: false
|
|
3979
|
+
##
|
|
3980
|
+
# :attr_reader: payout_plan
|
|
3981
|
+
# Payout plan of the registered user at the time when the transaction was made.
|
|
3982
|
+
field :payout_plan, :string, wire: "payout_plan", required: false
|
|
3983
|
+
end
|
|
3984
|
+
|
|
3985
|
+
# Hypermedia link used for transaction history pagination.
|
|
3986
|
+
class TransactionsHistoryLink < Model
|
|
3987
|
+
##
|
|
3988
|
+
# :attr_reader: rel
|
|
3989
|
+
# Pagination relation indicating which page the link retrieves, for example `next`.
|
|
3990
|
+
field :rel, :string, wire: "rel", required: true
|
|
3991
|
+
##
|
|
3992
|
+
# :attr_reader: href
|
|
3993
|
+
# Query string to use with the transaction history endpoint when requesting the linked page. Preserve the returned pagination references and query parameters.
|
|
3994
|
+
field :href, :string, wire: "href", required: true
|
|
3995
|
+
end
|
|
3996
|
+
|
|
3997
|
+
# 401 Unauthorized
|
|
3998
|
+
class Unauthorized < Model
|
|
3999
|
+
##
|
|
4000
|
+
# :attr_reader: errors
|
|
4001
|
+
field :errors, [:model, "UnauthorizedErrors"], wire: "errors", required: true
|
|
4002
|
+
end
|
|
4003
|
+
|
|
4004
|
+
class UnauthorizedErrors < Model
|
|
4005
|
+
##
|
|
4006
|
+
# :attr_reader: detail
|
|
4007
|
+
# Fuller message giving context to error
|
|
4008
|
+
field :detail, :string, wire: "detail", required: true
|
|
4009
|
+
##
|
|
4010
|
+
# :attr_reader: type
|
|
4011
|
+
# Key indicating type of error. Present only for typed 401 responses (e.g. invalid token, invalid password). Absent for generic unauthorized responses.
|
|
4012
|
+
field :type, :string, wire: "type", required: false
|
|
4013
|
+
end
|
|
4014
|
+
|
|
4015
|
+
# The unit of measure of the item.
|
|
4016
|
+
class UnitOfMeasure < Model
|
|
4017
|
+
##
|
|
4018
|
+
# :attr_reader: group_id
|
|
4019
|
+
# The group of the unit of measure.
|
|
4020
|
+
field :group_id, :string, wire: "group_id", required: true
|
|
4021
|
+
##
|
|
4022
|
+
# :attr_reader: unit_id
|
|
4023
|
+
# The specific unit of measure within the group.
|
|
4024
|
+
field :unit_id, :string, wire: "unit_id", required: true
|
|
4025
|
+
##
|
|
4026
|
+
# :attr_reader: unit_ratio
|
|
4027
|
+
# The ratio of the specified unit to the base unit of the group.
|
|
4028
|
+
field :unit_ratio, :number, wire: "unit_ratio", required: true
|
|
4029
|
+
end
|
|
4030
|
+
|
|
4031
|
+
class UpdateCustomerRequest < Model
|
|
4032
|
+
##
|
|
4033
|
+
# :attr_reader: personal_details
|
|
4034
|
+
field :personal_details, [:model, "PersonalDetails"], wire: "personal_details", required: false
|
|
4035
|
+
end
|
|
4036
|
+
|
|
4037
|
+
class UpdateMerchantMemberRequest < Model
|
|
4038
|
+
##
|
|
4039
|
+
# :attr_reader: roles
|
|
4040
|
+
field :roles, [:array, :string], wire: "roles", required: false
|
|
4041
|
+
##
|
|
4042
|
+
# :attr_reader: metadata
|
|
4043
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
4044
|
+
##
|
|
4045
|
+
# :attr_reader: attributes
|
|
4046
|
+
field :attributes, [:map, :any], wire: "attributes", required: false
|
|
4047
|
+
##
|
|
4048
|
+
# :attr_reader: user
|
|
4049
|
+
# Allows you to update user data of managed users.
|
|
4050
|
+
field :user, [:model, "UpdateMerchantMemberRequestUser"], wire: "user", required: false
|
|
4051
|
+
end
|
|
4052
|
+
|
|
4053
|
+
# Allows you to update user data of managed users.
|
|
4054
|
+
class UpdateMerchantMemberRequestUser < Model
|
|
4055
|
+
##
|
|
4056
|
+
# :attr_reader: nickname
|
|
4057
|
+
# User's nickname. Used for display purposes only.
|
|
4058
|
+
field :nickname, :string, wire: "nickname", required: false
|
|
4059
|
+
##
|
|
4060
|
+
# :attr_reader: password
|
|
4061
|
+
# Password of the member to add. Only used if `is_managed_user` is true.
|
|
4062
|
+
field :password, :string, wire: "password", required: false
|
|
4063
|
+
end
|
|
4064
|
+
|
|
4065
|
+
class UpdateMerchantRoleRequest < Model
|
|
4066
|
+
##
|
|
4067
|
+
# :attr_reader: name
|
|
4068
|
+
# User-defined name of the role.
|
|
4069
|
+
field :name, :string, wire: "name", required: false
|
|
4070
|
+
##
|
|
4071
|
+
# :attr_reader: permissions
|
|
4072
|
+
# User's permissions.
|
|
4073
|
+
field :permissions, [:array, :string], wire: "permissions", required: false
|
|
4074
|
+
##
|
|
4075
|
+
# :attr_reader: description
|
|
4076
|
+
# User-defined description of the role.
|
|
4077
|
+
field :description, :string, wire: "description", required: false
|
|
4078
|
+
end
|
|
4079
|
+
|
|
4080
|
+
class UpdateReaderRequest < Model
|
|
4081
|
+
##
|
|
4082
|
+
# :attr_reader: name
|
|
4083
|
+
# Custom human-readable, user-defined name for easier identification of the reader.
|
|
4084
|
+
field :name, :string, wire: "name", required: false
|
|
4085
|
+
##
|
|
4086
|
+
# :attr_reader: metadata
|
|
4087
|
+
field :metadata, [:map, :any], wire: "metadata", required: false
|
|
4088
|
+
end
|
|
4089
|
+
|
|
4090
|
+
# Details of a failed reader settings request.
|
|
4091
|
+
class UpdateReaderSettingsError < Model
|
|
4092
|
+
##
|
|
4093
|
+
# :attr_reader: errors
|
|
4094
|
+
field :errors, [:model, "UpdateReaderSettingsErrorErrors"], wire: "errors", required: true
|
|
4095
|
+
end
|
|
4096
|
+
|
|
4097
|
+
class UpdateReaderSettingsErrorErrors < Model
|
|
4098
|
+
##
|
|
4099
|
+
# :attr_reader: detail
|
|
4100
|
+
# Error message
|
|
4101
|
+
field :detail, :string, wire: "detail", required: true
|
|
4102
|
+
##
|
|
4103
|
+
# :attr_reader: type
|
|
4104
|
+
# Error code
|
|
4105
|
+
field :type, :string, wire: "type", required: false
|
|
4106
|
+
end
|
|
4107
|
+
|
|
4108
|
+
# Menu lock settings to update for a Solo reader.
|
|
4109
|
+
class UpdateReaderSettingsRequest < Model
|
|
4110
|
+
##
|
|
4111
|
+
# :attr_reader: menu_lock
|
|
4112
|
+
# Menu lock configuration. Provide at least one of `enabled` or `passcode`.
|
|
4113
|
+
field :menu_lock, [:model, "UpdateReaderSettingsRequestMenuLock"], wire: "menu_lock", required: true
|
|
4114
|
+
end
|
|
4115
|
+
|
|
4116
|
+
# Menu lock configuration. Provide at least one of `enabled` or `passcode`.
|
|
4117
|
+
class UpdateReaderSettingsRequestMenuLock < Model
|
|
4118
|
+
##
|
|
4119
|
+
# :attr_reader: enabled
|
|
4120
|
+
# Whether menu lock is enabled.
|
|
4121
|
+
field :enabled, :boolean, wire: "enabled", required: false
|
|
4122
|
+
##
|
|
4123
|
+
# :attr_reader: passcode
|
|
4124
|
+
# Four-digit PIN used to unlock the reader's menu.
|
|
4125
|
+
field :passcode, :string, wire: "passcode", required: false
|
|
4126
|
+
end
|
|
4127
|
+
|
|
4128
|
+
# Menu lock settings applied to the reader.
|
|
4129
|
+
class UpdateReaderSettingsResponse < Model
|
|
4130
|
+
##
|
|
4131
|
+
# :attr_reader: data
|
|
4132
|
+
field :data, [:model, "UpdateReaderSettingsResponseData"], wire: "data", required: true
|
|
4133
|
+
end
|
|
4134
|
+
|
|
4135
|
+
class UpdateReaderSettingsResponseData < Model
|
|
4136
|
+
##
|
|
4137
|
+
# :attr_reader: menu_lock
|
|
4138
|
+
# Settings included in the update. Omitted fields are not returned.
|
|
4139
|
+
field :menu_lock, [:model, "UpdateReaderSettingsResponseDataMenuLock"], wire: "menu_lock", required: true
|
|
4140
|
+
##
|
|
4141
|
+
# :attr_reader: status
|
|
4142
|
+
# Indicates that the reader applied the settings update.
|
|
4143
|
+
field :status, :string, wire: "status", required: true
|
|
4144
|
+
end
|
|
4145
|
+
|
|
4146
|
+
# Settings included in the update. Omitted fields are not returned.
|
|
4147
|
+
class UpdateReaderSettingsResponseDataMenuLock < Model
|
|
4148
|
+
##
|
|
4149
|
+
# :attr_reader: enabled
|
|
4150
|
+
# Whether menu lock is enabled.
|
|
4151
|
+
field :enabled, :boolean, wire: "enabled", required: false
|
|
4152
|
+
##
|
|
4153
|
+
# :attr_reader: passcode
|
|
4154
|
+
# Four-digit PIN used to unlock the reader's menu.
|
|
4155
|
+
field :passcode, :string, wire: "passcode", required: false
|
|
4156
|
+
end
|
|
4157
|
+
|
|
4158
|
+
# The reader cannot complete the settings request, or the settings are invalid.
|
|
4159
|
+
class UpdateReaderSettingsUnprocessableEntity < Model
|
|
4160
|
+
##
|
|
4161
|
+
# :attr_reader: errors
|
|
4162
|
+
field :errors, [:map, :any], wire: "errors", required: true
|
|
4163
|
+
end
|
|
4164
|
+
|
|
4165
|
+
# Known values; the API may return additional values.
|
|
4166
|
+
module BadRequestErrorsType
|
|
4167
|
+
INVALID_AFFILIATE_KEY = "INVALID_AFFILIATE_KEY"
|
|
4168
|
+
APP_OUTDATED = "APP_OUTDATED"
|
|
4169
|
+
INVALID_BEARER_TOKEN = "INVALID_BEARER_TOKEN"
|
|
4170
|
+
INVALID_USER_AGENT = "INVALID_USER_AGENT"
|
|
4171
|
+
NOT_ENOUGH_UNPAID_PAYOUTS = "NOT_ENOUGH_UNPAID_PAYOUTS"
|
|
4172
|
+
DUPLICATE_HEADERS = "DUPLICATE_HEADERS"
|
|
4173
|
+
end
|
|
4174
|
+
|
|
4175
|
+
# Known values; the API may return additional values.
|
|
4176
|
+
module CardType
|
|
4177
|
+
ALELO = "ALELO"
|
|
4178
|
+
AMEX = "AMEX"
|
|
4179
|
+
BANCOMAT = "BANCOMAT"
|
|
4180
|
+
CONECS = "CONECS"
|
|
4181
|
+
CUP = "CUP"
|
|
4182
|
+
DINERS = "DINERS"
|
|
4183
|
+
DISCOVER = "DISCOVER"
|
|
4184
|
+
EFTPOS = "EFTPOS"
|
|
4185
|
+
ELO = "ELO"
|
|
4186
|
+
ELV = "ELV"
|
|
4187
|
+
GIROCARD = "GIROCARD"
|
|
4188
|
+
HIPERCARD = "HIPERCARD"
|
|
4189
|
+
INTERAC = "INTERAC"
|
|
4190
|
+
JCB = "JCB"
|
|
4191
|
+
MAESTRO = "MAESTRO"
|
|
4192
|
+
MASTERCARD = "MASTERCARD"
|
|
4193
|
+
PLUXEE = "PLUXEE"
|
|
4194
|
+
SUMUP = "SUMUP"
|
|
4195
|
+
SWILE = "SWILE"
|
|
4196
|
+
TICKET = "TICKET"
|
|
4197
|
+
VISA = "VISA"
|
|
4198
|
+
VISA_ELECTRON = "VISA_ELECTRON"
|
|
4199
|
+
VISA_VPAY = "VISA_VPAY"
|
|
4200
|
+
VPAY = "VPAY"
|
|
4201
|
+
VR = "VR"
|
|
4202
|
+
UNKNOWN = "UNKNOWN"
|
|
4203
|
+
end
|
|
4204
|
+
|
|
4205
|
+
# Known values; the API may return additional values.
|
|
4206
|
+
module CheckoutAcceptedNextStepMechanismItem
|
|
4207
|
+
IFRAME = "iframe"
|
|
4208
|
+
BROWSER = "browser"
|
|
4209
|
+
end
|
|
4210
|
+
|
|
4211
|
+
# Known values; the API may return additional values.
|
|
4212
|
+
module CheckoutCreateRequestPurpose
|
|
4213
|
+
CHECKOUT = "CHECKOUT"
|
|
4214
|
+
SETUP_RECURRING_PAYMENT = "SETUP_RECURRING_PAYMENT"
|
|
4215
|
+
end
|
|
4216
|
+
|
|
4217
|
+
# Known values; the API may return additional values.
|
|
4218
|
+
module CheckoutEntryMode
|
|
4219
|
+
CUSTOMER_ENTRY = "CUSTOMER_ENTRY"
|
|
4220
|
+
MOTO = "MOTO"
|
|
4221
|
+
CARD = "CARD"
|
|
4222
|
+
BOLETO = "BOLETO"
|
|
4223
|
+
DIRECT_DEBIT = "DIRECT_DEBIT"
|
|
4224
|
+
IDEAL = "IDEAL"
|
|
4225
|
+
BANCONTACT = "BANCONTACT"
|
|
4226
|
+
EPS = "EPS"
|
|
4227
|
+
MYBANK = "MYBANK"
|
|
4228
|
+
SATISPAY = "SATISPAY"
|
|
4229
|
+
BLIK = "BLIK"
|
|
4230
|
+
P24 = "P24"
|
|
4231
|
+
GIROPAY = "GIROPAY"
|
|
4232
|
+
PIX = "PIX"
|
|
4233
|
+
QR_CODE_PIX = "QR_CODE_PIX"
|
|
4234
|
+
KLARNA = "KLARNA"
|
|
4235
|
+
BANCOMATPAY = "BANCOMATPAY"
|
|
4236
|
+
APPLE_PAY = "APPLE_PAY"
|
|
4237
|
+
PAYPAL = "PAYPAL"
|
|
4238
|
+
GOOGLE_PAY = "GOOGLE_PAY"
|
|
4239
|
+
end
|
|
4240
|
+
|
|
4241
|
+
# Known values; the API may return additional values.
|
|
4242
|
+
module CheckoutStatus
|
|
4243
|
+
PENDING = "PENDING"
|
|
4244
|
+
FAILED = "FAILED"
|
|
4245
|
+
PAID = "PAID"
|
|
4246
|
+
EXPIRED = "EXPIRED"
|
|
4247
|
+
end
|
|
4248
|
+
|
|
4249
|
+
# Known values; the API may return additional values.
|
|
4250
|
+
module CheckoutSuccessStatus
|
|
4251
|
+
PENDING = "PENDING"
|
|
4252
|
+
FAILED = "FAILED"
|
|
4253
|
+
PAID = "PAID"
|
|
4254
|
+
EXPIRED = "EXPIRED"
|
|
4255
|
+
end
|
|
4256
|
+
|
|
4257
|
+
# Known values; the API may return additional values.
|
|
4258
|
+
module CreateMerchantTokenRequestActionsItem
|
|
4259
|
+
CHECKOUT = "checkout"
|
|
4260
|
+
end
|
|
4261
|
+
|
|
4262
|
+
# Known values; the API may return additional values.
|
|
4263
|
+
module CreateReaderCheckoutRequestCardType
|
|
4264
|
+
CREDIT = "credit"
|
|
4265
|
+
DEBIT = "debit"
|
|
4266
|
+
end
|
|
4267
|
+
|
|
4268
|
+
# Known values; the API may return additional values.
|
|
4269
|
+
module CreateReaderCheckoutRequestPaymentType
|
|
4270
|
+
CARD = "card"
|
|
4271
|
+
PIX = "pix"
|
|
4272
|
+
end
|
|
4273
|
+
|
|
4274
|
+
# Known values; the API may return additional values.
|
|
4275
|
+
module Currency
|
|
4276
|
+
BRL = "BRL"
|
|
4277
|
+
CHF = "CHF"
|
|
4278
|
+
CLP = "CLP"
|
|
4279
|
+
COP = "COP"
|
|
4280
|
+
CZK = "CZK"
|
|
4281
|
+
DKK = "DKK"
|
|
4282
|
+
EUR = "EUR"
|
|
4283
|
+
GBP = "GBP"
|
|
4284
|
+
HRK = "HRK"
|
|
4285
|
+
HUF = "HUF"
|
|
4286
|
+
NOK = "NOK"
|
|
4287
|
+
PLN = "PLN"
|
|
4288
|
+
RON = "RON"
|
|
4289
|
+
SEK = "SEK"
|
|
4290
|
+
USD = "USD"
|
|
4291
|
+
end
|
|
4292
|
+
|
|
4293
|
+
# Known values; the API may return additional values.
|
|
4294
|
+
module DiscountApplicationMode
|
|
4295
|
+
MANUAL = "MANUAL"
|
|
4296
|
+
AUTOMATIC = "AUTOMATIC"
|
|
4297
|
+
end
|
|
4298
|
+
|
|
4299
|
+
# Known values; the API may return additional values.
|
|
4300
|
+
module DiscountClass
|
|
4301
|
+
ITEM = "ITEM"
|
|
4302
|
+
CATEGORY = "CATEGORY"
|
|
4303
|
+
BUNDLE = "BUNDLE"
|
|
4304
|
+
BUY_X_GET_Y = "BUY_X_GET_Y"
|
|
4305
|
+
MEAL_DEAL = "MEAL_DEAL"
|
|
4306
|
+
end
|
|
4307
|
+
|
|
4308
|
+
# Known values; the API may return additional values.
|
|
4309
|
+
module DiscountSourceLoyaltySchemeType
|
|
4310
|
+
STAMPS = "STAMPS"
|
|
4311
|
+
POINTS = "POINTS"
|
|
4312
|
+
end
|
|
4313
|
+
|
|
4314
|
+
# Known values; the API may return additional values.
|
|
4315
|
+
module DiscountSourceLoyaltyType
|
|
4316
|
+
PROMOTION = "PROMOTION"
|
|
4317
|
+
REWARD = "REWARD"
|
|
4318
|
+
end
|
|
4319
|
+
|
|
4320
|
+
# Known values; the API may return additional values.
|
|
4321
|
+
module EntryMode
|
|
4322
|
+
NONE = "none"
|
|
4323
|
+
MAGSTRIPE = "magstripe"
|
|
4324
|
+
CHIP = "chip"
|
|
4325
|
+
MANUAL_ENTRY = "manual entry"
|
|
4326
|
+
CUSTOMER_ENTRY = "customer entry"
|
|
4327
|
+
MAGSTRIPE_FALLBACK = "magstripe fallback"
|
|
4328
|
+
CONTACTLESS = "contactless"
|
|
4329
|
+
MOTO = "moto"
|
|
4330
|
+
CONTACTLESS_MAGSTRIPE = "contactless magstripe"
|
|
4331
|
+
BOLETO = "boleto"
|
|
4332
|
+
DIRECT_DEBIT = "direct debit"
|
|
4333
|
+
SOFORT = "sofort"
|
|
4334
|
+
IDEAL = "ideal"
|
|
4335
|
+
BANCONTACT = "bancontact"
|
|
4336
|
+
EPS = "eps"
|
|
4337
|
+
MYBANK = "mybank"
|
|
4338
|
+
SATISPAY = "satispay"
|
|
4339
|
+
BLIK = "blik"
|
|
4340
|
+
P24 = "p24"
|
|
4341
|
+
GIROPAY = "giropay"
|
|
4342
|
+
PIX = "pix"
|
|
4343
|
+
QR_CODE_PIX = "qr code pix"
|
|
4344
|
+
APPLE_PAY = "apple pay"
|
|
4345
|
+
GOOGLE_PAY = "google pay"
|
|
4346
|
+
SUMUP_GIFT_CARD = "sumup gift card"
|
|
4347
|
+
PAYPAL = "paypal"
|
|
4348
|
+
TWINT = "twint"
|
|
4349
|
+
IRIS = "iris"
|
|
4350
|
+
SUMUP_PAY = "sumup pay"
|
|
4351
|
+
NA = "na"
|
|
4352
|
+
end
|
|
4353
|
+
|
|
4354
|
+
# Known values; the API may return additional values.
|
|
4355
|
+
module EventObjectType
|
|
4356
|
+
MEMBER = "member"
|
|
4357
|
+
READER = "reader"
|
|
4358
|
+
end
|
|
4359
|
+
|
|
4360
|
+
# Known values; the API may return additional values.
|
|
4361
|
+
module EventType
|
|
4362
|
+
CHECKOUTS_CREATED = "checkouts.created"
|
|
4363
|
+
CHECKOUTS_FAILED = "checkouts.failed"
|
|
4364
|
+
CHECKOUTS_EXPIRED = "checkouts.expired"
|
|
4365
|
+
CHECKOUTS_UPDATED = "checkouts.updated"
|
|
4366
|
+
CHECKOUTS_PAID = "checkouts.paid"
|
|
4367
|
+
SALES_COMPLETED = "sales.completed"
|
|
4368
|
+
SALES_UPDATED = "sales.updated"
|
|
4369
|
+
MEMBERS_CREATED = "members.created"
|
|
4370
|
+
MEMBERS_UPDATED = "members.updated"
|
|
4371
|
+
MEMBERS_DELETED = "members.deleted"
|
|
4372
|
+
READERS_CREATED = "readers.created"
|
|
4373
|
+
READERS_DELETED = "readers.deleted"
|
|
4374
|
+
ROLES_CREATED = "roles.created"
|
|
4375
|
+
ROLES_UPDATED = "roles.updated"
|
|
4376
|
+
ROLES_DELETED = "roles.deleted"
|
|
4377
|
+
end
|
|
4378
|
+
|
|
4379
|
+
# Known values; the API may return additional values.
|
|
4380
|
+
module FinancialPayoutStatus
|
|
4381
|
+
SUCCESSFUL = "SUCCESSFUL"
|
|
4382
|
+
FAILED = "FAILED"
|
|
4383
|
+
end
|
|
4384
|
+
|
|
4385
|
+
# Known values; the API may return additional values.
|
|
4386
|
+
module FinancialPayoutType
|
|
4387
|
+
PAYOUT = "PAYOUT"
|
|
4388
|
+
CHARGE_BACK_DEDUCTION = "CHARGE_BACK_DEDUCTION"
|
|
4389
|
+
REFUND_DEDUCTION = "REFUND_DEDUCTION"
|
|
4390
|
+
DD_RETURN_DEDUCTION = "DD_RETURN_DEDUCTION"
|
|
4391
|
+
BALANCE_DEDUCTION = "BALANCE_DEDUCTION"
|
|
4392
|
+
end
|
|
4393
|
+
|
|
4394
|
+
# Known values; the API may return additional values.
|
|
4395
|
+
module GetReaderCheckoutResponseDataPaymentType
|
|
4396
|
+
CARD = "card"
|
|
4397
|
+
PIX = "pix"
|
|
4398
|
+
end
|
|
4399
|
+
|
|
4400
|
+
# Known values; the API may return additional values.
|
|
4401
|
+
module GetReaderCheckoutResponseDataStatus
|
|
4402
|
+
PENDING = "pending"
|
|
4403
|
+
SUCCESSFUL = "successful"
|
|
4404
|
+
FAILED = "failed"
|
|
4405
|
+
CANCELLED = "cancelled"
|
|
4406
|
+
end
|
|
4407
|
+
|
|
4408
|
+
# Known values; the API may return additional values.
|
|
4409
|
+
module MandatePayloadType
|
|
4410
|
+
RECURRENT = "recurrent"
|
|
4411
|
+
end
|
|
4412
|
+
|
|
4413
|
+
# Known values; the API may return additional values.
|
|
4414
|
+
module MandateResponseStatus
|
|
4415
|
+
ACTIVE = "active"
|
|
4416
|
+
INACTIVE = "inactive"
|
|
4417
|
+
end
|
|
4418
|
+
|
|
4419
|
+
# Known values; the API may return additional values.
|
|
4420
|
+
module MembershipStatus
|
|
4421
|
+
ACCEPTED = "accepted"
|
|
4422
|
+
PENDING = "pending"
|
|
4423
|
+
EXPIRED = "expired"
|
|
4424
|
+
DISABLED = "disabled"
|
|
4425
|
+
UNKNOWN = "unknown"
|
|
4426
|
+
end
|
|
4427
|
+
|
|
4428
|
+
# Known values; the API may return additional values.
|
|
4429
|
+
module PaymentInstrumentResponseType
|
|
4430
|
+
CARD = "card"
|
|
4431
|
+
end
|
|
4432
|
+
|
|
4433
|
+
# Known values; the API may return additional values.
|
|
4434
|
+
module PaymentType
|
|
4435
|
+
CASH = "CASH"
|
|
4436
|
+
POS = "POS"
|
|
4437
|
+
ECOM = "ECOM"
|
|
4438
|
+
RECURRING = "RECURRING"
|
|
4439
|
+
BITCOIN = "BITCOIN"
|
|
4440
|
+
BALANCE = "BALANCE"
|
|
4441
|
+
MOTO = "MOTO"
|
|
4442
|
+
BOLETO = "BOLETO"
|
|
4443
|
+
DIRECT_DEBIT = "DIRECT_DEBIT"
|
|
4444
|
+
APM = "APM"
|
|
4445
|
+
UNKNOWN = "UNKNOWN"
|
|
4446
|
+
end
|
|
4447
|
+
|
|
4448
|
+
# Known values; the API may return additional values.
|
|
4449
|
+
module ProcessCheckoutPaymentType
|
|
4450
|
+
CARD = "card"
|
|
4451
|
+
BOLETO = "boleto"
|
|
4452
|
+
IDEAL = "ideal"
|
|
4453
|
+
BLIK = "blik"
|
|
4454
|
+
BANCONTACT = "bancontact"
|
|
4455
|
+
GOOGLE_PAY = "google_pay"
|
|
4456
|
+
APPLE_PAY = "apple_pay"
|
|
4457
|
+
end
|
|
4458
|
+
|
|
4459
|
+
# Known values; the API may return additional values.
|
|
4460
|
+
module ReaderCheckoutStatusChangePayloadStatus
|
|
4461
|
+
SUCCESSFUL = "successful"
|
|
4462
|
+
FAILED = "failed"
|
|
4463
|
+
end
|
|
4464
|
+
|
|
4465
|
+
# Known values; the API may return additional values.
|
|
4466
|
+
module ReaderDeviceModel
|
|
4467
|
+
SOLO = "solo"
|
|
4468
|
+
VIRTUAL_SOLO = "virtual-solo"
|
|
4469
|
+
end
|
|
4470
|
+
|
|
4471
|
+
# Known values; the API may return additional values.
|
|
4472
|
+
module ReaderStatus
|
|
4473
|
+
UNKNOWN = "unknown"
|
|
4474
|
+
PROCESSING = "processing"
|
|
4475
|
+
PAIRED = "paired"
|
|
4476
|
+
EXPIRED = "expired"
|
|
4477
|
+
end
|
|
4478
|
+
|
|
4479
|
+
# Known values; the API may return additional values.
|
|
4480
|
+
module ReceiptTransactionProcessAs
|
|
4481
|
+
CREDIT = "CREDIT"
|
|
4482
|
+
DEBIT = "DEBIT"
|
|
4483
|
+
end
|
|
4484
|
+
|
|
4485
|
+
# Known values; the API may return additional values.
|
|
4486
|
+
module SaleChannelFilter
|
|
4487
|
+
POS = "POS"
|
|
4488
|
+
ONLINE_PAYMENTS = "ONLINE_PAYMENTS"
|
|
4489
|
+
KIOSK = "KIOSK"
|
|
4490
|
+
ONLINE_STORE = "ONLINE_STORE"
|
|
4491
|
+
SOLO = "SOLO"
|
|
4492
|
+
ORDER_AND_PAY = "ORDER_AND_PAY"
|
|
4493
|
+
INVOICE = "INVOICE"
|
|
4494
|
+
BOOKINGS = "BOOKINGS"
|
|
4495
|
+
ORDER_AGGREGATOR = "ORDER_AGGREGATOR"
|
|
4496
|
+
SUBSCRIPTIONS = "SUBSCRIPTIONS"
|
|
4497
|
+
UNKNOWN = "UNKNOWN"
|
|
4498
|
+
end
|
|
4499
|
+
|
|
4500
|
+
# Known values; the API may return additional values.
|
|
4501
|
+
module SaleItemFeatureValueType
|
|
4502
|
+
TEXT = "TEXT"
|
|
4503
|
+
INTEGER = "INTEGER"
|
|
4504
|
+
DECIMAL = "DECIMAL"
|
|
4505
|
+
DATE = "DATE"
|
|
4506
|
+
BOOLEAN = "BOOLEAN"
|
|
4507
|
+
end
|
|
4508
|
+
|
|
4509
|
+
# Known values; the API may return additional values.
|
|
4510
|
+
module SaleItemReferencesCatalogSource
|
|
4511
|
+
SUMUP = "SUMUP"
|
|
4512
|
+
EXTERNAL = "EXTERNAL"
|
|
4513
|
+
end
|
|
4514
|
+
|
|
4515
|
+
# Known values; the API may return additional values.
|
|
4516
|
+
module SaleItemServiceType
|
|
4517
|
+
IN_HOUSE = "IN_HOUSE"
|
|
4518
|
+
TAKE_AWAY = "TAKE_AWAY"
|
|
4519
|
+
end
|
|
4520
|
+
|
|
4521
|
+
# Known values; the API may return additional values.
|
|
4522
|
+
module SaleLifecycleState
|
|
4523
|
+
CLOSED = "CLOSED"
|
|
4524
|
+
end
|
|
4525
|
+
|
|
4526
|
+
# Known values; the API may return additional values.
|
|
4527
|
+
module SalePaymentCardType
|
|
4528
|
+
CREDIT = "credit"
|
|
4529
|
+
DEBIT = "debit"
|
|
4530
|
+
UNKNOWN = "unknown"
|
|
4531
|
+
end
|
|
4532
|
+
|
|
4533
|
+
# Known values; the API may return additional values.
|
|
4534
|
+
module SalePaymentStatus
|
|
4535
|
+
FAILED = "FAILED"
|
|
4536
|
+
SUCCESSFUL = "SUCCESSFUL"
|
|
4537
|
+
CANCELED = "CANCELED"
|
|
4538
|
+
end
|
|
4539
|
+
|
|
4540
|
+
# Known values; the API may return additional values.
|
|
4541
|
+
module SalePaymentStatusFilter
|
|
4542
|
+
PAID = "PAID"
|
|
4543
|
+
CHARGED_BACK = "CHARGED_BACK"
|
|
4544
|
+
end
|
|
4545
|
+
|
|
4546
|
+
# Known values; the API may return additional values.
|
|
4547
|
+
module StatusResponseDataConnectionType
|
|
4548
|
+
BTLE = "btle"
|
|
4549
|
+
EDGE = "edge"
|
|
4550
|
+
GPRS = "gprs"
|
|
4551
|
+
LTE = "lte"
|
|
4552
|
+
UMTS = "umts"
|
|
4553
|
+
USB = "usb"
|
|
4554
|
+
WI_FI = "Wi-Fi"
|
|
4555
|
+
end
|
|
4556
|
+
|
|
4557
|
+
# Known values; the API may return additional values.
|
|
4558
|
+
module StatusResponseDataState
|
|
4559
|
+
IDLE = "IDLE"
|
|
4560
|
+
SELECTING_TIP = "SELECTING_TIP"
|
|
4561
|
+
WAITING_FOR_CARD = "WAITING_FOR_CARD"
|
|
4562
|
+
WAITING_FOR_PIN = "WAITING_FOR_PIN"
|
|
4563
|
+
WAITING_FOR_SIGNATURE = "WAITING_FOR_SIGNATURE"
|
|
4564
|
+
UPDATING_FIRMWARE = "UPDATING_FIRMWARE"
|
|
4565
|
+
end
|
|
4566
|
+
|
|
4567
|
+
# Known values; the API may return additional values.
|
|
4568
|
+
module StatusResponseDataStatus
|
|
4569
|
+
ONLINE = "ONLINE"
|
|
4570
|
+
OFFLINE = "OFFLINE"
|
|
4571
|
+
end
|
|
4572
|
+
|
|
4573
|
+
# Known values; the API may return additional values.
|
|
4574
|
+
module TaxMode
|
|
4575
|
+
NO_TAX = "NO_TAX"
|
|
4576
|
+
GROSS = "GROSS"
|
|
4577
|
+
NET = "NET"
|
|
4578
|
+
end
|
|
4579
|
+
|
|
4580
|
+
# Known values; the API may return additional values.
|
|
4581
|
+
module TokenTokenType
|
|
4582
|
+
BEARER = "Bearer"
|
|
4583
|
+
end
|
|
4584
|
+
|
|
4585
|
+
# Known values; the API may return additional values.
|
|
4586
|
+
module TransactionEventStatus
|
|
4587
|
+
FAILED = "FAILED"
|
|
4588
|
+
PAID_OUT = "PAID_OUT"
|
|
4589
|
+
PENDING = "PENDING"
|
|
4590
|
+
RECONCILED = "RECONCILED"
|
|
4591
|
+
REFUNDED = "REFUNDED"
|
|
4592
|
+
SCHEDULED = "SCHEDULED"
|
|
4593
|
+
SUCCESSFUL = "SUCCESSFUL"
|
|
4594
|
+
end
|
|
4595
|
+
|
|
4596
|
+
# Known values; the API may return additional values.
|
|
4597
|
+
module TransactionEventType
|
|
4598
|
+
PAYOUT = "PAYOUT"
|
|
4599
|
+
CHARGE_BACK = "CHARGE_BACK"
|
|
4600
|
+
REFUND = "REFUND"
|
|
4601
|
+
PAYOUT_DEDUCTION = "PAYOUT_DEDUCTION"
|
|
4602
|
+
end
|
|
4603
|
+
|
|
4604
|
+
# Known values; the API may return additional values.
|
|
4605
|
+
module TransactionFullPayoutPlan
|
|
4606
|
+
SINGLE_PAYMENT = "SINGLE_PAYMENT"
|
|
4607
|
+
TRUE_INSTALLMENT = "TRUE_INSTALLMENT"
|
|
4608
|
+
ACCELERATED_INSTALLMENT = "ACCELERATED_INSTALLMENT"
|
|
4609
|
+
end
|
|
4610
|
+
|
|
4611
|
+
# Known values; the API may return additional values.
|
|
4612
|
+
module TransactionFullPayoutType
|
|
4613
|
+
BANK_ACCOUNT = "BANK_ACCOUNT"
|
|
4614
|
+
PREPAID_CARD = "PREPAID_CARD"
|
|
4615
|
+
end
|
|
4616
|
+
|
|
4617
|
+
# Known values; the API may return additional values.
|
|
4618
|
+
module TransactionFullProcessAs
|
|
4619
|
+
CREDIT = "CREDIT"
|
|
4620
|
+
DEBIT = "DEBIT"
|
|
4621
|
+
end
|
|
4622
|
+
|
|
4623
|
+
# Known values; the API may return additional values.
|
|
4624
|
+
module TransactionFullSimplePaymentType
|
|
4625
|
+
CASH = "CASH"
|
|
4626
|
+
CC_SIGNATURE = "CC_SIGNATURE"
|
|
4627
|
+
ELV = "ELV"
|
|
4628
|
+
ELV_WITHOUT_SIGNATURE = "ELV_WITHOUT_SIGNATURE"
|
|
4629
|
+
CC_CUSTOMER_ENTERED = "CC_CUSTOMER_ENTERED"
|
|
4630
|
+
MANUAL_ENTRY = "MANUAL_ENTRY"
|
|
4631
|
+
EMV = "EMV"
|
|
4632
|
+
RECURRING = "RECURRING"
|
|
4633
|
+
BALANCE = "BALANCE"
|
|
4634
|
+
MOTO = "MOTO"
|
|
4635
|
+
BOLETO = "BOLETO"
|
|
4636
|
+
APM = "APM"
|
|
4637
|
+
BITCOIN = "BITCOIN"
|
|
4638
|
+
CARD = "CARD"
|
|
4639
|
+
end
|
|
4640
|
+
|
|
4641
|
+
# Known values; the API may return additional values.
|
|
4642
|
+
module TransactionFullSimpleStatus
|
|
4643
|
+
SUCCESSFUL = "SUCCESSFUL"
|
|
4644
|
+
PAID_OUT = "PAID_OUT"
|
|
4645
|
+
CANCEL_FAILED = "CANCEL_FAILED"
|
|
4646
|
+
CANCELLED = "CANCELLED"
|
|
4647
|
+
CHARGEBACK = "CHARGEBACK"
|
|
4648
|
+
FAILED = "FAILED"
|
|
4649
|
+
REFUND_FAILED = "REFUND_FAILED"
|
|
4650
|
+
REFUNDED = "REFUNDED"
|
|
4651
|
+
NON_COLLECTION = "NON_COLLECTION"
|
|
4652
|
+
PENDING = "PENDING"
|
|
4653
|
+
end
|
|
4654
|
+
|
|
4655
|
+
# Known values; the API may return additional values.
|
|
4656
|
+
module TransactionFullVerificationMethod
|
|
4657
|
+
NONE = "none"
|
|
4658
|
+
SIGNATURE = "signature"
|
|
4659
|
+
OFFLINE_PIN = "offline PIN"
|
|
4660
|
+
ONLINE_PIN = "online PIN"
|
|
4661
|
+
OFFLINE_PIN_SIGNATURE = "offline PIN + signature"
|
|
4662
|
+
NA = "na"
|
|
4663
|
+
end
|
|
4664
|
+
|
|
4665
|
+
# Known values; the API may return additional values.
|
|
4666
|
+
module TransactionHistoryPayoutPlan
|
|
4667
|
+
SINGLE_PAYMENT = "SINGLE_PAYMENT"
|
|
4668
|
+
TRUE_INSTALLMENT = "TRUE_INSTALLMENT"
|
|
4669
|
+
ACCELERATED_INSTALLMENT = "ACCELERATED_INSTALLMENT"
|
|
4670
|
+
end
|
|
4671
|
+
|
|
4672
|
+
# Known values; the API may return additional values.
|
|
4673
|
+
module TransactionHistoryPayoutType
|
|
4674
|
+
BANK_ACCOUNT = "BANK_ACCOUNT"
|
|
4675
|
+
PREPAID_CARD = "PREPAID_CARD"
|
|
4676
|
+
end
|
|
4677
|
+
|
|
4678
|
+
# Known values; the API may return additional values.
|
|
4679
|
+
module TransactionHistoryType
|
|
4680
|
+
PAYMENT = "PAYMENT"
|
|
4681
|
+
REFUND = "REFUND"
|
|
4682
|
+
CHARGE_BACK = "CHARGE_BACK"
|
|
4683
|
+
end
|
|
4684
|
+
|
|
4685
|
+
# Known values; the API may return additional values.
|
|
4686
|
+
module TransactionMixinHistoryPayoutPlan
|
|
4687
|
+
SINGLE_PAYMENT = "SINGLE_PAYMENT"
|
|
4688
|
+
TRUE_INSTALLMENT = "TRUE_INSTALLMENT"
|
|
4689
|
+
ACCELERATED_INSTALLMENT = "ACCELERATED_INSTALLMENT"
|
|
4690
|
+
end
|
|
4691
|
+
|
|
4692
|
+
# Known values; the API may return additional values.
|
|
4693
|
+
module TransactionStatus
|
|
4694
|
+
SUCCESSFUL = "SUCCESSFUL"
|
|
4695
|
+
CANCELLED = "CANCELLED"
|
|
4696
|
+
FAILED = "FAILED"
|
|
4697
|
+
PENDING = "PENDING"
|
|
4698
|
+
REFUNDED = "REFUNDED"
|
|
4699
|
+
end
|
|
4700
|
+
|
|
4701
|
+
# Known values; the API may return additional values.
|
|
4702
|
+
module UnauthorizedErrorsType
|
|
4703
|
+
INVALID_ACCESS_TOKEN = "INVALID_ACCESS_TOKEN"
|
|
4704
|
+
INVALID_PASSWORD = "INVALID_PASSWORD"
|
|
4705
|
+
end
|
|
4706
|
+
|
|
4707
|
+
# Known values; the API may return additional values.
|
|
4708
|
+
module UpdateReaderSettingsResponseDataStatus
|
|
4709
|
+
APPLIED = "applied"
|
|
4710
|
+
end
|
|
4711
|
+
|
|
4712
|
+
# Known values; the API may return additional values.
|
|
4713
|
+
module UserType
|
|
4714
|
+
USER = "user"
|
|
4715
|
+
MANAGED_USER = "managed_user"
|
|
4716
|
+
SERVICE_ACCOUNT = "service_account"
|
|
4717
|
+
SYSTEM_ACCOUNT = "system_account"
|
|
4718
|
+
end
|
|
4719
|
+
end
|
|
4720
|
+
end
|