Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


The Amplify CLI auth command allows you to authenticate with the Amplify Platform under one or more accounts and switch between them.


Code Block
amplify auth <command> [options]


  • lslist - Lists all authenticated accounts
  • login - Log in to the Amplify Platform
  • logout - Log out of all or specific accounts
  • switch - Select default account and organization

ls, list

Displays a list of all authenticated accounts.


  • --json - Outputs accounts as JSON


Log into the Amplify Platform using Proof Key for Code Exchange (PKCE), client secret key, username/password, or signed JSON Web Token (JWT) file.


The access token will expire after a short period after it has been issued. The access token will automatically renew within a longer period of time since the token was issued. If too much time has passed, then the user must re-authenticate.


Revokes access tokens for one, multiple, or all accounts.


  • --all - Revoke all accounts
  • --json - Outputs revoked accounts as JSON


Once authenticated into at least one account, you can set the default account and organization to use for amplify commands.