bucket

package
v0.16.0 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2021 License: Apache-2.0 Imports: 4 Imported by: 1

Documentation

Overview

Package bucket contains auto-generated files. DO NOT MODIFY

Package bucket contains auto-generated files. DO NOT MODIFY

Package bucket contains auto-generated files. DO NOT MODIFY

Package bucket contains auto-generated files. DO NOT MODIFY

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client for managing a specific rate limit bucket resource See https://www.twilio.com/docs/verify/api/service-rate-limit-buckets for more details

func New

func New(client *client.Client, properties ClientProperties) *Client

New creates a new instance of the bucket client

func (Client) Delete

func (c Client) Delete() error

Delete removes a rate limit bucket resource from the account See https://www.twilio.com/docs/verify/api/service-rate-limit-buckets#delete-a-bucket for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information

func (Client) DeleteWithContext

func (c Client) DeleteWithContext(context context.Context) error

DeleteWithContext removes a rate limit bucket resource from the account See https://www.twilio.com/docs/verify/api/service-rate-limit-buckets#delete-a-bucket for more details

func (Client) Fetch

func (c Client) Fetch() (*FetchBucketResponse, error)

Fetch retrieves a rate limit bucket resource See https://www.twilio.com/docs/verify/api/service-rate-limit-buckets#fetch-a-bucket for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information

func (Client) FetchWithContext

func (c Client) FetchWithContext(context context.Context) (*FetchBucketResponse, error)

FetchWithContext retrieves a rate limit bucket resource See https://www.twilio.com/docs/verify/api/service-rate-limit-buckets#fetch-a-bucket for more details

func (Client) Update

func (c Client) Update(input *UpdateBucketInput) (*UpdateBucketResponse, error)

Update modifies a rate limit bucket resource See https://www.twilio.com/docs/verify/api/service-rate-limit-buckets#update-a-bucket for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information

func (Client) UpdateWithContext

func (c Client) UpdateWithContext(context context.Context, input *UpdateBucketInput) (*UpdateBucketResponse, error)

UpdateWithContext modifies a rate limit bucket resource See https://www.twilio.com/docs/verify/api/service-rate-limit-buckets#update-a-bucket for more details

type ClientProperties

type ClientProperties struct {
	RateLimitSid string
	ServiceSid   string
	Sid          string
}

ClientProperties are the properties required to manage the bucket resources

type FetchBucketResponse

type FetchBucketResponse struct {
	AccountSid   string     `json:"account_sid"`
	DateCreated  time.Time  `json:"date_created"`
	DateUpdated  *time.Time `json:"date_updated,omitempty"`
	Interval     int        `json:"interval"`
	Max          int        `json:"max"`
	RateLimitSid string     `json:"rate_limit_sid"`
	ServiceSid   string     `json:"service_sid"`
	Sid          string     `json:"sid"`
	URL          string     `json:"url"`
}

FetchBucketResponse defines the response fields for the retrieved rate limit bucket

type UpdateBucketInput

type UpdateBucketInput struct {
	Interval *int `form:"Interval,omitempty"`
	Max      *int `form:"Max,omitempty"`
}

UpdateBucketInput defines input fields for updating a rate limit bucket resource

type UpdateBucketResponse

type UpdateBucketResponse struct {
	AccountSid   string     `json:"account_sid"`
	DateCreated  time.Time  `json:"date_created"`
	DateUpdated  *time.Time `json:"date_updated,omitempty"`
	Interval     int        `json:"interval"`
	Max          int        `json:"max"`
	RateLimitSid string     `json:"rate_limit_sid"`
	ServiceSid   string     `json:"service_sid"`
	Sid          string     `json:"sid"`
	URL          string     `json:"url"`
}

UpdateBucketResponse defines the response fields for the updated rate limit bucket

Jump to

Keyboard shortcuts

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