https://github.com/eerimoq/gqt Skip to content Sign up * Product + Features + Mobile + Actions + Codespaces + Packages + Security + Code review + Issues + Integrations + GitHub Sponsors + Customer stories * Team * Enterprise * Explore + Explore GitHub + Learn and contribute + Topics + Collections + Trending + Learning Lab + GitHub Sponsors + Open source guides + Connect with others + The ReadME Project + Events + Community forum + GitHub Education + GitHub Stars program * Marketplace * Pricing + Plans + Compare plans + Contact Sales + Education [ ] * # In this repository All GitHub | Jump to | * No suggested jump to results * # In this repository All GitHub | Jump to | * # In this user All GitHub | Jump to | * # In this repository All GitHub | Jump to | Sign in Sign up {{ message }} eerimoq / gqt Public * * Notifications * Fork 0 * Star 46 Build and execute GraphQL queries in the terminal. License MIT license 46 stars 0 forks Star Notifications * Code * Issues 0 * Pull requests 0 * Actions * Projects 0 * Wiki * Security * Insights More * Code * Issues * Pull requests * Actions * Projects * Wiki * Security * Insights eerimoq/gqt This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. main Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default View all tags 1 branch 47 tags Code Latest commit @eerimoq eerimoq README. ... 111c93c Jun 4, 2022 README. 111c93c Git stats * 110 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time .github docs/assets gqt .gitignore .pylintrc LICENSE README.rst requirements.txt setup.py View code GraphQL client in the terminal Installation Controls Examples Known issues Ideas README.rst GraphQL client in the terminal Build and execute GraphQL queries in the terminal. This project is inspired by https://graphiql-online.com. https://github.com/eerimoq/gqt/raw/main/docs/assets/showcase.gif Installation pip3 install gqt It's recommended to install bat for pretty output. Controls * Navigate with arrow keys. * Select fields with . * Toggle between argument selection and its value with . * End with . Examples Set default GraphQL endpoint: $ export GQT_ENDPOINT=https://mys-lang.org/graphql Interactively create a query and execute it: $ gqt { "statistics": { "numberOfGraphqlRequests": 3 } } Repeat last query: $ gqt -r { "statistics": { "numberOfGraphqlRequests": 4 } } Print the query instead of executing it: $ gqt -q {statistics {numberOfGraphqlRequests}} YAML output: $ gqt -y statistics: numberOfGraphqlRequests: 8 Print the schema: $ gqt --print-schema type Query { standardLibrary: StandardLibrary! statistics: Statistics! activities: [Activity!]! } type StandardLibrary { package(name: String!): Package! packages: [Package!] numberOfPackages: Int numberOfDownloads: Int } ... Known issues * Arguments does not work very well. * Scrolling does not work. * Fragments and unions are not implemented. * Mutations and subscriptions are not implemented. * And much more. Ideas * Show GraphQL API documentation. * Mutations? * Subscriptions? * Arguments and variables: #: not null #: null $: variable Scalar example: +- Query | V standard_library | V package | # name: "" | # name | > packages List example: +- Query | V item | # kinds: | # kinds2: | [0] # a: "foo" | # b: "eq" | # c: | [0] # a: "x" | # b: "y" | [1] | [1] # a: "bar" | # b: "ne" | # c: | [2] Variables example: +- Query | V standardLibrary | V package | $ name: name | # id: 5 | $ kind: kind | # name | # numberOfDownloads | > statistics +- Variables | name: "foo" | kind: | [0] # a: "bar" | # b: "ne" | # c: | [1] Print the variables: $ gqt -v {"name": "foo", "kind": [{"a": "bar", "b": "ne"}]} About Build and execute GraphQL queries in the terminal. Resources Readme License MIT license Stars 46 stars Watchers 1 watching Forks 0 forks Releases 47 tags Sponsor this project Sponsor Learn more about GitHub Sponsors Packages 0 No packages published Languages * Python 100.0% * (c) 2022 GitHub, Inc. * Terms * Privacy * Security * Status * Docs * Contact GitHub * Pricing * API * Training * Blog * About You can't perform that action at this time. You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.