customer_segments

package
v0.0.0-...-dc3cc4a Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

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 customer segments API

func (*Client) ListCustomerSegments

func (a *Client) ListCustomerSegments(params *ListCustomerSegmentsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*ListCustomerSegmentsOK, error)

ListCustomerSegments lists customer segments

Retrieves the list of customer segments of a business.

func (*Client) RetrieveCustomerSegment

func (a *Client) RetrieveCustomerSegment(params *RetrieveCustomerSegmentParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*RetrieveCustomerSegmentOK, error)

RetrieveCustomerSegment retrieves customer segment

Retrieves a specific customer segment as identified by the `segment_id` value.

func (*Client) SetTransport

func (a *Client) SetTransport(transport runtime.ClientTransport)

SetTransport changes the transport on the client

type ClientOption

type ClientOption func(*runtime.ClientOperation)

ClientOption is the option for Client methods

type ClientService

type ClientService interface {
	ListCustomerSegments(params *ListCustomerSegmentsParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*ListCustomerSegmentsOK, error)

	RetrieveCustomerSegment(params *RetrieveCustomerSegmentParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*RetrieveCustomerSegmentOK, error)

	SetTransport(transport runtime.ClientTransport)
}

ClientService is the interface for Client methods

func New

func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService

New creates a new customer segments API client.

type ListCustomerSegmentsOK

type ListCustomerSegmentsOK struct {
	Payload *models.ListCustomerSegmentsResponse
}
ListCustomerSegmentsOK describes a response with status code 200, with default header values.

Success

func NewListCustomerSegmentsOK

func NewListCustomerSegmentsOK() *ListCustomerSegmentsOK

NewListCustomerSegmentsOK creates a ListCustomerSegmentsOK with default headers values

func (*ListCustomerSegmentsOK) Error

func (o *ListCustomerSegmentsOK) Error() string

func (*ListCustomerSegmentsOK) GetPayload

type ListCustomerSegmentsParams

