model

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// PaymentInfoStatusPending captures enum value "pending"
	PaymentInfoStatusPending string = "pending"

	// PaymentInfoStatusInProgress captures enum value "inProgress"
	PaymentInfoStatusInProgress string = "inProgress"

	// PaymentInfoStatusSuccess captures enum value "success"
	PaymentInfoStatusSuccess string = "success"
)
View Source
const (

	// PaymentInfoSuccessActionRedirect captures enum value "redirect"
	PaymentInfoSuccessActionRedirect string = "redirect"

	// PaymentInfoSuccessActionShowMessage captures enum value "showMessage"
	PaymentInfoSuccessActionShowMessage string = "showMessage"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateCustomerRequest

type CreateCustomerRequest struct {

	// Email
	// Example: me@you.com
	// Required: true
	Email string `json:"email"`
}

CreateCustomerRequest create customer request

swagger:model createCustomerRequest

func (*CreateCustomerRequest) ContextValidate

func (m *CreateCustomerRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this create customer request based on context it is used

func (*CreateCustomerRequest) MarshalBinary

func (m *CreateCustomerRequest) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*CreateCustomerRequest) UnmarshalBinary

func (m *CreateCustomerRequest) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*CreateCustomerRequest) Validate

func (m *CreateCustomerRequest) Validate(formats strfmt.Registry) error

Validate validates this create customer request

type CreatePaymentFromLinkRequest

type CreatePaymentFromLinkRequest interface{}

CreatePaymentFromLinkRequest create payment from link request

swagger:model createPaymentFromLinkRequest

type CreatePaymentMethodRequest

type CreatePaymentMethodRequest struct {

	// Currency ticker
	// Example: ETH_USDT
	// Required: true
	Ticker string `json:"ticker"`
}

CreatePaymentMethodRequest create payment method request

swagger:model createPaymentMethodRequest

func (*CreatePaymentMethodRequest) ContextValidate

func (m *CreatePaymentMethodRequest) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this create payment method request based on context it is used

func (*CreatePaymentMethodRequest) MarshalBinary

func (m *CreatePaymentMethodRequest) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*CreatePaymentMethodRequest) UnmarshalBinary

func (m *CreatePaymentMethodRequest) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*CreatePaymentMethodRequest) Validate

func (m *CreatePaymentMethodRequest) Validate(formats strfmt.Registry) error

Validate validates this create payment method request

type CurrencyExchangeRate

type CurrencyExchangeRate struct {

	// crypto amount
	// Example: 0.1231232453453
	CryptoAmount string `json:"cryptoAmount"`

	// crypto currency
	// Example: DAI
	CryptoCurrency string `json:"cryptoCurrency"`

	// display name
	// Example: USD → ETH_DAI
	DisplayName string `json:"displayName"`

	// exchange rate
	// Example: 51.1
	ExchangeRate float64 `json:"exchangeRate"`

	// fiat amount
	// Example: 49.9
	// Minimum: 0.01
	FiatAmount float64 `json:"fiatAmount"`

	// fiat currency
	// Example: USD
	FiatCurrency string `json:"fiatCurrency"`

	// network
	// Example: ETH
	Network string `json:"network"`
}

CurrencyExchangeRate currency exchange rate

swagger:model currencyExchangeRate

func (*CurrencyExchangeRate) ContextValidate

func (m *CurrencyExchangeRate) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this currency exchange rate based on context it is used

func (*CurrencyExchangeRate) MarshalBinary

func (m *CurrencyExchangeRate) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*CurrencyExchangeRate) UnmarshalBinary

func (m *CurrencyExchangeRate) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*CurrencyExchangeRate) Validate

func (m *CurrencyExchangeRate) Validate(formats strfmt.Registry) error

Validate validates this currency exchange rate

type Customer

type Customer struct {

	// Email
	// Example: me@you.com
	// Required: true
	Email string `json:"email"`

	// UUID
	// Example: a51e7a5-f0c8-48dc-a9fb-a335481ae846
	// Required: true
	ID string `json:"id"`
}

Customer customer

swagger:model customer

func (*Customer) ContextValidate

func (m *Customer) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this customer based on context it is used

func (*Customer) MarshalBinary

func (m *Customer) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Customer) UnmarshalBinary

func (m *Customer) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Customer) Validate

func (m *Customer) Validate(formats strfmt.Registry) error

Validate validates this customer

type ErrorResponse

type ErrorResponse struct {

	// Errors list
	Errors []*ErrorResponseItem `json:"errors"`

	// Error Message
	// Example: You are unauthenticated
	Message string `json:"message,omitempty"`

	// Error status
	// Example: unauthenticated
	Status string `json:"status,omitempty"`
}

