types

package
v0.0.0-...-56af7ee Latest Latest
Warning

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

Go to latest
Published: May 6, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AdditionalData

type AdditionalData struct {
	AuthCode                          string         `json:"authCode,omitempty"`
	AvsResult                         string         `json:"avsResult,omitempty"`
	Alias                             string         `json:"alias,omitempty"`
	AliasType                         string         `json:"aliasType,omitempty"`
	AuthorisedAmountCurrency          string         `json:"authorisedAmountCurrency,omitempty"`
	AuthorisedAmountValue             string         `json:"authorisedAmountValue,omitempty"`
	CardBin                           string         `json:"cardBin,omitempty"`
	CardEncryptedJSON                 string         `json:"card.encrypted.json,omitempty"`
	CardIssuingCountry                string         `json:"cardIssuingCountry,omitempty"`
	CardHolderName                    string         `json:"cardHolderName,omitempty"`
	CardPaymentMethod                 string         `json:"cardPaymentMethod,omitempty"`
	CardSummary                       string         `json:"cardSummary,omitempty"`
	CvcResult                         string         `json:"cvcResult,omitempty"`
	ExecuteThreeD                     string         `json:"executeThreeD,omitempty"`
	ExpiryDate                        *ExpiryTime    `json:"expiryDate,omitempty"`
	IndustryUsage                     string         `json:"industryUsage,omitempty"`
	IssuerCountry                     string         `json:"issuerCountry,omitempty"`
	MerchantReference                 string         `json:"merchantReference,omitempty"`
	PaymentMethod                     string         `json:"paymentMethod,omitempty"`
	PaymentMethodVariant              string         `json:"paymentMethodVariant,omitempty"`
	Recurring                         *RecurringData `json:"recurring,omitempty"`
	RequestedTestAcquirerResponseCode int            `json:"RequestedTestAcquirerResponseCode,omitempty"`
}

AdditionalData struct

type Amount

type Amount struct {
	Value    int    `json:"value"`
	Currency string `json:"currency"`
}

Amount struct

type BrowserInfo

type BrowserInfo struct {

	// The accept header value of the shopper's browser.
	AcceptHeader string `json:"acceptHeader"`

	// The color depth of the shopper's browser in bits per pixel. This should be obtained by using the browser's screen.colorDepth property. Accepted values: 1, 4, 8, 15, 16, 24, 30, 32 or 48 bit color depth.
	ColorDepth int `json:"colorDepth"`

	// Boolean value indicating if the shopper's browser is able to execute Java.
	JavaEnabled bool `json:"javaEnabled"`

	// Boolean value indicating if the shopper's browser is able to execute JavaScript. A default 'true' value is assumed if the field is not present.
	JavaScriptEnabled bool `json:"javaScriptEnabled"`

	// The navigator.language value of the shopper's browser (as defined in IETF BCP 47).
	Language string `json:"language"`

	// The total height of the shopper's device screen in pixels.
	ScreenHeight int `json:"screenHeight"`

	// The total width of the shopper's device screen in pixels.
	ScreenWidth int `json:"screenWidth"`

	// Time difference between UTC time and the shopper's browser local time, in minutes.
	TimeZoneOffset int `json:"timeZoneOffset"`

	// The user agent value of the shopper's browser.
	UserAgent string `json:"userAgent"`
}

BrowserInfo is the shopper's browser information, for 3D Secure, the full object is required for web integrations.

type Card

type Card struct {
	Cvc string `json:"cvc"`
}

Card struct

type ContractType

type ContractType string

ContractType const

const (
	ContractRecurring         ContractType = "RECURRING"
	ContractOneClick          ContractType = "ONECLICK"
	ContractRecurringOneClick ContractType = "RECURRING,ONECLICK"
)

Contract types

type DateTime

type DateTime struct {
	Time time.Time
}

DateTime struct

func (*DateTime) UnmarshalJSON

func (t *DateTime) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler. It supports string, object and null input.

func (*DateTime) UnmarshalText

func (t *DateTime) UnmarshalText(b []byte) error

UnmarshalText allows RFC3339 to implement the TextUnmarshaler interface

type Details

type Details struct {
	RecurringDetail *RecurringDetail `json:"RecurringDetail,omitempty"`
}

Details struct

type ExpiryTime

type ExpiryTime struct {
	Time time.Time
}

ExpiryTime struct

func (*ExpiryTime) UnmarshalJSON

func (t *ExpiryTime) UnmarshalJSON(b []byte) error

UnmarshalJSON implements json.Unmarshaler. It supports string, object and null input.

func (*ExpiryTime) UnmarshalText

func (t *ExpiryTime) UnmarshalText(b []byte) error

UnmarshalText allows to implement the TextUnmarshaler interface

type InteractionType

type InteractionType string

InteractionType const

const (
	InteractionEcommerce InteractionType = "Ecommerce"
	InteractionContAuth  InteractionType = "ContAuth"
)

Interaction types

type ModificationAdjustAuthorise

type ModificationAdjustAuthorise struct {
	PspReference string `json:"pspReference"`
	Response     string `json:"response"` //  "[adjustAuthorisation-received]"
}

ModificationAdjustAuthorise struct

type ModificationAdjustAuthoriseParams

type ModificationAdjustAuthoriseParams struct {
	AdditionalData     *AdditionalData `json:"additionalData"`
	MerchantAccount    string          `json:"merchantAccount"`
	ModificationAmount *Amount         `json:"modificationAmount"`
	OriginalReference  string          `json:"originalReference"`
	Reference          string          `json:"reference"`
}

ModificationAdjustAuthoriseParams struct

type ModificationCancel

type ModificationCancel struct {
	PspReference string `json:"pspReference"`
	Response     string `json:"response"` // "[cancel-received]"
}

ModificationCancel is the resource representing a Adyen payment.

type ModificationCancelOrRefund

type ModificationCancelOrRefund struct {
	PspReference string `json:"pspReference"`
	Response     string `json:"response"` // "[cancelOrRefund-received]"
}

ModificationCancelOrRefund struct

type ModificationCancelOrRefundParams

type ModificationCancelOrRefundParams struct {
	MerchantAccount   string `json:"merchantAccount"`
	OriginalReference string `json:"originalReference"`
	Reference         string `json:"reference"`
}

ModificationCancelOrRefundParams struct

type ModificationCancelParams

type ModificationCancelParams struct {
	MerchantAccount   string `json:"merchantAccount"`
	OriginalReference string `json:"originalReference"`
	Reference         string `json:"reference"`
}

ModificationCancelParams struct

type ModificationCapture

type ModificationCapture struct {
	PspReference string `json:"pspReference"`
	Response     string `json:"response"` // "response": "[capture-received]"
}

ModificationCapture is the resource representing a Adyen payment.

type ModificationCaptureParams

type ModificationCaptureParams struct {
	MerchantAccount    string  `json:"merchantAccount"`
	ModificationAmount *Amount `json:"modificationAmount"`
	OriginalReference  string  `json:"originalReference"`
	Reference          string  `json:"reference"`
}

ModificationCaptureParams struct

type ModificationRefund

type ModificationRefund struct {
	PspReference string `json:"pspReference"`
	Response     string `json:"response"` //  "[refund-received]"
}

ModificationRefund struct

type ModificationRefundParams

type ModificationRefundParams struct {
	MerchantAccount    string  `json:"merchantAccount"`
	ModificationAmount *Amount `json:"modificationAmount"`
	Reference          string  `json:"reference"`
	OriginalReference  string  `json:"originalReference"`
}

ModificationRefundParams struct

type ModificationTechnicalCancel

type ModificationTechnicalCancel struct {
	PspReference string `json:"pspReference"`
	Response     string `json:"response"` // "[technical-cancel-received]"
}

ModificationTechnicalCancel struct

type ModificationTechnicalCancelParams

type ModificationTechnicalCancelParams struct {
	MerchantAccount           string `json:"merchantAccount"`
	OriginalMerchantReference string `json:"originalMerchantReference"`
	Reference                 string `json:"reference"`
}

ModificationTechnicalCancelParams struct

type Notification

type Notification struct {
	Live              string              `json:"live"`
	NotificationItems []*NotificationItem `json:"notificationItems"`
}

Notification struct

type NotificationAdditionalData

type NotificationAdditionalData struct {
	AuthCode                 string      `json:"authCode"`
	CardHolderName           string      `json:"cardHolderName"`
	CardSummary              string      `json:"cardSummary"`
	ShopperEmail             string      `json:"shopperEmail"`
	AuthorisedAmountValue    string      `json:"authorisedAmountValue"`
	ExpiryDate               *ExpiryTime `json:"expiryDate"`
	AuthorisedAmountCurrency string      `json:"authorisedAmountCurrency"`
	CardBin                  string      `json:"cardBin"`
	AliasType                string      `json:"aliasType"`
	Alias                    string      `json:"alias"`
	CardPaymentMethod        string      `json:"cardPaymentMethod"`
	PaymentMethodVariant     string      `json:"paymentMethodVariant"`
	CardIssuingCountry       string      `json:"cardIssuingCountry"`
	ShopperReference         string      `json:"shopperReference"`
	IssuerCountry            string      `json:"issuerCountry"`
}

