Documentation
¶
Index ¶
- func WithAcceptApplicationJSON(r *runtime.ClientOperation)
- func WithAcceptApplicationXML(r *runtime.ClientOperation)
- func WithAcceptTextJSON(r *runtime.ClientOperation)
- func WithAcceptTextXML(r *runtime.ClientOperation)
- func WithContentTypeApplicationJSON(r *runtime.ClientOperation)
- func WithContentTypeApplicationXML(r *runtime.ClientOperation)
- func WithContentTypeApplicationxWwwFormUrlencoded(r *runtime.ClientOperation)
- func WithContentTypeTextJSON(r *runtime.ClientOperation)
- func WithContentTypeTextXML(r *runtime.ClientOperation)
- type Client
- func (a *Client) OAuth2PostToken(params *OAuth2PostTokenParams, opts ...ClientOption) (*OAuth2PostTokenOK, error)
- func (a *Client) OAuth2PostTokenRevoke(params *OAuth2PostTokenRevokeParams, opts ...ClientOption) (*OAuth2PostTokenRevokeOK, error)
- func (a *Client) SetTransport(transport runtime.ClientTransport)
- type ClientOption
- type ClientService
- type OAuth2PostTokenOK
- func (o *OAuth2PostTokenOK) Code() int
- func (o *OAuth2PostTokenOK) Error() string
- func (o *OAuth2PostTokenOK) GetPayload() interface{}
- func (o *OAuth2PostTokenOK) IsClientError() bool
- func (o *OAuth2PostTokenOK) IsCode(code int) bool
- func (o *OAuth2PostTokenOK) IsRedirect() bool
- func (o *OAuth2PostTokenOK) IsServerError() bool
- func (o *OAuth2PostTokenOK) IsSuccess() bool
- func (o *OAuth2PostTokenOK) String() string
- type OAuth2PostTokenParams
- func NewOAuth2PostTokenParams() *OAuth2PostTokenParams
- func NewOAuth2PostTokenParamsWithContext(ctx context.Context) *OAuth2PostTokenParams
- func NewOAuth2PostTokenParamsWithHTTPClient(client *http.Client) *OAuth2PostTokenParams
- func NewOAuth2PostTokenParamsWithTimeout(timeout time.Duration) *OAuth2PostTokenParams
- func (o *OAuth2PostTokenParams) SetContext(ctx context.Context)
- func (o *OAuth2PostTokenParams) SetDefaults()
- func (o *OAuth2PostTokenParams) SetHTTPClient(client *http.Client)
- func (o *OAuth2PostTokenParams) SetOAuthAccessTokenRequest(oAuthAccessTokenRequest *model.OAuthAccessTokenRequest)
- func (o *OAuth2PostTokenParams) SetTimeout(timeout time.Duration)
- func (o *OAuth2PostTokenParams) WithContext(ctx context.Context) *OAuth2PostTokenParams
- func (o *OAuth2PostTokenParams) WithDefaults() *OAuth2PostTokenParams
- func (o *OAuth2PostTokenParams) WithHTTPClient(client *http.Client) *OAuth2PostTokenParams
- func (o *OAuth2PostTokenParams) WithOAuthAccessTokenRequest(oAuthAccessTokenRequest *model.OAuthAccessTokenRequest) *OAuth2PostTokenParams
- func (o *OAuth2PostTokenParams) WithTimeout(timeout time.Duration) *OAuth2PostTokenParams
- func (o *OAuth2PostTokenParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type OAuth2PostTokenReader
- type OAuth2PostTokenRevokeOK
- func (o *OAuth2PostTokenRevokeOK) Code() int
- func (o *OAuth2PostTokenRevokeOK) Error() string
- func (o *OAuth2PostTokenRevokeOK) GetPayload() interface{}
- func (o *OAuth2PostTokenRevokeOK) IsClientError() bool
- func (o *OAuth2PostTokenRevokeOK) IsCode(code int) bool
- func (o *OAuth2PostTokenRevokeOK) IsRedirect() bool
- func (o *OAuth2PostTokenRevokeOK) IsServerError() bool
- func (o *OAuth2PostTokenRevokeOK) IsSuccess() bool
- func (o *OAuth2PostTokenRevokeOK) String() string
- type OAuth2PostTokenRevokeParams
- func NewOAuth2PostTokenRevokeParams() *OAuth2PostTokenRevokeParams
- func NewOAuth2PostTokenRevokeParamsWithContext(ctx context.Context) *OAuth2PostTokenRevokeParams
- func NewOAuth2PostTokenRevokeParamsWithHTTPClient(client *http.Client) *OAuth2PostTokenRevokeParams
- func NewOAuth2PostTokenRevokeParamsWithTimeout(timeout time.Duration) *OAuth2PostTokenRevokeParams
- func (o *OAuth2PostTokenRevokeParams) SetContext(ctx context.Context)
- func (o *OAuth2PostTokenRevokeParams) SetDefaults()
- func (o *OAuth2PostTokenRevokeParams) SetHTTPClient(client *http.Client)
- func (o *OAuth2PostTokenRevokeParams) SetTimeout(timeout time.Duration)
- func (o *OAuth2PostTokenRevokeParams) WithContext(ctx context.Context) *OAuth2PostTokenRevokeParams
- func (o *OAuth2PostTokenRevokeParams) WithDefaults() *OAuth2PostTokenRevokeParams
- func (o *OAuth2PostTokenRevokeParams) WithHTTPClient(client *http.Client) *OAuth2PostTokenRevokeParams
- func (o *OAuth2PostTokenRevokeParams) WithTimeout(timeout time.Duration) *OAuth2PostTokenRevokeParams
- func (o *OAuth2PostTokenRevokeParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type OAuth2PostTokenRevokeReader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithAcceptApplicationJSON ¶
func WithAcceptApplicationJSON(r *runtime.ClientOperation)
WithAcceptApplicationJSON sets the Accept header to "application/json".
func WithAcceptApplicationXML ¶
func WithAcceptApplicationXML(r *runtime.ClientOperation)
WithAcceptApplicationXML sets the Accept header to "application/xml".
func WithAcceptTextJSON ¶
func WithAcceptTextJSON(r *runtime.ClientOperation)
WithAcceptTextJSON sets the Accept header to "text/json".
func WithAcceptTextXML ¶
func WithAcceptTextXML(r *runtime.ClientOperation)
WithAcceptTextXML sets the Accept header to "text/xml".
func WithContentTypeApplicationJSON ¶
func WithContentTypeApplicationJSON(r *runtime.ClientOperation)
WithContentTypeApplicationJSON sets the Content-Type header to "application/json".
func WithContentTypeApplicationXML ¶
func WithContentTypeApplicationXML(r *runtime.ClientOperation)
WithContentTypeApplicationXML sets the Content-Type header to "application/xml".
func WithContentTypeApplicationxWwwFormUrlencoded ¶
func WithContentTypeApplicationxWwwFormUrlencoded(r *runtime.ClientOperation)
WithContentTypeApplicationxWwwFormUrlencoded sets the Content-Type header to "application/x-www-form-urlencoded".
func WithContentTypeTextJSON ¶
func WithContentTypeTextJSON(r *runtime.ClientOperation)
WithContentTypeTextJSON sets the Content-Type header to "text/json".
func WithContentTypeTextXML ¶
func WithContentTypeTextXML(r *runtime.ClientOperation)
WithContentTypeTextXML sets the Content-Type header to "text/xml".
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client for o auth2 API
func (*Client) OAuth2PostToken ¶
func (a *Client) OAuth2PostToken(params *OAuth2PostTokenParams, opts ...ClientOption) (*OAuth2PostTokenOK, error)
OAuth2PostToken o auth2 post token API
func (*Client) OAuth2PostTokenRevoke ¶
func (a *Client) OAuth2PostTokenRevoke(params *OAuth2PostTokenRevokeParams, opts ...ClientOption) (*OAuth2PostTokenRevokeOK, error)
OAuth2PostTokenRevoke o auth2 post token revoke API
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 may be used to customize the behavior of Client methods.
func WithAccept ¶
func WithAccept(mime string) ClientOption
WithAccept allows the client to force the Accept header to negotiate a specific Producer from the server.
You may use this option to set arbitrary extensions to your MIME media type.
func WithContentType ¶
func WithContentType(mime string) ClientOption
WithContentType allows the client to force the Content-Type header to negotiate a specific Consumer from the server.
You may use this option to set arbitrary extensions to your MIME media type.
type ClientService ¶
type ClientService interface {
OAuth2PostToken(params *OAuth2PostTokenParams, opts ...ClientOption) (*OAuth2PostTokenOK, error)
OAuth2PostTokenRevoke(params *OAuth2PostTokenRevokeParams, opts ...ClientOption) (*OAuth2PostTokenRevokeOK, 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 o auth2 API client.
func NewClientWithBasicAuth ¶
func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService
New creates a new o auth2 API client with basic auth credentials. It takes the following parameters: - host: http host (github.com). - basePath: any base path for the API client ("/v1", "/v3"). - scheme: http scheme ("http", "https"). - user: user for basic authentication header. - password: password for basic authentication header.
func NewClientWithBearerToken ¶
func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService
New creates a new o auth2 API client with a bearer token for authentication. It takes the following parameters: - host: http host (github.com). - basePath: any base path for the API client ("/v1", "/v3"). - scheme: http scheme ("http", "https"). - bearerToken: bearer token for Bearer authentication header.
type OAuth2PostTokenOK ¶
type OAuth2PostTokenOK struct {
Payload interface{}
}
OAuth2PostTokenOK describes a response with status code 200, with default header values.
OK
func NewOAuth2PostTokenOK ¶
func NewOAuth2PostTokenOK() *OAuth2PostTokenOK
NewOAuth2PostTokenOK creates a OAuth2PostTokenOK with default headers values
func (*OAuth2PostTokenOK) Code ¶
func (o *OAuth2PostTokenOK) Code() int
Code gets the status code for the o auth2 post token o k response
func (*OAuth2PostTokenOK) Error ¶
func (o *OAuth2PostTokenOK) Error() string
func (*OAuth2PostTokenOK) GetPayload ¶
func (o *OAuth2PostTokenOK) GetPayload() interface{}
func (*OAuth2PostTokenOK) IsClientError ¶
func (o *OAuth2PostTokenOK) IsClientError() bool
IsClientError returns true when this o auth2 post token o k response has a 4xx status code
func (*OAuth2PostTokenOK) IsCode ¶
func (o *OAuth2PostTokenOK) IsCode(code int) bool
IsCode returns true when this o auth2 post token o k response a status code equal to that given
func (*OAuth2PostTokenOK) IsRedirect ¶
func (o *OAuth2PostTokenOK) IsRedirect() bool
IsRedirect returns true when this o auth2 post token o k response has a 3xx status code
func (*OAuth2PostTokenOK) IsServerError ¶
func (o *OAuth2PostTokenOK) IsServerError() bool
IsServerError returns true when this o auth2 post token o k response has a 5xx status code
func (*OAuth2PostTokenOK) IsSuccess ¶
func (o *OAuth2PostTokenOK) IsSuccess() bool
IsSuccess returns true when this o auth2 post token o k response has a 2xx status code
func (*OAuth2PostTokenOK) String ¶
func (o *OAuth2PostTokenOK) String() string
type OAuth2PostTokenParams ¶
type OAuth2PostTokenParams struct {
// OAuthAccessTokenRequest.
OAuthAccessTokenRequest *model.OAuthAccessTokenRequest
Context context.Context
HTTPClient *http.Client
// contains filtered or unexported fields
}
OAuth2PostTokenParams contains all the parameters to send to the API endpoint
for the o auth2 post token operation. Typically these are written to a http.Request.
func NewOAuth2PostTokenParams ¶
func NewOAuth2PostTokenParams() *OAuth2PostTokenParams
NewOAuth2PostTokenParams creates a new OAuth2PostTokenParams 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 NewOAuth2PostTokenParamsWithContext ¶
func NewOAuth2PostTokenParamsWithContext(ctx context.Context) *OAuth2PostTokenParams
NewOAuth2PostTokenParamsWithContext creates a new OAuth2PostTokenParams object with the ability to set a context for a request.
func NewOAuth2PostTokenParamsWithHTTPClient ¶
func NewOAuth2PostTokenParamsWithHTTPClient(client *http.Client) *OAuth2PostTokenParams
NewOAuth2PostTokenParamsWithHTTPClient creates a new OAuth2PostTokenParams object with the ability to set a custom HTTPClient for a request.
func NewOAuth2PostTokenParamsWithTimeout ¶
func NewOAuth2PostTokenParamsWithTimeout(timeout time.Duration) *OAuth2PostTokenParams
NewOAuth2PostTokenParamsWithTimeout creates a new OAuth2PostTokenParams object with the ability to set a timeout on a request.
func (*OAuth2PostTokenParams) SetContext ¶
func (o *OAuth2PostTokenParams) SetContext(ctx context.Context)
SetContext adds the context to the o auth2 post token params
func (*OAuth2PostTokenParams) SetDefaults ¶
func (o *OAuth2PostTokenParams) SetDefaults()
SetDefaults hydrates default values in the o auth2 post token params (not the query body).
All values with no default are reset to their zero value.
func (*OAuth2PostTokenParams) SetHTTPClient ¶
func (o *OAuth2PostTokenParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the o auth2 post token params
func (*OAuth2PostTokenParams) SetOAuthAccessTokenRequest ¶
func (o *OAuth2PostTokenParams) SetOAuthAccessTokenRequest(oAuthAccessTokenRequest *model.OAuthAccessTokenRequest)
SetOAuthAccessTokenRequest adds the oAuthAccessTokenRequest to the o auth2 post token params
func (*OAuth2PostTokenParams) SetTimeout ¶
func (o *OAuth2PostTokenParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the o auth2 post token params
func (*OAuth2PostTokenParams) WithContext ¶
func (o *OAuth2PostTokenParams) WithContext(ctx context.Context) *OAuth2PostTokenParams
WithContext adds the context to the o auth2 post token params
func (*OAuth2PostTokenParams) WithDefaults ¶
func (o *OAuth2PostTokenParams) WithDefaults() *OAuth2PostTokenParams
WithDefaults hydrates default values in the o auth2 post token params (not the query body).
All values with no default are reset to their zero value.
func (*OAuth2PostTokenParams) WithHTTPClient ¶
func (o *OAuth2PostTokenParams) WithHTTPClient(client *http.Client) *OAuth2PostTokenParams
WithHTTPClient adds the HTTPClient to the o auth2 post token params
func (*OAuth2PostTokenParams) WithOAuthAccessTokenRequest ¶
func (o *OAuth2PostTokenParams) WithOAuthAccessTokenRequest(oAuthAccessTokenRequest *model.OAuthAccessTokenRequest) *OAuth2PostTokenParams
WithOAuthAccessTokenRequest adds the oAuthAccessTokenRequest to the o auth2 post token params
func (*OAuth2PostTokenParams) WithTimeout ¶
func (o *OAuth2PostTokenParams) WithTimeout(timeout time.Duration) *OAuth2PostTokenParams
WithTimeout adds the timeout to the o auth2 post token params
func (*OAuth2PostTokenParams) WriteToRequest ¶
func (o *OAuth2PostTokenParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type OAuth2PostTokenReader ¶
type OAuth2PostTokenReader struct {
// contains filtered or unexported fields
}
OAuth2PostTokenReader is a Reader for the OAuth2PostToken structure.
func (*OAuth2PostTokenReader) ReadResponse ¶
func (o *OAuth2PostTokenReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type OAuth2PostTokenRevokeOK ¶
type OAuth2PostTokenRevokeOK struct {
Payload interface{}
}
OAuth2PostTokenRevokeOK describes a response with status code 200, with default header values.
OK
func NewOAuth2PostTokenRevokeOK ¶
func NewOAuth2PostTokenRevokeOK() *OAuth2PostTokenRevokeOK
NewOAuth2PostTokenRevokeOK creates a OAuth2PostTokenRevokeOK with default headers values
func (*OAuth2PostTokenRevokeOK) Code ¶
func (o *OAuth2PostTokenRevokeOK) Code() int
Code gets the status code for the o auth2 post token revoke o k response
func (*OAuth2PostTokenRevokeOK) Error ¶
func (o *OAuth2PostTokenRevokeOK) Error() string
func (*OAuth2PostTokenRevokeOK) GetPayload ¶
func (o *OAuth2PostTokenRevokeOK) GetPayload() interface{}
func (*OAuth2PostTokenRevokeOK) IsClientError ¶
func (o *OAuth2PostTokenRevokeOK) IsClientError() bool
IsClientError returns true when this o auth2 post token revoke o k response has a 4xx status code
func (*OAuth2PostTokenRevokeOK) IsCode ¶
func (o *OAuth2PostTokenRevokeOK) IsCode(code int) bool
IsCode returns true when this o auth2 post token revoke o k response a status code equal to that given
func (*OAuth2PostTokenRevokeOK) IsRedirect ¶
func (o *OAuth2PostTokenRevokeOK) IsRedirect() bool
IsRedirect returns true when this o auth2 post token revoke o k response has a 3xx status code
func (*OAuth2PostTokenRevokeOK) IsServerError ¶
func (o *OAuth2PostTokenRevokeOK) IsServerError() bool
IsServerError returns true when this o auth2 post token revoke o k response has a 5xx status code
func (*OAuth2PostTokenRevokeOK) IsSuccess ¶
func (o *OAuth2PostTokenRevokeOK) IsSuccess() bool
IsSuccess returns true when this o auth2 post token revoke o k response has a 2xx status code
func (*OAuth2PostTokenRevokeOK) String ¶
func (o *OAuth2PostTokenRevokeOK) String() string
type OAuth2PostTokenRevokeParams ¶
type OAuth2PostTokenRevokeParams struct {
Context context.Context
HTTPClient *http.Client
// contains filtered or unexported fields
}
OAuth2PostTokenRevokeParams contains all the parameters to send to the API endpoint
for the o auth2 post token revoke operation. Typically these are written to a http.Request.
func NewOAuth2PostTokenRevokeParams ¶
func NewOAuth2PostTokenRevokeParams() *OAuth2PostTokenRevokeParams
NewOAuth2PostTokenRevokeParams creates a new OAuth2PostTokenRevokeParams 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 NewOAuth2PostTokenRevokeParamsWithContext ¶
func NewOAuth2PostTokenRevokeParamsWithContext(ctx context.Context) *OAuth2PostTokenRevokeParams
NewOAuth2PostTokenRevokeParamsWithContext creates a new OAuth2PostTokenRevokeParams object with the ability to set a context for a request.
func NewOAuth2PostTokenRevokeParamsWithHTTPClient ¶
func NewOAuth2PostTokenRevokeParamsWithHTTPClient(client *http.Client) *OAuth2PostTokenRevokeParams
NewOAuth2PostTokenRevokeParamsWithHTTPClient creates a new OAuth2PostTokenRevokeParams object with the ability to set a custom HTTPClient for a request.
func NewOAuth2PostTokenRevokeParamsWithTimeout ¶
func NewOAuth2PostTokenRevokeParamsWithTimeout(timeout time.Duration) *OAuth2PostTokenRevokeParams
NewOAuth2PostTokenRevokeParamsWithTimeout creates a new OAuth2PostTokenRevokeParams object with the ability to set a timeout on a request.
func (*OAuth2PostTokenRevokeParams) SetContext ¶
func (o *OAuth2PostTokenRevokeParams) SetContext(ctx context.Context)
SetContext adds the context to the o auth2 post token revoke params
func (*OAuth2PostTokenRevokeParams) SetDefaults ¶
func (o *OAuth2PostTokenRevokeParams) SetDefaults()
SetDefaults hydrates default values in the o auth2 post token revoke params (not the query body).
All values with no default are reset to their zero value.
func (*OAuth2PostTokenRevokeParams) SetHTTPClient ¶
func (o *OAuth2PostTokenRevokeParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the o auth2 post token revoke params
func (*OAuth2PostTokenRevokeParams) SetTimeout ¶
func (o *OAuth2PostTokenRevokeParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the o auth2 post token revoke params
func (*OAuth2PostTokenRevokeParams) WithContext ¶
func (o *OAuth2PostTokenRevokeParams) WithContext(ctx context.Context) *OAuth2PostTokenRevokeParams
WithContext adds the context to the o auth2 post token revoke params
func (*OAuth2PostTokenRevokeParams) WithDefaults ¶
func (o *OAuth2PostTokenRevokeParams) WithDefaults() *OAuth2PostTokenRevokeParams
WithDefaults hydrates default values in the o auth2 post token revoke params (not the query body).
All values with no default are reset to their zero value.
func (*OAuth2PostTokenRevokeParams) WithHTTPClient ¶
func (o *OAuth2PostTokenRevokeParams) WithHTTPClient(client *http.Client) *OAuth2PostTokenRevokeParams
WithHTTPClient adds the HTTPClient to the o auth2 post token revoke params
func (*OAuth2PostTokenRevokeParams) WithTimeout ¶
func (o *OAuth2PostTokenRevokeParams) WithTimeout(timeout time.Duration) *OAuth2PostTokenRevokeParams
WithTimeout adds the timeout to the o auth2 post token revoke params
func (*OAuth2PostTokenRevokeParams) WriteToRequest ¶
func (o *OAuth2PostTokenRevokeParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type OAuth2PostTokenRevokeReader ¶
type OAuth2PostTokenRevokeReader struct {
// contains filtered or unexported fields
}
OAuth2PostTokenRevokeReader is a Reader for the OAuth2PostTokenRevoke structure.
func (*OAuth2PostTokenRevokeReader) ReadResponse ¶
func (o *OAuth2PostTokenRevokeReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.