Documentation ¶
Index ¶
- type Client
- func (c *Client) Create(ctx context.Context, organizationID string, ...) (*openapi.ServiceAccountCreate, error)
- func (c *Client) Delete(ctx context.Context, organizationID, serviceAccountID string) error
- func (c *Client) Get(ctx context.Context, organizationID, serviceAccountID string) (*openapi.ServiceAccountRead, error)
- func (c *Client) List(ctx context.Context, organizationID string) (openapi.ServiceAccounts, error)
- func (c *Client) Rotate(ctx context.Context, organizationID, serviceAccountID string) (*openapi.ServiceAccountCreate, error)
- func (c *Client) Update(ctx context.Context, organizationID, serviceAccountID string, ...) (*openapi.ServiceAccountRead, error)
- type Options
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 is responsible for service account management.
func New ¶
func New(client client.Client, namespace, host string, oauth2 *oauth2.Authenticator, options *Options) *Client
New creates a new service account client.
func (*Client) Create ¶
func (c *Client) Create(ctx context.Context, organizationID string, request *openapi.ServiceAccountWrite) (*openapi.ServiceAccountCreate, error)
Create makes a new service account and issues an access token.
func (*Client) Get ¶
func (c *Client) Get(ctx context.Context, organizationID, serviceAccountID string) (*openapi.ServiceAccountRead, error)
Get retrieves information about a service account.
func (*Client) Rotate ¶
func (c *Client) Rotate(ctx context.Context, organizationID, serviceAccountID string) (*openapi.ServiceAccountCreate, error)
Rotate is a special version of Update where everything about the resource is preserved with the exception of the access token.
func (*Client) Update ¶
func (c *Client) Update(ctx context.Context, organizationID, serviceAccountID string, request *openapi.ServiceAccountWrite) (*openapi.ServiceAccountRead, error)
Update modifies any metadata for the service account if it exists. If a matching account doesn't exist it raises an error.
Click to show internal directories.
Click to hide internal directories.