NotificationAdditionalData struct

type NotificationItem

type NotificationItem struct {
	NotificationRequestItem *NotificationRequestItem `json:"NotificationRequestItem"`
}

NotificationItem struct

type NotificationRequestItem

type NotificationRequestItem struct {
	AdditionalData      *NotificationAdditionalData `json:"additionalData"`
	Amount              *Amount                     `json:"amount"`
	EventCode           string                      `json:"eventCode"`
	EventDate           *DateTime                   `json:"eventDate"`
	MerchantAccountCode string                      `json:"merchantAccountCode"`
	MerchantReference   string                      `json:"merchantReference"`
	Operations          []string                    `json:"operations"`
	OriginalReference   string                      `json:"originalReference"`
	PaymentMethod       string                      `json:"paymentMethod"`
	PspReference        string                      `json:"pspReference"`
	Reason              string                      `json:"reason"`
	Success             string                      `json:"success"`
}

NotificationRequestItem struct

type PaymentAuthorise

type PaymentAuthorise struct {
	AdditionalData *AdditionalData `json:"additionalData"`
	PspReference   string          `json:"pspReference"`
	ResultCode     string          `json:"resultCode"`
	AuthCode       string          `json:"authCode"`
	Md             string          `json:"md,omitempty"`
	PaRequest      string          `json:"paRequest,omitempty"`
	IssuerUrl      string          `json:"issuerUrl,omitempty"`
}

******************************************

RESPONSE FROM ADYEN

****************************************** PaymentAuthorise is the resource representing a Adyen payment respnse.

type PaymentAuthorise3dParams

type PaymentAuthorise3dParams struct {
	Md              string `json:"md"`
	PaResponse      string `json:"paResponse"`
	ShopperIP       string `json:"shopperIP"`
	MerchantAccount string `json:"merchantAccount"`
}

PaymentAuthorise3dParams struct

type PaymentAuthoriseForRecurringParams

type PaymentAuthoriseForRecurringParams struct {
	AdditionalData   *AdditionalData    `json:"additionalData"` // 3D Secure
	Amount           *Amount            `json:"amount"`
	BrowserInfo      *BrowserInfo       `json:"browserInfo"`
	Reference        string             `json:"reference"`
	ShopperEmail     string             `json:"shopperEmail"`
	ShopperIP        string             `json:"shopperIP"`
	ShopperReference string             `json:"shopperReference"`
	ShopperStatement string             `json:"shopperStatement"`
	Recurring        *RecurringContract `json:"recurring"`
	MerchantAccount  string             `json:"merchantAccount"`
}

PaymentAuthoriseForRecurringParams is the set of parameters that can be used when process an payment.

type PaymentAuthoriseOneClickParams

type PaymentAuthoriseOneClickParams struct {
	AdditionalData                   *AdditionalData    `json:"additionalData"` // 3D Secure
	Amount                           *Amount            `json:"amount"`
	Card                             *Card              `json:"card"`
	Reference                        string             `json:"reference"`
	ShopperEmail                     string             `json:"shopperEmail"`
	ShopperIP                        string             `json:"shopperIP"`
	ShopperReference                 string             `json:"shopperReference"`
	ShopperStatement                 string             `json:"shopperStatement"`
	SelectedRecurringDetailReference string             `json:"selectedRecurringDetailReference"`
	Recurring                        *RecurringContract `json:"recurring"`
	ShopperInteraction               InteractionType    `json:"shopperInteraction"` // Ecommerce
	MerchantAccount                  string             `json:"merchantAccount"`
}

PaymentAuthoriseOneClickParams is the set of parameters that can be used when process an payment.

type PaymentAuthoriseParams

type PaymentAuthoriseParams struct {
	AdditionalData   *AdditionalData `json:"additionalData"` // 3D Secure
	Amount           *Amount         `json:"amount"`
	Reference        string          `json:"reference"`
	ShopperEmail     string          `json:"shopperEmail"`
	ShopperReference string          `json:"shopperReference"`
	ShopperStatement string          `json:"shopperStatement"`
	MerchantAccount  string          `json:"merchantAccount"`
}

