Hi @JamesWholebear, That’s because you’re passing the body of the inbound request in to your querystring parser. You don’t actually need to manually parse the query params since they are available in an object on the event as event. queryStringParameters already.
I’m not sure what you’re printing there but it works for me in my tests:
And that’s using the following code in the function:
exports.handler = function (event, context, callback) {
console.log(event.queryStringParameters);
console.log(`This is the value of test: ${event.queryStringParameters.test}`);
console.log(event)
callback(null, {
statusCode: 200,
body: JSON.stringify(event)
});
};
Hi @JamesWholebear, if you look closely to the first screenshot that Gerald provided, you can see that the event objects has a body key. Similar to node/express, you can access the body of the incoming request via event.body. Let me know if you have any other questions.