{"id":14976130,"url":"https://github.com/migueloller/graphql-utilities","last_synced_at":"2025-08-08T12:07:40.080Z","repository":{"id":57253715,"uuid":"67389376","full_name":"migueloller/graphql-utilities","owner":"migueloller","description":"Build GraphQL types using the schema language.","archived":false,"fork":false,"pushed_at":"2017-02-01T06:39:17.000Z","size":71,"stargazers_count":35,"open_issues_count":12,"forks_count":4,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-06-29T13:49:27.295Z","etag":null,"topics":["graphql","graphql-js","graphql-schema","graphql-types","graphql-utilities"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/migueloller.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-09-05T05:01:30.000Z","updated_at":"2022-03-01T15:48:37.000Z","dependencies_parsed_at":"2022-08-31T23:50:13.577Z","dependency_job_id":null,"html_url":"https://github.com/migueloller/graphql-utilities","commit_stats":null,"previous_names":["bloveit/graphql-utilities"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/migueloller/graphql-utilities","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/migueloller%2Fgraphql-utilities","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/migueloller%2Fgraphql-utilities/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/migueloller%2Fgraphql-utilities/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/migueloller%2Fgraphql-utilities/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/migueloller","download_url":"https://codeload.github.com/migueloller/graphql-utilities/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/migueloller%2Fgraphql-utilities/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269417479,"owners_count":24413382,"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","status":"online","status_checked_at":"2025-08-08T02:00:09.200Z","response_time":72,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["graphql","graphql-js","graphql-schema","graphql-types","graphql-utilities"],"created_at":"2024-09-24T13:53:21.796Z","updated_at":"2025-08-08T12:07:40.052Z","avatar_url":"https://github.com/migueloller.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# graphql-utilities\n[![npm version](https://badge.fury.io/js/graphql-utilities.svg)](https://badge.fury.io/js/graphql-utilities) [![Build Status](https://travis-ci.org/bloveit/graphql-utilities.svg?branch=master)](https://travis-ci.org/bloveit/graphql-utilities) [![Coverage Status](https://coveralls.io/repos/github/bloveit/graphql-utilities/badge.svg?branch=master)](https://coveralls.io/github/bloveit/graphql-utilities?branch=master)\n\nInspired by [`graph.ql`](https://github.com/MatthewMueller/graph.ql), [`graphql-tools`](https://github.com/apollostack/graphql-tools), and [`graphql-helpers`](https://github.com/depop/graphql-helpers).\n\n## Why?\nThere are various libraries out there providing utilities for GraphQL and even the [reference implementation](https://github.com/graphql/graphql-js) itself is adding [new utilities](https://github.com/graphql/graphql-js/pull/471). So why do we need another one?\n\nNone of those libraries let you build GraphQL types using the schema language. This prevents gradual adoption of the tools and makes code separation and isolation a nightmare.\n\nWith `graphql-utilities` it's simple. `build` makes it extremely simple to build a GraphQL type.\n\n```js\nbuild(`\n  type Query {\n    ok: Boolean!\n  }\n`);\n\n/* is equivalent to */\n\nnew GraphQLObjectType({\n  name: 'Query',\n  fields: () =\u003e ({\n    ok: { type: new GraphQLNonNull(GraphQLBoolean) },\n  }),\n})\n```\n\n## Installation\n```\nnpm install --save graphql-utilities\n```\n\n## Getting Started\n```js\nimport { build } from 'graphql-utilities';\n\n// you can build a type\nconst Record = build(`\n  interface Record {\n    id: ID!\n  }\n`);\n\n// or you can build a schema\nconst Schema = build(`\n  schema {\n    query: Query\n  }\n\n  type Query {\n    ok: Boolean!\n  }\n`);\n```\n\n## TODO\n- [ ] Add detailed API docs.\n- [x] ~~Make `build` configuration interchangeable with types.~~\n- [x] ~~Allow `build` to accept a flag to skip inferred schema.~~\n\n## License\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmigueloller%2Fgraphql-utilities","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmigueloller%2Fgraphql-utilities","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmigueloller%2Fgraphql-utilities/lists"}