Options
All
  • Public
  • Public/Protected
  • All
Menu

Class LogoutCommand

Removes the locally stored SSO tokens from the client-side cache and sends an API call to the Amazon Web Services SSO service to invalidate the corresponding server-side Amazon Web Services SSO sign in session.

If a user uses Amazon Web Services SSO to access the AWS CLI, the user’s Amazon Web Services SSO sign in session is used to obtain an IAM session, as specified in the corresponding Amazon Web Services SSO permission set. More specifically, Amazon Web Services SSO assumes an IAM role in the target account on behalf of the user, and the corresponding temporary Amazon Web Services credentials are returned to the client.

After user logout, any existing IAM role sessions that were created by using Amazon Web Services SSO permission sets continue based on the duration configured in the permission set. For more information, see User authentications in the Amazon Web Services SSO User Guide.

example

Use a bare-bones client and the command you need to make an API call.

import { SSOClient, LogoutCommand } from "@aws-sdk/client-sso"; // ES Modules import
// const { SSOClient, LogoutCommand } = require("@aws-sdk/client-sso"); // CommonJS import
const client = new SSOClient(config);
const command = new LogoutCommand(input);
const response = await client.send(command);
see

LogoutCommandInput for command's input shape.

see

LogoutCommandOutput for command's response shape.

see

config for SSOClient's config shape.

Hierarchy

Implements

Index

Constructors

Properties

Constructors

constructor

Properties

Readonly input

Readonly middlewareStack

middlewareStack: IMiddlewareStack<LogoutCommandInput, LogoutCommandOutput>