ErrorResponse error response

swagger:model ErrorResponse

func (*ErrorResponse) ContextValidate

func (m *ErrorResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this error response based on the context it is used

func (*ErrorResponse) MarshalBinary

func (m *ErrorResponse) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ErrorResponse) UnmarshalBinary

func (m *ErrorResponse) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ErrorResponse) Validate

func (m *ErrorResponse) Validate(formats strfmt.Registry) error

Validate validates this error response

type ErrorResponseItem

type ErrorResponseItem struct {

	// Error field
	// Example: username
	Field string `json:"field,omitempty"`

	// Error Message
	// Example: You are unauthenticated
	Message string `json:"message,omitempty"`
}

ErrorResponseItem error response item

swagger:model ErrorResponseItem

func (*ErrorResponseItem) ContextValidate

func (m *ErrorResponseItem) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this error response item based on context it is used

func (*ErrorResponseItem) MarshalBinary

func (m *ErrorResponseItem) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ErrorResponseItem) UnmarshalBinary

func (m *ErrorResponseItem) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ErrorResponseItem) Validate

func (m *ErrorResponseItem) Validate(formats strfmt.Registry) error

Validate validates this error response item

type Payment

type Payment struct {

	// Currency
	// Example: USD
	// Required: true
	Currency string `json:"currency"`

	// customer
	Customer *Customer `json:"customer"`

	// Payment description
	// Example: M-sized sweater
	Description *string `json:"description"`

	// Payment UUID
	// Example: a51e7a5-f0c8-48dc-a9fb-a335481ae846
	// Required: true
	ID string `json:"id"`

	// Indicates is payment method can be changed
	// Example: true
	// Required: true
	IsLocked bool `json:"isLocked"`

	// Merchant's store name
	// Example: Delta Airlines
	// Required: true
	MerchantName string `json:"merchantName"`

	// payment info
	PaymentInfo *PaymentInfo `json:"paymentInfo"`

	// payment method
	PaymentMethod *PaymentMethod `json:"paymentMethod"`

	// Price
	// Example: 39.9
	// Required: true
	Price float64 `json:"price"`
}

Payment payment

swagger:model payment

func (*Payment) ContextValidate

func (m *Payment) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this payment based on the context it is used

func (*Payment) MarshalBinary

func (m *Payment) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Payment) UnmarshalBinary

func (m *Payment) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Payment) Validate

func (m *Payment) Validate(formats strfmt.Registry) error

Validate validates this payment

type PaymentInfo

type PaymentInfo struct {

	// Amount to pay in selected currency. Wei for ETH, Satoshi for BTC and so on...
	// Example: 1000000
	// Required: true
	Amount string `json:"amount"`

	// Human readable amount to pay.
	// Example: 0.123
	// Required: true
	AmountFormatted string `json:"amountFormatted"`

	// Expiration duration in minutes
	// Example: 20
	// Required: true
	ExpirationDurationMin int64 `json:"expirationDurationMin"`

	// payment expiration timestamp (UTC)
	// Example: 2023-03-09T20:18:07.809Z
	// Required: true
	// Format: datetime
	ExpiresAt strfmt.DateTime `json:"expiresAt"`

	// Payment link for QR code
	// Example: tron:TVEaDaTKJZ2RsQUWREWykouuHak9scyZaf
	// Required: true
	PaymentLink string `json:"paymentLink"`

	// recipient address
	// Example: 0xbca4a8417e823484b21d2f4f1f1324d951236a49
	// Required: true
	RecipientAddress string `json:"recipientAddress"`

	// Payment status
	// Example: success
	// Required: true
	// Enum: [pending inProgress success]
	Status string `json:"status"`

	// Success action. Present if payment is successful
	// Enum: [redirect showMessage]
	SuccessAction *string `json:"successAction,omitempty"`

	// Success message visible after payment confirmation (if successAction == `showMessage`)
	//
	// Example: Thanks you for purchasing our product! You will receive invitation on your email\n
	SuccessMessage *string `json:"successMessage,omitempty"`

	// Success URL to where a user should be redirected after payment confirmation.
	// Empty if success action is `showMessage`
	//
	// Example: https://site.com/success
	SuccessURL *string `json:"successUrl,omitempty"`
}

PaymentInfo Payment info

swagger:model paymentInfo

func (*PaymentInfo) ContextValidate

func (m *PaymentInfo) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this payment info based on context it is used