PaymentAuthoriseParams struct

type PaymentAuthoriseRecurringParams

type PaymentAuthoriseRecurringParams struct {
	AdditionalData                   *AdditionalData    `json:"additionalData"` // 3D Secure
	Amount                           *Amount            `json:"amount"`
	Reference                        string             `json:"reference"`
	ShopperEmail                     string             `json:"shopperEmail"`
	ShopperIP                        string             `json:"shopperIP"`
	ShopperReference                 string             `json:"shopperReference"`
	ShopperStatement                 string             `json:"shopperStatement"`
	SelectedRecurringDetailReference string             `json:"selectedRecurringDetailReference"`
	Recurring                        *RecurringContract `json:"recurring"`
	ShopperInteraction               InteractionType    `json:"shopperInteraction"` // ContAuth
	MerchantAccount                  string             `json:"merchantAccount"`
}

PaymentAuthoriseRecurringParams is the set of parameters that can be used when process an payment.

type RecurringContract

type RecurringContract struct {
	Contract ContractType `json:"contract"`
}

RecurringContract struct

type RecurringContractParams

type RecurringContractParams struct {
	Contract ContractType `json:"contract"`
}

RecurringContractParams struct

type RecurringData

type RecurringData struct {
	ShopperReference         string `json:"shopperReference"`
	RecurringDetailReference string `json:"recurringDetailReference"`
}

RecurringData struct

type RecurringDetail

type RecurringDetail struct {
	Acquirer                 string                         `json:"acquierer,omitempty"`
	AcquirerAccount          string                         `json:"acquirerAccount,omitempty"`
	AdditionalData           *RecurringDetailAdditionalData `json:"additionalData,omitempty"`
	Alias                    string                         `json:"alias,omitempty"`
	AliasType                string                         `json:"aliasType,omitempty"`
	Card                     *RecurringDetailCard           `json:"card,omitempty"`
	ContractTypes            []string                       `json:"contractTypes,omitempty"`
	CreationDate             *DateTime                      `json:"creationDate,omitempty"`
	FirstPspReference        string                         `json:"firstPspReference,omitempty"`
	PaymentMethodVariant     string                         `json:"paymentMethodVariant,omitempty"`
	RecurringDetailReference string                         `json:"recurringDetailReference,omitempty"`
	Variant                  string                         `json:"variant,omitempty"`
}

RecurringDetail struct

type RecurringDetailAdditionalData

type RecurringDetailAdditionalData struct {
	CardBin string `json:"cardBin,omitempty"`
}

RecurringDetailAdditionalData struct

type RecurringDetailCard

type RecurringDetailCard struct {
	ExpiryMonth string `json:"expiryMonth,omitempty"`
	ExpiryYear  string `json:"expiryYear,omitempty"`
	HolderName  string `json:"holderName,omitempty"`
	Number      string `json:"number,omitempty"`
}

RecurringDetailCard struct

type RecurringDetails

type RecurringDetails struct {
	CreationDate             string     `json:"creationDate,omitempty"`
	LastKnownShopperEmail    string     `json:"lastKnownShopperEmail,omitempty"`
	ShopperReference         string     `json:"shopperReference,omitempty"`
	Details                  []*Details `json:"details,omitempty"`
	InvalidOneclickContracts string     `json:"invalidOneclickContracts"`
}

RecurringDetails is the resource representing a Adyen recurringDetails.

type RecurringDetailsParams

type RecurringDetailsParams struct {
	MerchantAccount  string                   `json:"merchantAccount"`
	ShopperReference string                   `json:"shopperReference"`
	Recurring        *RecurringContractParams `json:"recurring"`
}

RecurringDetailsParams is the set of parameters that can be used when process an recurringDetails.

type RecurringDisable

type RecurringDisable struct {
	Response string     `json:"response"` //"[detail-successfully-disabled]"
	Details  *[]Details `json:"details"`
}

RecurringDisable struct

type RecurringDisableParams

type RecurringDisableParams struct {
	ShopperReference         string `json:"shopperReference"`
	RecurringDetailReference string `json:"recurringDetailReference"`
	MerchantAccount          string `json:"merchantAccount"`
}

RecurringDisableParams is the set of parameters that can be used when process an recurringDisable.

Jump to

Keyboard shortcuts

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