1

i tried deploying my golang server to heroku automatically, and the server runs until the playground. i use gqlgen from graphql golang but when i try to run the query and i fetch data in playground, i find the problem as below.

{"errors": {"message": "Unexpected token < in JSON at position 0","stack": "SyntaxError: Unexpected token < in JSON at position 0"}}

when I try to inspect element, the header status I get is 503 Service Unavailable

check the code in my github https://github.com/mwaziat/go_hrms

  • Share your code here to get more accurate response. – Farhad Sarvari Jun 25 '22 at 12:10
  • https://github.com/mwaziat/go_hrms – creator life Jun 25 '22 at 12:27
  • Please explain your issue in a better and clearer way. I think I got your point, I've been using gqlgen for a while and I recently started a new project with a newer version. Before the change to graphiql I've had the option to specify the base URL, now the base URL for the API is {yourhost}/graphql. It should be {yourhost}/graphql/ with a trailing slash. – Gianfranco Reppucci Jun 27 '22 at 21:30

0 Answers0