Documentation
¶
Index ¶
- func GetPosReqDT() string
- func GetToken(paymentMethod abstractions.IPaymentMethod) string
- func IsAppleOrGooglePay(paymentDataSource entities.PaymentDataSourceType) bool
- func MapReportResponse(rawResponse string, reportType reporttype.ReportType) (abstractions4.ITransaction, error)
- func MapResponse(rawResponse string, paymentMethod abstractions.IPaymentMethod) (*transactions.Transaction, error)
- type Gateway
- func (g *Gateway) BuildQueryString(queryStringParams map[string]string) string
- func (g *Gateway) GenerateRequestLog()
- func (g *Gateway) GenerateResponseLog()
- func (g *Gateway) GetRawResponse(responseStream *http.Response) (string, error)
- func (g *Gateway) SendRequest(ctx context.Context, verb string, endpoint string, data string, ...) (*GatewayResponse, error)
- func (g *Gateway) SendRequestWithMultipart(endpoint string, content *multipart.Writer, body bytes.Buffer) (*GatewayResponse, error)
- type GatewayResponse
- type GatewayResponseError
- type PorticoConnector
- func (p *PorticoConnector) BuildEnvelope(et *utils.ElementTree, transaction *utils.Element, clientTransactionId string) (string, error)
- func (p *PorticoConnector) ManageTransaction(ctx context.Context, builder abstractions4.IManagementBuilder) (abstractions4.ITransaction, error)
- func (p *PorticoConnector) ProcessAuthorization(ctx context.Context, builder abstractions4.IAuthorizationBuilder) (abstractions4.ITransaction, error)
- func (p *PorticoConnector) ProcessReport(ctx context.Context, builder abstractions5.IReportBuilder) (abstractions4.ITransaction, error)
- func (p *PorticoConnector) SendKeepAlive(ctx context.Context) (*network.NetworkMessageHeader, error)
- func (p *PorticoConnector) SerializeRequest(ctx context.Context, a abstractions4.IAuthorizationBuilder) (string, error)
- func (p *PorticoConnector) SupportsHostedPayments() bool
- func (p *PorticoConnector) SupportsOpenBanking() bool
- type XmlGateway
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetPosReqDT ¶
func GetPosReqDT() string
func GetToken ¶
func GetToken(paymentMethod abstractions.IPaymentMethod) string
func IsAppleOrGooglePay ¶
func IsAppleOrGooglePay(paymentDataSource entities.PaymentDataSourceType) bool
func MapReportResponse ¶
func MapReportResponse(rawResponse string, reportType reporttype.ReportType) (abstractions4.ITransaction, error)
func MapResponse ¶
func MapResponse(rawResponse string, paymentMethod abstractions.IPaymentMethod) (*transactions.Transaction, error)
Types ¶
type Gateway ¶
type Gateway struct {
ContentType string
EnableLogging bool
RequestLogger logging.IRequestLogger
LogEntry strings.Builder
LSChar string
Headers map[string]string
DynamicHeaders map[string]string
Timeout int
ServiceUrl string
AuthorizationHeaderKey string
WebProxy abstractions.IWebProxy
}
func NewGateway ¶
func (*Gateway) BuildQueryString ¶
func (*Gateway) GenerateRequestLog ¶
func (g *Gateway) GenerateRequestLog()
func (*Gateway) GenerateResponseLog ¶
func (g *Gateway) GenerateResponseLog()
func (*Gateway) GetRawResponse ¶
func (*Gateway) SendRequest ¶
func (*Gateway) SendRequestWithMultipart ¶
type GatewayResponse ¶
func (*GatewayResponse) GetRawResponse ¶
func (g *GatewayResponse) GetRawResponse() string
func (*GatewayResponse) GetStatusCode ¶
func (g *GatewayResponse) GetStatusCode() int
func (*GatewayResponse) SetRawResponse ¶
func (g *GatewayResponse) SetRawResponse(rawResponse string)
func (*GatewayResponse) SetStatusCode ¶
func (g *GatewayResponse) SetStatusCode(statusCode int)
type GatewayResponseError ¶
type GatewayResponseError struct {
// contains filtered or unexported fields
}
func NewGatewayResponseError ¶
func NewGatewayResponseError(msg string, errorCode string) *GatewayResponseError
func (*GatewayResponseError) Error ¶
func (e *GatewayResponseError) Error() string
Error implements the error interface.
func (*GatewayResponseError) GetErrorCode ¶
func (e *GatewayResponseError) GetErrorCode() string
type PorticoConnector ¶
type PorticoConnector struct {
*XmlGateway
SiteId string
LicenseId string
DeviceId string
Username string
Password string
DeveloperId string
VersionNumber string
SecretApiKey string
SdkNameVersion string
CardType string
IsSAFDataSupported bool
}
func NewPorticoConnector ¶
func NewPorticoConnector() *PorticoConnector
func (*PorticoConnector) BuildEnvelope ¶
func (p *PorticoConnector) BuildEnvelope(et *utils.ElementTree, transaction *utils.Element, clientTransactionId string) (string, error)
func (*PorticoConnector) ManageTransaction ¶
func (p *PorticoConnector) ManageTransaction(ctx context.Context, builder abstractions4.IManagementBuilder) (abstractions4.ITransaction, error)
func (*PorticoConnector) ProcessAuthorization ¶
func (p *PorticoConnector) ProcessAuthorization(ctx context.Context, builder abstractions4.IAuthorizationBuilder) (abstractions4.ITransaction, error)
func (*PorticoConnector) ProcessReport ¶
func (p *PorticoConnector) ProcessReport(ctx context.Context, builder abstractions5.IReportBuilder) (abstractions4.ITransaction, error)
func (*PorticoConnector) SendKeepAlive ¶
func (p *PorticoConnector) SendKeepAlive(ctx context.Context) (*network.NetworkMessageHeader, error)
func (*PorticoConnector) SerializeRequest ¶
func (p *PorticoConnector) SerializeRequest(ctx context.Context, a abstractions4.IAuthorizationBuilder) (string, error)
func (*PorticoConnector) SupportsHostedPayments ¶
func (p *PorticoConnector) SupportsHostedPayments() bool
func (*PorticoConnector) SupportsOpenBanking ¶
func (p *PorticoConnector) SupportsOpenBanking() bool
type XmlGateway ¶
type XmlGateway struct {
*Gateway
}
func NewXmlGateway ¶
func NewXmlGateway() *XmlGateway
func (*XmlGateway) DoTransaction ¶
Click to show internal directories.
Click to hide internal directories.