I’ve run into some trouble getting absinthe to work on my app. The error message in the logs is
[debug] ** (Phoenix.Router.NoRouteError) no route found for POST /graphql (LookupPhoenix.Router)
(lookup_phoenix) web/router.ex:1: LookupPhoenix.Router.match_route/4
(lookup_phoenix) web/router.ex:1: LookupPhoenix.Router.do_call/2
(lookup_phoenix) lib/lookup_phoenix/endpoint.ex:1: LookupPhoenix.Endpoint.phoenix_pipeline/1
(lookup_phoenix) lib/plug/debugger.ex:123: LookupPhoenix.Endpoint."call (overridable 3)"/2
(lookup_phoenix) lib/lookup_phoenix/endpoint.ex:1: LookupPhoenix.Endpoint.call/2
(plug) lib/plug/adapters/cowboy/handler.ex:15: Plug.Adapters.Cowboy.Handler.upgrade/4
(cowboy) /Users/carlson/dev/elixir/ns_umbrella/deps/cowboy/src/cowboy_protocol.erl:442: :cowboy_protocol.execute/4
The request in graphiQL is POST http://localhost:4001/graphql and the error message there is
SyntaxError: Unexpected token < in JSON at position 0
In web/router.ex I have the code
forward "/graphiql", Absinthe.Plug.GraphiQL,
schema: NoteApi.Schema
and in phoenix.router.ex I have added the code
defmodule NoteApi.Router do
use NoteApi.Web, :router
# ...
forward "/graphql", Absinthe.Plug,
schema: NoteApi.Schema
# ...
end
What would you suggest?


















