Documentation
¶
Index ¶
- Variables
- func EncryptCBC(key, data []byte) ([]byte, error)
- type API
- func (api API) ApplePay(data []byte) ([]byte, error)
- func (api API) ArnCode(data []byte) ([]byte, error)
- func (api API) Auth(data []byte) ([]byte, error)
- func (api API) FormMerchantData(data []byte) (*FormInitDTO, error)
- func (api API) FormResign(data []byte) (*FormResignDTO, error)
- func (api API) FormUpdate(data []byte) (*FormUpdateDTO, error)
- func (api API) GenerateSignature(data []byte) string
- func (api API) GooglePay(data []byte) ([]byte, error)
- func (api API) Recurring(data []byte) ([]byte, error)
- func (api API) Refund(data []byte) ([]byte, error)
- func (api API) Resign(data []byte) ([]byte, error)
- func (api API) Settle(data []byte) ([]byte, error)
- func (api API) Status(data []byte) ([]byte, error)
- func (api API) Void(data []byte) ([]byte, error)
- type FormInitDTO
- type FormResignDTO
- type FormUpdateDTO
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrInvalidBlockSize is returned when the block size is invalid ErrInvalidBlockSize = errors.New("block size must be greater than 0") // ErrEmptyData is returned when the data to encrypt is empty ErrEmptyData = errors.New("data to encrypt cannot be empty") // ErrInvalidKeySize is returned when the key size is invalid ErrInvalidKeySize = errors.New("key size must be 32 bytes") )
View Source
var ErrEmptyPayload = errors.New("empty payload")
ErrEmptyPayload is returned when the request payload is empty
Functions ¶
func EncryptCBC ¶
EncryptCBC encrypts data using AES-CBC mode with PKCS#7 padding key must be 32 bytes long
Types ¶
type API ¶ added in v1.7.0
type API struct {
// contains filtered or unexported fields
}
API represents the SolidGate API client
func (API) FormMerchantData ¶ added in v1.7.0
func (api API) FormMerchantData(data []byte) (*FormInitDTO, error)
FormMerchantData prepares merchant data for form initialization
func (API) FormResign ¶ added in v1.7.0
func (api API) FormResign(data []byte) (*FormResignDTO, error)
FormResign prepares data for form resignation
func (API) FormUpdate ¶ added in v1.7.0
func (api API) FormUpdate(data []byte) (*FormUpdateDTO, error)
FormUpdate prepares data for form update
func (API) GenerateSignature ¶ added in v1.7.0
GenerateSignature generates a signature for the request
type FormInitDTO ¶
type FormResignDTO ¶ added in v1.5.0
type FormUpdateDTO ¶
Click to show internal directories.
Click to hide internal directories.