Hi,
I am using cognitect/aws
library and trying to interact with sesv2
I keep getting the following errors when trying during the remote invoke
"cognitect.anomalies/category": "cognitect.anomalies/fault",
"cognitect.anomalies/message": "Unable to fetch credentials. See log for more details."
When trying to invoke it locally, I get the proper result What I am using is something like:
(def credentils (creds/profile-credentials-provider))
(def ses-client (aws/client {:region :us-east-1
:api :sesv2
:credentials-provider credentils}))
;; ...
(aws/invoke ses-client {:op {:SendMail ...}
:request {:.. }})
I double check my signature and I can also see that the
(aws/validate-request ses-client) ;;=> true
For both running locally, and remotely via the AWS Lambda
Anything that I may have missed?I don’t see useful logs in aws
@agilecreativity do you have profile credentials in ~/.aws/config?
Locally I do, but since I am running it through the AWS Lambda, I am not sure how to check it.
I assumed that it will use default
profile?
no
if you're running in lambda, you don't need to provide any config
leave off the :credentials-provider
you probably don't need to provide any explicit config locally either
You mean just do
(def ses-client (aws/client {:region :us-east-1
:api :sesv2})
yes
Let me give that a try.
you don't need to give the region either
if the region is the same as the lambda
Let me try that.
@ghadi It works! - I spent an hour try to get this to work. Thanks again.