{"id":19376583,"url":"https://github.com/gavinray97/graphql-operation-generator","last_synced_at":"2025-04-23T18:33:22.286Z","repository":{"id":47040543,"uuid":"288074878","full_name":"GavinRay97/graphql-operation-generator","owner":"GavinRay97","description":"Automatically generate GraphQL operations from a schema","archived":false,"fork":false,"pushed_at":"2021-09-16T05:17:32.000Z","size":92,"stargazers_count":6,"open_issues_count":2,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-20T11:08:52.942Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/GavinRay97.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-08-17T03:29:41.000Z","updated_at":"2024-02-18T00:28:33.000Z","dependencies_parsed_at":"2022-08-31T13:42:13.284Z","dependency_job_id":null,"html_url":"https://github.com/GavinRay97/graphql-operation-generator","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GavinRay97%2Fgraphql-operation-generator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GavinRay97%2Fgraphql-operation-generator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GavinRay97%2Fgraphql-operation-generator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GavinRay97%2Fgraphql-operation-generator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GavinRay97","download_url":"https://codeload.github.com/GavinRay97/graphql-operation-generator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250490590,"owners_count":21439171,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T08:44:27.594Z","updated_at":"2025-04-23T18:33:21.951Z","avatar_url":"https://github.com/GavinRay97.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"graphql-operation-generator\n=======================\n\nAutomatically generate GraphQL operations from a schema\n\n[![oclif](https://img.shields.io/badge/cli-oclif-brightgreen.svg)](https://oclif.io)\n[![Version](https://img.shields.io/npm/v/graphql-operation-generator.svg)](https://npmjs.org/package/graphql-operation-generator)\n[![Downloads/week](https://img.shields.io/npm/dw/graphql-query-generator.svg)](https://npmjs.org/package/graphql-operation-generator)\n[![License](https://img.shields.io/npm/l/graphql-query-generator.svg)](https://github.com/GavinRay97/graphql-operation-generator/blob/master/package.json)\n\n- [graphql-operation-generator](#graphql-operation-generator)\n- [Usage](#usage)\n\n\n# Usage\n```sh-session\n$ npm install -g graphql-operation-generator\n$ graphql-operation-generator --help\nAutomatically generate GraphQL operations from a schema\n\nUSAGE\n  $ graphql-operation-generator\n\nOPTIONS\n  -d, --depth=depth                             [default: 1] Maximum depth for nested operation selection sets to generate.\n  -h, --help                                    show CLI help\n  -o, --operations=query|mutation|subscription\n  -s, --schema=schema                           Optional file path to a GraphQL schema from the current directory, if not piping through stdin\n  -v, --version                                 show CLI version\n  --all                                         Generates all operations, equivalent to setting \"--operations query mutation subscription\"\n  --mutation-prefix=mutation-prefix\n  --query-prefix=query-prefix\n  --subscription-prefix=subscription-prefix\n\nEXAMPLES\n  # Pipe from stdin:\n  $ cat my-schema.graphql | graphql-operation-generator --all\n  $ cat my-schema.graphql | graphql-operation-generator --operations queries mutations --depth 2\n  # Or use a filepath to a schema:\n  $ graphql-query-generator --all --schema=./my-schema.graphql\n  ---------------------------------------------------------------------------\n  # 1. Use \"graphqurl\" to save introspection schema to file:\n  $ npx gq http://localhost:8080/v1/graphql --introspect \u003e schema.graphql\n\n  # 2. Use \"graphql-operation-generator\" to create queries, mutations, and subscriptions for every type in the schema:\n  $ cat schema.graphql | graphql-operation-generator --all \u003e queries.graphql\n\n  # 3. Use \"graphql-code-generator\" to generate Typescript types and a query client for every operation:\n  $ npx graphql-code-generator\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgavinray97%2Fgraphql-operation-generator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgavinray97%2Fgraphql-operation-generator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgavinray97%2Fgraphql-operation-generator/lists"}