I am working on an app that has a public api as we...
# prisma-whats-new
t
I am working on an app that has a public api as well as a web front end. Has anyone done anything like this with Graph.cool? If yes, Did you just expose some of the GraphQL Queries and Mutations? Or did you wrap it with a REST apI? Any examples anywhere?
n
hey Todd 👋
👋 1
there's currently a lot of movement in that area, we'll sono release more resources on how to handle this situation. here's one possible approach: https://github.com/graphcool/graphql-transform-schema
t
thank you
n
basically, you would run express-graphql in front of your Graphcool API
that is referred to as schema stitching, schema merging, schema transforming, or proxying. here's a relevant blog article: https://dev-blog.apollodata.com/graphql-tools-2-0-with-schema-stitching-8944064904a5
t
so basic idea is, create a public endpoint, and proxy off to the main endpoint
does that pretty much sum it up?
n
yea, pretty much
it gets really interesting when you enter the realm of combining different 'main enpoints' into a single public one 🙂
😁 1
t
🙂