Documentation
¶
Index ¶
- Variables
- type Alert
- type Client
- func (c *Client) ParseInvoiceOverdueWebhook(form url.Values) (InvoiceOverdue, error)
- func (c *Client) ParseInvoicePaidWebhook(form url.Values) (InvoicePaid, error)
- func (c *Client) ParseInvoiceSentWebhook(form url.Values) (InvoiceSent, error)
- func (c *Client) ParsePaymentSucceededWebhook(form url.Values) (PaymentSucceeded, error)
- func (c *Client) ParseSubscriptionCancelledWebhook(form url.Values) (SubscriptionCancelled, error)
- func (c *Client) ParseSubscriptionCreatedWebhook(form url.Values) (SubscriptionCreated, error)
- func (c *Client) ParseSubscriptionPaymentFailedWebhook(form url.Values) (SubscriptionPaymentFailed, error)
- func (c *Client) ParseSubscriptionPaymentRefundedWebhook(form url.Values) (SubscriptionPaymentRefunded, error)
- func (c *Client) ParseSubscriptionPaymentSucceededWebhook(form url.Values) (SubscriptionPaymentSucceeded, error)
- func (c *Client) ParseSubscriptionUpdatedWebhook(form url.Values) (SubscriptionUpdated, error)
- func (c *Client) ParseTransferCreatedWebhook(form url.Values) (TransferCreated, error)
- func (c *Client) ParseTransferPaidWebhook(form url.Values) (TransferPaid, error)
- func (c *Client) SetVerification(b bool)
- type InvoiceOverdue
- type InvoicePaid
- type InvoiceSent
- type PausedReason
- type PaymentMethod
- type PaymentSucceeded
- type RefundType
- type Status
- type SubscriptionCancelled
- type SubscriptionCreated
- type SubscriptionPaymentFailed
- type SubscriptionPaymentRefunded
- type SubscriptionPaymentSucceeded
- type SubscriptionUpdated
- type TransferCreated
- type TransferPaid
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrInvalidSignature = errors.New("paddle: invalid signature")
)
Functions ¶
This section is empty.
Types ¶
type Alert ¶
type Alert string
const ( AlertSubscriptionCreated Alert = "subscription_created" AlertSubscriptionUpdated Alert = "subscription_updated" AlertSubscriptionCancelled Alert = "subscription_cancelled" AlertSubscriptionPaymentSucceeded Alert = "subscription_payment_succeeded" AlertSubscriptionPaymentFailed Alert = "subscription_payment_failed" AlertSubscriptionPaymentRefunded Alert = "subscription_payment_refunded" AlertPaymentSucceeded Alert = "payment_succeeded" AlertPaymentRefunded Alert = "payment_refunded" AlertLockerProcessed Alert = "locker_processed" AlertPaymentDisputeCreated Alert = "payment_dispute_created" AlertPaymentDisputeClosed Alert = "payment_dispute_closed" AlertHighRiskTransactionCreated Alert = "high_risk_transaction_created" AlertHighRiskTransactionUpdated Alert = "high_risk_transaction_updated" AlertTransferCreated Alert = "transfer_created" AlertTransferPaid Alert = "transfer_paid" AlertNewAudienceMember Alert = "new_audience_member" AlertUpdateAudienceMember Alert = "update_audience_member" AlertInvoicePaid Alert = "invoice_paid" AlertInvoiceSent Alert = "invoice_sent" AlertInvoiceOverdue Alert = "invoice_overdue" )
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) ParseInvoiceOverdueWebhook ¶ added in v1.1.0
func (c *Client) ParseInvoiceOverdueWebhook(form url.Values) (InvoiceOverdue, error)
func (*Client) ParseInvoicePaidWebhook ¶ added in v1.1.0
func (c *Client) ParseInvoicePaidWebhook(form url.Values) (InvoicePaid, error)
func (*Client) ParseInvoiceSentWebhook ¶ added in v1.1.0
func (c *Client) ParseInvoiceSentWebhook(form url.Values) (InvoiceSent, error)
func (*Client) ParsePaymentSucceededWebhook ¶ added in v1.1.0
func (c *Client) ParsePaymentSucceededWebhook(form url.Values) (PaymentSucceeded, error)
func (*Client) ParseSubscriptionCancelledWebhook ¶
func (c *Client) ParseSubscriptionCancelledWebhook(form url.Values) (SubscriptionCancelled, error)
func (*Client) ParseSubscriptionCreatedWebhook ¶
func (c *Client) ParseSubscriptionCreatedWebhook(form url.Values) (SubscriptionCreated, error)
func (*Client) ParseSubscriptionPaymentFailedWebhook ¶ added in v1.1.0
func (c *Client) ParseSubscriptionPaymentFailedWebhook(form url.Values) (SubscriptionPaymentFailed, error)
func (*Client) ParseSubscriptionPaymentRefundedWebhook ¶
func (c *Client) ParseSubscriptionPaymentRefundedWebhook(form url.Values) (SubscriptionPaymentRefunded, error)
func (*Client) ParseSubscriptionPaymentSucceededWebhook ¶
func (c *Client) ParseSubscriptionPaymentSucceededWebhook(form url.Values) (SubscriptionPaymentSucceeded, error)
func (*Client) ParseSubscriptionUpdatedWebhook ¶
func (c *Client) ParseSubscriptionUpdatedWebhook(form url.Values) (SubscriptionUpdated, error)
func (*Client) ParseTransferCreatedWebhook ¶ added in v1.1.0
func (c *Client) ParseTransferCreatedWebhook(form url.Values) (TransferCreated, error)
func (*Client) ParseTransferPaidWebhook ¶ added in v1.1.0
func (c *Client) ParseTransferPaidWebhook(form url.Values) (TransferPaid, error)
func (*Client) SetVerification ¶
type InvoiceOverdue ¶ added in v1.1.0
type InvoiceOverdue struct { AlertName Alert AlertID string PaymentID string Amount string SaleGross string TermDays string Status Status PurchaseOrderNumber string InvoicedAt time.Time Currency string ProductID string ProductName string ProductAdditionalInformation string CustomerID string CustomerName string Email string CustomerVatNumber string CustomerCompanyNumber string CustomerAddress string CustomerCity string CustomerState string CustomerZipcode string Country string ContractID string ContractStartDate time.Time ContractEndDate time.Time Passthrough string DateCreated time.Time BalanceCurrency string PaymentTax string PaymentMethod PaymentMethod Fee string Earnings string EventTime time.Time }
type InvoicePaid ¶ added in v1.1.0
type InvoicePaid struct { AlertName Alert AlertID string PaymentID string Amount string SaleGross string TermDays string Status Status PurchaseOrderNumber string InvoicedAt time.Time Currency string ProductID string ProductName string ProductAdditionalInformation string CustomerID string CustomerName string Email string CustomerVatNumber string CustomerCompanyNumber string CustomerAddress string CustomerCity string CustomerState string CustomerZipcode string Country string ContractID string ContractStartDate time.Time ContractEndDate time.Time Passthrough string DateCreated time.Time BalanceCurrency string PaymentTax string PaymentMethod PaymentMethod Fee string Earnings string BalanceEarnings string BalanceFee string BalanceTax string BalanceGross string DateReconciled time.Time EventTime time.Time }
type InvoiceSent ¶ added in v1.1.0
type InvoiceSent struct { AlertName Alert AlertID string PaymentID string Amount string SaleGross string TermDays string Status Status PurchaseOrderNumber string InvoicedAt time.Time Currency string ProductID string ProductName string ProductAdditionalInformation string CustomerID string CustomerName string Email string CustomerVatNumber string CustomerCompanyNumber string CustomerAddress string CustomerCity string CustomerState string CustomerZipcode string Country string ContractID string ContractStartDate time.Time ContractEndDate time.Time Passthrough string DateCreated time.Time BalanceCurrency string PaymentTax string PaymentMethod PaymentMethod Fee string Earnings string EventTime time.Time }
type PausedReason ¶
type PausedReason string
const ( PausedReasonDelinquent PausedReason = "delinquent" PausedReasonVoluntary PausedReason = "voluntary" )
type PaymentMethod ¶
type PaymentMethod string
PaymentMethod defines possible payment method type.
const ( PaymentMethodCard PaymentMethod = "card" PaymentMethodPayPal PaymentMethod = "paypal" PaymentMethodFree PaymentMethod = "free" PaymentMethodApplePay PaymentMethod = "apple-pay" PaymentMethodWireTransfer PaymentMethod = "wire-transfer" )
type PaymentSucceeded ¶ added in v1.1.0
type PaymentSucceeded struct { AlertName Alert AlertID string BalanceCurrency string BalanceEarnings string BalanceFee string BalanceGross string BalanceTax string CheckoutID string Country string Coupon string Currency string CustomerName string Earnings string Email string EventTime time.Time Fee string MarketingConsent bool OrderID string // IP defines user IP. // Deprecated, see https://developer.paddle.com/webhook-reference/one-off-purchase-alerts/payment-succeeded IP string Passthrough string PaymentMethod PaymentMethod PaymentTax string ProductID string ProductName string Quantity int ReceiptURL string SaleGross string UsedPriceOverride bool }
type RefundType ¶
type RefundType string
RefundType defines possible reason for refund.
const ( RefundTypeFull RefundType = "full" RefundTypeVat RefundType = "vat" RefundTypePartial RefundType = "partial" )
type SubscriptionCancelled ¶
type SubscriptionCancelled struct { AlertName Alert AlertID string CancellationEffectiveDate time.Time CheckoutID string Currency string Email string EventTime time.Time MarketingConsent bool Passthrough string Quantity int Status Status SubscriptionID string SubscriptionPlanID string UnitPrice string UserID string }
type SubscriptionCreated ¶
type SubscriptionCreated struct { AlertName Alert AlertID string CancelURL string CheckoutID string Currency string Email string EventTime time.Time MarketingConsent bool NextBillDate time.Time Passthrough string Quantity int Source string Status Status SubscriptionID string SubscriptionPlanID string UnitPrice string UserID string UpdateURL string }
type SubscriptionPaymentFailed ¶ added in v1.1.0
type SubscriptionPaymentFailed struct { AlertName Alert AlertID string Amount string CancelURL string CheckoutID string Currency string Email string EventTime time.Time MarketingConsent bool NextRetryDate time.Time Passthrough string Quantity int Status Status SubscriptionID string SubscriptionPlanID string UnitPrice string UpdateURL string SubscriptionPaymentID string Installments int OrderID string UserID string AttemptNumber int }
type SubscriptionPaymentRefunded ¶
type SubscriptionPaymentRefunded struct { AlertName Alert AlertID string Amount string BalanceCurrency string BalanceEarningsDecrease string BalanceFeeRefund string BalanceGrossRefund string BalanceTaxRefund string CheckoutID string Currency string EarningsDecrease string Email string EventTime time.Time FeeRefund string GrossRefund string InitialPayment bool Instalments string MarketingConsent bool OrderID string Passthrough string Quantity int RefundReason string RefundType RefundType Status Status SubscriptionID string SubscriptionPaymentID string SubscriptionPlanID string TaxRefund string UnitPrice string UserID string }
type SubscriptionPaymentSucceeded ¶
type SubscriptionPaymentSucceeded struct { AlertName Alert AlertID string BalanceCurrency string BalanceEarnings string BalanceFee string BalanceGross string BalanceTax string CheckoutID string Country string Coupon string Currency string CustomerName string Earnings string Email string EventTime time.Time Fee string InitialPayment bool Instalments string MarketingConsent bool NextBillDate time.Time NextPaymentAmount string OrderID string Passthrough string PaymentMethod PaymentMethod PaymentTax string PlanName string Quantity int ReceiptURL string SaleGross string Status Status SubscriptionID string SubscriptionPaymentID string SubscriptionPlanID string UnitPrice string UserID string }
type SubscriptionUpdated ¶
type SubscriptionUpdated struct { AlertName Alert AlertID string UpdateURL string CancelURL string CheckoutID string Currency string Email string EventTime time.Time MarketingConsent bool NewPrice string NewQuantity int NewUnitPrice string NextBillDate time.Time Passthrough string Status Status SubscriptionID string SubscriptionPlanID string UserID string OldNextBillDate time.Time OldPrice string OldQuantity int OldStatus Status OldSubscriptionPlanID string OldUnitPrice string PausedAt time.Time PausedFrom time.Time PausedReason PausedReason }
type TransferCreated ¶ added in v1.1.0
Source Files
¶
- signature.go
- structs.go
- webhook_invoice_overdue.go
- webhook_invoice_paid.go
- webhook_invoice_sent.go
- webhook_payment_succeeded.go
- webhook_subscription_cancelled.go
- webhook_subscription_created.go
- webhook_subscription_payment_failed.go
- webhook_subscription_payment_refunded.go
- webhook_subscription_payment_succeeded.go
- webhook_subscription_updated.go
- webhook_transfer_created.go
- webhook_transfer_paid.go
- webhooks.go
Click to show internal directories.
Click to hide internal directories.