invoice

package
v34.2.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2018 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package invoice provides the /invoices APIs

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get(id string, params *stripe.InvoiceParams) (*stripe.Invoice, error)

Get returns the details of an invoice. For more details see https://stripe.com/docs/api#retrieve_invoice.

func GetNext

func GetNext(params *stripe.InvoiceParams) (*stripe.Invoice, error)

GetNext returns the upcoming invoice's properties. For more details see https://stripe.com/docs/api#retrieve_customer_invoice.

func New

func New(params *stripe.InvoiceParams) (*stripe.Invoice, error)

New POSTs new invoices. For more details see https://stripe.com/docs/api#create_invoice.

func Pay

func Pay(id string, params *stripe.InvoicePayParams) (*stripe.Invoice, error)

Pay pays an invoice. For more details see https://stripe.com/docs/api#pay_invoice.

func Update

func Update(id string, params *stripe.InvoiceParams) (*stripe.Invoice, error)

Update updates an invoice's properties. For more details see https://stripe.com/docs/api#update_invoice.

Types

type Client

type Client struct {
	B   stripe.Backend
	Key string
}

Client is the client used to invoke /invoices APIs.

func (Client) Get

func (c Client) Get(id string, params *stripe.InvoiceParams) (*stripe.Invoice, error)

func (Client) GetNext

func (c Client) GetNext(params *stripe.InvoiceParams) (*stripe.Invoice, error)

func (Client) List

func (c Client) List(listParams *stripe.InvoiceListParams) *Iter

func (Client) ListLines

func (c Client) ListLines(listParams *stripe.InvoiceLineListParams) *LineIter

func (Client) New

func (c Client) New(params *stripe.InvoiceParams) (*stripe.Invoice, error)

func (Client) Pay

func (c Client) Pay(id string, params *stripe.InvoicePayParams) (*stripe.Invoice, error)

func (Client) Update

func (c Client) Update(id string, params *stripe.InvoiceParams) (*stripe.Invoice, error)

type Iter

type Iter struct {
	*stripe.Iter
}

Iter is an iterator for lists of Invoices. The embedded Iter carries methods with it; see its documentation for details.

func List

func List(params *stripe.InvoiceListParams) *Iter

List returns a list of invoices. For more details see https://stripe.com/docs/api#list_customer_invoices.

func (*Iter) Invoice

func (i *Iter) Invoice() *stripe.Invoice

Invoice returns the most recent Invoice visited by a call to Next.

type LineIter

type LineIter struct {
	*stripe.Iter
}

LineIter is an iterator for lists of InvoiceLines. The embedded Iter carries methods with it; see its documentation for details.

func ListLines

func ListLines(params *stripe.InvoiceLineListParams) *LineIter

ListLines returns a list of line items. For more details see https://stripe.com/docs/api#invoice_lines.

func (*LineIter) InvoiceLine

func (i *LineIter) InvoiceLine() *stripe.InvoiceLine

InvoiceLine returns the most recent InvoiceLine visited by a call to Next.

Jump to

Keyboard shortcuts

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