authorization

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2023 License: Apache-2.0 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 authorization API

func (*Client) GetAPIAPIVersion

func (a *Client) GetAPIAPIVersion(params *GetAPIAPIVersionParams) (*GetAPIAPIVersionOK, error)

GetAPIAPIVersion lists available API versions

Returns a list of available API versions. No authentication is required to access this endpoint.

func (*Client) PostAPI24Login

func (a *Client) PostAPI24Login(params *PostAPI24LoginParams) (*PostApi24LoginOK, error)

PostAPI24Login ps o s t login placeholder

Exchange an API token for a session token.

func (*Client) PostAPI24Logout

func (a *Client) PostAPI24Logout(params *PostAPI24LogoutParams) (*PostApi24LogoutOK, error)

PostAPI24Logout ps o s t logout placeholder

Invalidate a session token.

func (*Client) PostOauth210Token

func (a *Client) PostOauth210Token(params *PostOauth210TokenParams) (*PostOauth210TokenOK, error)

PostOauth210Token gets access token

Exchanges an ID Token for an OAuth 2.0 access token.

func (*Client) SetTransport

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

SetTransport changes the transport on the client

type ClientService

type ClientService interface {
	GetAPIAPIVersion(params *GetAPIAPIVersionParams) (*GetAPIAPIVersionOK, error)

	PostAPI24Login(params *PostAPI24LoginParams) (*PostApi24LoginOK, error)

	PostAPI24Logout(params *PostAPI24LogoutParams) (*PostApi24LogoutOK, error)

	PostOauth210Token(params *PostOauth210TokenParams) (*PostOauth210TokenOK, 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 authorization API client.

type GetAPIAPIVersionBadRequest

type GetAPIAPIVersionBadRequest struct {
	Payload *models.Error
}

GetAPIAPIVersionBadRequest handles this case with default header values.

BadRequest

func NewGetAPIAPIVersionBadRequest

func NewGetAPIAPIVersionBadRequest() *GetAPIAPIVersionBadRequest

NewGetAPIAPIVersionBadRequest creates a GetAPIAPIVersionBadRequest with default headers values

func (*GetAPIAPIVersionBadRequest) Error

func (*GetAPIAPIVersionBadRequest) GetPayload

func (o *GetAPIAPIVersionBadRequest) GetPayload() *models.Error

type GetAPIAPIVersionOK

type GetAPIAPIVersionOK struct {
	Payload *models.APIVersionResponse
}

GetAPIAPIVersionOK handles this case with default header values.

OK

func NewGetAPIAPIVersionOK

func NewGetAPIAPIVersionOK() *GetAPIAPIVersionOK

NewGetAPIAPIVersionOK creates a GetAPIAPIVersionOK with default headers values

func (*GetAPIAPIVersionOK) Error

func (o *GetAPIAPIVersionOK) Error() string

func (*GetAPIAPIVersionOK) GetPayload

func (o *GetAPIAPIVersionOK) GetPayload() *models.APIVersionResponse

type GetAPIAPIVersionParams

type GetAPIAPIVersionParams struct {
	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

GetAPIAPIVersionParams contains all the parameters to send to the API endpoint for the get API API version operation typically these are written to a http.Request

func NewGetAPIAPIVersionParams

func NewGetAPIAPIVersionParams() *GetAPIAPIVersionParams

NewGetAPIAPIVersionParams creates a new GetAPIAPIVersionParams object with the default values initialized.

func NewGetAPIAPIVersionParamsWithContext

func NewGetAPIAPIVersionParamsWithContext(ctx context.Context) *GetAPIAPIVersionParams

NewGetAPIAPIVersionParamsWithContext creates a new GetAPIAPIVersionParams object with the default values initialized, and the ability to set a context for a request

func NewGetAPIAPIVersionParamsWithHTTPClient

func NewGetAPIAPIVersionParamsWithHTTPClient(client *http.Client) *GetAPIAPIVersionParams

NewGetAPIAPIVersionParamsWithHTTPClient creates a new GetAPIAPIVersionParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewGetAPIAPIVersionParamsWithTimeout

func NewGetAPIAPIVersionParamsWithTimeout(timeout time.Duration) *GetAPIAPIVersionParams

NewGetAPIAPIVersionParamsWithTimeout creates a new GetAPIAPIVersionParams object with the default values initialized, and the ability to set a timeout on a request

func (*GetAPIAPIVersionParams) SetContext

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

SetContext adds the context to the get API API version params

func (*GetAPIAPIVersionParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the get API API version params

func (*GetAPIAPIVersionParams) SetTimeout

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

SetTimeout adds the timeout to the get API API version params

func (*GetAPIAPIVersionParams) WithContext

WithContext adds the context to the get API API version params

func (*GetAPIAPIVersionParams) WithHTTPClient

func (o *GetAPIAPIVersionParams) WithHTTPClient(client *http.Client) *GetAPIAPIVersionParams

WithHTTPClient adds the HTTPClient to the get API API version params

func (*GetAPIAPIVersionParams) WithTimeout

WithTimeout adds the timeout to the get API API version params

func (*GetAPIAPIVersionParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type GetAPIAPIVersionReader

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

GetAPIAPIVersionReader is a Reader for the GetAPIAPIVersion structure.

func (*GetAPIAPIVersionReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type PostAPI24LoginParams

type PostAPI24LoginParams struct {

	/*APIToken
	  API token for a user.

	*/
	APIToken *string

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

PostAPI24LoginParams contains all the parameters to send to the API endpoint for the post API 24 login operation typically these are written to a http.Request

func NewPostAPI24LoginParams

func NewPostAPI24LoginParams() *PostAPI24LoginParams

NewPostAPI24LoginParams creates a new PostAPI24LoginParams object with the default values initialized.

func NewPostAPI24LoginParamsWithContext

func NewPostAPI24LoginParamsWithContext(ctx context.Context) *PostAPI24LoginParams

NewPostAPI24LoginParamsWithContext creates a new PostAPI24LoginParams object with the default values initialized, and the ability to set a context for a request

func NewPostAPI24LoginParamsWithHTTPClient

func NewPostAPI24LoginParamsWithHTTPClient(client *http.Client) *PostAPI24LoginParams

NewPostAPI24LoginParamsWithHTTPClient creates a new PostAPI24LoginParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewPostAPI24LoginParamsWithTimeout

func NewPostAPI24LoginParamsWithTimeout(timeout time.Duration) *PostAPI24LoginParams

NewPostAPI24LoginParamsWithTimeout creates a new PostAPI24LoginParams object with the default values initialized, and the ability to set a timeout on a request

func (*PostAPI24LoginParams) SetAPIToken

func (o *PostAPI24LoginParams) SetAPIToken(aPIToken *string)

SetAPIToken adds the apiToken to the post API 24 login params

func (*PostAPI24LoginParams) SetContext

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

SetContext adds the context to the post API 24 login params

func (*PostAPI24LoginParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the post API 24 login params

func (*PostAPI24LoginParams) SetTimeout

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

SetTimeout adds the timeout to the post API 24 login params

func (*PostAPI24LoginParams) WithAPIToken

func (o *PostAPI24LoginParams) WithAPIToken(aPIToken *string) *PostAPI24LoginParams

WithAPIToken adds the aPIToken to the post API 24 login params

func (*PostAPI24LoginParams) WithContext

WithContext adds the context to the post API 24 login params

func (*PostAPI24LoginParams) WithHTTPClient

func (o *PostAPI24LoginParams) WithHTTPClient(client *http.Client) *PostAPI24LoginParams

WithHTTPClient adds the HTTPClient to the post API 24 login params

func (*PostAPI24LoginParams) WithTimeout

func (o *PostAPI24LoginParams) WithTimeout(timeout time.Duration) *PostAPI24LoginParams

WithTimeout adds the timeout to the post API 24 login params

func (*PostAPI24LoginParams) WriteToRequest

func (o *PostAPI24LoginParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type PostAPI24LoginReader

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

PostAPI24LoginReader is a Reader for the PostAPI24Login structure.

func (*PostAPI24LoginReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type PostAPI24LogoutParams

type PostAPI24LogoutParams struct {

	/*XAuthToken
	  Session token for a user.

	*/
	XAuthToken *string

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

PostAPI24LogoutParams contains all the parameters to send to the API endpoint for the post API 24 logout operation typically these are written to a http.Request

func NewPostAPI24LogoutParams

func NewPostAPI24LogoutParams() *PostAPI24LogoutParams

NewPostAPI24LogoutParams creates a new PostAPI24LogoutParams object with the default values initialized.

func NewPostAPI24LogoutParamsWithContext

func NewPostAPI24LogoutParamsWithContext(ctx context.Context) *PostAPI24LogoutParams

NewPostAPI24LogoutParamsWithContext creates a new PostAPI24LogoutParams object with the default values initialized, and the ability to set a context for a request

func NewPostAPI24LogoutParamsWithHTTPClient

func NewPostAPI24LogoutParamsWithHTTPClient(client *http.Client) *PostAPI24LogoutParams

NewPostAPI24LogoutParamsWithHTTPClient creates a new PostAPI24LogoutParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewPostAPI24LogoutParamsWithTimeout

func NewPostAPI24LogoutParamsWithTimeout(timeout time.Duration) *PostAPI24LogoutParams

NewPostAPI24LogoutParamsWithTimeout creates a new PostAPI24LogoutParams object with the default values initialized, and the ability to set a timeout on a request

func (*PostAPI24LogoutParams) SetContext

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

SetContext adds the context to the post API 24 logout params

func (*PostAPI24LogoutParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the post API 24 logout params

func (*PostAPI24LogoutParams) SetTimeout

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

SetTimeout adds the timeout to the post API 24 logout params

func (*PostAPI24LogoutParams) SetXAuthToken

func (o *PostAPI24LogoutParams) SetXAuthToken(xAuthToken *string)

SetXAuthToken adds the xAuthToken to the post API 24 logout params

func (*PostAPI24LogoutParams) WithContext

WithContext adds the context to the post API 24 logout params

func (*PostAPI24LogoutParams) WithHTTPClient

func (o *PostAPI24LogoutParams) WithHTTPClient(client *http.Client) *PostAPI24LogoutParams

WithHTTPClient adds the HTTPClient to the post API 24 logout params

func (*PostAPI24LogoutParams) WithTimeout

func (o *PostAPI24LogoutParams) WithTimeout(timeout time.Duration) *PostAPI24LogoutParams

WithTimeout adds the timeout to the post API 24 logout params

func (*PostAPI24LogoutParams) WithXAuthToken

func (o *PostAPI24LogoutParams) WithXAuthToken(xAuthToken *string) *PostAPI24LogoutParams

WithXAuthToken adds the xAuthToken to the post API 24 logout params

func (*PostAPI24LogoutParams) WriteToRequest

func (o *PostAPI24LogoutParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type PostAPI24LogoutReader

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

PostAPI24LogoutReader is a Reader for the PostAPI24Logout structure.

func (*PostAPI24LogoutReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type PostApi24LoginBadRequest

type PostApi24LoginBadRequest struct {
	Payload *models.Error
}

PostApi24LoginBadRequest handles this case with default header values.

BadRequest

func NewPostApi24LoginBadRequest

func NewPostApi24LoginBadRequest() *PostApi24LoginBadRequest

NewPostApi24LoginBadRequest creates a PostApi24LoginBadRequest with default headers values

func (*PostApi24LoginBadRequest) Error

func (o *PostApi24LoginBadRequest) Error() string

func (*PostApi24LoginBadRequest) GetPayload

func (o *PostApi24LoginBadRequest) GetPayload() *models.Error

type PostApi24LoginOK

type PostApi24LoginOK struct {
	/*Session token for a user.
	 */
	XAuthToken string

	Payload *models.UsernameResponse
}

PostApi24LoginOK handles this case with default header values.

OK

func NewPostApi24LoginOK

func NewPostApi24LoginOK() *PostApi24LoginOK

NewPostApi24LoginOK creates a PostApi24LoginOK with default headers values

func (*PostApi24LoginOK) Error

func (o *PostApi24LoginOK) Error() string

func (*PostApi24LoginOK) GetPayload

func (o *PostApi24LoginOK) GetPayload() *models.UsernameResponse

type PostApi24LogoutBadRequest

type PostApi24LogoutBadRequest struct {
	Payload *models.Error
}

PostApi24LogoutBadRequest handles this case with default header values.

BadRequest

func NewPostApi24LogoutBadRequest

func NewPostApi24LogoutBadRequest() *PostApi24LogoutBadRequest

NewPostApi24LogoutBadRequest creates a PostApi24LogoutBadRequest with default headers values

func (*PostApi24LogoutBadRequest) Error

func (o *PostApi24LogoutBadRequest) Error() string

func (*PostApi24LogoutBadRequest) GetPayload

func (o *PostApi24LogoutBadRequest) GetPayload() *models.Error

type PostApi24LogoutOK

type PostApi24LogoutOK struct {
}

PostApi24LogoutOK handles this case with default header values.

OK

func NewPostApi24LogoutOK

func NewPostApi24LogoutOK() *PostApi24LogoutOK

NewPostApi24LogoutOK creates a PostApi24LogoutOK with default headers values

func (*PostApi24LogoutOK) Error

func (o *PostApi24LogoutOK) Error() string

type PostOauth210TokenBadRequest

type PostOauth210TokenBadRequest struct {
	Payload *models.PostOauth210TokenBadRequestBody
}

PostOauth210TokenBadRequest handles this case with default header values.

BAD REQUEST

func NewPostOauth210TokenBadRequest

func NewPostOauth210TokenBadRequest() *PostOauth210TokenBadRequest

NewPostOauth210TokenBadRequest creates a PostOauth210TokenBadRequest with default headers values

func (*PostOauth210TokenBadRequest) Error

func (*PostOauth210TokenBadRequest) GetPayload

type PostOauth210TokenOK

type PostOauth210TokenOK struct {
	Payload *models.PostOauth210TokenOKBody
}

PostOauth210TokenOK handles this case with default header values.

OK

func NewPostOauth210TokenOK

func NewPostOauth210TokenOK() *PostOauth210TokenOK

NewPostOauth210TokenOK creates a PostOauth210TokenOK with default headers values

func (*PostOauth210TokenOK) Error

func (o *PostOauth210TokenOK) Error() string

func (*PostOauth210TokenOK) GetPayload

type PostOauth210TokenParams

type PostOauth210TokenParams struct {

	/*GrantType
	  The method by which the access token will be obtained. The Pure Storage REST API supports the OAuth 2.0 "token exchange" grant type, which indicates that a token exchange is being performed. Set `grant_type` to `urn:ietf:params:oauth:grant-type:token-exchange`.

	*/
	GrantType string
	/*SubjectToken
	  An encoded security ID Token representing the identity of the party on behalf of whom the request is being made. The token must be issued by a trusted identity provider which must be either a registered application in Pure1 or an enabled API client on the array. The token must be a JSON Web Token and must contain the following claims:
	> | JWT claim | Location | API Client Field | Description | Required By |
	> |-|-|-|-|-|
	> | kid | Header | key_id | Key ID of the API client that issues the identity token. | FlashArray and FlashBlade only. |
	> | aud | Payload | id | Client ID of the API client that issues the identity token. | FlashArray and FlashBlade only. |
	> | sub | Payload | | Login name of the array user for whom the token should be issued. This must be a valid user in the system. | FlashArray and FlashBlade only. |
	> | iss | Payload | issuer | Application ID for the Pure1 or API client's trusted identity issuer on the array. | All products. |
	> | iat | Payload | | Timestamp of when the identity token was issued. Measured in milliseconds since the UNIX epoch. | All products. |
	> | exp | Payload | | Timestamp of when the identity token will expire. Measured in milliseconds since the UNIX epoch. | All products. |

	Each token must also be signed with the private key that is paired with the API client's public key.

	*/
	SubjectToken string
	/*SubjectTokenType
	  An identifier that indicates the type of security token specifed in the `subject_token` parameter. The Pure Storage REST API supports the JSON Web Token (JWT) as the means for requesting the access token. Set `subject_token_type` to `urn:ietf:params:oauth:token-type:jwt`.

	*/
	SubjectTokenType string

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

PostOauth210TokenParams contains all the parameters to send to the API endpoint for the post oauth210 token operation typically these are written to a http.Request

func NewPostOauth210TokenParams

func NewPostOauth210TokenParams() *PostOauth210TokenParams

NewPostOauth210TokenParams creates a new PostOauth210TokenParams object with the default values initialized.

func NewPostOauth210TokenParamsWithContext

func NewPostOauth210TokenParamsWithContext(ctx context.Context) *PostOauth210TokenParams

NewPostOauth210TokenParamsWithContext creates a new PostOauth210TokenParams object with the default values initialized, and the ability to set a context for a request

func NewPostOauth210TokenParamsWithHTTPClient

func NewPostOauth210TokenParamsWithHTTPClient(client *http.Client) *PostOauth210TokenParams

NewPostOauth210TokenParamsWithHTTPClient creates a new PostOauth210TokenParams object with the default values initialized, and the ability to set a custom HTTPClient for a request

func NewPostOauth210TokenParamsWithTimeout

func NewPostOauth210TokenParamsWithTimeout(timeout time.Duration) *PostOauth210TokenParams

NewPostOauth210TokenParamsWithTimeout creates a new PostOauth210TokenParams object with the default values initialized, and the ability to set a timeout on a request

func (*PostOauth210TokenParams) SetContext

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

SetContext adds the context to the post oauth210 token params

func (*PostOauth210TokenParams) SetGrantType

func (o *PostOauth210TokenParams) SetGrantType(grantType string)

SetGrantType adds the grantType to the post oauth210 token params

func (*PostOauth210TokenParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the post oauth210 token params

func (*PostOauth210TokenParams) SetSubjectToken

func (o *PostOauth210TokenParams) SetSubjectToken(subjectToken string)

SetSubjectToken adds the subjectToken to the post oauth210 token params

func (*PostOauth210TokenParams) SetSubjectTokenType

func (o *PostOauth210TokenParams) SetSubjectTokenType(subjectTokenType string)

SetSubjectTokenType adds the subjectTokenType to the post oauth210 token params

func (*PostOauth210TokenParams) SetTimeout

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

SetTimeout adds the timeout to the post oauth210 token params

func (*PostOauth210TokenParams) WithContext

WithContext adds the context to the post oauth210 token params

func (*PostOauth210TokenParams) WithGrantType

func (o *PostOauth210TokenParams) WithGrantType(grantType string) *PostOauth210TokenParams

WithGrantType adds the grantType to the post oauth210 token params

func (*PostOauth210TokenParams) WithHTTPClient

func (o *PostOauth210TokenParams) WithHTTPClient(client *http.Client) *PostOauth210TokenParams

WithHTTPClient adds the HTTPClient to the post oauth210 token params

func (*PostOauth210TokenParams) WithSubjectToken

func (o *PostOauth210TokenParams) WithSubjectToken(subjectToken string) *PostOauth210TokenParams

WithSubjectToken adds the subjectToken to the post oauth210 token params

func (*PostOauth210TokenParams) WithSubjectTokenType

func (o *PostOauth210TokenParams) WithSubjectTokenType(subjectTokenType string) *PostOauth210TokenParams

WithSubjectTokenType adds the subjectTokenType to the post oauth210 token params

func (*PostOauth210TokenParams) WithTimeout

WithTimeout adds the timeout to the post oauth210 token params

func (*PostOauth210TokenParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type PostOauth210TokenReader

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

PostOauth210TokenReader is a Reader for the PostOauth210Token structure.

func (*PostOauth210TokenReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type PostOauth210TokenUnauthorized

type PostOauth210TokenUnauthorized struct {
	Payload *models.PostOauth210TokenUnauthorizedBody
}

PostOauth210TokenUnauthorized handles this case with default header values.

UNAUTHORIZED

func NewPostOauth210TokenUnauthorized

func NewPostOauth210TokenUnauthorized() *PostOauth210TokenUnauthorized

NewPostOauth210TokenUnauthorized creates a PostOauth210TokenUnauthorized with default headers values

func (*PostOauth210TokenUnauthorized) Error

func (*PostOauth210TokenUnauthorized) GetPayload

Jump to

Keyboard shortcuts

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