Skip to content
Merged
15 changes: 15 additions & 0 deletions api/client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -6013,3 +6013,18 @@ func (c *Client) DeleteAppAuthConfig(ctx context.Context, name string) error {
})
return trace.Wrap(err)
}

// AppAuthConfigSessionsClient returns an [appauthconfigv1.AppAuthConfigSessionsServiceClient].
func (c *Client) AppAuthConfigSessionsClient() appauthconfigv1.AppAuthConfigSessionsServiceClient {
return appauthconfigv1.NewAppAuthConfigSessionsServiceClient(c.conn)
}

// CreateAppSessionWithJWT creates an app session using JWT token.
func (c *Client) CreateAppSessionWithJWT(ctx context.Context, req *appauthconfigv1.CreateAppSessionWithJWTRequest) (types.WebSession, error) {
clt := c.AppAuthConfigSessionsClient()
res, err := clt.CreateAppSessionWithJWT(ctx, req)
if err != nil {
return nil, trace.Wrap(err)
}
return res.GetSession(), nil
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading