I am currently using Amplify to set up my backend because Appsync is a key part of my stack.
However, I also use SQS to publish certain messages into a queue. This is easily done using the in-code editor of lambda but since I'm running lambda functions locally now, I am unable to send messages to the queue now with the following error:
InvalidParameterValue: The request has a 'X-Amzn-Trace-Id' HTTP header which is reserved for AWS X-Ray trace header and has an invalid value 'amplify-mock-x-amzn-trace-id'
This is my code to send messages into the queue.
response = await sqs.sendMessageBatch(slackParams).promise().catch(async (err) => { console.log(response from sqs: ${err}); });
Once I do amplify push, the code works fine on the cloud lambda but the issue comes only when I do amplify mock api. (During local testing, I am unable to add to the queue)
Is there any way I can mock my SQS setup locally as well? Any help is appreciated!