Versions in this module Expand all Collapse all v1 v1.0.9 Sep 22, 2021 Changes in this version + var ErrInvalidKey = errors.New("invalid public or secret key") + func WebhookHTTPHandler(handler EventHandler) http.Handler + type Account struct + Email string + type AccountList struct + Data []*Account + func (list *AccountList) Find(id string) *Account + type Balance struct + Available int64 + Currency string + Total int64 + type BalanceList struct + Data []*Balance + func (list *BalanceList) Find(id string) *Balance + type Bank struct + Active bool + Code string + Name string + type BankAccount struct + AccountType BankAccountType + BankCode string + BranchCode string + Brand string + LastDigits string + Name string + Number string + type BankAccountList struct + Data []*BankAccount + func (list *BankAccountList) Find(id string) *BankAccount + type BankAccountType string + const Current + const Normal + type Base struct + Created time.Time + ID string + Live bool + Location *string + Object string + type Capability struct + Banks []string + Country string + Location string + Object string + PaymentMethods []PaymentMethod + ZeroInterestInstallments bool + type Card struct + Bank string + Brand string + City string + Country string + ExpirationMonth time.Month + ExpirationYear int + Financing string + Fingerprint string + LastDigits string + Name string + PostalCode string + SecurityCodeCheck bool + type CardList struct + Data []*Card + func (list *CardList) Find(id string) *Card + type Charge struct + Amount int64 + AuthorizeURI string + Authorized bool + Capture bool + Card *Card + Currency string + CustomerID string + Description *string + Dispute *Dispute + FailureCode *string + FailureMessage *string + IP *string + Metadata map[string]interface{} + Offsite OffsiteTypes + Paid bool + Refunded int64 + Refunds *RefundList + ReturnURI string + Reversed bool + Source *Source + SourceOfFund SourceOfFunds + Status ChargeStatus + Transaction string + type ChargeList struct + Data []*Charge + func (list *ChargeList) Find(id string) *Charge + type ChargeSearchResult struct + Data []*Charge + type ChargeStatus string + const ChargeFailed + const ChargePending + const ChargeReversed + const ChargeSuccessful + type Client struct + APIVersion string + Endpoints map[core.Endpoint]string + GoVersion string + func NewClient(pkey, skey string) (*Client, error) + func (c *Client) Do(result interface{}, operation core.Operation) error + func (c *Client) Request(operation core.Operation) (req *http.Request, err error) + type Customer struct + Cards *CardList + DefaultCard string + Description string + Email string + Metadata map[string]interface{} + type CustomerList struct + Data []*Customer + func (list *CustomerList) Find(id string) *Customer + type CustomerSearchResult struct + Data []*Customer + type Date time.Time + func (d *Date) UnmarshalJSON(b []byte) error + func (d Date) MarshalJSON() ([]byte, error) + func (d Date) String() string + type Deletion struct + Deleted bool + type DeletionList struct + Data []*Deletion + func (list *DeletionList) Find(id string) *Deletion + type Dispute struct + Amount int64 + Charge string + Currency string + Message string + Metadata map[string]interface{} + Status DisputeStatus + type DisputeList struct + Data []*Dispute + func (list *DisputeList) Find(id string) *Dispute + type DisputeSearchResult struct + Data []*Dispute + type DisputeStatus string + const Closed + const Lost + const Open + const Pending + const Won + type Document struct + Deleted bool + DownloadURI string + Filename string + type DocumentList struct + Data []*Document + func (list *DocumentList) Find(id string) *Document + type ErrInternal string + func (err ErrInternal) Error() string + type ErrTransport struct + Buffer []byte + Err error + func (err ErrTransport) Error() string + type Error struct + Code string + Location string + Message string + StatusCode int + func (err *Error) Error() string + func (err *Error) String() string + type Event struct + Data interface{} + Key string + func (ev *Event) UnmarshalJSON(buffer []byte) error + type EventHandler interface + HandleEvent func(http.ResponseWriter, *http.Request, *Event) + type EventHandlerFunc func(http.ResponseWriter, *http.Request, *Event) + func (f EventHandlerFunc) HandleEvent(resp http.ResponseWriter, req *http.Request, event *Event) + type EventList struct + Data []*Event + func (list *EventList) Find(id string) *Event + type Link struct + Amount int64 + Charges ChargeList + Currency string + Description string + Multiple bool + PaymentURI string + Title string + Used bool + type LinkList struct + Data []*Link + func (list *LinkList) Find(id string) *Link + type LinkSearchResult struct + Data []*Link + type List struct + From string + Limit int + Offset int + Order Ordering + To string + Total int + type Occurrence struct + Message string + ProcessedAt time.Time + Result string + RetryDate Date + Schedule string + ScheduleDate Date + Status schedule.OccurrenceStatus + type OccurrenceList struct + Data []*Occurrence + func (list *OccurrenceList) Find(id string) *Occurrence + type OccurrenceStatus string + const OccurrenceFailed + const OccurrenceSkip + const OccurrenceSuccessful + type OffsiteTypes string + const Alipay + const InternetBankingBAY + const InternetBankingBBL + const InternetBankingKTB + const InternetBankingSCB + type Ordering string + const Chronological + const ReverseChronological + const UnspecifiedOrder + type PaymentMethod struct + Banks []Bank + CardBrands []string + Currencies []string + InstallmentTerms []int + Name string + Object string + type Receipt struct + ChargeFee int64 + CompanyAddress string + CompanyName string + CompanyTaxID string + CreditNote bool + Currency string + CustomerAddress string + CustomerEmail string + CustomerName string + CustomerStatementName string + CustomerTaxID string + Date time.Time + Number string + SubTotal int64 + Total int64 + TransferFee int64 + VAT int64 + VoidedFee int64 + WHT int64 + type ReceiptList struct + Data []*Receipt + func (list *ReceiptList) Find(id string) *Receipt + type Recipient struct + Active bool + BankAccount *BankAccount + Description *string + Email string + FailureCode *string + Name string + TaxID *string + Type RecipientType + Verified bool + type RecipientList struct + Data []*Recipient + func (list *RecipientList) Find(id string) *Recipient + type RecipientSearchResult struct + Data []*Recipient + type RecipientType string + const Corporation + const Individual + type References struct + Barcode string + ExpiresAt time.Time + type Refund struct + Amount int64 + Charge string + Currency string + Metadata map[string]interface{} + Transaction string + type RefundList struct + Data []*Refund + func (list *RefundList) Find(id string) *Refund + type RefundSearchResult struct + Data []*Refund + type ScannableCode struct + Image *Document + Object string + Type string + type Schedule struct + Charge *schedule.ChargeDetail + EndDate Date + Every int + InWords string + NextOccurrences []Date + Occurrences OccurrenceList + On schedule.On + Period schedule.Period + StartDate Date + Status schedule.Status + Transfer *schedule.TransferDetail + type ScheduleList struct + Data []*Schedule + func (list *ScheduleList) Find(id string) *Schedule + type SearchResult struct + Filters map[string]string + Order Ordering + Page int + Query string + Scope SearchScope + Total int + TotalPages int + type SearchScope string + const ChargeScope + const CustomerScope + const DisputeScope + const LinkScope + const RecipientScope + const RefundScope + const TransferScope + const UnspecifiedScope + type Source struct + Amount int64 + Currency string + Flow string + References *References + ScannableCode *ScannableCode + Type string + ZeroInterestInstallments bool + type SourceOfFunds string + const FromCard + const FromOffsite + type Token struct + Card *Card + Used bool + type TokenList struct + Data []*Token + func (list *TokenList) Find(id string) *Token + type Transaction struct + Amount int64 + Currency string + Source string + Transferable time.Time + Type TransactionType + type TransactionList struct + Data []*Transaction + func (list *TransactionList) Find(id string) *Transaction + type TransactionType string + const Credit + const Debit + type Transfer struct + Amount int64 + BankAccount *BankAccount + Currency string + FailureCode *string + FailureMessage *string + Fee int64 + Metadata map[string]interface{} + Paid bool + Recipient string + Sent bool + Transaction *string + type TransferList struct + Data []*Transfer + func (list *TransferList) Find(id string) *Transfer + type TransferSearchResult struct + Data []*Transfer