Workdocs not sending emails on feedback.

1

I am using create_comment API in my lambda to add comments on a document. This API adds comment on the file but workdocs doesn't send email despite NotifyCollaborators=True. When comment is posted manually on the document, it is sending the email. Please help in understanding why email is not being received on posting comment through API.

https://docs.aws.amazon.com/workdocs/latest/APIReference/API_CreateComment.html (Adding: Lambda execution role has AmazonWorkDocsFullAccess)

質問済み 3ヶ月前121ビュー
1回答
0

Hey, you need to setting up notifications permission for your Lambda function's execution role.

Here is the documentation to do it: https://docs.aws.amazon.com/workdocs/latest/developerguide/manage-notifications.html

profile picture
エキスパート
回答済み 3ヶ月前
  • Hello, thanks for sharing. My lambda role has AmazonWorkDocsFullAccess.

        "Version": "2012-10-17",
        "Statement": [
            {
                "Effect": "Allow",
                "Action": [
                    "workdocs:*",
                    "ds:DescribeDirectories",
                    "ec2:DescribeVpcs",
                    "ec2:DescribeSubnets"
                ],
                "Resource": "*"
            }
        ]
    }```
    
  • Did you do this step "Call the notification subscription APIs to enable or disable publishing of SNS messages to your endpoint"?

  • This API is just for subscribing to any event happening in Workdocs to an SNS topic. This topic was attached manually. My SNS topic invokes a lambda and lambda is able to receive the event and process it. Lambda then creates comment on the uploaded file, after which ideally email should go out to users having access permissions which is not happening currently but comments get posted. CreateNotificationSubscription is not related to having control over email notifications.

  • Understood. There are multiple factors that could prevent collaborators from receiving notifications, despite having the Notify Collaborators option activated:

    1. Users with "viewer" permissions may not be eligible to receive email notifications.
    2. Notification settings or permissions configured at the folder level might not automatically apply to individual files without being explicitly set for each one.
    3. The system typically does not send notifications to "anonymous viewers," meaning users outside the organization who access a file via an external link.

    Resources:

    1. Users with "viewer" permissions may not be eligible to receive email notifications. - Agreed on this, they don't get emails even by manually adding comment unless their email-id is mentioned like "xyz@domain.com"
    2. Notification settings or permissions configured at the folder level might not automatically apply to individual files without being explicitly set for each one. - Notification settings at file level were not muted.
    3. The system typically does not send notifications to "anonymous viewers," meaning users outside the organization who access a file via an external link. - Agreed on this but even the co-owners/contributors didn't receive emails.

    Meanwhile, thanks for the efforts to look into this. Much appreciated!

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