Documentation ¶
Overview ¶
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Code generated by `gogenitor`. DO NOT EDIT.
Index ¶
- Constants
- type APIError
- type Account
- type AccountType
- type Address
- type AddressWithDetails
- type Affiliate
- type AffiliateTags
- type AmountEvent
- type ApiKeysService
- func (s *ApiKeysService) CreateApikey(ctx context.Context, merchantCode string, body CreateApikeyBody) (*Apikey, error)
- func (s *ApiKeysService) GetApikey(ctx context.Context, merchantCode string, keyId string) (*Apikey, error)
- func (s *ApiKeysService) ListApikeys(ctx context.Context, merchantCode string, params ListApikeysParams) (*ApikeysList, error)
- func (s *ApiKeysService) RevokeApikey(ctx context.Context, merchantCode string, keyId string) error
- func (s *ApiKeysService) UpdateApikey(ctx context.Context, merchantCode string, keyId string, body UpdateApikeyBody) error
- type Apikey
- type ApikeyType
- type ApikeysList
- type AppSettings
- type Attributes
- type AuthToken
- type AuthTokenGrantType
- type AuthorizationService
- type Authorize200Response
- type AuthorizeParams
- type BankAccount
- type BusinessOwner
- type BusinessOwners
- type Card
- type CardExpiryMonth
- type CardResponse
- type CardResponseType
- type CardType
- type Checkout
- type CheckoutCreateRequest
- type CheckoutCreateRequestPersonalDetails
- type CheckoutCreateRequestPersonalDetailsAddress
- type CheckoutCreateRequestPersonalDetailsAddressState
- type CheckoutCreateRequestPurpose
- type CheckoutCreateRequestStatus
- type CheckoutCreateRequestTransaction
- type CheckoutCreateRequestTransactionEntryMode
- type CheckoutCreateRequestTransactionPaymentType
- type CheckoutCreateRequestTransactionStatus
- type CheckoutProcessMixin
- type CheckoutProcessMixinPaymentType
- type CheckoutStatus
- type CheckoutSuccess
- type CheckoutSuccessPaymentInstrument
- type CheckoutSuccessStatus
- type CheckoutSuccessTransaction
- type CheckoutSuccessTransactionEntryMode
- type CheckoutSuccessTransactionPaymentType
- type CheckoutSuccessTransactionStatus
- type CheckoutTransaction
- type CheckoutTransactionEntryMode
- type CheckoutTransactionPaymentType
- type CheckoutTransactionStatus
- type CheckoutsService
- func (s *CheckoutsService) Create(ctx context.Context, body CreateCheckoutBody) (*Checkout, error)
- func (s *CheckoutsService) Deactivate(ctx context.Context, id string) (*DeactivateCheckout200Response, error)
- func (s *CheckoutsService) Get(ctx context.Context, id string) (*CheckoutSuccess, error)
- func (s *CheckoutsService) List(ctx context.Context, params ListCheckoutsParams) (*ListCheckouts200Response, error)
- func (s *CheckoutsService) ListAvailablePaymentMethods(ctx context.Context, merchantCode string, params GetPaymentMethodsParams) (*GetPaymentMethods200Response, error)
- func (s *CheckoutsService) Process(ctx context.Context, id string, body ProcessCheckoutBody) (*CheckoutSuccess, error)
- type Client
- type CompatChangeOperatorsPasswordBody
- type CompatError
- type CountryDetails
- type CreateApikeyBody
- type CreateCheckoutBody
- type CreateCheckoutBodyPersonalDetails
- type CreateCheckoutBodyPersonalDetailsAddress
- type CreateCheckoutBodyPersonalDetailsAddressState
- type CreateCheckoutBodyPurpose
- type CreateCheckoutBodyStatus
- type CreateCheckoutBodyTransaction
- type CreateCheckoutBodyTransactionEntryMode
- type CreateCheckoutBodyTransactionPaymentType
- type CreateCheckoutBodyTransactionStatus
- type CreateCustomerBody
- type CreateMerchantMemberBody
- type CreateReaderBody
- type CreateReaderCheckout
- type CreateReaderCheckout201Response
- type CreateReaderCheckout201ResponseData
- type CreateReaderCheckout400Response
- type CreateReaderCheckout400ResponseErrors
- type CreateReaderCheckout422Response
- type CreateReaderCheckout422ResponseErrors
- type CreateReaderCheckout500Response
- type CreateReaderCheckout500ResponseErrors
- type CreateReaderCheckout502Response
- type CreateReaderCheckout502ResponseErrors
- type CreateReaderCheckout504Response
- type CreateReaderCheckout504ResponseErrors
- type CreateReaderCheckoutAmount
- type CreateReaderCheckoutBody
- type CreateReaderCheckoutBodyCardType
- type CreateReaderCheckoutCardType
- type CreateReaderTerminate422Response
- type CreateReaderTerminate422ResponseErrors
- type CreateReaderTerminate500Response
- type CreateReaderTerminate500ResponseErrors
- type CreateReaderTerminate502Response
- type CreateReaderTerminate502ResponseErrors
- type CreateReaderTerminate504Response
- type CreateReaderTerminate504ResponseErrors
- type CreateSubAccountBody
- type CreateSubAccountBodyPermissions
- type CreateToken200Response
- type CreateTokenBody
- type CreateTokenBodyGrantType
- type Currency
- type Customer
- type CustomersService
- func (s *CustomersService) Create(ctx context.Context, body CreateCustomerBody) (*Customer, error)
- func (s *CustomersService) DeactivatePaymentInstrument(ctx context.Context, customerId string, token string) (*DeactivatePaymentInstrument204Response, error)
- func (s *CustomersService) Get(ctx context.Context, customerId string) (*Customer, error)
- func (s *CustomersService) ListPaymentInstruments(ctx context.Context, customerId string) (*ListPaymentInstruments200Response, error)
- func (s *CustomersService) Update(ctx context.Context, customerId string, body UpdateCustomerBody) (*Customer, error)
- type Date
- type DeactivateCheckout200Response
- type DeactivateCheckout200ResponsePurpose
- type DeactivateCheckout200ResponseStatus
- type DeactivateCheckout200ResponseTransaction
- type DeactivateCheckout200ResponseTransactionEntryMode
- type DeactivateCheckout200ResponseTransactionPaymentType
- type DeactivateCheckout200ResponseTransactionStatus
- type DeactivatePaymentInstrument204Response
- type DetailsError
- type DetailsErrorFailedConstraint
- type DoingBusinessAs
- type DoingBusinessAsAddress
- type Error
- type ErrorExtended
- type ErrorForbidden
- type Event
- type EventId
- type EventStatus
- type EventType
- type FinancialPayout
- type FinancialPayoutStatus
- type FinancialPayoutType
- type FinancialPayouts
- type GetAccountParams
- type GetPaymentMethods200Response
- type GetPaymentMethods200ResponseAvailablePaymentMethod
- type GetPaymentMethodsParams
- type GetReaderParams
- type GetReceiptParams
- type GetTransactionParams
- type GetTransactionV21Params
- type HorizontalAccuracy
- type Invite
- type Lat
- type LegalType
- type Link
- type LinkRefund
- type ListApikeysParams
- type ListBankAccounts200Response
- type ListBankAccountsParams
- type ListBankAccountsV11200Response
- type ListBankAccountsV11Params
- type ListCheckouts200Response
- type ListCheckoutsParams
- type ListMerchantMembers200Response
- type ListMerchantMembersParams
- type ListPaymentInstruments200Response
- type ListPayoutsParams
- type ListReaders200Response
- type ListSubAccounts200Response
- type ListSubAccountsParams
- type ListTransactions200Response
- type ListTransactionsParams
- type ListTransactionsV21200Response
- type ListTransactionsV21Params
- type Lon
- type MandatePayload
- type MandatePayloadType
- type MandateResponse
- type Member
- type MembersService
- func (s *MembersService) Create(ctx context.Context, merchantCode string, body CreateMerchantMemberBody) (*Member, error)
- func (s *MembersService) Delete(ctx context.Context, merchantCode string, memberId string) error
- func (s *MembersService) Get(ctx context.Context, merchantCode string, memberId string) (*Member, error)
- func (s *MembersService) List(ctx context.Context, merchantCode string, params ListMerchantMembersParams) (*ListMerchantMembers200Response, error)
- func (s *MembersService) Update(ctx context.Context, merchantCode string, memberId string, ...) (*Member, error)
- type MembershipStatus
- type MembershipUser
- type MembershipUserClassic
- type MembershipsService
- type MerchantAccount
- type MerchantProfile
- type MerchantService
- func (s *MerchantService) Get(ctx context.Context, params GetAccountParams) (*MerchantAccount, error)
- func (s *MerchantService) GetDoingBusinessAs(ctx context.Context) (*DoingBusinessAs, error)
- func (s *MerchantService) GetMerchantProfile(ctx context.Context) (*MerchantProfile, error)
- func (s *MerchantService) GetPersonalProfile(ctx context.Context) (*PersonalProfile, error)
- func (s *MerchantService) GetSettings(ctx context.Context) (*MerchantSettings, error)
- func (s *MerchantService) ListBankAccounts(ctx context.Context, merchantCode string, params ListBankAccountsV11Params) (*ListBankAccountsV11200Response, error)
- func (s *MerchantService) ListBankAccountsDeprecated(ctx context.Context, params ListBankAccountsParams) (*ListBankAccounts200Response, error)
- type MerchantSettings
- type MerchantSettingsMotoPayment
- type Meta
- type Metadata
- type Oauth2Scope
- type Oauth2Scopes
- type Operator
- type OperatorAccountType
- type OperatorPermissions
- type PaymentInstrumentResponse
- type PaymentInstrumentResponseCard
- type PaymentInstrumentResponseCardType
- type PaymentInstrumentResponseType
- type PayoutsService
- type Permissions
- type PersonalDetails
- type PersonalProfile
- type ProcessCheckout400Response
- type ProcessCheckoutBody
- type ProcessCheckoutBodyPaymentType
- type Product
- type Reader
- type ReaderDevice
- type ReaderDeviceModel
- type ReaderId
- type ReaderName
- type ReaderPairingCode
- type ReaderStatus
- type ReadersService
- func (s *ReadersService) Create(ctx context.Context, merchantCode string, body CreateReaderBody) (*Reader, error)
- func (s *ReadersService) CreateCheckout(ctx context.Context, merchantCode string, id string, ...) (*CreateReaderCheckout201Response, error)
- func (s *ReadersService) DeleteReader(ctx context.Context, merchantCode string, id ReaderId) error
- func (s *ReadersService) Get(ctx context.Context, merchantCode string, id ReaderId, params GetReaderParams) (*Reader, error)
- func (s *ReadersService) List(ctx context.Context, merchantCode string) (*ListReaders200Response, error)
- func (s *ReadersService) TerminateCheckout(ctx context.Context, merchantCode string, id string) error
- func (s *ReadersService) Update(ctx context.Context, merchantCode string, id ReaderId, body UpdateReaderBody) error
- type Receipt
- type ReceiptAcquirerData
- type ReceiptCard
- type ReceiptEmvData
- type ReceiptEvent
- type ReceiptMerchantData
- type ReceiptMerchantDataMerchantProfile
- type ReceiptMerchantDataMerchantProfileAddress
- type ReceiptTransaction
- type ReceiptTransactionProduct
- type ReceiptTransactionVatRate
- type ReceiptsService
- type RefundTransaction204Response
- type RefundTransactionBody
- type SharedService
- type SubaccountsService
- func (s *SubaccountsService) CompatChangeOperatorsPassword(ctx context.Context, operatorId int, body CompatChangeOperatorsPasswordBody) (*Operator, error)
- func (s *SubaccountsService) CompatDisableOperator(ctx context.Context, operatorId int) (*Operator, error)
- func (s *SubaccountsService) CompatGetOperator(ctx context.Context, operatorId int) (*Operator, error)
- func (s *SubaccountsService) CreateSubAccount(ctx context.Context, body CreateSubAccountBody) (*Operator, error)
- func (s *SubaccountsService) DeactivateSubAccount(ctx context.Context, operatorId int) (*Operator, error)
- func (s *SubaccountsService) ListSubAccounts(ctx context.Context, params ListSubAccountsParams) (*ListSubAccounts200Response, error)
- func (s *SubaccountsService) UpdateSubAccount(ctx context.Context, operatorId int, body UpdateSubAccountBody) (*Operator, error)
- type Time
- type TimeoffsetDetails
- type TimestampEvent
- type TransactionEvent
- type TransactionFull
- type TransactionFullEntryMode
- type TransactionFullLocation
- type TransactionFullPaymentType
- type TransactionFullPayoutPlan
- type TransactionFullPayoutType
- type TransactionFullSimplePaymentType
- type TransactionFullSimpleStatus
- type TransactionFullStatus
- type TransactionFullVerificationMethod
- type TransactionHistory
- type TransactionHistoryCardType
- type TransactionHistoryPaymentType
- type TransactionHistoryPayoutPlan
- type TransactionHistoryStatus
- type TransactionHistoryType
- type TransactionId
- type TransactionMixinBase
- type TransactionMixinBasePaymentType
- type TransactionMixinBaseStatus
- type TransactionMixinCheckout
- type TransactionMixinCheckoutEntryMode
- type TransactionMixinHistory
- type TransactionMixinHistoryPayoutPlan
- type TransactionsService
- func (s *TransactionsService) Get(ctx context.Context, merchantCode string, params GetTransactionV21Params) (*TransactionFull, error)
- func (s *TransactionsService) GetDeprecated(ctx context.Context, params GetTransactionParams) (*TransactionFull, error)
- func (s *TransactionsService) List(ctx context.Context, merchantCode string, params ListTransactionsV21Params) (*ListTransactionsV21200Response, error)
- func (s *TransactionsService) ListDeprecated(ctx context.Context, params ListTransactionsParams) (*ListTransactions200Response, error)
- func (s *TransactionsService) Refund(ctx context.Context, txnId string, body RefundTransactionBody) (*RefundTransaction204Response, error)
- type UpdateApikeyBody
- type UpdateCustomerBody
- type UpdateMerchantMemberBody
- type UpdateMerchantMemberBodyUser
- type UpdateReaderBody
- type UpdateSubAccountBody
- type UpdateSubAccountBodyPermissions
- type VatRates
Constants ¶
const ( // APIUrl is the URL of our API. Currently, SumUp doesn't provide any // other environment or APIs thus APIUrl is used as the default URL // for the client. APIUrl = "https://api.sumup.com" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIError ¶
type APIError struct { // Platform code for the error. ErrorCode *string `json:"error_code,omitempty"` // Short description of the error. Message *string `json:"message,omitempty"` // 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. Param *string `json:"param,omitempty"` // Short description of the error. ErrorMessage *string `json:"error_message,omitempty"` // HTTP status code for the error. StatusCode *string `json:"status_code,omitempty"` // Details of the error. Details *string `json:"details,omitempty"` FailedConstraints *[]string `json:"failed_constraints,omitempty"` // The status code. Status *float64 `json:"status,omitempty"` // Short title of the error. Title *string `json:"title,omitempty"` }
APIError is custom error type for SumUp API that combinas *all* of our current error types into one underlying struct.
type Account ¶
type Account struct { // The role of the user. Type *AccountType `json:"type,omitempty"` // Username of the user profile. Username *string `json:"username,omitempty"` }
Account: Profile information.
type AccountType ¶
type AccountType string
AccountType: The role of the user.
const ( AccountTypeNormal AccountType = "normal" AccountTypeOperator AccountType = "operator" )
type Address ¶
type Address struct { // City name from the address. City *string `json:"city,omitempty"` // Two letter country code formatted according to [ISO3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2). Country string `json:"country"` // First line of the address with details of the street name and number. Line1 *string `json:"line_1,omitempty"` // Second line of the address with details of the building, unit, apartment, and floor numbers. Line2 *string `json:"line_2,omitempty"` // Postal code from the address. PostalCode *string `json:"postal_code,omitempty"` // State name or abbreviation from the address. State *string `json:"state,omitempty"` }
Address: Profile's personal address information.
type AddressWithDetails ¶
type AddressWithDetails struct { // Address line 1 AddressLine1 *string `json:"address_line_1,omitempty"` // Address line 2 AddressLine2 *string `json:"address_line_2,omitempty"` // City City *string `json:"city,omitempty"` // undefined Company *string `json:"company,omitempty"` // Country ISO 3166-1 code Country *string `json:"country,omitempty"` // Country Details CountryDetails *CountryDetails `json:"country_details,omitempty"` // undefined FirstName *string `json:"first_name,omitempty"` // Landline number Landline *string `json:"landline,omitempty"` // undefined LastName *string `json:"last_name,omitempty"` // Postal code PostCode *string `json:"post_code,omitempty"` // Region code RegionCode *string `json:"region_code,omitempty"` // Country region id RegionId *float64 `json:"region_id,omitempty"` // Region name RegionName *string `json:"region_name,omitempty"` // undefined StateId *string `json:"state_id,omitempty"` // TimeOffset Details TimeoffsetDetails *TimeoffsetDetails `json:"timeoffset_details,omitempty"` }
AddressWithDetails: Details of the registered address.
type Affiliate ¶
type Affiliate struct { // Application ID of the affiliate. // It is a unique identifier for the application and should be set by the integrator in the [Affiliate Keys](https://developer.sumup.com/affiliate-keys) page. AppId string `json:"app_id"` // Foreign transaction ID of the affiliate. // It is a unique identifier for the transaction. // It can be used later to fetch the transaction details via the [Transactions API](https://developer.sumup.com/api/transactions/get). ForeignTransactionId string `json:"foreign_transaction_id"` // Key of the affiliate. // It is a unique identifier for the key and should be generated by the integrator in the [Affiliate Keys](https://developer.sumup.com/affiliate-keys) page. // // Format: uuid Key string `json:"key"` // Additional metadata for the transaction. // It is key-value object that can be associated with the transaction. Tags *AffiliateTags `json:"tags,omitempty"` }
Affiliate: Affiliate metadata for the transaction. It is an optional field that allow for integrators to track the source of the transaction.
type AffiliateTags ¶
AffiliateTags: Additional metadata for the transaction. It is key-value object that can be associated with the transaction.
type ApiKeysService ¶
type ApiKeysService service
func (*ApiKeysService) CreateApikey ¶
func (s *ApiKeysService) CreateApikey(ctx context.Context, merchantCode string, body CreateApikeyBody) (*Apikey, error)
CreateApikey: Create an API key Creates a new API key for the user.
func (*ApiKeysService) GetApikey ¶
func (s *ApiKeysService) GetApikey(ctx context.Context, merchantCode string, keyId string) (*Apikey, error)
GetApikey: Retrieve an API Key Gets an API key.
func (*ApiKeysService) ListApikeys ¶
func (s *ApiKeysService) ListApikeys(ctx context.Context, merchantCode string, params ListApikeysParams) (*ApikeysList, error)
ListApikeys: List API keys Returns paginated list of API keys.
func (*ApiKeysService) RevokeApikey ¶
RevokeApikey: Revoke an API key Revokes an API key.
func (*ApiKeysService) UpdateApikey ¶
func (s *ApiKeysService) UpdateApikey(ctx context.Context, merchantCode string, keyId string, body UpdateApikeyBody) error
UpdateApikey: Update an API key Updates an API key.
type Apikey ¶
type Apikey struct { CreatedAt time.Time `json:"created_at"` // Unique identifier of the API Key. Id string `json:"id"` // User-assigned name of the API Key. Name string `json:"name"` // The plaintext value of the API key. This field is returned only in the response to API key creation and is // never again available in the plaintext form. Plaintext *string `json:"plaintext,omitempty"` // Last 8 characters of the API key. Preview string `json:"preview"` // Max items: 128 Scopes Oauth2Scopes `json:"scopes"` Type ApikeyType `json:"type"` UpdatedAt time.Time `json:"updated_at"` }
Apikey is a schema definition.
type ApikeyType ¶
type ApikeyType string
ApikeyType is a schema definition.
const ( ApikeyTypePublic ApikeyType = "public" ApikeyTypeSecret ApikeyType = "secret" )
type ApikeysList ¶
ApikeysList is a schema definition.
type AppSettings ¶
type AppSettings struct { // Advanced mode. AdvancedMode *string `json:"advanced_mode,omitempty"` // Barcode scanner. BarcodeScanner *string `json:"barcode_scanner,omitempty"` // Cash payment. CashPayment *string `json:"cash_payment,omitempty"` // Checkout preference CheckoutPreference *string `json:"checkout_preference,omitempty"` // Expected max transaction amount. ExpectedMaxTransactionAmount *float64 `json:"expected_max_transaction_amount,omitempty"` // Include vat. IncludeVat *bool `json:"include_vat,omitempty"` // Manual entry. ManualEntry *string `json:"manual_entry,omitempty"` // Manual entry tutorial. ManualEntryTutorial *bool `json:"manual_entry_tutorial,omitempty"` // Mobile payment. MobilePayment *string `json:"mobile_payment,omitempty"` // Mobile payment tutorial. MobilePaymentTutorial *bool `json:"mobile_payment_tutorial,omitempty"` // Reader payment. ReaderPayment *string `json:"reader_payment,omitempty"` // Referral. Referral *string `json:"referral,omitempty"` // Tax enabled. TaxEnabled *bool `json:"tax_enabled,omitempty"` // Terminal mode tutorial. TerminalModeTutorial *bool `json:"terminal_mode_tutorial,omitempty"` // Tip rates. TipRates *[]float64 `json:"tip_rates,omitempty"` // Tipping. Tipping *string `json:"tipping,omitempty"` }
AppSettings: Mobile app settings
type Attributes ¶
Attributes: Object attributes that modifiable only by SumUp applications.
type AuthToken ¶
type AuthToken struct { // The client ID of your application that was generated when you [registered it](https://developer.sumup.com/docs/register-app). ClientId string `json:"client_id"` // The client secret of your application that was generated when you [registered it](https://developer.sumup.com/docs/register-app). ClientSecret string `json:"client_secret"` // The authorization code that you received from requesting an authorization code. Code string `json:"code"` // The grant type used for obtaining an access token. GrantType AuthTokenGrantType `json:"grant_type"` // A **required** parameter when generating a refresh token. RefreshToken *string `json:"refresh_token,omitempty"` }
AuthToken: Authorization token flow
type AuthTokenGrantType ¶
type AuthTokenGrantType string
AuthTokenGrantType: The grant type used for obtaining an access token.
const ( AuthTokenGrantTypeAuthorizationCode AuthTokenGrantType = "authorization_code" AuthTokenGrantTypeRefreshToken AuthTokenGrantType = "refresh_token" )
type AuthorizationService ¶
type AuthorizationService service
func (*AuthorizationService) Authorize ¶
func (s *AuthorizationService) Authorize(ctx context.Context, params AuthorizeParams) (*Authorize200Response, error)
Authorize: Request authorization from users Request authorization from users and grant your application access to resources associated with the user's profile.
func (*AuthorizationService) CreateToken ¶
func (s *AuthorizationService) CreateToken(ctx context.Context, body CreateTokenBody) (*CreateToken200Response, error)
CreateToken: Generate a token Generate a token or a refresh token
type Authorize200Response ¶
type Authorize200Response struct { }
Authorize200Response is a schema definition.
type AuthorizeParams ¶
type AuthorizeParams struct { // The client ID of your application that was generated when you [registered it](https://developer.sumup.com/docs/register-app/). ClientId *string // The URI to which the merchant user is redirected after authorizing your application to access their user's profile // data and to which the authorization code is sent. The value must match exactly one of the [registered URIs](https://developer.sumup.com/docs/register-app#3-create-oauth-client-credentials) // for your application. RedirectUri *string // The type of the expected response. The value must be `code` to indicate that you expect to receive an authorization // code. ResponseType *string // A space-separated list of scopes for which you request authorization. If you don't specify any scopes in // the request, your application will be granted authorization for the default scopes. Scope *string // A unique local state that can be used for correlating requests and responses and for preventing [cross-site request // forgery](https://tools.ietf.org/html/rfc6749#section-10.12). State *string }
AuthorizeParams: query parameters for Authorize
func (*AuthorizeParams) QueryValues ¶
func (p *AuthorizeParams) QueryValues() url.Values
QueryValues converts AuthorizeParams into url.Values.
type BankAccount ¶
type BankAccount struct { // Account category - business or personal AccountCategory *string `json:"account_category,omitempty"` AccountHolderName *string `json:"account_holder_name,omitempty"` // Account number AccountNumber *string `json:"account_number,omitempty"` // Type of the account AccountType *string `json:"account_type,omitempty"` // Bank code BankCode *string `json:"bank_code,omitempty"` // Bank name BankName *string `json:"bank_name,omitempty"` // Branch code BranchCode *string `json:"branch_code,omitempty"` // Creation date of the bank account CreatedAt *string `json:"created_at,omitempty"` // IBAN Iban *string `json:"iban,omitempty"` // The primary bank account is the one used for payouts Primary *bool `json:"primary,omitempty"` // Status in the verification process Status *string `json:"status,omitempty"` // SWIFT code Swift *string `json:"swift,omitempty"` }
BankAccount is a schema definition.
type BusinessOwner ¶
type BusinessOwner struct { // Date of birth DateOfBirth *string `json:"date_of_birth,omitempty"` // BO's first name FirstName *string `json:"first_name,omitempty"` // BO's Landline Landline *string `json:"landline,omitempty"` // BO's last name of the user LastName *string `json:"last_name,omitempty"` // Mobile phone number MobilePhone *string `json:"mobile_phone,omitempty"` // Ownership percentage Ownership *float64 `json:"ownership,omitempty"` }
BusinessOwner is a schema definition.
type BusinessOwners ¶
type BusinessOwners []BusinessOwner
BusinessOwners: Business owners information.
type Card ¶
type Card struct { // Three or four-digit card verification value (security code) of the payment card. // Write only // Min length: 3 // Max length: 4 Cvv string `json:"cvv"` // Month from the expiration time of the payment card. Accepted format is `MM`. // Write only ExpiryMonth CardExpiryMonth `json:"expiry_month"` // Year from the expiration time of the payment card. Accepted formats are `YY` and `YYYY`. // Write only // Min length: 2 // Max length: 4 ExpiryYear string `json:"expiry_year"` // Last 4 digits of the payment card number. // Read only // Min length: 4 // Max length: 4 Last4Digits string `json:"last_4_digits"` // Name of the cardholder as it appears on the payment card. // Write only Name string `json:"name"` // Number of the payment card (without spaces). // Write only Number string `json:"number"` // Issuing card network of the payment card. // Read only Type CardType `json:"type"` // Required five-digit ZIP code. Applicable only to merchant users in the USA. // Write only // Min length: 5 // Max length: 5 ZipCode *string `json:"zip_code,omitempty"` }
Card: __Required when payment type is `card`.__ Details of the payment card.
type CardExpiryMonth ¶
type CardExpiryMonth string
CardExpiryMonth: Month from the expiration time of the payment card. Accepted format is `MM`. Write only
const ( CardExpiryMonth01 CardExpiryMonth = "01" CardExpiryMonth02 CardExpiryMonth = "02" CardExpiryMonth03 CardExpiryMonth = "03" CardExpiryMonth04 CardExpiryMonth = "04" CardExpiryMonth05 CardExpiryMonth = "05" CardExpiryMonth06 CardExpiryMonth = "06" CardExpiryMonth07 CardExpiryMonth = "07" CardExpiryMonth08 CardExpiryMonth = "08" CardExpiryMonth09 CardExpiryMonth = "09" CardExpiryMonth10 CardExpiryMonth = "10" CardExpiryMonth11 CardExpiryMonth = "11" CardExpiryMonth12 CardExpiryMonth = "12" )
type CardResponse ¶
type CardResponse struct { // Last 4 digits of the payment card number. // Read only // Min length: 4 // Max length: 4 Last4Digits *string `json:"last_4_digits,omitempty"` // Issuing card network of the payment card. // Read only Type *CardResponseType `json:"type,omitempty"` }
CardResponse: Details of the payment card.
type CardResponseType ¶
type CardResponseType string
CardResponseType: Issuing card network of the payment card. Read only
const ( CardResponseTypeAmex CardResponseType = "AMEX" CardResponseTypeCup CardResponseType = "CUP" CardResponseTypeDiners CardResponseType = "DINERS" CardResponseTypeDiscover CardResponseType = "DISCOVER" CardResponseTypeElo CardResponseType = "ELO" CardResponseTypeElv CardResponseType = "ELV" CardResponseTypeHipercard CardResponseType = "HIPERCARD" CardResponseTypeJcb CardResponseType = "JCB" CardResponseTypeMaestro CardResponseType = "MAESTRO" CardResponseTypeMastercard CardResponseType = "MASTERCARD" CardResponseTypeUnknown CardResponseType = "UNKNOWN" CardResponseTypeVisa CardResponseType = "VISA" CardResponseTypeVisaElectron CardResponseType = "VISA_ELECTRON" CardResponseTypeVisaVpay CardResponseType = "VISA_VPAY" )
type CardType ¶
type CardType string
CardType: Issuing card network of the payment card. Read only
const ( CardTypeAmex CardType = "AMEX" CardTypeCup CardType = "CUP" CardTypeDiners CardType = "DINERS" CardTypeDiscover CardType = "DISCOVER" CardTypeElo CardType = "ELO" CardTypeElv CardType = "ELV" CardTypeHipercard CardType = "HIPERCARD" CardTypeJcb CardType = "JCB" CardTypeMaestro CardType = "MAESTRO" CardTypeMastercard CardType = "MASTERCARD" CardTypeUnknown CardType = "UNKNOWN" CardTypeVisa CardType = "VISA" CardTypeVisaElectron CardType = "VISA_ELECTRON" CardTypeVisaVpay CardType = "VISA_VPAY" )
type Checkout ¶
type Checkout struct { // Amount of the payment. Amount *float64 `json:"amount,omitempty"` // Unique ID of the payment checkout specified by the client application when creating the checkout resource. // Max length: 90 CheckoutReference *string `json:"checkout_reference,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Unique identification of a customer. If specified, the checkout session and payment instrument are associated with // the referenced customer. CustomerId *string `json:"customer_id,omitempty"` // Date and time of the creation of the payment checkout. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Date *time.Time `json:"date,omitempty"` // Short description of the checkout visible in the SumUp dashboard. The description can contribute to reporting, allowing // easier identification of a checkout. Description *string `json:"description,omitempty"` // Unique ID of the checkout resource. // Read only Id *string `json:"id,omitempty"` // Created mandate Mandate *MandateResponse `json:"mandate,omitempty"` // Unique identifying code of the merchant profile. MerchantCode *string `json:"merchant_code,omitempty"` // Email address of the registered user (merchant) to whom the payment is made. // Format: email PayToEmail *string `json:"pay_to_email,omitempty"` // URL to which the SumUp platform sends the processing status of the payment checkout. // Format: uri ReturnUrl *string `json:"return_url,omitempty"` // Current status of the checkout. Status *CheckoutStatus `json:"status,omitempty"` // List of transactions related to the payment. // Unique items only Transactions *[]CheckoutTransaction `json:"transactions,omitempty"` // Date and time of the checkout expiration before which the client application needs to send a processing request. // If no value is present, the checkout does not have an expiration time. ValidUntil *time.Time `json:"valid_until,omitempty"` }
Checkout: Details of the payment checkout.
type CheckoutCreateRequest ¶
type CheckoutCreateRequest struct { // Amount of the payment. Amount float64 `json:"amount"` // Unique ID of the payment checkout specified by the client application when creating the checkout resource. // Max length: 90 CheckoutReference string `json:"checkout_reference"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency Currency `json:"currency"` // Unique identification of a customer. If specified, the checkout session and payment instrument are associated with // the referenced customer. CustomerId *string `json:"customer_id,omitempty"` // Date and time of the creation of the payment checkout. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. // // Read only Date *time.Time `json:"date,omitempty"` // Short description of the checkout visible in the SumUp dashboard. The description can contribute to reporting, allowing // easier identification of a checkout. Description *string `json:"description,omitempty"` // Unique ID of the checkout resource. // Read only Id *string `json:"id,omitempty"` // Unique identifying code of the merchant profile. MerchantCode string `json:"merchant_code"` // Email address of the registered user (merchant) to whom the payment is made. It is highly recommended to // use `merchant_code` instead of `pay_to_email`. // Format: email PayToEmail *string `json:"pay_to_email,omitempty"` // Alternative payment method name PaymentType *string `json:"payment_type,omitempty"` // Object containing personal details about the payer, typical for __Boleto__ checkouts PersonalDetails *CheckoutCreateRequestPersonalDetails `json:"personal_details,omitempty"` // Purpose of the checkout. // Default: CHECKOUT Purpose *CheckoutCreateRequestPurpose `json:"purpose,omitempty"` // __Required__ for [APMs](https://developer.sumup.com/online-payments/apm/introduction) and __recommended__ for // card payments. Refers to a url where the end user is redirected once the payment processing completes. If // not specified, the [Payment Widget](https://developer.sumup.com/online-payments/tools/card-widget) renders [3DS // challenge](https://developer.sumup.com/online-payments/features/3ds) within an iframe instead of performing a // full-page redirect. RedirectUrl *string `json:"redirect_url,omitempty"` // URL to which the SumUp platform sends the processing status of the payment checkout. // Format: uri ReturnUrl *string `json:"return_url,omitempty"` // Current status of the checkout. // Read only Status *CheckoutCreateRequestStatus `json:"status,omitempty"` // List of transactions related to the payment. // Read only // Unique items only Transactions *[]CheckoutCreateRequestTransaction `json:"transactions,omitempty"` // Date and time of the checkout expiration before which the client application needs to send a processing request. // If no value is present, the checkout does not have an expiration time. // Read only ValidUntil *time.Time `json:"valid_until,omitempty"` }
CheckoutCreateRequest: Details of the payment checkout.
type CheckoutCreateRequestPersonalDetails ¶
type CheckoutCreateRequestPersonalDetails struct { // Payer's address information Address *CheckoutCreateRequestPersonalDetailsAddress `json:"address,omitempty"` // Payer's email address Email *string `json:"email,omitempty"` // Payer's first name FirstName *string `json:"first_name,omitempty"` // Payer's last name LastName *string `json:"last_name,omitempty"` // Payer's tax identification number (CPF) TaxId *string `json:"tax_id,omitempty"` }
CheckoutCreateRequestPersonalDetails: Object containing personal details about the payer, typical for __Boleto__ checkouts
type CheckoutCreateRequestPersonalDetailsAddress ¶
type CheckoutCreateRequestPersonalDetailsAddress struct { // Payer's city City *string `json:"city,omitempty"` // Payer's country Country *string `json:"country,omitempty"` // Field for address details Line1 *string `json:"line_1,omitempty"` // Payer's postal code. Must be eight digits long, however an optional dash could be applied after the 5th digit // ([more information about the format available here](https://en.wikipedia.org/wiki/List_of_postal_codes_in_Brazil)). Both // options are accepted as correct. // Pattern: ^\d{5}-?\d{3}$ PostalCode *string `json:"postal_code,omitempty"` // Payer's state code State *CheckoutCreateRequestPersonalDetailsAddressState `json:"state,omitempty"` }
CheckoutCreateRequestPersonalDetailsAddress: Payer's address information
type CheckoutCreateRequestPersonalDetailsAddressState ¶
type CheckoutCreateRequestPersonalDetailsAddressState string
CheckoutCreateRequestPersonalDetailsAddressState: Payer's state code
const ( CheckoutCreateRequestPersonalDetailsAddressStateAc CheckoutCreateRequestPersonalDetailsAddressState = "AC" CheckoutCreateRequestPersonalDetailsAddressStateAl CheckoutCreateRequestPersonalDetailsAddressState = "AL" CheckoutCreateRequestPersonalDetailsAddressStateAm CheckoutCreateRequestPersonalDetailsAddressState = "AM" CheckoutCreateRequestPersonalDetailsAddressStateAp CheckoutCreateRequestPersonalDetailsAddressState = "AP" CheckoutCreateRequestPersonalDetailsAddressStateBa CheckoutCreateRequestPersonalDetailsAddressState = "BA" CheckoutCreateRequestPersonalDetailsAddressStateCe CheckoutCreateRequestPersonalDetailsAddressState = "CE" CheckoutCreateRequestPersonalDetailsAddressStateDf CheckoutCreateRequestPersonalDetailsAddressState = "DF" CheckoutCreateRequestPersonalDetailsAddressStateEs CheckoutCreateRequestPersonalDetailsAddressState = "ES" CheckoutCreateRequestPersonalDetailsAddressStateGo CheckoutCreateRequestPersonalDetailsAddressState = "GO" CheckoutCreateRequestPersonalDetailsAddressStateMa CheckoutCreateRequestPersonalDetailsAddressState = "MA" CheckoutCreateRequestPersonalDetailsAddressStateMg CheckoutCreateRequestPersonalDetailsAddressState = "MG" CheckoutCreateRequestPersonalDetailsAddressStateMs CheckoutCreateRequestPersonalDetailsAddressState = "MS" CheckoutCreateRequestPersonalDetailsAddressStateMt CheckoutCreateRequestPersonalDetailsAddressState = "MT" CheckoutCreateRequestPersonalDetailsAddressStatePa CheckoutCreateRequestPersonalDetailsAddressState = "PA" CheckoutCreateRequestPersonalDetailsAddressStatePb CheckoutCreateRequestPersonalDetailsAddressState = "PB" CheckoutCreateRequestPersonalDetailsAddressStatePe CheckoutCreateRequestPersonalDetailsAddressState = "PE" CheckoutCreateRequestPersonalDetailsAddressStatePi CheckoutCreateRequestPersonalDetailsAddressState = "PI" CheckoutCreateRequestPersonalDetailsAddressStatePr CheckoutCreateRequestPersonalDetailsAddressState = "PR" CheckoutCreateRequestPersonalDetailsAddressStateRj CheckoutCreateRequestPersonalDetailsAddressState = "RJ" CheckoutCreateRequestPersonalDetailsAddressStateRn CheckoutCreateRequestPersonalDetailsAddressState = "RN" CheckoutCreateRequestPersonalDetailsAddressStateRo CheckoutCreateRequestPersonalDetailsAddressState = "RO" CheckoutCreateRequestPersonalDetailsAddressStateRr CheckoutCreateRequestPersonalDetailsAddressState = "RR" CheckoutCreateRequestPersonalDetailsAddressStateRs CheckoutCreateRequestPersonalDetailsAddressState = "RS" CheckoutCreateRequestPersonalDetailsAddressStateSc CheckoutCreateRequestPersonalDetailsAddressState = "SC" CheckoutCreateRequestPersonalDetailsAddressStateSe CheckoutCreateRequestPersonalDetailsAddressState = "SE" CheckoutCreateRequestPersonalDetailsAddressStateSp CheckoutCreateRequestPersonalDetailsAddressState = "SP" CheckoutCreateRequestPersonalDetailsAddressStateTo CheckoutCreateRequestPersonalDetailsAddressState = "TO" )
type CheckoutCreateRequestPurpose ¶
type CheckoutCreateRequestPurpose string
CheckoutCreateRequestPurpose: Purpose of the checkout. Default: CHECKOUT
const ( CheckoutCreateRequestPurposeCheckout CheckoutCreateRequestPurpose = "CHECKOUT" CheckoutCreateRequestPurposeSetupRecurringPayment CheckoutCreateRequestPurpose = "SETUP_RECURRING_PAYMENT" )
type CheckoutCreateRequestStatus ¶
type CheckoutCreateRequestStatus string
CheckoutCreateRequestStatus: Current status of the checkout. Read only
const ( CheckoutCreateRequestStatusFailed CheckoutCreateRequestStatus = "FAILED" CheckoutCreateRequestStatusPaid CheckoutCreateRequestStatus = "PAID" CheckoutCreateRequestStatusPending CheckoutCreateRequestStatus = "PENDING" )
type CheckoutCreateRequestTransaction ¶
type CheckoutCreateRequestTransaction struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments. AuthCode *string `json:"auth_code,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Entry mode of the payment details. EntryMode *CheckoutCreateRequestTransactionEntryMode `json:"entry_mode,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Internal unique ID of the transaction on the SumUp platform. InternalId *int `json:"internal_id,omitempty"` // Unique code of the registered merchant to whom the payment is made. MerchantCode *string `json:"merchant_code,omitempty"` // Payment type used for the transaction. PaymentType *CheckoutCreateRequestTransactionPaymentType `json:"payment_type,omitempty"` // Current status of the transaction. Status *CheckoutCreateRequestTransactionStatus `json:"status,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Amount of the tip (out of the total transaction amount). TipAmount *float64 `json:"tip_amount,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` // Amount of the applicable VAT (out of the total transaction amount). VatAmount *float64 `json:"vat_amount,omitempty"` }
CheckoutCreateRequestTransaction is a schema definition.
type CheckoutCreateRequestTransactionEntryMode ¶
type CheckoutCreateRequestTransactionEntryMode string
CheckoutCreateRequestTransactionEntryMode: Entry mode of the payment details.
const ( CheckoutCreateRequestTransactionEntryModeBoleto CheckoutCreateRequestTransactionEntryMode = "BOLETO" CheckoutCreateRequestTransactionEntryModeCustomerEntry CheckoutCreateRequestTransactionEntryMode = "CUSTOMER_ENTRY" )
type CheckoutCreateRequestTransactionPaymentType ¶
type CheckoutCreateRequestTransactionPaymentType string
CheckoutCreateRequestTransactionPaymentType: Payment type used for the transaction.
const ( CheckoutCreateRequestTransactionPaymentTypeBoleto CheckoutCreateRequestTransactionPaymentType = "BOLETO" CheckoutCreateRequestTransactionPaymentTypeEcom CheckoutCreateRequestTransactionPaymentType = "ECOM" CheckoutCreateRequestTransactionPaymentTypeRecurring CheckoutCreateRequestTransactionPaymentType = "RECURRING" )
type CheckoutCreateRequestTransactionStatus ¶
type CheckoutCreateRequestTransactionStatus string
CheckoutCreateRequestTransactionStatus: Current status of the transaction.
const ( CheckoutCreateRequestTransactionStatusCancelled CheckoutCreateRequestTransactionStatus = "CANCELLED" CheckoutCreateRequestTransactionStatusFailed CheckoutCreateRequestTransactionStatus = "FAILED" CheckoutCreateRequestTransactionStatusPending CheckoutCreateRequestTransactionStatus = "PENDING" CheckoutCreateRequestTransactionStatusSuccessful CheckoutCreateRequestTransactionStatus = "SUCCESSFUL" )
type CheckoutProcessMixin ¶
type CheckoutProcessMixin struct { // __Required when payment type is `card`.__ Details of the payment card. Card *Card `json:"card,omitempty"` // __Required when `token` is provided.__ Unique ID of the customer. CustomerId *string `json:"customer_id,omitempty"` // Number of installments for deferred payments. Available only to merchant users in Brazil. // Min: 1 // Max: 12 Installments *int `json:"installments,omitempty"` // Mandate is passed when a card is to be tokenized Mandate *MandatePayload `json:"mandate,omitempty"` PaymentType CheckoutProcessMixinPaymentType `json:"payment_type"` // __Required when using a tokenized card to process a checkout.__ Unique token identifying the saved payment card // for a customer. Token *string `json:"token,omitempty"` }
CheckoutProcessMixin: Details of the payment instrument for processing the checkout.
type CheckoutProcessMixinPaymentType ¶
type CheckoutProcessMixinPaymentType string
CheckoutProcessMixinPaymentType is a schema definition.
const ( CheckoutProcessMixinPaymentTypeBancontact CheckoutProcessMixinPaymentType = "bancontact" CheckoutProcessMixinPaymentTypeBlik CheckoutProcessMixinPaymentType = "blik" CheckoutProcessMixinPaymentTypeBoleto CheckoutProcessMixinPaymentType = "boleto" CheckoutProcessMixinPaymentTypeCard CheckoutProcessMixinPaymentType = "card" CheckoutProcessMixinPaymentTypeIdeal CheckoutProcessMixinPaymentType = "ideal" )
type CheckoutStatus ¶
type CheckoutStatus string
CheckoutStatus: Current status of the checkout.
const ( CheckoutStatusFailed CheckoutStatus = "FAILED" CheckoutStatusPaid CheckoutStatus = "PAID" CheckoutStatusPending CheckoutStatus = "PENDING" )
type CheckoutSuccess ¶
type CheckoutSuccess struct { // Amount of the payment. Amount *float64 `json:"amount,omitempty"` // Unique ID of the payment checkout specified by the client application when creating the checkout resource. // Max length: 90 CheckoutReference *string `json:"checkout_reference,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Unique identification of a customer. If specified, the checkout session and payment instrument are associated with // the referenced customer. CustomerId *string `json:"customer_id,omitempty"` // Date and time of the creation of the payment checkout. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Date *time.Time `json:"date,omitempty"` // Short description of the checkout visible in the SumUp dashboard. The description can contribute to reporting, allowing // easier identification of a checkout. Description *string `json:"description,omitempty"` // Unique ID of the checkout resource. // Read only Id *string `json:"id,omitempty"` // Created mandate Mandate *MandateResponse `json:"mandate,omitempty"` // Unique identifying code of the merchant profile. MerchantCode *string `json:"merchant_code,omitempty"` // Name of the merchant MerchantName *string `json:"merchant_name,omitempty"` // Email address of the registered user (merchant) to whom the payment is made. // Format: email PayToEmail *string `json:"pay_to_email,omitempty"` // Object containing token information for the specified payment instrument PaymentInstrument *CheckoutSuccessPaymentInstrument `json:"payment_instrument,omitempty"` // Refers to a url where the end user is redirected once the payment processing completes. RedirectUrl *string `json:"redirect_url,omitempty"` // URL to which the SumUp platform sends the processing status of the payment checkout. // Format: uri ReturnUrl *string `json:"return_url,omitempty"` // Current status of the checkout. Status *CheckoutSuccessStatus `json:"status,omitempty"` // Transaction code of the successful transaction with which the payment for the checkout is completed. // Read only TransactionCode *string `json:"transaction_code,omitempty"` // Transaction ID of the successful transaction with which the payment for the checkout is completed. // Read only TransactionId *string `json:"transaction_id,omitempty"` // List of transactions related to the payment. // Unique items only Transactions *[]CheckoutSuccessTransaction `json:"transactions,omitempty"` // Date and time of the checkout expiration before which the client application needs to send a processing request. // If no value is present, the checkout does not have an expiration time. ValidUntil *time.Time `json:"valid_until,omitempty"` }
CheckoutSuccess is a schema definition.
type CheckoutSuccessPaymentInstrument ¶
type CheckoutSuccessPaymentInstrument struct { // Token value Token *string `json:"token,omitempty"` }
CheckoutSuccessPaymentInstrument: Object containing token information for the specified payment instrument
type CheckoutSuccessStatus ¶
type CheckoutSuccessStatus string
CheckoutSuccessStatus: Current status of the checkout.
const ( CheckoutSuccessStatusFailed CheckoutSuccessStatus = "FAILED" CheckoutSuccessStatusPaid CheckoutSuccessStatus = "PAID" CheckoutSuccessStatusPending CheckoutSuccessStatus = "PENDING" )
type CheckoutSuccessTransaction ¶
type CheckoutSuccessTransaction struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments. AuthCode *string `json:"auth_code,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Entry mode of the payment details. EntryMode *CheckoutSuccessTransactionEntryMode `json:"entry_mode,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Internal unique ID of the transaction on the SumUp platform. InternalId *int `json:"internal_id,omitempty"` // Unique code of the registered merchant to whom the payment is made. MerchantCode *string `json:"merchant_code,omitempty"` // Payment type used for the transaction. PaymentType *CheckoutSuccessTransactionPaymentType `json:"payment_type,omitempty"` // Current status of the transaction. Status *CheckoutSuccessTransactionStatus `json:"status,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Amount of the tip (out of the total transaction amount). TipAmount *float64 `json:"tip_amount,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` // Amount of the applicable VAT (out of the total transaction amount). VatAmount *float64 `json:"vat_amount,omitempty"` }
CheckoutSuccessTransaction is a schema definition.
type CheckoutSuccessTransactionEntryMode ¶
type CheckoutSuccessTransactionEntryMode string
CheckoutSuccessTransactionEntryMode: Entry mode of the payment details.
const ( CheckoutSuccessTransactionEntryModeBoleto CheckoutSuccessTransactionEntryMode = "BOLETO" CheckoutSuccessTransactionEntryModeCustomerEntry CheckoutSuccessTransactionEntryMode = "CUSTOMER_ENTRY" )
type CheckoutSuccessTransactionPaymentType ¶
type CheckoutSuccessTransactionPaymentType string
CheckoutSuccessTransactionPaymentType: Payment type used for the transaction.
const ( CheckoutSuccessTransactionPaymentTypeBoleto CheckoutSuccessTransactionPaymentType = "BOLETO" CheckoutSuccessTransactionPaymentTypeEcom CheckoutSuccessTransactionPaymentType = "ECOM" CheckoutSuccessTransactionPaymentTypeRecurring CheckoutSuccessTransactionPaymentType = "RECURRING" )
type CheckoutSuccessTransactionStatus ¶
type CheckoutSuccessTransactionStatus string
CheckoutSuccessTransactionStatus: Current status of the transaction.
const ( CheckoutSuccessTransactionStatusCancelled CheckoutSuccessTransactionStatus = "CANCELLED" CheckoutSuccessTransactionStatusFailed CheckoutSuccessTransactionStatus = "FAILED" CheckoutSuccessTransactionStatusPending CheckoutSuccessTransactionStatus = "PENDING" CheckoutSuccessTransactionStatusSuccessful CheckoutSuccessTransactionStatus = "SUCCESSFUL" )
type CheckoutTransaction ¶
type CheckoutTransaction struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments. AuthCode *string `json:"auth_code,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Entry mode of the payment details. EntryMode *CheckoutTransactionEntryMode `json:"entry_mode,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Internal unique ID of the transaction on the SumUp platform. InternalId *int `json:"internal_id,omitempty"` // Unique code of the registered merchant to whom the payment is made. MerchantCode *string `json:"merchant_code,omitempty"` // Payment type used for the transaction. PaymentType *CheckoutTransactionPaymentType `json:"payment_type,omitempty"` // Current status of the transaction. Status *CheckoutTransactionStatus `json:"status,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Amount of the tip (out of the total transaction amount). TipAmount *float64 `json:"tip_amount,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` // Amount of the applicable VAT (out of the total transaction amount). VatAmount *float64 `json:"vat_amount,omitempty"` }
CheckoutTransaction is a schema definition.
type CheckoutTransactionEntryMode ¶
type CheckoutTransactionEntryMode string
CheckoutTransactionEntryMode: Entry mode of the payment details.
const ( CheckoutTransactionEntryModeBoleto CheckoutTransactionEntryMode = "BOLETO" CheckoutTransactionEntryModeCustomerEntry CheckoutTransactionEntryMode = "CUSTOMER_ENTRY" )
type CheckoutTransactionPaymentType ¶
type CheckoutTransactionPaymentType string
CheckoutTransactionPaymentType: Payment type used for the transaction.
const ( CheckoutTransactionPaymentTypeBoleto CheckoutTransactionPaymentType = "BOLETO" CheckoutTransactionPaymentTypeEcom CheckoutTransactionPaymentType = "ECOM" CheckoutTransactionPaymentTypeRecurring CheckoutTransactionPaymentType = "RECURRING" )
type CheckoutTransactionStatus ¶
type CheckoutTransactionStatus string
CheckoutTransactionStatus: Current status of the transaction.
const ( CheckoutTransactionStatusCancelled CheckoutTransactionStatus = "CANCELLED" CheckoutTransactionStatusFailed CheckoutTransactionStatus = "FAILED" CheckoutTransactionStatusPending CheckoutTransactionStatus = "PENDING" CheckoutTransactionStatusSuccessful CheckoutTransactionStatus = "SUCCESSFUL" )
type CheckoutsService ¶
type CheckoutsService service
func (*CheckoutsService) Create ¶
func (s *CheckoutsService) Create(ctx context.Context, body CreateCheckoutBody) (*Checkout, error)
Create: Create a checkout Creates a new payment checkout resource. The unique `checkout_reference` created by this request, is used for further manipulation of the checkout.
For 3DS checkouts, add the `redirect_url` parameter to your request body schema.
Follow by processing a checkout to charge the provided payment instrument.
func (*CheckoutsService) Deactivate ¶
func (s *CheckoutsService) Deactivate(ctx context.Context, id string) (*DeactivateCheckout200Response, error)
Deactivate: Deactivate a checkout Deactivates an identified checkout resource. If the checkout has already been processed it can not be deactivated.
func (*CheckoutsService) Get ¶
func (s *CheckoutsService) Get(ctx context.Context, id string) (*CheckoutSuccess, error)
Get: Retrieve a checkout Retrieves an identified checkout resource. Use this request after processing a checkout to confirm its status and inform the end user respectively.
func (*CheckoutsService) List ¶
func (s *CheckoutsService) List(ctx context.Context, params ListCheckoutsParams) (*ListCheckouts200Response, error)
List: List checkouts Lists created checkout resources according to the applied `checkout_reference`.
func (*CheckoutsService) ListAvailablePaymentMethods ¶
func (s *CheckoutsService) ListAvailablePaymentMethods(ctx context.Context, merchantCode string, params GetPaymentMethodsParams) (*GetPaymentMethods200Response, error)
ListAvailablePaymentMethods: Get available payment methods Get payment methods available for the given merchant to use with a checkout.
func (*CheckoutsService) Process ¶
func (s *CheckoutsService) Process(ctx context.Context, id string, body ProcessCheckoutBody) (*CheckoutSuccess, error)
Process: Process a checkout Processing a checkout will attempt to charge the provided payment instrument for the amount of the specified checkout resource initiated in the `Create a checkout` endpoint.
Follow this request with `Retrieve a checkout` to confirm its status.
type Client ¶
type Client struct { ApiKeys *ApiKeysService Authorization *AuthorizationService Checkouts *CheckoutsService Customers *CustomersService Members *MembersService Merchant *MerchantService Payouts *PayoutsService Readers *ReadersService Receipts *ReceiptsService Subaccounts *SubaccountsService Transactions *TransactionsService // contains filtered or unexported fields }
func NewClient ¶
func NewClient() *Client
NewClient creates new SumUp API client. To use APIs that require authentication use Client.WithAuth.
func (*Client) NewRequest ¶
type CompatChangeOperatorsPasswordBody ¶
type CompatChangeOperatorsPasswordBody struct { // Min length: 8 Password *string `json:"password,omitempty"` }
CompatChangeOperatorsPasswordBody is a schema definition.
type CompatError ¶
CompatError: Error
func (*CompatError) Error ¶
func (e *CompatError) Error() string
type CountryDetails ¶
type CountryDetails struct { // Currency ISO 4217 code Currency *string `json:"currency,omitempty"` // Country EN name EnName *string `json:"en_name,omitempty"` // Country ISO code IsoCode *string `json:"iso_code,omitempty"` // Country native name NativeName *string `json:"native_name,omitempty"` }
CountryDetails: Country Details
type CreateApikeyBody ¶
type CreateApikeyBody struct { // Max length: 255 Name string `json:"name"` // Max items: 128 Scopes Oauth2Scopes `json:"scopes"` }
CreateApikeyBody is a schema definition.
type CreateCheckoutBody ¶
type CreateCheckoutBody struct { // Amount of the payment. Amount float64 `json:"amount"` // Unique ID of the payment checkout specified by the client application when creating the checkout resource. // Max length: 90 CheckoutReference string `json:"checkout_reference"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency Currency `json:"currency"` // Unique identification of a customer. If specified, the checkout session and payment instrument are associated with // the referenced customer. CustomerId *string `json:"customer_id,omitempty"` // Date and time of the creation of the payment checkout. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. // // Read only Date *time.Time `json:"date,omitempty"` // Short description of the checkout visible in the SumUp dashboard. The description can contribute to reporting, allowing // easier identification of a checkout. Description *string `json:"description,omitempty"` // Unique ID of the checkout resource. // Read only Id *string `json:"id,omitempty"` // Unique identifying code of the merchant profile. MerchantCode string `json:"merchant_code"` // Email address of the registered user (merchant) to whom the payment is made. It is highly recommended to // use `merchant_code` instead of `pay_to_email`. // Format: email PayToEmail *string `json:"pay_to_email,omitempty"` // Alternative payment method name PaymentType *string `json:"payment_type,omitempty"` // Object containing personal details about the payer, typical for __Boleto__ checkouts PersonalDetails *CreateCheckoutBodyPersonalDetails `json:"personal_details,omitempty"` // Purpose of the checkout. // Default: CHECKOUT Purpose *CreateCheckoutBodyPurpose `json:"purpose,omitempty"` // __Required__ for [APMs](https://developer.sumup.com/online-payments/apm/introduction) and __recommended__ for // card payments. Refers to a url where the end user is redirected once the payment processing completes. If // not specified, the [Payment Widget](https://developer.sumup.com/online-payments/tools/card-widget) renders [3DS // challenge](https://developer.sumup.com/online-payments/features/3ds) within an iframe instead of performing a // full-page redirect. RedirectUrl *string `json:"redirect_url,omitempty"` // URL to which the SumUp platform sends the processing status of the payment checkout. // Format: uri ReturnUrl *string `json:"return_url,omitempty"` // Current status of the checkout. // Read only Status *CreateCheckoutBodyStatus `json:"status,omitempty"` // List of transactions related to the payment. // Read only // Unique items only Transactions *[]CreateCheckoutBodyTransaction `json:"transactions,omitempty"` // Date and time of the checkout expiration before which the client application needs to send a processing request. // If no value is present, the checkout does not have an expiration time. // Read only ValidUntil *time.Time `json:"valid_until,omitempty"` }
CreateCheckoutBody: Details of the payment checkout.
type CreateCheckoutBodyPersonalDetails ¶
type CreateCheckoutBodyPersonalDetails struct { // Payer's address information Address *CreateCheckoutBodyPersonalDetailsAddress `json:"address,omitempty"` // Payer's email address Email *string `json:"email,omitempty"` // Payer's first name FirstName *string `json:"first_name,omitempty"` // Payer's last name LastName *string `json:"last_name,omitempty"` // Payer's tax identification number (CPF) TaxId *string `json:"tax_id,omitempty"` }
CreateCheckoutBodyPersonalDetails: Object containing personal details about the payer, typical for __Boleto__ checkouts
type CreateCheckoutBodyPersonalDetailsAddress ¶
type CreateCheckoutBodyPersonalDetailsAddress struct { // Payer's city City *string `json:"city,omitempty"` // Payer's country Country *string `json:"country,omitempty"` // Field for address details Line1 *string `json:"line_1,omitempty"` // Payer's postal code. Must be eight digits long, however an optional dash could be applied after the 5th digit // ([more information about the format available here](https://en.wikipedia.org/wiki/List_of_postal_codes_in_Brazil)). Both // options are accepted as correct. // Pattern: ^\d{5}-?\d{3}$ PostalCode *string `json:"postal_code,omitempty"` // Payer's state code State *CreateCheckoutBodyPersonalDetailsAddressState `json:"state,omitempty"` }
CreateCheckoutBodyPersonalDetailsAddress: Payer's address information
type CreateCheckoutBodyPersonalDetailsAddressState ¶
type CreateCheckoutBodyPersonalDetailsAddressState string
CreateCheckoutBodyPersonalDetailsAddressState: Payer's state code
const ( CreateCheckoutBodyPersonalDetailsAddressStateAc CreateCheckoutBodyPersonalDetailsAddressState = "AC" CreateCheckoutBodyPersonalDetailsAddressStateAl CreateCheckoutBodyPersonalDetailsAddressState = "AL" CreateCheckoutBodyPersonalDetailsAddressStateAm CreateCheckoutBodyPersonalDetailsAddressState = "AM" CreateCheckoutBodyPersonalDetailsAddressStateAp CreateCheckoutBodyPersonalDetailsAddressState = "AP" CreateCheckoutBodyPersonalDetailsAddressStateBa CreateCheckoutBodyPersonalDetailsAddressState = "BA" CreateCheckoutBodyPersonalDetailsAddressStateCe CreateCheckoutBodyPersonalDetailsAddressState = "CE" CreateCheckoutBodyPersonalDetailsAddressStateDf CreateCheckoutBodyPersonalDetailsAddressState = "DF" CreateCheckoutBodyPersonalDetailsAddressStateEs CreateCheckoutBodyPersonalDetailsAddressState = "ES" CreateCheckoutBodyPersonalDetailsAddressStateGo CreateCheckoutBodyPersonalDetailsAddressState = "GO" CreateCheckoutBodyPersonalDetailsAddressStateMa CreateCheckoutBodyPersonalDetailsAddressState = "MA" CreateCheckoutBodyPersonalDetailsAddressStateMg CreateCheckoutBodyPersonalDetailsAddressState = "MG" CreateCheckoutBodyPersonalDetailsAddressStateMs CreateCheckoutBodyPersonalDetailsAddressState = "MS" CreateCheckoutBodyPersonalDetailsAddressStateMt CreateCheckoutBodyPersonalDetailsAddressState = "MT" CreateCheckoutBodyPersonalDetailsAddressStatePa CreateCheckoutBodyPersonalDetailsAddressState = "PA" CreateCheckoutBodyPersonalDetailsAddressStatePb CreateCheckoutBodyPersonalDetailsAddressState = "PB" CreateCheckoutBodyPersonalDetailsAddressStatePe CreateCheckoutBodyPersonalDetailsAddressState = "PE" CreateCheckoutBodyPersonalDetailsAddressStatePi CreateCheckoutBodyPersonalDetailsAddressState = "PI" CreateCheckoutBodyPersonalDetailsAddressStatePr CreateCheckoutBodyPersonalDetailsAddressState = "PR" CreateCheckoutBodyPersonalDetailsAddressStateRj CreateCheckoutBodyPersonalDetailsAddressState = "RJ" CreateCheckoutBodyPersonalDetailsAddressStateRn CreateCheckoutBodyPersonalDetailsAddressState = "RN" CreateCheckoutBodyPersonalDetailsAddressStateRo CreateCheckoutBodyPersonalDetailsAddressState = "RO" CreateCheckoutBodyPersonalDetailsAddressStateRr CreateCheckoutBodyPersonalDetailsAddressState = "RR" CreateCheckoutBodyPersonalDetailsAddressStateRs CreateCheckoutBodyPersonalDetailsAddressState = "RS" CreateCheckoutBodyPersonalDetailsAddressStateSc CreateCheckoutBodyPersonalDetailsAddressState = "SC" CreateCheckoutBodyPersonalDetailsAddressStateSe CreateCheckoutBodyPersonalDetailsAddressState = "SE" CreateCheckoutBodyPersonalDetailsAddressStateSp CreateCheckoutBodyPersonalDetailsAddressState = "SP" CreateCheckoutBodyPersonalDetailsAddressStateTo CreateCheckoutBodyPersonalDetailsAddressState = "TO" )
type CreateCheckoutBodyPurpose ¶
type CreateCheckoutBodyPurpose string
CreateCheckoutBodyPurpose: Purpose of the checkout. Default: CHECKOUT
const ( CreateCheckoutBodyPurposeCheckout CreateCheckoutBodyPurpose = "CHECKOUT" CreateCheckoutBodyPurposeSetupRecurringPayment CreateCheckoutBodyPurpose = "SETUP_RECURRING_PAYMENT" )
type CreateCheckoutBodyStatus ¶
type CreateCheckoutBodyStatus string
CreateCheckoutBodyStatus: Current status of the checkout. Read only
const ( CreateCheckoutBodyStatusFailed CreateCheckoutBodyStatus = "FAILED" CreateCheckoutBodyStatusPaid CreateCheckoutBodyStatus = "PAID" CreateCheckoutBodyStatusPending CreateCheckoutBodyStatus = "PENDING" )
type CreateCheckoutBodyTransaction ¶
type CreateCheckoutBodyTransaction struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments. AuthCode *string `json:"auth_code,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Entry mode of the payment details. EntryMode *CreateCheckoutBodyTransactionEntryMode `json:"entry_mode,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Internal unique ID of the transaction on the SumUp platform. InternalId *int `json:"internal_id,omitempty"` // Unique code of the registered merchant to whom the payment is made. MerchantCode *string `json:"merchant_code,omitempty"` // Payment type used for the transaction. PaymentType *CreateCheckoutBodyTransactionPaymentType `json:"payment_type,omitempty"` // Current status of the transaction. Status *CreateCheckoutBodyTransactionStatus `json:"status,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Amount of the tip (out of the total transaction amount). TipAmount *float64 `json:"tip_amount,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` // Amount of the applicable VAT (out of the total transaction amount). VatAmount *float64 `json:"vat_amount,omitempty"` }
CreateCheckoutBodyTransaction is a schema definition.
type CreateCheckoutBodyTransactionEntryMode ¶
type CreateCheckoutBodyTransactionEntryMode string
CreateCheckoutBodyTransactionEntryMode: Entry mode of the payment details.
const ( CreateCheckoutBodyTransactionEntryModeBoleto CreateCheckoutBodyTransactionEntryMode = "BOLETO" CreateCheckoutBodyTransactionEntryModeCustomerEntry CreateCheckoutBodyTransactionEntryMode = "CUSTOMER_ENTRY" )
type CreateCheckoutBodyTransactionPaymentType ¶
type CreateCheckoutBodyTransactionPaymentType string
CreateCheckoutBodyTransactionPaymentType: Payment type used for the transaction.
const ( CreateCheckoutBodyTransactionPaymentTypeBoleto CreateCheckoutBodyTransactionPaymentType = "BOLETO" CreateCheckoutBodyTransactionPaymentTypeEcom CreateCheckoutBodyTransactionPaymentType = "ECOM" CreateCheckoutBodyTransactionPaymentTypeRecurring CreateCheckoutBodyTransactionPaymentType = "RECURRING" )
type CreateCheckoutBodyTransactionStatus ¶
type CreateCheckoutBodyTransactionStatus string
CreateCheckoutBodyTransactionStatus: Current status of the transaction.
const ( CreateCheckoutBodyTransactionStatusCancelled CreateCheckoutBodyTransactionStatus = "CANCELLED" CreateCheckoutBodyTransactionStatusFailed CreateCheckoutBodyTransactionStatus = "FAILED" CreateCheckoutBodyTransactionStatusPending CreateCheckoutBodyTransactionStatus = "PENDING" CreateCheckoutBodyTransactionStatusSuccessful CreateCheckoutBodyTransactionStatus = "SUCCESSFUL" )
type CreateCustomerBody ¶
type CreateCustomerBody struct { // Unique ID of the customer. CustomerId string `json:"customer_id"` // Personal details for the customer. PersonalDetails *PersonalDetails `json:"personal_details,omitempty"` }
CreateCustomerBody is a schema definition.
type CreateMerchantMemberBody ¶
type CreateMerchantMemberBody struct { // Object attributes that modifiable only by SumUp applications. Attributes *Attributes `json:"attributes,omitempty"` // Email address of the member to add. // Format: email Email string `json:"email"` // True if the user is managed by the merchant. In this case, we'll created a virtual user with the provided password // and nickname. IsManagedUser *bool `json:"is_managed_user,omitempty"` // Set of user-defined key-value pairs attached to the object. Partial updates are not supported. When updating, always // submit whole metadata. Metadata *Metadata `json:"metadata,omitempty"` // Nickname of the member to add. Only used if `is_managed_user` is true. Used for display purposes only. Nickname *string `json:"nickname,omitempty"` // Password of the member to add. Only used if `is_managed_user` is true. // Format: password // Min length: 8 Password *string `json:"password,omitempty"` // List of roles to assign to the new member. Roles []string `json:"roles"` }
CreateMerchantMemberBody is a schema definition.
type CreateReaderBody ¶
type CreateReaderBody struct { // Set of user-defined key-value pairs attached to the object. // Max properties: 50 Meta *Meta `json:"meta,omitempty"` // Custom human-readable, user-defined name for easier identification of the reader. // Max length: 500 Name *ReaderName `json:"name,omitempty"` // 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. // Min length: 8 // Max length: 9 PairingCode ReaderPairingCode `json:"pairing_code"` }
CreateReaderBody is a schema definition.
type CreateReaderCheckout ¶
type CreateReaderCheckout struct { // Affiliate metadata for the transaction. // It is an optional field that allow for integrators to track the source of the transaction. Affiliate *Affiliate `json:"affiliate,omitempty"` // The card type of the card used for the transaction. // Is is required only for some countries (e.g: Brazil). CardType *CreateReaderCheckoutCardType `json:"card_type,omitempty"` // Description of the checkout to be shown in the Merchant Sales Description *string `json:"description,omitempty"` // Number of installments for the transaction. // It may vary according to the merchant country. // For example, in Brazil, the maximum number of installments is 12. Installments *int `json:"installments,omitempty"` // Webhook URL to which the payment result will be sent. // It must be a HTTPS url. // Format: uri ReturnUrl *string `json:"return_url,omitempty"` // List of tipping rates to be displayed to the cardholder. // The rates are in percentage and should be between 0.01 and 0.99. // The list should be sorted in ascending order. TipRates *[]float64 `json:"tip_rates,omitempty"` // Amount of the transaction. // The amount is represented as an integer value altogether with the currency and the minor unit. // For example, EUR 1.00 is represented as value 100 with minor unit of 2. TotalAmount CreateReaderCheckoutAmount `json:"total_amount"` }
CreateReaderCheckout: Reader Checkout
type CreateReaderCheckout201Response ¶
type CreateReaderCheckout201Response struct {
Data *CreateReaderCheckout201ResponseData `json:"data,omitempty"`
}
CreateReaderCheckout201Response is a schema definition.
type CreateReaderCheckout201ResponseData ¶
type CreateReaderCheckout201ResponseData struct { // The client transaction ID is a unique identifier for the transaction that is generated for the client. // It can be used later to fetch the transaction details via the [Transactions API](https://developer.sumup.com/api/transactions/get). // Format: uuid ClientTransactionId *string `json:"client_transaction_id,omitempty"` }
CreateReaderCheckout201ResponseData is a schema definition.
type CreateReaderCheckout400Response ¶
type CreateReaderCheckout400Response struct {
Errors *CreateReaderCheckout400ResponseErrors `json:"errors,omitempty"`
}
CreateReaderCheckout400Response is a schema definition.
func (*CreateReaderCheckout400Response) Error ¶
func (e *CreateReaderCheckout400Response) Error() string
type CreateReaderCheckout400ResponseErrors ¶
type CreateReaderCheckout400ResponseErrors struct {
Detail *string `json:"detail,omitempty"`
}
CreateReaderCheckout400ResponseErrors is a schema definition.
type CreateReaderCheckout422Response ¶
type CreateReaderCheckout422Response struct {
Errors *CreateReaderCheckout422ResponseErrors `json:"errors,omitempty"`
}
CreateReaderCheckout422Response is a schema definition.
func (*CreateReaderCheckout422Response) Error ¶
func (e *CreateReaderCheckout422Response) Error() string
type CreateReaderCheckout422ResponseErrors ¶
CreateReaderCheckout422ResponseErrors is a schema definition.
type CreateReaderCheckout500Response ¶
type CreateReaderCheckout500Response struct {
Errors *CreateReaderCheckout500ResponseErrors `json:"errors,omitempty"`
}
CreateReaderCheckout500Response is a schema definition.
func (*CreateReaderCheckout500Response) Error ¶
func (e *CreateReaderCheckout500Response) Error() string
type CreateReaderCheckout500ResponseErrors ¶
type CreateReaderCheckout500ResponseErrors struct {
Detail *string `json:"detail,omitempty"`
}
CreateReaderCheckout500ResponseErrors is a schema definition.
type CreateReaderCheckout502Response ¶
type CreateReaderCheckout502Response struct {
Errors *CreateReaderCheckout502ResponseErrors `json:"errors,omitempty"`
}
CreateReaderCheckout502Response is a schema definition.
func (*CreateReaderCheckout502Response) Error ¶
func (e *CreateReaderCheckout502Response) Error() string
type CreateReaderCheckout502ResponseErrors ¶
type CreateReaderCheckout502ResponseErrors struct {
Detail *string `json:"detail,omitempty"`
}
CreateReaderCheckout502ResponseErrors is a schema definition.
type CreateReaderCheckout504Response ¶
type CreateReaderCheckout504Response struct {
Errors *CreateReaderCheckout504ResponseErrors `json:"errors,omitempty"`
}
CreateReaderCheckout504Response is a schema definition.
func (*CreateReaderCheckout504Response) Error ¶
func (e *CreateReaderCheckout504Response) Error() string
type CreateReaderCheckout504ResponseErrors ¶
type CreateReaderCheckout504ResponseErrors struct {
Detail *string `json:"detail,omitempty"`
}
CreateReaderCheckout504ResponseErrors is a schema definition.
type CreateReaderCheckoutAmount ¶
type CreateReaderCheckoutAmount struct { // Currency ISO 4217 code Currency string `json:"currency"` // The minor units of the currency. It represents the number of decimals of the currency. // For the currencies CLP, COP and HUF, the minor unit is 0. MinorUnit int `json:"minor_unit"` // Total amount of the transaction. // It must be a positive integer. Value int `json:"value"` }
CreateReaderCheckoutAmount: Amount of the transaction. The amount is represented as an integer value altogether with the currency and the minor unit. For example, EUR 1.00 is represented as value 100 with minor unit of 2.
type CreateReaderCheckoutBody ¶
type CreateReaderCheckoutBody struct { // Affiliate metadata for the transaction. // It is an optional field that allow for integrators to track the source of the transaction. Affiliate *Affiliate `json:"affiliate,omitempty"` // The card type of the card used for the transaction. // Is is required only for some countries (e.g: Brazil). CardType *CreateReaderCheckoutBodyCardType `json:"card_type,omitempty"` // Description of the checkout to be shown in the Merchant Sales Description *string `json:"description,omitempty"` // Number of installments for the transaction. // It may vary according to the merchant country. // For example, in Brazil, the maximum number of installments is 12. Installments *int `json:"installments,omitempty"` // Webhook URL to which the payment result will be sent. // It must be a HTTPS url. // Format: uri ReturnUrl *string `json:"return_url,omitempty"` // List of tipping rates to be displayed to the cardholder. // The rates are in percentage and should be between 0.01 and 0.99. // The list should be sorted in ascending order. TipRates *[]float64 `json:"tip_rates,omitempty"` // Amount of the transaction. // The amount is represented as an integer value altogether with the currency and the minor unit. // For example, EUR 1.00 is represented as value 100 with minor unit of 2. TotalAmount CreateReaderCheckoutAmount `json:"total_amount"` }
CreateReaderCheckoutBody: Reader Checkout
type CreateReaderCheckoutBodyCardType ¶
type CreateReaderCheckoutBodyCardType string
CreateReaderCheckoutBodyCardType: The card type of the card used for the transaction. Is is required only for some countries (e.g: Brazil).
const ( CreateReaderCheckoutBodyCardTypeCredit CreateReaderCheckoutBodyCardType = "credit" CreateReaderCheckoutBodyCardTypeDebit CreateReaderCheckoutBodyCardType = "debit" )
type CreateReaderCheckoutCardType ¶
type CreateReaderCheckoutCardType string
CreateReaderCheckoutCardType: The card type of the card used for the transaction. Is is required only for some countries (e.g: Brazil).
const ( CreateReaderCheckoutCardTypeCredit CreateReaderCheckoutCardType = "credit" CreateReaderCheckoutCardTypeDebit CreateReaderCheckoutCardType = "debit" )
type CreateReaderTerminate422Response ¶
type CreateReaderTerminate422Response struct {
Errors *CreateReaderTerminate422ResponseErrors `json:"errors,omitempty"`
}
CreateReaderTerminate422Response is a schema definition.
func (*CreateReaderTerminate422Response) Error ¶
func (e *CreateReaderTerminate422Response) Error() string
type CreateReaderTerminate422ResponseErrors ¶
CreateReaderTerminate422ResponseErrors is a schema definition.
type CreateReaderTerminate500Response ¶
type CreateReaderTerminate500Response struct {
Errors *CreateReaderTerminate500ResponseErrors `json:"errors,omitempty"`
}
CreateReaderTerminate500Response is a schema definition.
func (*CreateReaderTerminate500Response) Error ¶
func (e *CreateReaderTerminate500Response) Error() string
type CreateReaderTerminate500ResponseErrors ¶
type CreateReaderTerminate500ResponseErrors struct {
Detail *string `json:"detail,omitempty"`
}
CreateReaderTerminate500ResponseErrors is a schema definition.
type CreateReaderTerminate502Response ¶
type CreateReaderTerminate502Response struct {
Errors *CreateReaderTerminate502ResponseErrors `json:"errors,omitempty"`
}
CreateReaderTerminate502Response is a schema definition.
func (*CreateReaderTerminate502Response) Error ¶
func (e *CreateReaderTerminate502Response) Error() string
type CreateReaderTerminate502ResponseErrors ¶
type CreateReaderTerminate502ResponseErrors struct {
Detail *string `json:"detail,omitempty"`
}
CreateReaderTerminate502ResponseErrors is a schema definition.
type CreateReaderTerminate504Response ¶
type CreateReaderTerminate504Response struct {
Errors *CreateReaderTerminate504ResponseErrors `json:"errors,omitempty"`
}
CreateReaderTerminate504Response is a schema definition.
func (*CreateReaderTerminate504Response) Error ¶
func (e *CreateReaderTerminate504Response) Error() string
type CreateReaderTerminate504ResponseErrors ¶
type CreateReaderTerminate504ResponseErrors struct {
Detail *string `json:"detail,omitempty"`
}
CreateReaderTerminate504ResponseErrors is a schema definition.
type CreateSubAccountBody ¶
type CreateSubAccountBody struct { Nickname *string `json:"nickname,omitempty"` // Min length: 8 Password string `json:"password"` Permissions *CreateSubAccountBodyPermissions `json:"permissions,omitempty"` // Format: email Username string `json:"username"` }
CreateSubAccountBody is a schema definition.
type CreateSubAccountBodyPermissions ¶
type CreateSubAccountBodyPermissions struct { CreateMotoPayments *bool `json:"create_moto_payments,omitempty"` CreateReferral *bool `json:"create_referral,omitempty"` FullTransactionHistoryView *bool `json:"full_transaction_history_view,omitempty"` RefundTransactions *bool `json:"refund_transactions,omitempty"` }
CreateSubAccountBodyPermissions is a schema definition.
type CreateToken200Response ¶
type CreateToken200Response struct { // The access token that you need to use in your requests to the SumUp API. AccessToken *string `json:"access_token,omitempty"` // The validity of the access token in seconds. ExpiresIn *int `json:"expires_in,omitempty"` // The refresh token provided in the request call RefreshToken *string `json:"refresh_token,omitempty"` // List of authorization scopes granted to your access token. Scope *string `json:"scope,omitempty"` // The type of the token. The value is always `Bearer`. TokenType *string `json:"token_type,omitempty"` }
CreateToken200Response is a schema definition.
type CreateTokenBody ¶
type CreateTokenBody struct { // The client ID of your application that was generated when you [registered it](https://developer.sumup.com/docs/register-app). ClientId string `json:"client_id"` // The client secret of your application that was generated when you [registered it](https://developer.sumup.com/docs/register-app). ClientSecret string `json:"client_secret"` // The authorization code that you received from requesting an authorization code. Code string `json:"code"` // The grant type used for obtaining an access token. GrantType CreateTokenBodyGrantType `json:"grant_type"` // A **required** parameter when generating a refresh token. RefreshToken *string `json:"refresh_token,omitempty"` }
CreateTokenBody: Authorization token flow
type CreateTokenBodyGrantType ¶
type CreateTokenBodyGrantType string
CreateTokenBodyGrantType: The grant type used for obtaining an access token.
const ( CreateTokenBodyGrantTypeAuthorizationCode CreateTokenBodyGrantType = "authorization_code" CreateTokenBodyGrantTypeRefreshToken CreateTokenBodyGrantType = "refresh_token" )
type Currency ¶
type Currency string
Currency: Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported currency values are enumerated above.
const ( CurrencyBgn Currency = "BGN" CurrencyBrl Currency = "BRL" CurrencyChf Currency = "CHF" CurrencyClp Currency = "CLP" CurrencyCzk Currency = "CZK" CurrencyDkk Currency = "DKK" CurrencyEur Currency = "EUR" CurrencyGbp Currency = "GBP" CurrencyHrk Currency = "HRK" CurrencyHuf Currency = "HUF" CurrencyNok Currency = "NOK" CurrencyPln Currency = "PLN" CurrencyRon Currency = "RON" CurrencySek Currency = "SEK" CurrencyUsd Currency = "USD" )
type Customer ¶
type Customer struct { // Unique ID of the customer. CustomerId string `json:"customer_id"` // Personal details for the customer. PersonalDetails *PersonalDetails `json:"personal_details,omitempty"` }
Customer is a schema definition.
type CustomersService ¶
type CustomersService service
func (*CustomersService) Create ¶
func (s *CustomersService) Create(ctx context.Context, body CreateCustomerBody) (*Customer, error)
Create: Create a customer Creates a new saved customer resource which you can later manipulate and save payment instruments to.
func (*CustomersService) DeactivatePaymentInstrument ¶
func (s *CustomersService) DeactivatePaymentInstrument(ctx context.Context, customerId string, token string) (*DeactivatePaymentInstrument204Response, error)
DeactivatePaymentInstrument: Deactivate a payment instrument Deactivates an identified card payment instrument resource for a customer.
func (*CustomersService) Get ¶
Get: Retrieve a customer Retrieves an identified saved customer resource through the unique `customer_id` parameter, generated upon customer creation.
func (*CustomersService) ListPaymentInstruments ¶
func (s *CustomersService) ListPaymentInstruments(ctx context.Context, customerId string) (*ListPaymentInstruments200Response, error)
ListPaymentInstruments: List payment instruments Lists all payment instrument resources that are saved for an identified customer.
func (*CustomersService) Update ¶
func (s *CustomersService) Update(ctx context.Context, customerId string, body UpdateCustomerBody) (*Customer, error)
Update: Update a customer Updates an identified saved customer resource's personal details.
The request only overwrites the parameters included in the request, all other parameters will remain with their initially assigned values.
type DeactivateCheckout200Response ¶
type DeactivateCheckout200Response struct { // Amount of the payment. Amount *float64 `json:"amount,omitempty"` // Unique ID of the payment checkout specified by the client application when creating the checkout resource. // Max length: 90 CheckoutReference *string `json:"checkout_reference,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Date and time of the creation of the payment checkout. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. // // Read only Date *time.Time `json:"date,omitempty"` // Short description of the checkout visible in the SumUp dashboard. The description can contribute to reporting, allowing // easier identification of a checkout. Description *string `json:"description,omitempty"` // Unique ID of the checkout resource. // Read only Id *string `json:"id,omitempty"` // Unique identifying code of the merchant profile. MerchantCode *string `json:"merchant_code,omitempty"` // The merchant's country MerchantCountry *string `json:"merchant_country,omitempty"` // Merchant name MerchantName *string `json:"merchant_name,omitempty"` // Email address of the registered user (merchant) to whom the payment is made. It is highly recommended to // use `merchant_code` instead of `pay_to_email`. // Format: email PayToEmail *string `json:"pay_to_email,omitempty"` // Purpose of the checkout creation initially Purpose *DeactivateCheckout200ResponsePurpose `json:"purpose,omitempty"` // Current status of the checkout. // Read only Status *DeactivateCheckout200ResponseStatus `json:"status,omitempty"` // List of transactions related to the payment. // Read only // Unique items only Transactions *[]DeactivateCheckout200ResponseTransaction `json:"transactions,omitempty"` // Date and time of the checkout expiration before which the client application needs to send a processing request. // If no value is present, the checkout does not have an expiration time. // Read only ValidUntil *time.Time `json:"valid_until,omitempty"` }
DeactivateCheckout200Response: Details of the deleted checkout.
type DeactivateCheckout200ResponsePurpose ¶
type DeactivateCheckout200ResponsePurpose string
DeactivateCheckout200ResponsePurpose: Purpose of the checkout creation initially
const ( DeactivateCheckout200ResponsePurposeCheckout DeactivateCheckout200ResponsePurpose = "CHECKOUT" DeactivateCheckout200ResponsePurposeSetupRecurringPayment DeactivateCheckout200ResponsePurpose = "SETUP_RECURRING_PAYMENT" )
type DeactivateCheckout200ResponseStatus ¶
type DeactivateCheckout200ResponseStatus string
DeactivateCheckout200ResponseStatus: Current status of the checkout. Read only
const (
DeactivateCheckout200ResponseStatusExpired DeactivateCheckout200ResponseStatus = "EXPIRED"
)
type DeactivateCheckout200ResponseTransaction ¶
type DeactivateCheckout200ResponseTransaction struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments. AuthCode *string `json:"auth_code,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Entry mode of the payment details. EntryMode *DeactivateCheckout200ResponseTransactionEntryMode `json:"entry_mode,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Internal unique ID of the transaction on the SumUp platform. InternalId *int `json:"internal_id,omitempty"` // Unique code of the registered merchant to whom the payment is made. MerchantCode *string `json:"merchant_code,omitempty"` // Payment type used for the transaction. PaymentType *DeactivateCheckout200ResponseTransactionPaymentType `json:"payment_type,omitempty"` // Current status of the transaction. Status *DeactivateCheckout200ResponseTransactionStatus `json:"status,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Amount of the tip (out of the total transaction amount). TipAmount *float64 `json:"tip_amount,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` // Amount of the applicable VAT (out of the total transaction amount). VatAmount *float64 `json:"vat_amount,omitempty"` }
DeactivateCheckout200ResponseTransaction is a schema definition.
type DeactivateCheckout200ResponseTransactionEntryMode ¶
type DeactivateCheckout200ResponseTransactionEntryMode string
DeactivateCheckout200ResponseTransactionEntryMode: Entry mode of the payment details.
const ( DeactivateCheckout200ResponseTransactionEntryModeBoleto DeactivateCheckout200ResponseTransactionEntryMode = "BOLETO" DeactivateCheckout200ResponseTransactionEntryModeCustomerEntry DeactivateCheckout200ResponseTransactionEntryMode = "CUSTOMER_ENTRY" )
type DeactivateCheckout200ResponseTransactionPaymentType ¶
type DeactivateCheckout200ResponseTransactionPaymentType string
DeactivateCheckout200ResponseTransactionPaymentType: Payment type used for the transaction.
const ( DeactivateCheckout200ResponseTransactionPaymentTypeBoleto DeactivateCheckout200ResponseTransactionPaymentType = "BOLETO" DeactivateCheckout200ResponseTransactionPaymentTypeEcom DeactivateCheckout200ResponseTransactionPaymentType = "ECOM" DeactivateCheckout200ResponseTransactionPaymentTypeRecurring DeactivateCheckout200ResponseTransactionPaymentType = "RECURRING" )
type DeactivateCheckout200ResponseTransactionStatus ¶
type DeactivateCheckout200ResponseTransactionStatus string
DeactivateCheckout200ResponseTransactionStatus: Current status of the transaction.
const ( DeactivateCheckout200ResponseTransactionStatusCancelled DeactivateCheckout200ResponseTransactionStatus = "CANCELLED" DeactivateCheckout200ResponseTransactionStatusFailed DeactivateCheckout200ResponseTransactionStatus = "FAILED" DeactivateCheckout200ResponseTransactionStatusPending DeactivateCheckout200ResponseTransactionStatus = "PENDING" DeactivateCheckout200ResponseTransactionStatusSuccessful DeactivateCheckout200ResponseTransactionStatus = "SUCCESSFUL" )
type DeactivatePaymentInstrument204Response ¶
type DeactivatePaymentInstrument204Response struct { }
DeactivatePaymentInstrument204Response is a schema definition.
type DetailsError ¶
type DetailsError struct { // Details of the error. Details *string `json:"details,omitempty"` FailedConstraints *[]DetailsErrorFailedConstraint `json:"failed_constraints,omitempty"` // The status code. Status *float64 `json:"status,omitempty"` // Short title of the error. Title *string `json:"title,omitempty"` }
DetailsError: Error message structure.
func (*DetailsError) Error ¶
func (e *DetailsError) Error() string
type DetailsErrorFailedConstraint ¶
type DetailsErrorFailedConstraint struct { Message *string `json:"message,omitempty"` Reference *string `json:"reference,omitempty"` }
DetailsErrorFailedConstraint is a schema definition.
type DoingBusinessAs ¶
type DoingBusinessAs struct { Address *DoingBusinessAsAddress `json:"address,omitempty"` // Doing business as name BusinessName *string `json:"business_name,omitempty"` // Doing business as company registration number CompanyRegistrationNumber *string `json:"company_registration_number,omitempty"` // Doing business as email Email *string `json:"email,omitempty"` // Doing business as VAT ID VatId *string `json:"vat_id,omitempty"` // Doing business as website Website *string `json:"website,omitempty"` }
DoingBusinessAs: Doing Business As information
type DoingBusinessAsAddress ¶
type DoingBusinessAsAddress struct { // Address line 1 AddressLine1 *string `json:"address_line_1,omitempty"` // Address line 2 AddressLine2 *string `json:"address_line_2,omitempty"` // City City *string `json:"city,omitempty"` // Country ISO 3166-1 code Country *string `json:"country,omitempty"` // Postal code PostCode *string `json:"post_code,omitempty"` // Country region ID RegionId *float64 `json:"region_id,omitempty"` // Country region name RegionName *string `json:"region_name,omitempty"` }
DoingBusinessAsAddress is a schema definition.
type Error ¶
type Error struct { // Platform code for the error. ErrorCode *string `json:"error_code,omitempty"` // Short description of the error. Message *string `json:"message,omitempty"` }
Error: Error message structure.
type ErrorExtended ¶
type ErrorExtended struct { // Platform code for the error. ErrorCode *string `json:"error_code,omitempty"` // Short description of the error. Message *string `json:"message,omitempty"` // 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. Param *string `json:"param,omitempty"` }
ErrorExtended is a schema definition.
func (*ErrorExtended) Error ¶
func (e *ErrorExtended) Error() string
type ErrorForbidden ¶
type ErrorForbidden struct { // Platform code for the error. ErrorCode *string `json:"error_code,omitempty"` // Short description of the error. ErrorMessage *string `json:"error_message,omitempty"` // HTTP status code for the error. StatusCode *string `json:"status_code,omitempty"` }
ErrorForbidden: Error message for forbidden requests.
func (*ErrorForbidden) Error ¶
func (e *ErrorForbidden) Error() string
type Event ¶
type Event struct { // Amount of the event. Amount *AmountEvent `json:"amount,omitempty"` // Amount deducted for the event. DeductedAmount *float64 `json:"deducted_amount,omitempty"` // Amount of the fee deducted for the event. DeductedFeeAmount *float64 `json:"deducted_fee_amount,omitempty"` // Amount of the fee related to the event. FeeAmount *float64 `json:"fee_amount,omitempty"` // Unique ID of the transaction event. // Format: int64 Id *EventId `json:"id,omitempty"` // Consecutive number of the installment. InstallmentNumber *int `json:"installment_number,omitempty"` // Status of the transaction event. Status *EventStatus `json:"status,omitempty"` // Date and time of the transaction event. Timestamp *TimestampEvent `json:"timestamp,omitempty"` // Unique ID of the transaction. TransactionId *TransactionId `json:"transaction_id,omitempty"` // Type of the transaction event. Type *EventType `json:"type,omitempty"` }
Event is a schema definition.
type EventStatus ¶
type EventStatus string
EventStatus: Status of the transaction event.
const ( EventStatusFailed EventStatus = "FAILED" EventStatusPaidOut EventStatus = "PAID_OUT" EventStatusPending EventStatus = "PENDING" EventStatusRefunded EventStatus = "REFUNDED" EventStatusScheduled EventStatus = "SCHEDULED" EventStatusSuccessful EventStatus = "SUCCESSFUL" )
type FinancialPayout ¶
type FinancialPayout struct { Amount *float64 `json:"amount,omitempty"` Currency *string `json:"currency,omitempty"` // Format: date Date *Date `json:"date,omitempty"` Fee *float64 `json:"fee,omitempty"` Id *int `json:"id,omitempty"` Reference *string `json:"reference,omitempty"` Status *FinancialPayoutStatus `json:"status,omitempty"` TransactionCode *string `json:"transaction_code,omitempty"` Type *FinancialPayoutType `json:"type,omitempty"` }
FinancialPayout is a schema definition.
type FinancialPayoutStatus ¶
type FinancialPayoutStatus string
FinancialPayoutStatus is a schema definition.
const ( FinancialPayoutStatusFailed FinancialPayoutStatus = "FAILED" FinancialPayoutStatusSuccessful FinancialPayoutStatus = "SUCCESSFUL" )
type FinancialPayoutType ¶
type FinancialPayoutType string
FinancialPayoutType is a schema definition.
const ( FinancialPayoutTypeBalanceDeduction FinancialPayoutType = "BALANCE_DEDUCTION" FinancialPayoutTypeChargeBackDeduction FinancialPayoutType = "CHARGE_BACK_DEDUCTION" FinancialPayoutTypeDdReturnDeduction FinancialPayoutType = "DD_RETURN_DEDUCTION" FinancialPayoutTypePayout FinancialPayoutType = "PAYOUT" FinancialPayoutTypeRefundDeduction FinancialPayoutType = "REFUND_DEDUCTION" )
type FinancialPayouts ¶
type FinancialPayouts []FinancialPayout
FinancialPayouts is a schema definition.
type GetAccountParams ¶
type GetAccountParams struct { // A list of additional information you want to receive for the user. By default only personal and merchant profile // information will be returned. Include *[]string }
GetAccountParams: query parameters for GetAccount
func (*GetAccountParams) QueryValues ¶
func (p *GetAccountParams) QueryValues() url.Values
QueryValues converts GetAccountParams into url.Values.
type GetPaymentMethods200Response ¶
type GetPaymentMethods200Response struct {
AvailablePaymentMethods *[]GetPaymentMethods200ResponseAvailablePaymentMethod `json:"available_payment_methods,omitempty"`
}
GetPaymentMethods200Response is a schema definition.
type GetPaymentMethods200ResponseAvailablePaymentMethod ¶
type GetPaymentMethods200ResponseAvailablePaymentMethod struct { // The ID of the payment method. Id string `json:"id"` }
GetPaymentMethods200ResponseAvailablePaymentMethod is a schema definition.
type GetPaymentMethodsParams ¶
type GetPaymentMethodsParams struct { // The amount for which the payment methods should be eligible, in major units. Note that currency must also // be provided when filtering by amount. Amount *float64 // The currency for which the payment methods should be eligible. Currency *string }
GetPaymentMethodsParams: query parameters for GetPaymentMethods
func (*GetPaymentMethodsParams) QueryValues ¶
func (p *GetPaymentMethodsParams) QueryValues() url.Values
QueryValues converts GetPaymentMethodsParams into url.Values.
type GetReaderParams ¶
type GetReaderParams struct { // Return the reader only if it has been modified after the specified timestamp given in the headers. // // Timestamps are accepted in the following formats: // - HTTP Standard: [IMF format (RFC 5322)](https://www.rfc-editor.org/rfc/rfc5322#section-3.3), sometimes also // referred to as [RFC 7231](https://www.rfc-editor.org/rfc/rfc7231#section-7.1.1.1). // - RFC 3339: Used for timestamps in JSON payloads on this API. IfModifiedSince *string }
GetReaderParams: query parameters for GetReader
func (*GetReaderParams) QueryValues ¶
func (p *GetReaderParams) QueryValues() url.Values
QueryValues converts GetReaderParams into url.Values.
type GetReceiptParams ¶
type GetReceiptParams struct { // Merchant code. Mid string // The ID of the transaction event (refund). TxEventId *int }
GetReceiptParams: query parameters for GetReceipt
func (*GetReceiptParams) QueryValues ¶
func (p *GetReceiptParams) QueryValues() url.Values
QueryValues converts GetReceiptParams into url.Values.
type GetTransactionParams ¶
type GetTransactionParams struct { // Retrieves the transaction resource with the specified transaction ID (the `id` parameter in the transaction resource). Id *string // Retrieves the transaction resource with the specified internal transaction ID (the `internal_id` parameter in // the transaction resource). InternalId *string // Retrieves the transaction resource with the specified transaction code. TransactionCode *string }
GetTransactionParams: query parameters for GetTransaction
func (*GetTransactionParams) QueryValues ¶
func (p *GetTransactionParams) QueryValues() url.Values
QueryValues converts GetTransactionParams into url.Values.
type GetTransactionV21Params ¶
type GetTransactionV21Params struct { // Retrieves the transaction resource with the specified transaction ID (the `id` parameter in the transaction resource). Id *string // Retrieves the transaction resource with the specified internal transaction ID (the `internal_id` parameter in // the transaction resource). InternalId *string // Retrieves the transaction resource with the specified transaction code. TransactionCode *string }
GetTransactionV21Params: query parameters for GetTransactionV2.1
func (*GetTransactionV21Params) QueryValues ¶
func (p *GetTransactionV21Params) QueryValues() url.Values
QueryValues converts GetTransactionV21Params into url.Values.
type HorizontalAccuracy ¶
type HorizontalAccuracy float64
HorizontalAccuracy: Indication of the precision of the geographical position received from the payment terminal.
type Invite ¶
type Invite struct { // Email address of the invited user. // Format: email Email string `json:"email"` ExpiresAt time.Time `json:"expires_at"` }
Invite: Pending invitation for membership.
type Lat ¶
type Lat float64
Lat: Latitude value from the coordinates of the payment location (as received from the payment terminal reader).
Min: 0 Max: 90
type LegalType ¶
type LegalType struct { // Legal type short description Description *string `json:"description,omitempty"` // Legal type description FullDescription *string `json:"full_description,omitempty"` // Unique id Id *float64 `json:"id,omitempty"` // Sole trader legal type if true SoleTrader *bool `json:"sole_trader,omitempty"` }
LegalType: Id of the legal type of the merchant profile
type Link ¶
type Link struct { // URL for accessing the related resource. // Format: uri Href *string `json:"href,omitempty"` // Specifies the relation to the current resource. Rel *string `json:"rel,omitempty"` // Specifies the media type of the related resource. Type *string `json:"type,omitempty"` }
Link: Details of a link to a related resource.
type LinkRefund ¶
type LinkRefund struct { // URL for accessing the related resource. // Format: uri Href *string `json:"href,omitempty"` // Maximum allowed amount for the refund. MaxAmount *float64 `json:"max_amount,omitempty"` // Minimum allowed amount for the refund. MinAmount *float64 `json:"min_amount,omitempty"` // Specifies the relation to the current resource. Rel *string `json:"rel,omitempty"` // Specifies the media type of the related resource. Type *string `json:"type,omitempty"` }
LinkRefund is a schema definition.
type ListApikeysParams ¶
type ListApikeysParams struct { // Maximum number of keys to return. Limit *int // Offset of the first key to return. Offset *int }
ListApikeysParams: query parameters for ListAPIKeys
func (*ListApikeysParams) QueryValues ¶
func (p *ListApikeysParams) QueryValues() url.Values
QueryValues converts ListApikeysParams into url.Values.
type ListBankAccounts200Response ¶
type ListBankAccounts200Response []BankAccount
ListBankAccounts200Response is a schema definition.
type ListBankAccountsParams ¶
type ListBankAccountsParams struct { // If true only the primary bank account (the one used for payouts) will be returned. Primary *bool }
ListBankAccountsParams: query parameters for ListBankAccounts
func (*ListBankAccountsParams) QueryValues ¶
func (p *ListBankAccountsParams) QueryValues() url.Values
QueryValues converts ListBankAccountsParams into url.Values.
type ListBankAccountsV11200Response ¶
type ListBankAccountsV11200Response []BankAccount
ListBankAccountsV11200Response is a schema definition.
type ListBankAccountsV11Params ¶
type ListBankAccountsV11Params struct { // If true only the primary bank account (the one used for payouts) will be returned. Primary *bool }
ListBankAccountsV11Params: query parameters for ListBankAccountsV11
func (*ListBankAccountsV11Params) QueryValues ¶
func (p *ListBankAccountsV11Params) QueryValues() url.Values
QueryValues converts ListBankAccountsV11Params into url.Values.
type ListCheckouts200Response ¶
type ListCheckouts200Response []CheckoutSuccess
ListCheckouts200Response is a schema definition.
type ListCheckoutsParams ¶
type ListCheckoutsParams struct { // Filters the list of checkout resources by the unique ID of the checkout. CheckoutReference *string }
ListCheckoutsParams: query parameters for ListCheckouts
func (*ListCheckoutsParams) QueryValues ¶
func (p *ListCheckoutsParams) QueryValues() url.Values
QueryValues converts ListCheckoutsParams into url.Values.
type ListMerchantMembers200Response ¶
type ListMerchantMembers200Response struct { Items []Member `json:"items"` TotalCount *int `json:"total_count,omitempty"` }
ListMerchantMembers200Response is a schema definition.
type ListMerchantMembersParams ¶
type ListMerchantMembersParams struct { // Filter the returned users by email address prefix. Email *string // Maximum number of member to return. Limit *int // Offset of the first member to return. Offset *int // Filter the returned users by role. Roles *[]string // Indicates to skip count query. Scroll *bool // Filter the returned members by the membership status. Status *MembershipStatus }
ListMerchantMembersParams: query parameters for ListMerchantMembers
func (*ListMerchantMembersParams) QueryValues ¶
func (p *ListMerchantMembersParams) QueryValues() url.Values
QueryValues converts ListMerchantMembersParams into url.Values.
type ListPaymentInstruments200Response ¶
type ListPaymentInstruments200Response []PaymentInstrumentResponse
ListPaymentInstruments200Response is a schema definition.
type ListPayoutsParams ¶
type ListPayoutsParams struct { // End date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). EndDate Date Format *string Limit *int Order *string // Start date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). StartDate Date }
ListPayoutsParams: query parameters for ListPayouts
func (*ListPayoutsParams) QueryValues ¶
func (p *ListPayoutsParams) QueryValues() url.Values
QueryValues converts ListPayoutsParams into url.Values.
type ListReaders200Response ¶
type ListReaders200Response struct {
Items []Reader `json:"items"`
}
ListReaders200Response is a schema definition.
type ListSubAccounts200Response ¶
type ListSubAccounts200Response []Operator
ListSubAccounts200Response is a schema definition.
type ListSubAccountsParams ¶
type ListSubAccountsParams struct { // If true the list of operators will include also the primary user. IncludePrimary *bool // Search query used to filter users that match given query term. // // Current implementation allow querying only over the email address. // All operators whos email address contains the query string are returned. Query *string }
ListSubAccountsParams: query parameters for ListSubAccounts
func (*ListSubAccountsParams) QueryValues ¶
func (p *ListSubAccountsParams) QueryValues() url.Values
QueryValues converts ListSubAccountsParams into url.Values.
type ListTransactions200Response ¶
type ListTransactions200Response struct { Items *[]TransactionHistory `json:"items,omitempty"` Links *[]Link `json:"links,omitempty"` }
ListTransactions200Response is a schema definition.
type ListTransactionsParams ¶
type ListTransactionsParams struct { // Filters the results by the latest modification time of resources and returns only transactions that are modified // *at or after* the specified timestamp (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). ChangesSince *time.Time // Specifies the maximum number of results per page. Value must be a positive integer and if not specified, will // return 10 results. Limit *int // Filters the results by the reference ID of transaction events and returns only transactions with events whose // IDs are *smaller* than the specified value. This parameters supersedes the `newest_time` parameter (if both // are provided in the request). NewestRef *string // Filters the results by the creation time of resources and returns only transactions that are created *before* // the specified timestamp (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). NewestTime *time.Time // Filters the results by the reference ID of transaction events and returns only transactions with events whose // IDs are *greater* than the specified value. This parameters supersedes the `oldest_time` parameter (if both // are provided in the request). OldestRef *string // Filters the results by the creation time of resources and returns only transactions that are created *at // or after* the specified timestamp (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). OldestTime *time.Time // Specifies the order in which the returned results are displayed. Order *string // Filters the returned results by the specified list of payment types used for the transactions. PaymentTypes *[]string // Filters the returned results by the specified list of final statuses of the transactions. Statuses *[]string // Retrieves the transaction resource with the specified transaction code. TransactionCode *string // Filters the returned results by the specified list of transaction types. Types *[]string // Filters the returned results by user email. Users *[]string }
ListTransactionsParams: query parameters for ListTransactions
func (*ListTransactionsParams) QueryValues ¶
func (p *ListTransactionsParams) QueryValues() url.Values
QueryValues converts ListTransactionsParams into url.Values.
type ListTransactionsV21200Response ¶
type ListTransactionsV21200Response struct { Items *[]TransactionHistory `json:"items,omitempty"` Links *[]Link `json:"links,omitempty"` }
ListTransactionsV21200Response is a schema definition.
type ListTransactionsV21Params ¶
type ListTransactionsV21Params struct { // Filters the results by the latest modification time of resources and returns only transactions that are modified // *at or after* the specified timestamp (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). ChangesSince *time.Time // Specifies the maximum number of results per page. Value must be a positive integer and if not specified, will // return 10 results. Limit *int // Filters the results by the reference ID of transaction events and returns only transactions with events whose // IDs are *smaller* than the specified value. This parameters supersedes the `newest_time` parameter (if both // are provided in the request). NewestRef *string // Filters the results by the creation time of resources and returns only transactions that are created *before* // the specified timestamp (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). NewestTime *time.Time // Filters the results by the reference ID of transaction events and returns only transactions with events whose // IDs are *greater* than the specified value. This parameters supersedes the `oldest_time` parameter (if both // are provided in the request). OldestRef *string // Filters the results by the creation time of resources and returns only transactions that are created *at // or after* the specified timestamp (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format). OldestTime *time.Time // Specifies the order in which the returned results are displayed. Order *string // Filters the returned results by the specified list of payment types used for the transactions. PaymentTypes *[]string // Filters the returned results by the specified list of final statuses of the transactions. Statuses *[]string // Retrieves the transaction resource with the specified transaction code. TransactionCode *string // Filters the returned results by the specified list of transaction types. Types *[]string // Filters the returned results by user email. Users *[]string }
ListTransactionsV21Params: query parameters for ListTransactionsV2.1
func (*ListTransactionsV21Params) QueryValues ¶
func (p *ListTransactionsV21Params) QueryValues() url.Values
QueryValues converts ListTransactionsV21Params into url.Values.
type Lon ¶
type Lon float64
Lon: Longitude value from the coordinates of the payment location (as received from the payment terminal reader).
Min: 0 Max: 180
type MandatePayload ¶
type MandatePayload struct { // Indicates the mandate type Type MandatePayloadType `json:"type"` // Operating system and web client used by the end-user UserAgent string `json:"user_agent"` // IP address of the end user. Supports IPv4 and IPv6 UserIp *string `json:"user_ip,omitempty"` }
MandatePayload: Mandate is passed when a card is to be tokenized
type MandatePayloadType ¶
type MandatePayloadType string
MandatePayloadType: Indicates the mandate type
const (
MandatePayloadTypeRecurrent MandatePayloadType = "recurrent"
)
type MandateResponse ¶
type MandateResponse struct { // Merchant code which has the mandate MerchantCode *string `json:"merchant_code,omitempty"` // Mandate status Status *string `json:"status,omitempty"` // Indicates the mandate type Type *string `json:"type,omitempty"` }
MandateResponse: Created mandate
type Member ¶
type Member struct { // Object attributes that modifiable only by SumUp applications. Attributes *Attributes `json:"attributes,omitempty"` CreatedAt time.Time `json:"created_at"` // ID of the member. Id string `json:"id"` // Pending invitation for membership. Invite *Invite `json:"invite,omitempty"` // Set of user-defined key-value pairs attached to the object. Partial updates are not supported. When updating, always // submit whole metadata. Metadata *Metadata `json:"metadata,omitempty"` // User's permissions. Permissions []string `json:"permissions"` // User's roles. Roles []string `json:"roles"` Status MembershipStatus `json:"status"` UpdatedAt time.Time `json:"updated_at"` // User information. User *MembershipUser `json:"user,omitempty"` }
Member: A member is user within specific resource identified by resource id, resource type, and associated roles.
type MembersService ¶
type MembersService service
func (*MembersService) Create ¶
func (s *MembersService) Create(ctx context.Context, merchantCode string, body CreateMerchantMemberBody) (*Member, error)
Create: Create a merchant member.
func (*MembersService) Get ¶
func (s *MembersService) Get(ctx context.Context, merchantCode string, memberId string) (*Member, error)
Get: Get merchant member Returns merchant member details.
func (*MembersService) List ¶
func (s *MembersService) List(ctx context.Context, merchantCode string, params ListMerchantMembersParams) (*ListMerchantMembers200Response, error)
List: List members Lists merchant members with their roles and permissions.
func (*MembersService) Update ¶
func (s *MembersService) Update(ctx context.Context, merchantCode string, memberId string, body UpdateMerchantMemberBody) (*Member, error)
Update: Update merchant member Update assigned roles of the member.
type MembershipStatus ¶
type MembershipStatus string
MembershipStatus is a schema definition.
const ( MembershipStatusAccepted MembershipStatus = "accepted" MembershipStatusDisabled MembershipStatus = "disabled" MembershipStatusExpired MembershipStatus = "expired" MembershipStatusPending MembershipStatus = "pending" MembershipStatusUnknown MembershipStatus = "unknown" )
type MembershipUser ¶
type MembershipUser struct { // Classic identifiers of the user. Classic *MembershipUserClassic `json:"classic,omitempty"` // Time when the user has been disabled. Applies only to virtual users (`virtual_user: true`). DisabledAt *time.Time `json:"disabled_at,omitempty"` // 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. Email string `json:"email"` // Identifier for the End-User (also called Subject). Id string `json:"id"` // True if the user has enabled MFA on login. MfaOnLoginEnabled bool `json:"mfa_on_login_enabled"` // User's preferred name. Used for display purposes only. Nickname *string `json:"nickname,omitempty"` // 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. // Format: uri Picture *string `json:"picture,omitempty"` // True if the user is a virtual user (operator). VirtualUser bool `json:"virtual_user"` }
MembershipUser: User information.
type MembershipUserClassic ¶
type MembershipUserClassic struct { // Format: int32 UserId int `json:"user_id"` }
MembershipUserClassic: Classic identifiers of the user.
type MembershipsService ¶
type MembershipsService service
type MerchantAccount ¶
type MerchantAccount struct { // Profile information. Account *Account `json:"account,omitempty"` // Mobile app settings AppSettings *AppSettings `json:"app_settings,omitempty"` // Merchant comes from payleven BR migration IsMigratedPaylevenBr *bool `json:"is_migrated_payleven_br,omitempty"` // Account's merchant profile MerchantProfile *MerchantProfile `json:"merchant_profile,omitempty"` // User permissions Permissions *Permissions `json:"permissions,omitempty"` // Account's personal profile. PersonalProfile *PersonalProfile `json:"personal_profile,omitempty"` }
MerchantAccount: Details of the merchant account.
type MerchantProfile ¶
type MerchantProfile struct { // Details of the registered address. Address *AddressWithDetails `json:"address,omitempty"` BankAccounts *[]BankAccount `json:"bank_accounts,omitempty"` // Business owners information. BusinessOwners *BusinessOwners `json:"business_owners,omitempty"` // Company name CompanyName *string `json:"company_name,omitempty"` // Company registration number CompanyRegistrationNumber *string `json:"company_registration_number,omitempty"` // Merchant country code formatted according to [ISO3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) (for // internal usage only) Country *string `json:"country,omitempty"` // Doing Business As information DoingBusinessAs *DoingBusinessAs `json:"doing_business_as,omitempty"` // True if the merchant is extdev Extdev *bool `json:"extdev,omitempty"` // Id of the legal type of the merchant profile LegalType *LegalType `json:"legal_type,omitempty"` // Merchant locale (for internal usage only) Locale *string `json:"locale,omitempty"` // Merchant category code MerchantCategoryCode *string `json:"merchant_category_code,omitempty"` // Unique identifying code of the merchant profile MerchantCode *string `json:"merchant_code,omitempty"` // Mobile phone number MobilePhone *string `json:"mobile_phone,omitempty"` // Nature and purpose of the business NatureAndPurpose *string `json:"nature_and_purpose,omitempty"` // True if the payout zone of this merchant is migrated PayoutZoneMigrated *bool `json:"payout_zone_migrated,omitempty"` // Permanent certificate access code (Portugal) PermanentCertificateAccessCode *string `json:"permanent_certificate_access_code,omitempty"` // Merchant settings (like \"payout_type\", \"payout_period\") Settings *MerchantSettings `json:"settings,omitempty"` // Vat ID VatId *string `json:"vat_id,omitempty"` // Merchant VAT rates VatRates *VatRates `json:"vat_rates,omitempty"` // Website Website *string `json:"website,omitempty"` }
MerchantProfile: Account's merchant profile
type MerchantService ¶
type MerchantService service
func (*MerchantService) Get ¶
func (s *MerchantService) Get(ctx context.Context, params GetAccountParams) (*MerchantAccount, error)
Get: Retrieve a profile Returns user profile information.
func (*MerchantService) GetDoingBusinessAs ¶
func (s *MerchantService) GetDoingBusinessAs(ctx context.Context) (*DoingBusinessAs, error)
GetDoingBusinessAs: Retrieve DBA Retrieves Doing Business As profile.
func (*MerchantService) GetMerchantProfile ¶
func (s *MerchantService) GetMerchantProfile(ctx context.Context) (*MerchantProfile, error)
GetMerchantProfile: Retrieve a merchant profile Retrieves merchant profile data.
func (*MerchantService) GetPersonalProfile ¶
func (s *MerchantService) GetPersonalProfile(ctx context.Context) (*PersonalProfile, error)
GetPersonalProfile: Retrieve a personal profile Retrieves personal profile data.
func (*MerchantService) GetSettings ¶
func (s *MerchantService) GetSettings(ctx context.Context) (*MerchantSettings, error)
GetSettings: Get settings Retrieves merchant settings.
func (*MerchantService) ListBankAccounts ¶
func (s *MerchantService) ListBankAccounts(ctx context.Context, merchantCode string, params ListBankAccountsV11Params) (*ListBankAccountsV11200Response, error)
ListBankAccounts: List bank accounts Retrieves bank accounts of the merchant.
func (*MerchantService) ListBankAccountsDeprecated ¶
func (s *MerchantService) ListBankAccountsDeprecated(ctx context.Context, params ListBankAccountsParams) (*ListBankAccounts200Response, error)
ListBankAccountsDeprecated: List bank accounts Retrieves bank accounts of the merchant.
type MerchantSettings ¶
type MerchantSettings struct { // Whether merchant will receive daily payout emails DailyPayoutEmail *bool `json:"daily_payout_email,omitempty"` // Whether merchant has gross settlement enabled GrossSettlement *bool `json:"gross_settlement,omitempty"` // Whether merchant will receive monthly payout emails MonthlyPayoutEmail *bool `json:"monthly_payout_email,omitempty"` // Whether merchant can make MOTO payments MotoPayment *MerchantSettingsMotoPayment `json:"moto_payment,omitempty"` // Payout Instrument PayoutInstrument *string `json:"payout_instrument,omitempty"` // Whether merchant will receive payouts on demand PayoutOnDemand *bool `json:"payout_on_demand,omitempty"` // Whether merchant can edit payouts on demand PayoutOnDemandAvailable *bool `json:"payout_on_demand_available,omitempty"` // Payout frequency PayoutPeriod *string `json:"payout_period,omitempty"` // Payout type PayoutType *string `json:"payout_type,omitempty"` // Whether to show printers in mobile app PrintersEnabled *bool `json:"printers_enabled,omitempty"` // Stone merchant code StoneMerchantCode *string `json:"stone_merchant_code,omitempty"` // Whether to show tax in receipts (saved per transaction) TaxEnabled *bool `json:"tax_enabled,omitempty"` }
MerchantSettings: Merchant settings (like \"payout_type\", \"payout_period\")
type MerchantSettingsMotoPayment ¶
type MerchantSettingsMotoPayment string
MerchantSettingsMotoPayment: Whether merchant can make MOTO payments
const ( MerchantSettingsMotoPaymentEnforced MerchantSettingsMotoPayment = "ENFORCED" MerchantSettingsMotoPaymentOff MerchantSettingsMotoPayment = "OFF" MerchantSettingsMotoPaymentOn MerchantSettingsMotoPayment = "ON" )
type Metadata ¶
Metadata: Set of user-defined key-value pairs attached to the object. Partial updates are not supported. When updating, always submit whole metadata.
type Oauth2Scope ¶
type Oauth2Scope string
Oauth2Scope is a schema definition.
const ( Oauth2ScopeAccountingRead Oauth2Scope = "accounting.read" Oauth2ScopeAccountingWrite Oauth2Scope = "accounting.write" Oauth2ScopeEmail Oauth2Scope = "email" Oauth2ScopeInvoicesRead Oauth2Scope = "invoices.read" Oauth2ScopeInvoicesWrite Oauth2Scope = "invoices.write" Oauth2ScopePaymentInstruments Oauth2Scope = "payment_instruments" Oauth2ScopePayments Oauth2Scope = "payments" Oauth2ScopeProducts Oauth2Scope = "products" Oauth2ScopeProfile Oauth2Scope = "profile" Oauth2ScopeReadersRead Oauth2Scope = "readers.read" Oauth2ScopeReadersWrite Oauth2Scope = "readers.write" Oauth2ScopeTransactionsHistory Oauth2Scope = "transactions.history" Oauth2ScopeUserAppSettings Oauth2Scope = "user.app-settings" Oauth2ScopeUserPayoutSettings Oauth2Scope = "user.payout-settings" Oauth2ScopeUserProfile Oauth2Scope = "user.profile" Oauth2ScopeUserProfileReadonly Oauth2Scope = "user.profile_readonly" Oauth2ScopeUserSubaccounts Oauth2Scope = "user.subaccounts" )
type Oauth2Scopes ¶
type Oauth2Scopes []Oauth2Scope
Oauth2Scopes is a schema definition. Max items: 128
type Operator ¶
type Operator struct { AccountType OperatorAccountType `json:"account_type"` CreatedAt time.Time `json:"created_at"` Disabled bool `json:"disabled"` // Format: int32 Id int `json:"id"` Nickname *string `json:"nickname,omitempty"` Permissions OperatorPermissions `json:"permissions"` UpdatedAt time.Time `json:"updated_at"` Username string `json:"username"` }
Operator is a schema definition.
type OperatorAccountType ¶
type OperatorAccountType string
OperatorAccountType is a schema definition.
const ( OperatorAccountTypeNormal OperatorAccountType = "normal" OperatorAccountTypeOperator OperatorAccountType = "operator" )
type OperatorPermissions ¶
type OperatorPermissions struct { Admin bool `json:"admin"` CreateMotoPayments bool `json:"create_moto_payments"` CreateReferral bool `json:"create_referral"` FullTransactionHistoryView bool `json:"full_transaction_history_view"` RefundTransactions bool `json:"refund_transactions"` }
OperatorPermissions is a schema definition.
type PaymentInstrumentResponse ¶
type PaymentInstrumentResponse struct { // Indicates whether the payment instrument is active and can be used for payments. To deactivate it, send a // `DELETE` request to the resource endpoint. // Read only // Default: true Active *bool `json:"active,omitempty"` // Details of the payment card. Card *PaymentInstrumentResponseCard `json:"card,omitempty"` // Creation date of payment instrument. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. CreatedAt *time.Time `json:"created_at,omitempty"` // Created mandate Mandate *MandateResponse `json:"mandate,omitempty"` // Unique token identifying the saved payment card for a customer. // Read only Token *string `json:"token,omitempty"` // Type of the payment instrument. Type *PaymentInstrumentResponseType `json:"type,omitempty"` }
PaymentInstrumentResponse: Payment Instrument Response
type PaymentInstrumentResponseCard ¶
type PaymentInstrumentResponseCard struct { // Last 4 digits of the payment card number. // Read only // Min length: 4 // Max length: 4 Last4Digits *string `json:"last_4_digits,omitempty"` // Issuing card network of the payment card. // Read only Type *PaymentInstrumentResponseCardType `json:"type,omitempty"` }
PaymentInstrumentResponseCard: Details of the payment card.
type PaymentInstrumentResponseCardType ¶
type PaymentInstrumentResponseCardType string
PaymentInstrumentResponseCardType: Issuing card network of the payment card. Read only
const ( PaymentInstrumentResponseCardTypeAmex PaymentInstrumentResponseCardType = "AMEX" PaymentInstrumentResponseCardTypeCup PaymentInstrumentResponseCardType = "CUP" PaymentInstrumentResponseCardTypeDiners PaymentInstrumentResponseCardType = "DINERS" PaymentInstrumentResponseCardTypeDiscover PaymentInstrumentResponseCardType = "DISCOVER" PaymentInstrumentResponseCardTypeElo PaymentInstrumentResponseCardType = "ELO" PaymentInstrumentResponseCardTypeElv PaymentInstrumentResponseCardType = "ELV" PaymentInstrumentResponseCardTypeHipercard PaymentInstrumentResponseCardType = "HIPERCARD" PaymentInstrumentResponseCardTypeJcb PaymentInstrumentResponseCardType = "JCB" PaymentInstrumentResponseCardTypeMaestro PaymentInstrumentResponseCardType = "MAESTRO" PaymentInstrumentResponseCardTypeMastercard PaymentInstrumentResponseCardType = "MASTERCARD" PaymentInstrumentResponseCardTypeUnknown PaymentInstrumentResponseCardType = "UNKNOWN" PaymentInstrumentResponseCardTypeVisa PaymentInstrumentResponseCardType = "VISA" PaymentInstrumentResponseCardTypeVisaElectron PaymentInstrumentResponseCardType = "VISA_ELECTRON" PaymentInstrumentResponseCardTypeVisaVpay PaymentInstrumentResponseCardType = "VISA_VPAY" )
type PaymentInstrumentResponseType ¶
type PaymentInstrumentResponseType string
PaymentInstrumentResponseType: Type of the payment instrument.
const (
PaymentInstrumentResponseTypeCard PaymentInstrumentResponseType = "card"
)
type PayoutsService ¶
type PayoutsService service
func (*PayoutsService) List ¶
func (s *PayoutsService) List(ctx context.Context, params ListPayoutsParams) (*FinancialPayouts, error)
List: List payouts Lists ordered payouts for the merchant profile.
type Permissions ¶
type Permissions struct { // Create MOTO payments CreateMotoPayments *bool `json:"create_moto_payments,omitempty"` // Create referral CreateReferral *bool `json:"create_referral,omitempty"` // Can view full merchant transaction history FullTransactionHistoryView *bool `json:"full_transaction_history_view,omitempty"` // Refund transactions RefundTransactions *bool `json:"refund_transactions,omitempty"` }
Permissions: User permissions
type PersonalDetails ¶
type PersonalDetails struct { // Profile's personal address information. Address *Address `json:"address,omitempty"` // Date of birth of the customer. // Format: date Birthdate *Date `json:"birthdate,omitempty"` // Email address of the customer. Email *string `json:"email,omitempty"` // First name of the customer. FirstName *string `json:"first_name,omitempty"` // Last name of the customer. LastName *string `json:"last_name,omitempty"` // Phone number of the customer. Phone *string `json:"phone,omitempty"` }
PersonalDetails: Personal details for the customer.
type PersonalProfile ¶
type PersonalProfile struct { // Details of the registered address. Address *AddressWithDetails `json:"address,omitempty"` Complete *bool `json:"complete,omitempty"` // Date of birth DateOfBirth *string `json:"date_of_birth,omitempty"` // First name of the user FirstName *string `json:"first_name,omitempty"` // Last name of the user LastName *string `json:"last_name,omitempty"` // Mobile phone number MobilePhone *string `json:"mobile_phone,omitempty"` }
PersonalProfile: Account's personal profile.
type ProcessCheckout400Response ¶
type ProcessCheckout400Response json.RawMessage
ProcessCheckout400Response is a schema definition.
func (*ProcessCheckout400Response) Error ¶
func (e *ProcessCheckout400Response) Error() string
type ProcessCheckoutBody ¶
type ProcessCheckoutBody struct { // __Required when payment type is `card`.__ Details of the payment card. Card *Card `json:"card,omitempty"` // __Required when `token` is provided.__ Unique ID of the customer. CustomerId *string `json:"customer_id,omitempty"` // Number of installments for deferred payments. Available only to merchant users in Brazil. // Min: 1 // Max: 12 Installments *int `json:"installments,omitempty"` // Mandate is passed when a card is to be tokenized Mandate *MandatePayload `json:"mandate,omitempty"` PaymentType ProcessCheckoutBodyPaymentType `json:"payment_type"` // __Required when using a tokenized card to process a checkout.__ Unique token identifying the saved payment card // for a customer. Token *string `json:"token,omitempty"` }
ProcessCheckoutBody: Details of the payment instrument for processing the checkout.
type ProcessCheckoutBodyPaymentType ¶
type ProcessCheckoutBodyPaymentType string
ProcessCheckoutBodyPaymentType is a schema definition.
const ( ProcessCheckoutBodyPaymentTypeBancontact ProcessCheckoutBodyPaymentType = "bancontact" ProcessCheckoutBodyPaymentTypeBlik ProcessCheckoutBodyPaymentType = "blik" ProcessCheckoutBodyPaymentTypeBoleto ProcessCheckoutBodyPaymentType = "boleto" ProcessCheckoutBodyPaymentTypeCard ProcessCheckoutBodyPaymentType = "card" ProcessCheckoutBodyPaymentTypeIdeal ProcessCheckoutBodyPaymentType = "ideal" )
type Product ¶
type Product struct { // Name of the product from the merchant's catalog. Name *string `json:"name,omitempty"` // Price of the product without VAT. Price *float64 `json:"price,omitempty"` // Price of a single product item with VAT. PriceWithVat *float64 `json:"price_with_vat,omitempty"` // Number of product items for the purchase. Quantity *float64 `json:"quantity,omitempty"` // Amount of the VAT for a single product item (calculated as the product of `price` and `vat_rate`, i.e. `single_vat_amount // = price * vat_rate`). SingleVatAmount *float64 `json:"single_vat_amount,omitempty"` // Total price of the product items without VAT (calculated as the product of `price` and `quantity`, i.e. `total_price // = price * quantity`). TotalPrice *float64 `json:"total_price,omitempty"` // Total price of the product items including VAT (calculated as the product of `price_with_vat` and `quantity`, i.e. // `total_with_vat = price_with_vat * quantity`). TotalWithVat *float64 `json:"total_with_vat,omitempty"` // Total VAT amount for the purchase (calculated as the product of `single_vat_amount` and `quantity`, i.e. `vat_amount // = single_vat_amount * quantity`). VatAmount *float64 `json:"vat_amount,omitempty"` // VAT rate applicable to the product. VatRate *float64 `json:"vat_rate,omitempty"` }
Product: Details of the product for which the payment is made.
type Reader ¶
type Reader struct { // Reader creation timestamp. CreatedAt time.Time `json:"created_at"` // Information about the underlying physical device. Device ReaderDevice `json:"device"` // Unique identifier of the object. // // Note that this identifies the instance of the physical devices pairing with your SumUp account. // // If you DELETE a reader, and pair the device again, the ID will be different. Do not use this ID to refer to // a physical device. // Min length: 30 // Max length: 30 Id ReaderId `json:"id"` // Set of user-defined key-value pairs attached to the object. // Max properties: 50 Meta *Meta `json:"meta,omitempty"` // Custom human-readable, user-defined name for easier identification of the reader. // Max length: 500 Name ReaderName `json:"name"` // The status of the reader object gives information about the current state of the reader. // // Possible values: // // - `unknown` - The reader status is unknown. // - `processing` - The reader is created and waits for the physical device to confirm the pairing. // - `paired` - The reader is paired with a merchant account and can be used with SumUp APIs. // - `expired` - The pairing is expired and no longer usable with the account. The resource needs to get recreated Status ReaderStatus `json:"status"` // Reader last-modification timestamp. UpdatedAt time.Time `json:"updated_at"` }
Reader: A physical card reader device that can accept in-person payments.
type ReaderDevice ¶
type ReaderDevice struct { // A unique identifier of the physical device (e.g. serial number). Identifier string `json:"identifier"` // Identifier of the model of the device. Model ReaderDeviceModel `json:"model"` }
ReaderDevice: Information about the underlying physical device.
type ReaderDeviceModel ¶
type ReaderDeviceModel string
ReaderDeviceModel: Identifier of the model of the device.
const ( ReaderDeviceModelSolo ReaderDeviceModel = "solo" ReaderDeviceModelVirtualSolo ReaderDeviceModel = "virtual-solo" )
type ReaderId ¶
type ReaderId string
ReaderId: Unique identifier of the object.
Note that this identifies the instance of the physical devices pairing with your SumUp account.
If you DELETE a reader, and pair the device again, the ID will be different. Do not use this ID to refer to a physical device.
Min length: 30 Max length: 30
type ReaderName ¶
type ReaderName string
ReaderName: Custom human-readable, user-defined name for easier identification of the reader.
Max length: 500
type ReaderPairingCode ¶
type ReaderPairingCode string
ReaderPairingCode: 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.
Min length: 8 Max length: 9
type ReaderStatus ¶
type ReaderStatus string
ReaderStatus: The status of the reader object gives information about the current state of the reader.
Possible values:
- `unknown` - The reader status is unknown. - `processing` - The reader is created and waits for the physical device to confirm the pairing. - `paired` - The reader is paired with a merchant account and can be used with SumUp APIs. - `expired` - The pairing is expired and no longer usable with the account. The resource needs to get recreated
const ( ReaderStatusExpired ReaderStatus = "expired" ReaderStatusPaired ReaderStatus = "paired" ReaderStatusProcessing ReaderStatus = "processing" ReaderStatusUnknown ReaderStatus = "unknown" )
type ReadersService ¶
type ReadersService service
func (*ReadersService) Create ¶
func (s *ReadersService) Create(ctx context.Context, merchantCode string, body CreateReaderBody) (*Reader, error)
Create: Create a Reader Create a new reader linked to the merchant account.
func (*ReadersService) CreateCheckout ¶
func (s *ReadersService) CreateCheckout(ctx context.Context, merchantCode string, id string, body CreateReaderCheckoutBody) (*CreateReaderCheckout201Response, error)
CreateCheckout: Create a Reader Checkout Create a Checkout for a Reader.
This process is asynchronous and the actual transaction may take some time to be stared on the device.
There are some caveats when using this endpoint: * The target device must be online, otherwise checkout won't be accepted * After the checkout is accepted, the system has 60 seconds to start the payment on the target device. During this time, any other checkout for the same device will be rejected.
**Note**: If the target device is a Solo, it must be in version 3.3.24.3 or higher.
func (*ReadersService) DeleteReader ¶
DeleteReader: Delete a reader Deletes a Reader.
func (*ReadersService) Get ¶
func (s *ReadersService) Get(ctx context.Context, merchantCode string, id ReaderId, params GetReaderParams) (*Reader, error)
Get: Retrieve a Reader Gets a Reader.
func (*ReadersService) List ¶
func (s *ReadersService) List(ctx context.Context, merchantCode string) (*ListReaders200Response, error)
List: List Readers Returns list of all readers of the merchant.
func (*ReadersService) TerminateCheckout ¶
func (s *ReadersService) TerminateCheckout(ctx context.Context, merchantCode string, id string) error
TerminateCheckout: Create a Reader Terminate action Create a Terminate action for a Reader.
It stops the current transaction on the target device.
This process is asynchronous and the actual termination may take some time to be performed on the device.
There are some caveats when using this endpoint: * The target device must be online, otherwise terminate won't be accepted * The action will succeed only if the device is waiting for cardholder action: e.g: waiting for card, waiting for PIN, etc. * There is no confirmation of the termination.
If a transaction is successfully terminated and `return_url` was provided on Checkout, the transaction status will be sent as `failed` to the provided URL.
**Note**: If the target device is a Solo, it must be in version 3.3.28.0 or higher.
func (*ReadersService) Update ¶
func (s *ReadersService) Update(ctx context.Context, merchantCode string, id ReaderId, body UpdateReaderBody) error
Update: Update a Reader Updates a Reader.
type Receipt ¶
type Receipt struct { AcquirerData *ReceiptAcquirerData `json:"acquirer_data,omitempty"` EmvData *ReceiptEmvData `json:"emv_data,omitempty"` // Receipt merchant data MerchantData *ReceiptMerchantData `json:"merchant_data,omitempty"` // Transaction information. TransactionData *ReceiptTransaction `json:"transaction_data,omitempty"` }
Receipt is a schema definition.
type ReceiptAcquirerData ¶
type ReceiptAcquirerData struct { AuthorizationCode *string `json:"authorization_code,omitempty"` LocalTime *string `json:"local_time,omitempty"` ReturnCode *string `json:"return_code,omitempty"` Tid *string `json:"tid,omitempty"` }
ReceiptAcquirerData is a schema definition.
type ReceiptCard ¶
type ReceiptCard struct { // Card last 4 digits. Last4Digits *string `json:"last_4_digits,omitempty"` // Card Scheme. Type *string `json:"type,omitempty"` }
ReceiptCard is a schema definition.
type ReceiptEvent ¶
type ReceiptEvent struct { // Amount of the event. Amount *AmountEvent `json:"amount,omitempty"` // Unique ID of the transaction event. // Format: int64 Id *EventId `json:"id,omitempty"` ReceiptNo *string `json:"receipt_no,omitempty"` // Status of the transaction event. Status *EventStatus `json:"status,omitempty"` // Date and time of the transaction event. Timestamp *TimestampEvent `json:"timestamp,omitempty"` // Unique ID of the transaction. TransactionId *TransactionId `json:"transaction_id,omitempty"` // Type of the transaction event. Type *EventType `json:"type,omitempty"` }
ReceiptEvent is a schema definition.
type ReceiptMerchantData ¶
type ReceiptMerchantData struct { Locale *string `json:"locale,omitempty"` MerchantProfile *ReceiptMerchantDataMerchantProfile `json:"merchant_profile,omitempty"` }
ReceiptMerchantData: Receipt merchant data
type ReceiptMerchantDataMerchantProfile ¶
type ReceiptMerchantDataMerchantProfile struct { Address *ReceiptMerchantDataMerchantProfileAddress `json:"address,omitempty"` BusinessName *string `json:"business_name,omitempty"` Email *string `json:"email,omitempty"` MerchantCode *string `json:"merchant_code,omitempty"` }
ReceiptMerchantDataMerchantProfile is a schema definition.
type ReceiptMerchantDataMerchantProfileAddress ¶
type ReceiptMerchantDataMerchantProfileAddress struct { AddressLine1 *string `json:"address_line_1,omitempty"` City *string `json:"city,omitempty"` Country *string `json:"country,omitempty"` CountryEnName *string `json:"country_en_name,omitempty"` CountryNativeName *string `json:"country_native_name,omitempty"` Landline *string `json:"landline,omitempty"` PostCode *string `json:"post_code,omitempty"` }
ReceiptMerchantDataMerchantProfileAddress is a schema definition.
type ReceiptTransaction ¶
type ReceiptTransaction struct { // Transaction amount. Amount *string `json:"amount,omitempty"` Card *ReceiptCard `json:"card,omitempty"` // Transaction currency. Currency *string `json:"currency,omitempty"` // Transaction entry mode. EntryMode *string `json:"entry_mode,omitempty"` // Events Events *[]ReceiptEvent `json:"events,omitempty"` // Number of installments. InstallmentsCount *int `json:"installments_count,omitempty"` // Transaction type. PaymentType *string `json:"payment_type,omitempty"` // Products Products *[]ReceiptTransactionProduct `json:"products,omitempty"` // Receipt number ReceiptNo *string `json:"receipt_no,omitempty"` // Transaction processing status. Status *string `json:"status,omitempty"` // Time created at. Timestamp *time.Time `json:"timestamp,omitempty"` // Tip amount (included in transaction amount). TipAmount *string `json:"tip_amount,omitempty"` // Transaction code. TransactionCode *string `json:"transaction_code,omitempty"` // Transaction VAT amount. VatAmount *string `json:"vat_amount,omitempty"` // Vat rates. VatRates *[]ReceiptTransactionVatRate `json:"vat_rates,omitempty"` // Cardholder verification method. VerificationMethod *string `json:"verification_method,omitempty"` }
ReceiptTransaction: Transaction information.
type ReceiptTransactionProduct ¶
type ReceiptTransactionProduct struct { // Product description. Description *string `json:"description,omitempty"` // Product name. Name *string `json:"name,omitempty"` // Product price. Price *float64 `json:"price,omitempty"` // Product quantity. Quantity *int `json:"quantity,omitempty"` // Quantity x product price. TotalPrice *float64 `json:"total_price,omitempty"` }
ReceiptTransactionProduct is a schema definition.
type ReceiptTransactionVatRate ¶
type ReceiptTransactionVatRate struct { // Gross Gross *float64 `json:"gross,omitempty"` // Net Net *float64 `json:"net,omitempty"` // Rate Rate *float64 `json:"rate,omitempty"` // Vat Vat *float64 `json:"vat,omitempty"` }
ReceiptTransactionVatRate is a schema definition.
type ReceiptsService ¶
type ReceiptsService service
func (*ReceiptsService) Get ¶
func (s *ReceiptsService) Get(ctx context.Context, id string, params GetReceiptParams) (*Receipt, error)
Get: Retrieve receipt details Retrieves receipt specific data for a transaction.
type RefundTransaction204Response ¶
type RefundTransaction204Response struct { }
RefundTransaction204Response is a schema definition.
type RefundTransactionBody ¶
type RefundTransactionBody struct { // Amount to be refunded. Eligible amount can't exceed the amount of the transaction and varies based on country // and currency. If you do not specify a value, the system performs a full refund of the transaction. Amount *float64 `json:"amount,omitempty"` }
RefundTransactionBody: Optional amount for partial refunds of transactions.
type SharedService ¶
type SharedService service
type SubaccountsService ¶
type SubaccountsService service
func (*SubaccountsService) CompatChangeOperatorsPassword ¶
func (s *SubaccountsService) CompatChangeOperatorsPassword(ctx context.Context, operatorId int, body CompatChangeOperatorsPasswordBody) (*Operator, error)
CompatChangeOperatorsPassword: Change operators password. Changes operators password, if the operator was disabled they will be unblocked.
func (*SubaccountsService) CompatDisableOperator ¶
func (s *SubaccountsService) CompatDisableOperator(ctx context.Context, operatorId int) (*Operator, error)
CompatDisableOperator: Disable operator.
func (*SubaccountsService) CompatGetOperator ¶
func (s *SubaccountsService) CompatGetOperator(ctx context.Context, operatorId int) (*Operator, error)
CompatGetOperator: Get operator Returns specific operator.
func (*SubaccountsService) CreateSubAccount ¶
func (s *SubaccountsService) CreateSubAccount(ctx context.Context, body CreateSubAccountBody) (*Operator, error)
CreateSubAccount: Create operator. Creates new operator for currently authorized users' merchant.
func (*SubaccountsService) DeactivateSubAccount ¶
func (s *SubaccountsService) DeactivateSubAccount(ctx context.Context, operatorId int) (*Operator, error)
DeactivateSubAccount: Disable operator.
func (*SubaccountsService) ListSubAccounts ¶
func (s *SubaccountsService) ListSubAccounts(ctx context.Context, params ListSubAccountsParams) (*ListSubAccounts200Response, error)
ListSubAccounts: List operators. Returns list of operators for currently authorized user's merchant.
func (*SubaccountsService) UpdateSubAccount ¶
func (s *SubaccountsService) UpdateSubAccount(ctx context.Context, operatorId int, body UpdateSubAccountBody) (*Operator, error)
UpdateSubAccount: Update operator. Updates operator. If the operator was disabled and their password is updated they will be unblocked.
type TimeoffsetDetails ¶
type TimeoffsetDetails struct { // Daylight Saving Time Dst *bool `json:"dst,omitempty"` // UTC offset Offset *float64 `json:"offset,omitempty"` // Postal code PostCode *string `json:"post_code,omitempty"` }
TimeoffsetDetails: TimeOffset Details
type TimestampEvent ¶
type TimestampEvent string
TimestampEvent: Date and time of the transaction event.
type TransactionEvent ¶
type TransactionEvent struct { // Amount of the event. Amount *AmountEvent `json:"amount,omitempty"` // Date when the transaction event occurred. // Format: date Date *Date `json:"date,omitempty"` // Date when the transaction event is due to occur. // Format: date DueDate *Date `json:"due_date,omitempty"` // Type of the transaction event. EventType *EventType `json:"event_type,omitempty"` // Unique ID of the transaction event. // Format: int64 Id *EventId `json:"id,omitempty"` // Consecutive number of the installment that is paid. Applicable only payout events, i.e. `event_type = PAYOUT`. InstallmentNumber *int `json:"installment_number,omitempty"` // Status of the transaction event. Status *EventStatus `json:"status,omitempty"` // Date and time of the transaction event. Timestamp *TimestampEvent `json:"timestamp,omitempty"` }
TransactionEvent: Details of a transaction event.
type TransactionFull ¶
type TransactionFull struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments. AuthCode *string `json:"auth_code,omitempty"` // Details of the payment card. Card *CardResponse `json:"card,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Entry mode of the payment details. EntryMode *TransactionFullEntryMode `json:"entry_mode,omitempty"` // List of events related to the transaction. // Unique items only Events *[]Event `json:"events,omitempty"` // Indication of the precision of the geographical position received from the payment terminal. HorizontalAccuracy *HorizontalAccuracy `json:"horizontal_accuracy,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Internal unique ID of the transaction on the SumUp platform. InternalId *int `json:"internal_id,omitempty"` // Latitude value from the coordinates of the payment location (as received from the payment terminal reader). // Min: 0 // Max: 90 Lat *Lat `json:"lat,omitempty"` // List of hyperlinks for accessing related resources. // Unique items only Links *[]interface{} `json:"links,omitempty"` // Local date and time of the creation of the transaction. LocalTime *time.Time `json:"local_time,omitempty"` // Details of the payment location as received from the payment terminal. Location *TransactionFullLocation `json:"location,omitempty"` // Longitude value from the coordinates of the payment location (as received from the payment terminal reader). // Min: 0 // Max: 180 Lon *Lon `json:"lon,omitempty"` // Unique code of the registered merchant to whom the payment is made. MerchantCode *string `json:"merchant_code,omitempty"` // Payment type used for the transaction. PaymentType *TransactionFullPaymentType `json:"payment_type,omitempty"` // Payout plan of the registered user at the time when the transaction was made. PayoutPlan *TransactionFullPayoutPlan `json:"payout_plan,omitempty"` // Payout type for the transaction. PayoutType *TransactionFullPayoutType `json:"payout_type,omitempty"` // Number of payouts that are made to the registered user specified in the `user` property. PayoutsReceived *int `json:"payouts_received,omitempty"` // Total number of payouts to the registered user specified in the `user` property. PayoutsTotal *int `json:"payouts_total,omitempty"` // Short description of the payment. The value is taken from the `description` property of the related checkout resource. ProductSummary *string `json:"product_summary,omitempty"` // List of products from the merchant's catalogue for which the transaction serves as a payment. Products *[]Product `json:"products,omitempty"` // Simple name of the payment type. SimplePaymentType *TransactionFullSimplePaymentType `json:"simple_payment_type,omitempty"` // Status generated from the processing status and the latest transaction state. SimpleStatus *TransactionFullSimpleStatus `json:"simple_status,omitempty"` // Current status of the transaction. Status *TransactionFullStatus `json:"status,omitempty"` // Indicates whether tax deduction is enabled for the transaction. TaxEnabled *bool `json:"tax_enabled,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Amount of the tip (out of the total transaction amount). TipAmount *float64 `json:"tip_amount,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` // List of transaction events related to the transaction. TransactionEvents *[]TransactionEvent `json:"transaction_events,omitempty"` // Email address of the registered user (merchant) to whom the payment is made. // Format: email Username *string `json:"username,omitempty"` // Amount of the applicable VAT (out of the total transaction amount). VatAmount *float64 `json:"vat_amount,omitempty"` // List of VAT rates applicable to the transaction. VatRates *[]interface{} `json:"vat_rates,omitempty"` // Verification method used for the transaction. VerificationMethod *TransactionFullVerificationMethod `json:"verification_method,omitempty"` }
TransactionFull is a schema definition.
type TransactionFullEntryMode ¶
type TransactionFullEntryMode string
TransactionFullEntryMode: Entry mode of the payment details.
const ( TransactionFullEntryModeBoleto TransactionFullEntryMode = "BOLETO" TransactionFullEntryModeCustomerEntry TransactionFullEntryMode = "CUSTOMER_ENTRY" )
type TransactionFullLocation ¶
type TransactionFullLocation struct { // Indication of the precision of the geographical position received from the payment terminal. HorizontalAccuracy *HorizontalAccuracy `json:"horizontal_accuracy,omitempty"` // Latitude value from the coordinates of the payment location (as received from the payment terminal reader). // Min: 0 // Max: 90 Lat *Lat `json:"lat,omitempty"` // Longitude value from the coordinates of the payment location (as received from the payment terminal reader). // Min: 0 // Max: 180 Lon *Lon `json:"lon,omitempty"` }
TransactionFullLocation: Details of the payment location as received from the payment terminal.
type TransactionFullPaymentType ¶
type TransactionFullPaymentType string
TransactionFullPaymentType: Payment type used for the transaction.
const ( TransactionFullPaymentTypeBoleto TransactionFullPaymentType = "BOLETO" TransactionFullPaymentTypeEcom TransactionFullPaymentType = "ECOM" TransactionFullPaymentTypeRecurring TransactionFullPaymentType = "RECURRING" )
type TransactionFullPayoutPlan ¶
type TransactionFullPayoutPlan string
TransactionFullPayoutPlan: Payout plan of the registered user at the time when the transaction was made.
const ( TransactionFullPayoutPlanAcceleratedInstallment TransactionFullPayoutPlan = "ACCELERATED_INSTALLMENT" TransactionFullPayoutPlanSinglePayment TransactionFullPayoutPlan = "SINGLE_PAYMENT" TransactionFullPayoutPlanTrueInstallment TransactionFullPayoutPlan = "TRUE_INSTALLMENT" )
type TransactionFullPayoutType ¶
type TransactionFullPayoutType string
TransactionFullPayoutType: Payout type for the transaction.
const ( TransactionFullPayoutTypeBalance TransactionFullPayoutType = "BALANCE" TransactionFullPayoutTypeBankAccount TransactionFullPayoutType = "BANK_ACCOUNT" TransactionFullPayoutTypePrepaidCard TransactionFullPayoutType = "PREPAID_CARD" )
type TransactionFullSimplePaymentType ¶
type TransactionFullSimplePaymentType string
TransactionFullSimplePaymentType: Simple name of the payment type.
const ( TransactionFullSimplePaymentTypeCash TransactionFullSimplePaymentType = "CASH" TransactionFullSimplePaymentTypeCcCustomerEntered TransactionFullSimplePaymentType = "CC_CUSTOMER_ENTERED" TransactionFullSimplePaymentTypeCcSignature TransactionFullSimplePaymentType = "CC_SIGNATURE" TransactionFullSimplePaymentTypeElv TransactionFullSimplePaymentType = "ELV" TransactionFullSimplePaymentTypeEmv TransactionFullSimplePaymentType = "EMV" TransactionFullSimplePaymentTypeManualEntry TransactionFullSimplePaymentType = "MANUAL_ENTRY" TransactionFullSimplePaymentTypeMoto TransactionFullSimplePaymentType = "MOTO" )
type TransactionFullSimpleStatus ¶
type TransactionFullSimpleStatus string
TransactionFullSimpleStatus: Status generated from the processing status and the latest transaction state.
const ( TransactionFullSimpleStatusCancelFailed TransactionFullSimpleStatus = "CANCEL_FAILED" TransactionFullSimpleStatusCancelled TransactionFullSimpleStatus = "CANCELLED" TransactionFullSimpleStatusChargeback TransactionFullSimpleStatus = "CHARGEBACK" TransactionFullSimpleStatusFailed TransactionFullSimpleStatus = "FAILED" TransactionFullSimpleStatusNonCollection TransactionFullSimpleStatus = "NON_COLLECTION" TransactionFullSimpleStatusPaidOut TransactionFullSimpleStatus = "PAID_OUT" TransactionFullSimpleStatusRefundFailed TransactionFullSimpleStatus = "REFUND_FAILED" TransactionFullSimpleStatusRefunded TransactionFullSimpleStatus = "REFUNDED" TransactionFullSimpleStatusSuccessful TransactionFullSimpleStatus = "SUCCESSFUL" )
type TransactionFullStatus ¶
type TransactionFullStatus string
TransactionFullStatus: Current status of the transaction.
const ( TransactionFullStatusCancelled TransactionFullStatus = "CANCELLED" TransactionFullStatusFailed TransactionFullStatus = "FAILED" TransactionFullStatusPending TransactionFullStatus = "PENDING" TransactionFullStatusSuccessful TransactionFullStatus = "SUCCESSFUL" )
type TransactionFullVerificationMethod ¶
type TransactionFullVerificationMethod string
TransactionFullVerificationMethod: Verification method used for the transaction.
const ( TransactionFullVerificationMethodConfirmationCodeVerified TransactionFullVerificationMethod = "confirmation code verified" TransactionFullVerificationMethodNone TransactionFullVerificationMethod = "none" TransactionFullVerificationMethodOfflinePin TransactionFullVerificationMethod = "offline pin" TransactionFullVerificationMethodOfflinePinSignature TransactionFullVerificationMethod = "offline pin + signature" TransactionFullVerificationMethodOnlinePin TransactionFullVerificationMethod = "online pin" TransactionFullVerificationMethodSignature TransactionFullVerificationMethod = "signature" )
type TransactionHistory ¶
type TransactionHistory struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Issuing card network of the payment card used for the transaction. CardType *TransactionHistoryCardType `json:"card_type,omitempty"` // Client-specific ID of the transaction. ClientTransactionId *string `json:"client_transaction_id,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Payment type used for the transaction. PaymentType *TransactionHistoryPaymentType `json:"payment_type,omitempty"` // Payout plan of the registered user at the time when the transaction was made. PayoutPlan *TransactionHistoryPayoutPlan `json:"payout_plan,omitempty"` // Number of payouts that are made to the registered user specified in the `user` property. PayoutsReceived *int `json:"payouts_received,omitempty"` // Total number of payouts to the registered user specified in the `user` property. PayoutsTotal *int `json:"payouts_total,omitempty"` // Short description of the payment. The value is taken from the `description` property of the related checkout resource. ProductSummary *string `json:"product_summary,omitempty"` // Current status of the transaction. Status *TransactionHistoryStatus `json:"status,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` // Unique ID of the transaction. TransactionId *TransactionId `json:"transaction_id,omitempty"` // Type of the transaction for the registered user specified in the `user` property. Type *TransactionHistoryType `json:"type,omitempty"` // Email address of the registered user (merchant) to whom the payment is made. // Format: email User *string `json:"user,omitempty"` }
TransactionHistory is a schema definition.
type TransactionHistoryCardType ¶
type TransactionHistoryCardType string
TransactionHistoryCardType: Issuing card network of the payment card used for the transaction.
const ( TransactionHistoryCardTypeAmex TransactionHistoryCardType = "AMEX" TransactionHistoryCardTypeCup TransactionHistoryCardType = "CUP" TransactionHistoryCardTypeDiners TransactionHistoryCardType = "DINERS" TransactionHistoryCardTypeDiscover TransactionHistoryCardType = "DISCOVER" TransactionHistoryCardTypeElo TransactionHistoryCardType = "ELO" TransactionHistoryCardTypeElv TransactionHistoryCardType = "ELV" TransactionHistoryCardTypeHipercard TransactionHistoryCardType = "HIPERCARD" TransactionHistoryCardTypeJcb TransactionHistoryCardType = "JCB" TransactionHistoryCardTypeMaestro TransactionHistoryCardType = "MAESTRO" TransactionHistoryCardTypeMastercard TransactionHistoryCardType = "MASTERCARD" TransactionHistoryCardTypeUnknown TransactionHistoryCardType = "UNKNOWN" TransactionHistoryCardTypeVisa TransactionHistoryCardType = "VISA" TransactionHistoryCardTypeVisaElectron TransactionHistoryCardType = "VISA_ELECTRON" TransactionHistoryCardTypeVisaVpay TransactionHistoryCardType = "VISA_VPAY" )
type TransactionHistoryPaymentType ¶
type TransactionHistoryPaymentType string
TransactionHistoryPaymentType: Payment type used for the transaction.
const ( TransactionHistoryPaymentTypeBoleto TransactionHistoryPaymentType = "BOLETO" TransactionHistoryPaymentTypeEcom TransactionHistoryPaymentType = "ECOM" TransactionHistoryPaymentTypeRecurring TransactionHistoryPaymentType = "RECURRING" )
type TransactionHistoryPayoutPlan ¶
type TransactionHistoryPayoutPlan string
TransactionHistoryPayoutPlan: Payout plan of the registered user at the time when the transaction was made.
const ( TransactionHistoryPayoutPlanAcceleratedInstallment TransactionHistoryPayoutPlan = "ACCELERATED_INSTALLMENT" TransactionHistoryPayoutPlanSinglePayment TransactionHistoryPayoutPlan = "SINGLE_PAYMENT" TransactionHistoryPayoutPlanTrueInstallment TransactionHistoryPayoutPlan = "TRUE_INSTALLMENT" )
type TransactionHistoryStatus ¶
type TransactionHistoryStatus string
TransactionHistoryStatus: Current status of the transaction.
const ( TransactionHistoryStatusCancelled TransactionHistoryStatus = "CANCELLED" TransactionHistoryStatusFailed TransactionHistoryStatus = "FAILED" TransactionHistoryStatusPending TransactionHistoryStatus = "PENDING" TransactionHistoryStatusSuccessful TransactionHistoryStatus = "SUCCESSFUL" )
type TransactionHistoryType ¶
type TransactionHistoryType string
TransactionHistoryType: Type of the transaction for the registered user specified in the `user` property.
const ( TransactionHistoryTypeChargeBack TransactionHistoryType = "CHARGE_BACK" TransactionHistoryTypePayment TransactionHistoryType = "PAYMENT" TransactionHistoryTypeRefund TransactionHistoryType = "REFUND" )
type TransactionMixinBase ¶
type TransactionMixinBase struct { // Total amount of the transaction. Amount *float64 `json:"amount,omitempty"` // Three-letter [ISO4217](https://en.wikipedia.org/wiki/ISO_4217) code of the currency for the amount. Currently supported // currency values are enumerated above. Currency *Currency `json:"currency,omitempty"` // Unique ID of the transaction. Id *string `json:"id,omitempty"` // Current number of the installment for deferred payments. // Min: 1 InstallmentsCount *int `json:"installments_count,omitempty"` // Payment type used for the transaction. PaymentType *TransactionMixinBasePaymentType `json:"payment_type,omitempty"` // Current status of the transaction. Status *TransactionMixinBaseStatus `json:"status,omitempty"` // Date and time of the creation of the transaction. Response format expressed according to [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) code. Timestamp *time.Time `json:"timestamp,omitempty"` // Transaction code returned by the acquirer/processing entity after processing the transaction. TransactionCode *string `json:"transaction_code,omitempty"` }
TransactionMixinBase: Details of the transaction.
type TransactionMixinBasePaymentType ¶
type TransactionMixinBasePaymentType string
TransactionMixinBasePaymentType: Payment type used for the transaction.
const ( TransactionMixinBasePaymentTypeBoleto TransactionMixinBasePaymentType = "BOLETO" TransactionMixinBasePaymentTypeEcom TransactionMixinBasePaymentType = "ECOM" TransactionMixinBasePaymentTypeRecurring TransactionMixinBasePaymentType = "RECURRING" )
type TransactionMixinBaseStatus ¶
type TransactionMixinBaseStatus string
TransactionMixinBaseStatus: Current status of the transaction.
const ( TransactionMixinBaseStatusCancelled TransactionMixinBaseStatus = "CANCELLED" TransactionMixinBaseStatusFailed TransactionMixinBaseStatus = "FAILED" TransactionMixinBaseStatusPending TransactionMixinBaseStatus = "PENDING" TransactionMixinBaseStatusSuccessful TransactionMixinBaseStatus = "SUCCESSFUL" )
type TransactionMixinCheckout ¶
type TransactionMixinCheckout struct { // Authorization code for the transaction sent by the payment card issuer or bank. Applicable only to card payments. AuthCode *string `json:"auth_code,omitempty"` // Entry mode of the payment details. EntryMode *TransactionMixinCheckoutEntryMode `json:"entry_mode,omitempty"` // Internal unique ID of the transaction on the SumUp platform. InternalId *int `json:"internal_id,omitempty"` // Unique code of the registered merchant to whom the payment is made. MerchantCode *string `json:"merchant_code,omitempty"` // Amount of the tip (out of the total transaction amount). TipAmount *float64 `json:"tip_amount,omitempty"` // Amount of the applicable VAT (out of the total transaction amount). VatAmount *float64 `json:"vat_amount,omitempty"` }
TransactionMixinCheckout is a schema definition.
type TransactionMixinCheckoutEntryMode ¶
type TransactionMixinCheckoutEntryMode string
TransactionMixinCheckoutEntryMode: Entry mode of the payment details.
const ( TransactionMixinCheckoutEntryModeBoleto TransactionMixinCheckoutEntryMode = "BOLETO" TransactionMixinCheckoutEntryModeCustomerEntry TransactionMixinCheckoutEntryMode = "CUSTOMER_ENTRY" )
type TransactionMixinHistory ¶
type TransactionMixinHistory struct { // Payout plan of the registered user at the time when the transaction was made. PayoutPlan *TransactionMixinHistoryPayoutPlan `json:"payout_plan,omitempty"` // Number of payouts that are made to the registered user specified in the `user` property. PayoutsReceived *int `json:"payouts_received,omitempty"` // Total number of payouts to the registered user specified in the `user` property. PayoutsTotal *int `json:"payouts_total,omitempty"` // Short description of the payment. The value is taken from the `description` property of the related checkout resource. ProductSummary *string `json:"product_summary,omitempty"` }
TransactionMixinHistory is a schema definition.
type TransactionMixinHistoryPayoutPlan ¶
type TransactionMixinHistoryPayoutPlan string
TransactionMixinHistoryPayoutPlan: Payout plan of the registered user at the time when the transaction was made.
const ( TransactionMixinHistoryPayoutPlanAcceleratedInstallment TransactionMixinHistoryPayoutPlan = "ACCELERATED_INSTALLMENT" TransactionMixinHistoryPayoutPlanSinglePayment TransactionMixinHistoryPayoutPlan = "SINGLE_PAYMENT" TransactionMixinHistoryPayoutPlanTrueInstallment TransactionMixinHistoryPayoutPlan = "TRUE_INSTALLMENT" )
type TransactionsService ¶
type TransactionsService service
func (*TransactionsService) Get ¶
func (s *TransactionsService) Get(ctx context.Context, merchantCode string, params GetTransactionV21Params) (*TransactionFull, error)
Get: Retrieve a transaction Retrieves the full details of an identified transaction. The transaction resource is identified by a query parameter and *one* of following parameters is required:
- `id`
- `internal_id`
- `transaction_code`
- `foreign_transaction_id`
- `client_transaction_id`
func (*TransactionsService) GetDeprecated ¶
func (s *TransactionsService) GetDeprecated(ctx context.Context, params GetTransactionParams) (*TransactionFull, error)
GetDeprecated: Retrieve a transaction Retrieves the full details of an identified transaction. The transaction resource is identified by a query parameter and *one* of following parameters is required:
- `id`
- `internal_id`
- `transaction_code`
- `foreign_transaction_id`
- `client_transaction_id`
func (*TransactionsService) List ¶
func (s *TransactionsService) List(ctx context.Context, merchantCode string, params ListTransactionsV21Params) (*ListTransactionsV21200Response, error)
List: List transactions Lists detailed history of all transactions associated with the merchant profile.
func (*TransactionsService) ListDeprecated ¶
func (s *TransactionsService) ListDeprecated(ctx context.Context, params ListTransactionsParams) (*ListTransactions200Response, error)
ListDeprecated: List transactions Lists detailed history of all transactions associated with the merchant profile.
func (*TransactionsService) Refund ¶
func (s *TransactionsService) Refund(ctx context.Context, txnId string, body RefundTransactionBody) (*RefundTransaction204Response, error)
Refund: Refund a transaction Refunds an identified transaction either in full or partially.
type UpdateApikeyBody ¶
type UpdateApikeyBody struct { // New name for the API key. // Max length: 255 Name string `json:"name"` // Max items: 128 Scopes Oauth2Scopes `json:"scopes"` }
UpdateApikeyBody is a schema definition.
type UpdateCustomerBody ¶
type UpdateCustomerBody struct { // Personal details for the customer. PersonalDetails *PersonalDetails `json:"personal_details,omitempty"` }
UpdateCustomerBody is a schema definition.
type UpdateMerchantMemberBody ¶
type UpdateMerchantMemberBody struct { // Object attributes that modifiable only by SumUp applications. Attributes *Attributes `json:"attributes,omitempty"` // Set of user-defined key-value pairs attached to the object. Partial updates are not supported. When updating, always // submit whole metadata. Metadata *Metadata `json:"metadata,omitempty"` Roles *[]string `json:"roles,omitempty"` // Allows you to update user data of managed users. User *UpdateMerchantMemberBodyUser `json:"user,omitempty"` }
UpdateMerchantMemberBody is a schema definition.
type UpdateMerchantMemberBodyUser ¶
type UpdateMerchantMemberBodyUser struct { // User's preferred name. Used for display purposes only. Nickname *string `json:"nickname,omitempty"` // Password of the member to add. Only used if `is_managed_user` is true. // Format: password // Min length: 8 Password *string `json:"password,omitempty"` }
UpdateMerchantMemberBodyUser: Allows you to update user data of managed users.
type UpdateReaderBody ¶
type UpdateReaderBody struct { // Set of user-defined key-value pairs attached to the object. // Max properties: 50 Meta *Meta `json:"meta,omitempty"` // Custom human-readable, user-defined name for easier identification of the reader. // Max length: 500 Name *ReaderName `json:"name,omitempty"` }
UpdateReaderBody is a schema definition.
type UpdateSubAccountBody ¶
type UpdateSubAccountBody struct { Disabled *bool `json:"disabled,omitempty"` Nickname *string `json:"nickname,omitempty"` // Min length: 8 Password *string `json:"password,omitempty"` Permissions *UpdateSubAccountBodyPermissions `json:"permissions,omitempty"` // Format: email // Max length: 256 Username *string `json:"username,omitempty"` }
UpdateSubAccountBody is a schema definition.
type UpdateSubAccountBodyPermissions ¶
type UpdateSubAccountBodyPermissions struct { CreateMotoPayments *bool `json:"create_moto_payments,omitempty"` CreateReferral *bool `json:"create_referral,omitempty"` FullTransactionHistoryView *bool `json:"full_transaction_history_view,omitempty"` RefundTransactions *bool `json:"refund_transactions,omitempty"` }
UpdateSubAccountBodyPermissions is a schema definition.
type VatRates ¶
type VatRates struct { // Country ISO code Country *string `json:"country,omitempty"` // Description Description *string `json:"description,omitempty"` // Internal ID Id *float64 `json:"id,omitempty"` // Ordering Ordering *float64 `json:"ordering,omitempty"` // Rate Rate *float64 `json:"rate,omitempty"` }
VatRates: Merchant VAT rates