I have a graphql API that I'm trying to implement - one public facing and one private. In my router.ex file I thought I could do something like this:
pipeline :auth do
plug :accepts, ["json"]
forward "/", Absinthe.Plug, schema: DxAppRcWeb.AuthSchema
end
pipeline :api do
plug :accepts, ["json"]
forward "/", Absinthe.Plug, schema: DxAppRcWeb.Schema
end
Unfortunately, I'm getting an error:
Absinthe.Plug has already been forwarded to. A module can only be forwarded a single time
What's the right way to do this sort of thing?