What is the best way to setup documentation for a graphql API made using APPsync?

Viewed 186

We have an API we are starting to develop in TypeScript using AWS Lambda and Exposing it to the world with AppSync using graphql.

We looked into documenting with swagger and tsoa and it's only showing the regular request and response of the lambdas and lives in s3

  1. It can't hit the lambda
  2. It doesn't show that this is graphql at all
  3. It feels like we hacked it together

Is there a better way ?

1 Answers

There is the official documentation from AWS to inspect an AppSync GraphQL schema and prototype queries from a local machine leveraging a local GraphiQL instance in the browsers.

Link: https://aws.amazon.com/blogs/mobile/appsync-graphiql-local

Your generated GraphiQL Playground will look like this.

You can also maintain the proper security of the AppSync by just following the documentation.

Related