func (*PaymentInfo) MarshalBinary

func (m *PaymentInfo) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*PaymentInfo) UnmarshalBinary

func (m *PaymentInfo) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*PaymentInfo) Validate

func (m *PaymentInfo) Validate(formats strfmt.Registry) error

Validate validates this payment info

type PaymentLink struct {

	// Currency
	// Example: USD
	// Required: true
	Currency string `json:"currency"`

	// Payment description
	// Example: M-sized sweater
	Description *string `json:"description"`

	// Merchant's store name
	// Example: Delta Airlines
	// Required: true
	MerchantName string `json:"merchantName"`

	// Price
	// Example: 39.9
	// Required: true
	Price float64 `json:"price"`
}

PaymentLink payment link

swagger:model paymentLink

func (*PaymentLink) ContextValidate

func (m *PaymentLink) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this payment link based on context it is used

func (*PaymentLink) MarshalBinary

func (m *PaymentLink) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*PaymentLink) UnmarshalBinary

func (m *PaymentLink) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*PaymentLink) Validate

func (m *PaymentLink) Validate(formats strfmt.Registry) error

Validate validates this payment link

type PaymentMethod

type PaymentMethod struct {

	// blockchain
	Blockchain string `json:"blockchain"`

	// blockchain name
	BlockchainName string `json:"blockchainName"`

	// display name
	DisplayName string `json:"displayName"`

	// is test
	IsTest bool `json:"isTest"`

	// name
	Name string `json:"name"`

	// network Id
	NetworkID string `json:"networkId"`

	// ticker
	Ticker string `json:"ticker"`
}

PaymentMethod PaymentType

swagger:model paymentMethod

func (*PaymentMethod) ContextValidate

func (m *PaymentMethod) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this payment method based on context it is used

func (*PaymentMethod) MarshalBinary

func (m *PaymentMethod) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*PaymentMethod) UnmarshalBinary

func (m *PaymentMethod) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*PaymentMethod) Validate

func (m *PaymentMethod) Validate(formats strfmt.Registry) error

Validate validates this payment method

type PaymentRedirectInfo

type PaymentRedirectInfo struct {

	// Payment UUID
	// Example: a51e7a5-f0c8-48dc-a9fb-a335481ae846
	// Required: true
	ID string `json:"id"`
}

PaymentRedirectInfo payment redirect info

swagger:model paymentRedirectInfo

func (*PaymentRedirectInfo) ContextValidate

func (m *PaymentRedirectInfo) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this payment redirect info based on context it is used

func (*PaymentRedirectInfo) MarshalBinary

func (m *PaymentRedirectInfo) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*PaymentRedirectInfo) UnmarshalBinary

func (m *PaymentRedirectInfo) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*PaymentRedirectInfo) Validate

func (m *PaymentRedirectInfo) Validate(formats strfmt.Registry) error

Validate validates this payment redirect info

type SupportedPaymentMethod

type SupportedPaymentMethod struct {

	// blockchain
	Blockchain string `json:"blockchain"`

	// blockchain name
	BlockchainName string `json:"blockchainName"`

	// display name
	DisplayName string `json:"displayName"`

	// name
	Name string `json:"name"`

	// ticker
	Ticker string `json:"ticker"`
}

SupportedPaymentMethod PaymentType

swagger:model supportedPaymentMethod

func (*SupportedPaymentMethod) ContextValidate

func (m *SupportedPaymentMethod) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this supported payment method based on context it is used

func (*SupportedPaymentMethod) MarshalBinary

func (m *SupportedPaymentMethod) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*SupportedPaymentMethod) UnmarshalBinary

func (m *SupportedPaymentMethod) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*SupportedPaymentMethod) Validate

func (m *SupportedPaymentMethod) Validate(formats strfmt.Registry) error

Validate validates this supported payment method

type SupportedPaymentMethods

type SupportedPaymentMethods struct {

	// available methods
	AvailableMethods []*SupportedPaymentMethod `json:"availableMethods"`
}

SupportedPaymentMethods supported payment methods

swagger:model supportedPaymentMethods

func (*SupportedPaymentMethods) ContextValidate

func (m *SupportedPaymentMethods) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this supported payment methods based on the context it is used

func (*SupportedPaymentMethods) MarshalBinary

func (m *SupportedPaymentMethods) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*SupportedPaymentMethods) UnmarshalBinary

func (m *SupportedPaymentMethods) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*SupportedPaymentMethods) Validate

func (m *SupportedPaymentMethods) Validate(formats strfmt.Registry) error

Validate validates this supported payment methods

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL