model

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: May 12, 2023 License: MPL-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CustomerAddress

type CustomerAddress struct {
	City       string `cty:"city"`
	Country    string `cty:"country"`
	LineOne    string `cty:"line1"`
	LineTwo    string `cty:"line2"`
	PostalCode string `cty:"postal_code"`
	State      string `cty:"state"`
}

type CustomerAddressParams

type CustomerAddressParams struct {
	City       *string `cty:"city"`
	Country    *string `cty:"country"`
	LineOne    *string `cty:"line1"`
	LineTwo    *string `cty:"line2"`
	PostalCode *string `cty:"postal_code"`
	State      *string `cty:"state"`
}

func (CustomerAddressParams) ToStripeParam

func (p CustomerAddressParams) ToStripeParam() *stripe.AddressParams

type CustomerInvoiceSettings

type CustomerInvoiceSettings struct {
	CustomFields         []CustomerInvoiceSettingsCustomFieldParams    `cty:"custom_fields"`
	DefaultPaymentMethod string                                        `cty:"default_payment_method"`
	Footer               string                                        `cty:"footer"`
	RenderingOptions     CustomerInvoiceSettingsRenderingOptionsParams `cty:"rendering_options"`
}

type CustomerInvoiceSettingsCustomField

type CustomerInvoiceSettingsCustomField struct {
	Name  string `cty:"name"`
	Value string `cty:"name"`
}

type CustomerInvoiceSettingsCustomFieldParams

type CustomerInvoiceSettingsCustomFieldParams struct {
	Name  *string `cty:"name"`
	Value *string `cty:"name"`
}

func (*CustomerInvoiceSettingsCustomFieldParams) ToStripeParam

type CustomerInvoiceSettingsParams

type CustomerInvoiceSettingsParams struct {
	CustomFields         []*CustomerInvoiceSettingsCustomFieldParams    `cty:"custom_fields"`
	DefaultPaymentMethod *string                                        `cty:"default_payment_method"`
	Footer               *string                                        `cty:"footer"`
	RenderingOptions     *CustomerInvoiceSettingsRenderingOptionsParams `cty:"rendering_options"`
}

func (*CustomerInvoiceSettingsParams) ToStripeParam

type CustomerInvoiceSettingsRenderingOptions

type CustomerInvoiceSettingsRenderingOptions struct {
	AmountTaxDisplay string `cty:"amount_tax_display"`
}

type CustomerInvoiceSettingsRenderingOptionsParams

type CustomerInvoiceSettingsRenderingOptionsParams struct {
	AmountTaxDisplay *string `cty:"amount_tax_display"`
}

func (*CustomerInvoiceSettingsRenderingOptionsParams) ToStripeParams

type CustomerParams

type CustomerParams struct {
	Address             *CustomerAddressParams         `cty:"address"`
	Description         *string                        `cty:"description"`
	Email               *string                        `cty:"email"`
	Metadata            *map[string]string             `cty:"metadata"`
	Name                *string                        `cty:"name"`
	PaymentMethod       *string                        `cty:"payment_method"`
	Phone               *string                        `cty:"phone"`
	Shipping            *CustomerShippingParams        `cty:"shipping"`
	Balance             *int64                         `cty:"balance"`
	Coupon              *string                        `cty:"coupon"`
	InvoicePrefix       *string                        `cty:"invoice_prefix"`
	InvoiceSettings     *CustomerInvoiceSettingsParams `cty:"invoice_settings"`
	NextInvoiceSequence *int64                         `cty:"next_invoice_sequence"`
	PreferredLocales    []*string                      `cty:"preferred_locales"`
	PromotionCode       *string                        `cty:"promotion_code"`
	Tax                 *CustomerTaxParams             `cty:"tax"`
	TaxExempt           *string                        `cty:"tax_exempt"`
	TaxIdData           []*CustomerTaxIdDataParams     `cty:"tax_id_data"`
	TestClock           *string                        `cty:"test_clock"`
}

func (CustomerParams) ToStripeCustomerParams

func (p CustomerParams) ToStripeCustomerParams() *stripe.CustomerParams

type CustomerResponse

type CustomerResponse struct {
	Address             *CustomerAddress  `cty:"address"`
	Description         string            `cty:"description"`
	Email               string            `cty:"email"`
	Metadata            map[string]string `cty:"metadata"`
	Name                string            `cty:"name"`
	DefaultSource       string            `cty:"default_source"`
	Phone               string            `cty:"phone"`
	Shipping            *CustomerShipping `cty:"shipping"`
	Balance             int64             `cty:"balance"`
	InvoicePrefix       string            `cty:"invoice_prefix"`
	NextInvoiceSequence int64             `cty:"next_invoice_sequence"`
	PreferredLocales    []string          `cty:"preferred_locales"`
	PromotionCode       string            `cty:"promotion_code"`
	Tax                 *CustomerTax      `cty:"tax"`
	TaxExempt           string            `cty:"tax_exempt"`
}

func FromStripeCustomer

func FromStripeCustomer(res *stripe.Customer) CustomerResponse

type CustomerShipping

type CustomerShipping struct {
	Address        CustomerAddressParams `cty:"address"`
	Name           string                `cty:"name"`
	Phone          string                `cty:"phone"`
	Carrier        string                `cty:"carrier"`
	TrackingNumber string                `cty:"tracking_number"`
}

type CustomerShippingParams

type CustomerShippingParams struct {
	Address CustomerAddressParams `cty:"address"`
	Name    *string               `cty:"name"`
	Phone   *string               `cty:"phone"`
}

func (*CustomerShippingParams) ToStripeParam

type CustomerTax

type CustomerTax struct {
	IpAddress string `cty:"ip_address"`
}

type CustomerTaxIdData

type CustomerTaxIdData struct {
	Type  string `cty:"type"`
	Value string `cty:"value"`
}

type CustomerTaxIdDataParams

type CustomerTaxIdDataParams struct {
	Type  *string `cty:"type"`
	Value *string `cty:"value"`
}

func (*CustomerTaxIdDataParams) ToStripeParams

type CustomerTaxParams

type CustomerTaxParams struct {
	IpAddress *string `cty:"ip_address"`
}

func (*CustomerTaxParams) ToStripeParams

func (p *CustomerTaxParams) ToStripeParams() *stripe.CustomerTaxParams

Jump to

Keyboard shortcuts

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