I am trying to a SNS subscription with a topic-"email-deliveries", and I've created subscription already. So it is in "Pending confirmation". Of course, I created endpoint in the server and it is ready to receive the response. After created subscription, I've received a response header that is missing "SubscriptionUrl" that I can confirm subscription.
The "console.log(req.headers)":
{
'accept-encoding': 'gzip,deflate',
'content-type': 'text/plain; charset=UTF-8',
'user-agent': 'Amazon Simple Notification Service Agent',
'x-amz-sns-message-id': 'dc2d4247-bc09-4865-9a48-7e7c2560645f',
'x-amz-sns-message-type': 'SubscriptionConfirmation',
'x-amz-sns-topic-arn': 'arn:aws:sns:us-east-1:620094933128:email-deliveries',
'x-amzn-trace-id': 'Root=1-62549704-42c7cf8e5bec7dfb5fd712c0',
'x-forwarded-for': '72.21.217.67',
'x-forwarded-port': '443',
'x-forwarded-proto': 'https',
'x-amzn-apigateway-api-id': 'c1e8lfdv52',
'content-length': '1599',
host: '52.86.191.0:3001',
connection: 'Keep-Alive'
}
I am using Loopback node framework on the server.
If you had already experienced in this kind of error, Please let me know.
Thanks.
It looks like you are only parsing the headers, the suscription is part of the body (data) of the email, have you checked the data?