create #graphql & #rest #apis with @vercel @nextjs @node in 10 mins #webdev

create #graphql & #rest #apis with @vercel @nextjs @node in 10 mins

node

vercel nextjs

curl result

$ curl 'http://localhost:3000/graphql' -H 'Accept-Encoding: gzip, deflate, br' -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Connection: keep-alive' -H 'DNT: 1' -H 'Origin: http://localhost:3000' --data-binary '{"query":"{sayHello}"}' --compressed

{"data":{"sayHello":"Hello World!"}}

browser result