· 1 min read in aws, sns, development
AWS SNS error - Invalid parameter
So I was playing with AWS Lambdas, and wanted to setup SNS notification for that.
aws sns publish --topic-arn arn:aws:sns:eu-west-1:22834709971:my-awesome-sns-topic --subject 'Subject' --message 'Hello, hello!'However got stuck on the following error - it just says Invalid Parameter
An error occurred (InvalidParameter) when calling the Publish operation: Invalid parameter: TopicArnTurns out this has to do with my region settings.
I’d created SNS in eu-west-1 region (Ireland). But default region on my account was us-west-1
So, clearly that is a conflict.
Solution is easy, I just had to set region in ~/.aws/config
[default]output = textregion = eu-west-1That’s it!