Documentation
¶
Overview ¶
Package sub provides the /subscriptions APIs
Index ¶
- func Cancel(id string, params *stripe.SubscriptionCancelParams) (*stripe.Subscription, error)
- func Get(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
- func New(params *stripe.SubscriptionParams) (*stripe.Subscription, error)
- func Update(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
- type Client
- func (c Client) Cancel(id string, params *stripe.SubscriptionCancelParams) (*stripe.Subscription, error)
- func (c Client) Get(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
- func (c Client) List(listParams *stripe.SubscriptionListParams) *Iter
- func (c Client) New(params *stripe.SubscriptionParams) (*stripe.Subscription, error)
- func (c Client) Search(params *stripe.SubscriptionSearchParams) *SearchIter
- func (c Client) Update(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
- type Iter
- type SearchIter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Cancel ¶
func Cancel(id string, params *stripe.SubscriptionCancelParams) (*stripe.Subscription, error)
Cancel removes a subscription.
func Get ¶
func Get(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
Get returns the details of a subscription.
func New ¶
func New(params *stripe.SubscriptionParams) (*stripe.Subscription, error)
New creates a new subscription.
func Update ¶
func Update(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
Update updates a subscription's properties.
Types ¶
type Client ¶
Client is used to invoke /subscriptions APIs.
func (Client) Cancel ¶
func (c Client) Cancel(id string, params *stripe.SubscriptionCancelParams) (*stripe.Subscription, error)
Cancel removes a subscription.
func (Client) Get ¶
func (c Client) Get(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
Get returns the details of a subscription.
func (Client) List ¶
func (c Client) List(listParams *stripe.SubscriptionListParams) *Iter
List returns a list of subscriptions.
func (Client) New ¶
func (c Client) New(params *stripe.SubscriptionParams) (*stripe.Subscription, error)
New creates a new subscription.
func (Client) Search ¶ added in v72.97.0
func (c Client) Search(params *stripe.SubscriptionSearchParams) *SearchIter
Search returns a search result containing subscriptions.
func (Client) Update ¶
func (c Client) Update(id string, params *stripe.SubscriptionParams) (*stripe.Subscription, error)
Update updates a subscription's properties.
type Iter ¶
Iter is an iterator for subscriptions.
func List ¶
func List(params *stripe.SubscriptionListParams) *Iter
List returns a list of subscriptions.
func (*Iter) Subscription ¶
func (i *Iter) Subscription() *stripe.Subscription
Subscription returns the subscription which the iterator is currently pointing to.
func (*Iter) SubscriptionList ¶
func (i *Iter) SubscriptionList() *stripe.SubscriptionList
SubscriptionList returns the current list object which the iterator is currently using. List objects will change as new API calls are made to continue pagination.
type SearchIter ¶ added in v72.97.0
type SearchIter struct {
*stripe.SearchIter
}
SearchIter is an iterator for subscriptions.
func Search ¶ added in v72.97.0
func Search(params *stripe.SubscriptionSearchParams) *SearchIter
Search returns a search result containing subscriptions.
func (*SearchIter) Subscription ¶ added in v72.97.0
func (i *SearchIter) Subscription() *stripe.Subscription
Subscription returns the subscription which the iterator is currently pointing to.
func (*SearchIter) SubscriptionSearchResult ¶ added in v72.97.0
func (i *SearchIter) SubscriptionSearchResult() *stripe.SubscriptionSearchResult
SubscriptionSearchResult returns the current list object which the iterator is currently using. List objects will change as new API calls are made to continue pagination.