Documentation ¶
Index ¶
- type BantupayAuthorizationData
- type ErrorResponse
- type LoginWithBantupayData
- type Merchant
- func (m *Merchant) GetPaymentData(targetUser, paymentDestination, assetCode, assetIssuer, amount, memo string) (paymentData *PayWithBantupayData, err error)
- func (m *Merchant) SendAuthorizationRequest(targetUser, authDescription, deviceInfo string) (authInfo *BantupayAuthorizationData, err error)
- func (m *Merchant) SendLoginRequest(targetUser string) (loginInfo *LoginWithBantupayData, err error)
- func (m *Merchant) VerifyAuthorizationRequest(targetUser, authID string) (err error)
- func (m *Merchant) VerifyLoginRequest(targetUser, loginID string) (userDetail *MerchantBudsInfo, err error)
- type MerchantBudsInfo
- type PayWithBantupayData
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ErrorResponse ¶
type LoginWithBantupayData ¶
type Merchant ¶
type Merchant struct { BantupayUsername string `json:"bantupayUsername" ` BaseURL string `json:"baseUrl"` KP *keypair.Full }
Merchant holds Merchant data model
func NewMerchant ¶
func NewMerchant(baseUrl, merchantBantupayUsername, secretKey string) (merchantInfo *Merchant, err error)
NewMerchant retrieves merchant Info from the bantupay API
func (*Merchant) GetPaymentData ¶
func (m *Merchant) GetPaymentData(targetUser, paymentDestination, assetCode, assetIssuer, amount, memo string) (paymentData *PayWithBantupayData, err error)
GetPaymentData verifies if authID is authorized and resturns nil
func (*Merchant) SendAuthorizationRequest ¶
func (m *Merchant) SendAuthorizationRequest(targetUser, authDescription, deviceInfo string) (authInfo *BantupayAuthorizationData, err error)
SendAuthorizationRequest sends 2FA authorization request and retrieves QRCode and dynamic link
func (*Merchant) SendLoginRequest ¶
func (m *Merchant) SendLoginRequest(targetUser string) (loginInfo *LoginWithBantupayData, err error)
SendLoginRequest sends login request and retrieves QRCode and dynamic link
func (*Merchant) VerifyAuthorizationRequest ¶
VerifyAuthorizationRequest verifies if authID is authorized and resturns nil
func (*Merchant) VerifyLoginRequest ¶
func (m *Merchant) VerifyLoginRequest(targetUser, loginID string) (userDetail *MerchantBudsInfo, err error)
VerifyLoginRequest verifies if loginID is authorized and resturns nil
type MerchantBudsInfo ¶
type MerchantBudsInfo struct { Username string `json:"username"` PublicKey string `json:"publicKey"` Email string `json:"email"` LastName string `json:"lastName"` FirstName string `json:"firstName"` MiddleName string `json:"middleName"` Mobile string `json:"mobile"` BantuTalk string `json:"bantuTalk"` ImageThumbnail string `json:"imageThumbnail"` Verified uint `json:"verified"` Suspended uint `json:"suspended"` }
MerchantBudsInfo model for bantu user directory info
type PayWithBantupayData ¶
Click to show internal directories.
Click to hide internal directories.