I have the following call:
$http.get(
'../api/hello', {
params: {
hello: "world"
}
}).then(function (res) {
//do response
})
and the following route:
server.route({
path: '/api/hello',
method: 'GET',
handler(req, reply) {
//get hello
}
})
I'm trying to get the parameter called 'hello' on the '//get hello'. I have tried to use 'req.params' but it returns {}.
Is there something wrong with the call or how can i get the hello parameter? Thanks in advance