timokoessler / 2FAGuard

A modern and secure Windows app for managing your 2FA authentication codes.

Home Page:https://2faguard.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow CLI Interaction for Retrieving and Copying TOTP Token Codes to Clipboard

casilvam-cgd opened this issue · comments

What is your idea?

Description:

Allow interaction with the app via the CLI to retrieve TOTP token codes and copy them directly to the clipboard without having to open the GUI. This feature would greatly enhance the usability and convenience of the app, especially for users who prefer command-line workflows or need to access token codes quickly without navigating through the graphical interface.

Feature Specifications:

  • Command syntax: 2FAGuard.exe --get-code my-token --copy-to-clipboard
  • Functionality:
    • Retrieve TOTP token code for a specified token using the CLI.
    • Option to copy the token code directly to the clipboard.
  • Benefits:
    • Enables efficient token code retrieval without GUI interaction.
    • Supports command-line workflows and automation scripts.
    • Enhances usability for power users and developers.

Output example:

> C:\path-to-exe\2FAGuard.exe --get-code my-token --copy-to-clipboard
Token code for 'my-token': 123456
Token code copied to clipboard successfully.

Additional Notes:

  • It would be beneficial to include clear documentation or help messages within the CLI interface to guide users on how to use this feature effectively.
  • This feature would significantly enhance the app's accessibility and utility for users who rely on CLI workflows.
  • Provides a very convenient way for StreamDeck users to quickly access TOTP token codes.

If you need any further clarification or details, please let me know. Thank you!

Thanks for your suggestion. 👍 Automating several actions in one script would cause the problem that confirmation with Windows Hello or entering the password would be required for each command.

If you want to try the CLI, you can now download it from the release page.
Its a first minimal version that includes a list and a get command.
For use with the portable version, simply place the executable in the same folder. Later, the CLI will be available as an optional component that can be installed and updated from the GUI. The CLI does not work with the Microsoft Store version of 2FAGuard.