Hi, I am trying to invoke the lambda with functio...
# general
n
Hi, I am trying to invoke the lambda with function url (lets name this as "funcUrlLambda" ) from another lambda (lets say this as "apiGwLambda"). I have given apiGwLambda role permission in funcUrlLambda. In apiGwLambda, I am doing the signv4 with the access key and secret key from lambda env variables. For signV4, I am using the code from these links https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-examples-using-sdks.html#sig-v4-examples-using-sdk-java https://docs.aws.amazon.com/AmazonS3/latest/API/samples/AWSS3SigV4JavaSamples.zip But I am getting this error {"message":"The security token included in the request is invalid."} from funcUrlLambda. It would be super helpful if you could provide some help on this ?
f
hey @Navin GV why not invoking the function directly instead (not through the url)?
this snippet uses
aws-api-gateway-client
to do the signing, not sure if it’d work for lambda url https://github.com/AnomalyInnovations/aws-api-gateway-cli-test/blob/master/index.js#L159-L166
n
Ok. Will check it