type ListCustomerSegmentsParams struct {

	/* Cursor.

	     A pagination cursor returned by previous calls to __ListCustomerSegments__.
	Used to retrieve the next set of query results.

	See the [Pagination guide](https://developer.squareup.com/docs/docs/working-with-apis/pagination) for more information.
	*/
	Cursor *string

	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

ListCustomerSegmentsParams contains all the parameters to send to the API endpoint

for the list customer segments operation.

Typically these are written to a http.Request.

func NewListCustomerSegmentsParams

func NewListCustomerSegmentsParams() *ListCustomerSegmentsParams

NewListCustomerSegmentsParams creates a new ListCustomerSegmentsParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewListCustomerSegmentsParamsWithContext

func NewListCustomerSegmentsParamsWithContext(ctx context.Context) *ListCustomerSegmentsParams

NewListCustomerSegmentsParamsWithContext creates a new ListCustomerSegmentsParams object with the ability to set a context for a request.

func NewListCustomerSegmentsParamsWithHTTPClient

func NewListCustomerSegmentsParamsWithHTTPClient(client *http.Client) *ListCustomerSegmentsParams

NewListCustomerSegmentsParamsWithHTTPClient creates a new ListCustomerSegmentsParams object with the ability to set a custom HTTPClient for a request.

func NewListCustomerSegmentsParamsWithTimeout

func NewListCustomerSegmentsParamsWithTimeout(timeout time.Duration) *ListCustomerSegmentsParams

NewListCustomerSegmentsParamsWithTimeout creates a new ListCustomerSegmentsParams object with the ability to set a timeout on a request.

func (*ListCustomerSegmentsParams) SetContext

func (o *ListCustomerSegmentsParams) SetContext(ctx context.Context)

SetContext adds the context to the list customer segments params

func (*ListCustomerSegmentsParams) SetCursor

func (o *ListCustomerSegmentsParams) SetCursor(cursor *string)

SetCursor adds the cursor to the list customer segments params

func (*ListCustomerSegmentsParams) SetDefaults

func (o *ListCustomerSegmentsParams) SetDefaults()

SetDefaults hydrates default values in the list customer segments params (not the query body).

All values with no default are reset to their zero value.

func (*ListCustomerSegmentsParams) SetHTTPClient

func (o *ListCustomerSegmentsParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the list customer segments params

func (*ListCustomerSegmentsParams) SetTimeout

func (o *ListCustomerSegmentsParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the list customer segments params

func (*ListCustomerSegmentsParams) WithContext

WithContext adds the context to the list customer segments params

func (*ListCustomerSegmentsParams) WithCursor

WithCursor adds the cursor to the list customer segments params

func (*ListCustomerSegmentsParams) WithDefaults

WithDefaults hydrates default values in the list customer segments params (not the query body).

All values with no default are reset to their zero value.

func (*ListCustomerSegmentsParams) WithHTTPClient

WithHTTPClient adds the HTTPClient to the list customer segments params

func (*ListCustomerSegmentsParams) WithTimeout

WithTimeout adds the timeout to the list customer segments params

func (*ListCustomerSegmentsParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type ListCustomerSegmentsReader

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

ListCustomerSegmentsReader is a Reader for the ListCustomerSegments structure.

func (*ListCustomerSegmentsReader) ReadResponse

func (o *ListCustomerSegmentsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

type RetrieveCustomerSegmentOK

type RetrieveCustomerSegmentOK struct {
	Payload *models.RetrieveCustomerSegmentResponse
}
RetrieveCustomerSegmentOK describes a response with status code 200, with default header values.

Success

func NewRetrieveCustomerSegmentOK

func NewRetrieveCustomerSegmentOK() *RetrieveCustomerSegmentOK

NewRetrieveCustomerSegmentOK creates a RetrieveCustomerSegmentOK with default headers values

func (*RetrieveCustomerSegmentOK) Error

func (o *RetrieveCustomerSegmentOK) Error() string

func (*RetrieveCustomerSegmentOK) GetPayload

type RetrieveCustomerSegmentParams

type RetrieveCustomerSegmentParams struct {

	/* SegmentID.

	   The Square-issued ID of the customer segment.
	*/
	SegmentID string

	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

RetrieveCustomerSegmentParams contains all the parameters to send to the API endpoint

for the retrieve customer segment operation.

Typically these are written to a http.Request.

func NewRetrieveCustomerSegmentParams

func NewRetrieveCustomerSegmentParams() *RetrieveCustomerSegmentParams

NewRetrieveCustomerSegmentParams creates a new RetrieveCustomerSegmentParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewRetrieveCustomerSegmentParamsWithContext

func NewRetrieveCustomerSegmentParamsWithContext(ctx context.Context) *RetrieveCustomerSegmentParams

NewRetrieveCustomerSegmentParamsWithContext creates a new RetrieveCustomerSegmentParams object with the ability to set a context for a request.

func NewRetrieveCustomerSegmentParamsWithHTTPClient

func NewRetrieveCustomerSegmentParamsWithHTTPClient(client *http.Client) *RetrieveCustomerSegmentParams

NewRetrieveCustomerSegmentParamsWithHTTPClient creates a new RetrieveCustomerSegmentParams object with the ability to set a custom HTTPClient for a request.

func NewRetrieveCustomerSegmentParamsWithTimeout

func NewRetrieveCustomerSegmentParamsWithTimeout(timeout time.Duration) *RetrieveCustomerSegmentParams

NewRetrieveCustomerSegmentParamsWithTimeout creates a new RetrieveCustomerSegmentParams object with the ability to set a timeout on a request.

func (*RetrieveCustomerSegmentParams) SetContext

func (o *RetrieveCustomerSegmentParams) SetContext(ctx context.Context)

SetContext adds the context to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) SetDefaults

func (o *RetrieveCustomerSegmentParams) SetDefaults()

SetDefaults hydrates default values in the retrieve customer segment params (not the query body).

All values with no default are reset to their zero value.

func (*RetrieveCustomerSegmentParams) SetHTTPClient

func (o *RetrieveCustomerSegmentParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) SetSegmentID

func (o *RetrieveCustomerSegmentParams) SetSegmentID(segmentID string)

SetSegmentID adds the segmentId to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) SetTimeout

func (o *RetrieveCustomerSegmentParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) WithContext

WithContext adds the context to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) WithDefaults

WithDefaults hydrates default values in the retrieve customer segment params (not the query body).

All values with no default are reset to their zero value.

func (*RetrieveCustomerSegmentParams) WithHTTPClient

WithHTTPClient adds the HTTPClient to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) WithSegmentID

WithSegmentID adds the segmentID to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) WithTimeout

WithTimeout adds the timeout to the retrieve customer segment params

func (*RetrieveCustomerSegmentParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type RetrieveCustomerSegmentReader

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

RetrieveCustomerSegmentReader is a Reader for the RetrieveCustomerSegment structure.

func (*RetrieveCustomerSegmentReader) ReadResponse

func (o *RetrieveCustomerSegmentReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

Jump to

Keyboard shortcuts

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