For some providers that have a SDK that allows for Token Generation on the command line, the saml-to cli is also featured to output access credentials to the command line for headless interaction.
To see the specific interaction with Headless mode, click the links in the aforementioned list.
Usage
Options
--org
In the event you're a member of multiple organizations, with providers of the same name, you can seed the command with a specific organization with this flag.
E.g. npx saml-to login aws --org stark-international
--headless
No prompts, and output vary based on the provider. See Headless above.
Example Output
Following these commands, a browser window would be opened to begin the SAML Authentication flow.
saml-to assume [role]
Assume a role
Options:
--help Show help [boolean]
--version Show version number [boolean]
--role The role to assume [string]
--org Specify an organization [string]
--headless Output access credentials to the terminal [boolean] [default: false]
--save Similar to headless, but saves the CLI configuration for a provider to the config file [string]
--provider Specify the provider [string]
➜ ~ npx saml-to assume
npx: installed 1 in 3.035s
? Which role would you like to assume? (Use arrow keys)
arn:aws:iam::874599868815:role/admin [aws-iam] (stark-international)
❯ arn:aws:iam::874599868815:role/iam-readonly [aws-iam] (stark-international)
Assuming arn:aws:iam::874599868815:role/iam-readonly
➜ ~