aws / aws-toolkit-vscode

Amazon Q, CodeCatalyst, Local Lambda debug, SAM/CFN syntax, ECS Terminal, AWS resources
https://marketplace.visualstudio.com/items?itemName=AmazonWebServices.amazon-q-vscode
Apache License 2.0
1.47k stars 408 forks source link

Expose a synchronous API to Amazon Q allowing introspecting current session state. #5434

Open heyrichardshi opened 1 month ago

heyrichardshi commented 1 month ago

Problem

I would like to be able to call an API exposed by Amazon Q in order to determine the current session state (e.g. active, expired, logged out, etc). Currently, Amazon Q exposes no such API and I am forced to depend on implementation details of Amazon Q, such as reading the session cache files and making assumptions about them.

Expected behavior

Amazon Q exposes a synchronous API that allows an operation to retrieve the current Amazon Q state, e.g. extensions.getExtension('amazon.q').exports.getSessionState() which would return some object containing data about the session state.

justinmk3 commented 1 month ago

Has overlap with: