aws-samples / amazon-q-teams-gateway

MIT No Attribution
10 stars 1 forks source link

Idc requirement now installed, causing client-qbusiness to fail. #19

Open LAYTAT opened 2 months ago

LAYTAT commented 2 months ago

Hi team, In very short, this bot is not working. image

In not so short, it is caused by this line of api call. The expection is being thrown here on line 51 in the code using @aws-sdk/client-qbusiness:

const response = await getClient(env).send(new ChatSyncCommand(input)); // It is the issue of needing to get access via Idc.

This issue is: I don't currently see how to get through this using current SDK.

Any guidance will be greatly appreciated, thank you!

rstrahan commented 2 months ago

Hi @LAYTAT - So sorry for the delay - I am just back from vacation. Thanks for reporting this.. We have the same issue with the Slack gateway - see https://github.com/aws-samples/amazon-q-slack-gateway/issues/33

If you have created a new Amazon Q Business application on or after April 30th, 2022, you will not be able to set up a Slack or Microsoft Teams gateway using the instructions provided. This is because new Amazon Q Business applications require integration with IAM Identity Center. We are currently working on updating the solution and the necessary steps for new applications created since April 30th, 2022.

I have added a notice to the README to this effect to inform other users, and we will update the repo again when the changes have been implemented.

JMJHOX commented 2 months ago

Taking a look into this error I saw this thread: https://repost.aws/questions/QUqqemQYRpRUqxqxEBzR-jVQ/amazon-q-business-chat-sync-cli-command-always-failing

I tried using this command on aws cli to see what´s wrong and try to fix it:

"aws qbusiness chat-sync --application-id "appid" --user-id "userid" --user-message "test" --debug"

but it returns this message:

"An error occurred (AccessDeniedException) when calling the ChatSync operation: User is not authorized for this service call"

Seems like this bug may be related to the AWS API.

trichards-symplr commented 1 month ago

Do you have any news on this? It is May 31st, and I'd like to use this to prototype a chatbot for Teams for my company.

JMJHOX commented 1 month ago

Do you have any news on this? It is May 31st, and I'd like to use this to prototype a chatbot for Teams for my company.

I´m waiting too, there is any updates on this?

leenmin-aws commented 1 month ago

Hi, the changes and README to support IAM identity center using your own identity provider have been published. Please make sure that your users (matching emails in the identity provider) are also added and subscribed to the Q business application (see updated prerequisites).