{"id":21396799,"url":"https://github.com/favware/graphql-pokemon","last_synced_at":"2025-05-16T00:06:34.022Z","repository":{"id":36076809,"uuid":"218856223","full_name":"favware/graphql-pokemon","owner":"favware","description":"Extensive Pokémon GraphQL API","archived":false,"fork":false,"pushed_at":"2025-05-11T11:44:30.000Z","size":48908,"stargazers_count":165,"open_issues_count":15,"forks_count":14,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-05-11T12:30:12.937Z","etag":null,"topics":["favware","graphql","graphql-pokemon","hacktoberfest","pokemon","showdown","smogon"],"latest_commit_sha":null,"homepage":"http://graphql-pokemon.js.org/","language":"TypeScript","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/favware.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE.md","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":".github/SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["favna"],"patreon":"favna","open_collective":null,"ko_fi":"favna","tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":"https://donate.favware.tech/paypal"}},"created_at":"2019-10-31T20:30:08.000Z","updated_at":"2025-05-11T11:42:43.000Z","dependencies_parsed_at":"2023-12-15T21:57:50.361Z","dependency_job_id":"2559be7b-ac12-4d93-b5eb-05934736bb7b","html_url":"https://github.com/favware/graphql-pokemon","commit_stats":{"total_commits":1875,"total_committers":17,"mean_commits":"110.29411764705883","dds":0.5482666666666667,"last_synced_commit":"c25e25b1f22725d6a86b7a238bdda74a7b2c1aa3"},"previous_names":[],"tags_count":134,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/favware%2Fgraphql-pokemon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/favware%2Fgraphql-pokemon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/favware%2Fgraphql-pokemon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/favware%2Fgraphql-pokemon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/favware","download_url":"https://codeload.github.com/favware/graphql-pokemon/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254442854,"owners_count":22071878,"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":["favware","graphql","graphql-pokemon","hacktoberfest","pokemon","showdown","smogon"],"created_at":"2024-11-22T14:29:18.612Z","updated_at":"2025-05-16T00:06:33.986Z","avatar_url":"https://github.com/favware.png","language":"TypeScript","funding_links":["https://github.com/sponsors/favna","https://patreon.com/favna","https://ko-fi.com/favna","https://donate.favware.tech/paypal","https://github.com/sponsors/Favna"],"categories":["Index"],"sub_categories":["Games \u0026 Comics"],"readme":"\u003cdiv align=\"center\"\u003e\n\n[\u003cimg height=\"200\" src=\"https://cdn.favware.tech/img/gqlp.png\" alt=\"ArchAngel\"/\u003e][dashboard]\n\n# [`GraphQL-Pokemon`][dashboard]\n\n**Extensive Pokémon GraphQL API!**\n\n[![GitHub](https://img.shields.io/github/license/favware/graphql-pokemon)](https://github.com/favware/graphql-pokemon/blob/main/LICENSE)\n\n[![npm](https://img.shields.io/npm/v/@favware/graphql-pokemon?color=crimson\u0026label=TypeScript%20API%20Typings%20Version\u0026logo=npm)](https://www.npmjs.com/package/@favware/graphql-pokemon)\n\n[![Support Server](https://discord.com/api/guilds/512303595966824458/embed.png?style=banner2)](https://join.favware.tech)\n\n\u003c/div\u003e\n\n---\n\n**Table of Contents**\n\n- [GraphQL-Pokemon](#graphql-pokemon)\n  - [About](#about)\n  - [Key Features](#key-features)\n  - [JavaScript Companion Library](#javascript-companion-library)\n  - [Known bugs / limitations](#known-bugs--limitations)\n  - [API Documentation](#api-documentation)\n    - [Autogenerated text based documentation](#autogenerated-text-based-documentation)\n    - [Interactive playground with documentation embedded](#interactive-playground-with-documentation-embedded)\n  - [Usage](#usage)\n    - [Using `Fetch`](#using-fetch)\n    - [Using `Apollo Boost`](#using-apollo-boost)\n    - [Using `Apollo Client React`](#using-apollo-client-react)\n  - [Meta](#meta)\n    - [License](#license)\n    - [Buy us some doughnuts](#buy-us-some-doughnuts)\n  - [Contributors](#contributors)\n\n---\n\n## About\n\n[GraphQL-Pokemon][dashboard] is a GraphQL API that provides extensive Pokémon\ndata. Unlike contemporary APIs this API focusses on speed, accuracy and data\nquality. New game data is added within relatively short time after release, and\nSmogon tier data is automatically updated after tier shifts. Data used for this\nAPI is pulled from the [Pokemon Showdown GitHub][showdown-github], [Serebii],\nand [Bulbapedia].\n\n## Key Features\n\n- Fully generated client-side TypeScript typings published to\n  - [npm] as `@favware/graphql-pokemon`\n  - [GitHub Package Registry][ghcr_npm] as `@favware/graphql-pokemon`\n- Docker images of the API for private hosting published to\n  - [Dockerhub] as `favware/graphql-pokemon`\n  - [GitHub Package Registry][ghcr_docker] as\n    `ghcr.io/favware/graphql-pokemon:latest`\n- Provides information about various assets in Pokémon\n  - Pokédex\n  - Items\n  - Abilities\n  - Moves\n  - Learnsets\n  - Type matchups\n  - Natures\n\n## JavaScript Companion Library\n\nFor those consuming this API through JavaScript, you can install the companion\nlibrary to add additional tools for parsing the responses as well as get the\nTypeScript typings for the responses.\n\nInstall library through your favourite package manager:\n\n```sh\nnpm install @favware/graphql-pokemon\nyarn add @favware/graphql-pokemon\npnpm add @favware/graphql-pokemon\nbun add @favware/graphql-pokemon\n```\n\nFor the usage of the JavaScript Companion Library please see [the autogenerated\ndocumentation][docs].\n\n## Known bugs / limitations\n\n- [ ] It is currently not possible to get all data of all Pokémon in one query,\n      as the resulting data object is too large for NodeJS to process. This will\n      be fixed in [#900](https://github.com/favware/graphql-pokemon/issues/900).\n\n## API Documentation\n\nThere are two ways to consume the documentation that this API offers. They are\nas follows.\n\n### Autogenerated text based documentation\n\nFor those who want purely text based documentation about all the GraphQL Queries\nand Types that are in this API, including a documentation search for those\nsymbols, please see [the autogenerated documentation][docs] powered by\n[magidoc].\n\n### Interactive playground with documentation embedded\n\nFor those who want an interactive playground where they can directly test their\nqueries and read about each query as they select them, please use [the GraphQL\nPlayground on the API][dashboard].\n\n## Usage\n\n_These examples are written as based on TypeScript. For JavaScript simply change\nout the imports to `require` syntax and remove any type information._\n\n### Using `Fetch`\n\n_note: for a working example see [dragonite]_\n\n```ts\nimport type { Query } from '@favware/graphql-pokemon';\n\ninterface GraphQLPokemonResponse\u003cK extends keyof Omit\u003cQuery, '__typename'\u003e\u003e {\n  data: Record\u003cK, Omit\u003cQuery[K], '__typename'\u003e\u003e;\n}\n\nfetch('https://graphqlpokemon.favware.tech/v8', {\n  method: 'POST',\n  headers: {\n    'Content-Type': 'application/json'\n  },\n  body: JSON.stringify({\n    query: `\n      {\n        getPokemon(pokemon: dragonite) {\n            sprite\n            num\n            species\n            color\n        }\n      }\n    `\n  })\n})\n  .then((res) =\u003e res.json() as Promise\u003cGraphQLPokemonResponse\u003c'getPokemon'\u003e\u003e)\n  .then((json) =\u003e console.log(json.data));\n```\n\n### Using `Apollo Boost`\n\n_note: for a working example see [dexa]_\n\n```ts\nimport type { Query, QueryGetFuzzyPokemonArgs } from '@favware/graphql-pokemon';\nimport ApolloClient from 'apollo-boost';\nimport fetch from 'cross-fetch';\nimport gql from 'graphql-tag';\n\ntype GraphQLPokemonResponse\u003cK extends keyof Omit\u003cQuery, '__typename'\u003e\u003e = Record\u003c\n  K,\n  Omit\u003cQuery[K], '__typename'\u003e\n\u003e;\n\nconst getFuzzyPokemon = gql`\n  query getFuzzyPokemon($pokemon: String!) {\n    getFuzzyPokemon(pokemon: $pokemon) {\n      sprite\n      num\n      species\n      color\n    }\n  }\n`;\n\nconst apolloClient = new ApolloClient({\n  uri: 'https://graphqlpokemon.favware.tech/v8',\n  fetch\n});\n\nconst {\n  data: { getFuzzyPokemon: pokemonData }\n} = await apolloClient.query\u003c\n  GraphQLPokemonResponse\u003c'getFuzzyPokemon'\u003e,\n  QueryGetFuzzyPokemonArgs\n\u003e({\n  query: getFuzzyPokemon,\n  variables: { pokemon: 'dragonite' }\n});\n\nconsole.log(pokemonData);\n```\n\n### Using `Apollo Client React`\n\n```ts\n// ApolloClient setup\nimport { ApolloClient } from 'apollo-client';\nimport { InMemoryCache } from 'apollo-cache-inmemory';\nimport { HttpLink } from 'apollo-link-http';\n\n// Instantiate required constructor fields\nconst cache = new InMemoryCache();\nconst link = new HttpLink({\n  uri: 'https://graphqlpokemon.favware.tech/v8'\n});\n\nexport const client = new ApolloClient({\n  // Provide required constructor fields\n  cache: cache,\n  link: link,\n\n  // Provide some optional constructor fields\n  name: 'graphql-pokemon-client',\n  version: '1.0',\n  queryDeduplication: false,\n  defaultOptions: {\n    watchQuery: {\n      fetchPolicy: 'cache-and-network'\n    }\n  }\n});\n```\n\n```tsx\n// Component\nimport React from 'react';\nimport gql from 'graphql-tag';\nimport { useQuery } from '@apollo/react-hooks';\nimport type { Query } from '@favware/graphql-pokemon';\nimport { client } from './ApolloClient';\n\ninterface GraphQLPokemonResponse\u003cK extends keyof Omit\u003cQuery, '__typename'\u003e\u003e {\n  data: Record\u003cK, Omit\u003cQuery[K], '__typename'\u003e\u003e;\n}\n\nconst GET_POKEMON_DETAILS = gql`\n  {\n    getPokemon(pokemon: dragonite) {\n      sprite\n      num\n      species\n      color\n    }\n  }\n`;\n\nexport const Pokemon: React.FC = () =\u003e {\n  const { loading, error, data } = useQuery\u003c\n    GraphQLPokemonResponse\u003c'getPokemon'\u003e\n  \u003e(GET_POKEMON_DETAILS, {\n    client: client\n  });\n\n  if (loading) return 'Loading...';\n  if (error) return `Error! ${error.message}`;\n\n  return \u003cdiv\u003e Insert how you want to display the data here \u003c/div\u003e;\n};\n```\n\n## Meta\n\n### License\n\nCopyright © 2019, [Favware](https://github.com/favware). Released under the\n[MIT License](LICENSE.md).\n\n### Buy us some doughnuts\n\nFavware projects is and always will be open source, even if we don't get\ndonations. That being said, we know there are amazing people who may still want\nto donate just to show their appreciation. Thank you very much in advance!\n\nWe accept donations through Ko-fi, Paypal, Patreon, GitHub Sponsorships, and\nvarious crypto currencies. You can use the buttons below to donate through your\nmethod of choice.\n\n|   Donate With   |                      Address                      |\n| :-------------: | :-----------------------------------------------: |\n|      Ko-fi      |  [Click Here](https://donate.favware.tech/kofi)   |\n|     Patreon     | [Click Here](https://donate.favware.tech/patreon) |\n|     PayPal      | [Click Here](https://donate.favware.tech/paypal)  |\n| GitHub Sponsors |  [Click Here](https://github.com/sponsors/Favna)  |\n|     Bitcoin     |       `1E643TNif2MTh75rugepmXuq35Tck4TnE5`        |\n|    Ethereum     |   `0xF653F666903cd8739030D2721bF01095896F5D6E`    |\n|    LiteCoin     |       `LZHvBkaJqKJRa8N7Dyu41Jd1PDBAofCik6`        |\n\n## Contributors\n\nPlease make sure to read the [Contributing Guide][contributing] before making a\npull request.\n\nThank you to all the people who already contributed to GraphQL-Pokemon!\n\n\u003ca href=\"https://github.com/favware/graphql-pokemon/graphs/contributors\"\u003e\n  \u003cimg src=\"https://contrib.rocks/image?repo=favware/graphql-pokemon\" /\u003e\n\u003c/a\u003e\n\n[contributing]: ./.github/CONTRIBUTING.md\n[dashboard]: https://graphqlpokemon.favware.tech/v8\n[yarn]: https://yarnpkg.com/package/@favware/graphql-pokemon\n[npm]: https://www.npmjs.com/package/@favware/graphql-pokemon\n[ghcr_npm]: https://github.com/favware/graphql-pokemon/packages/199047\n[ghcr_docker]:\n  https://github.com/orgs/favware/packages/container/package/graphql-pokemon\n[dockerhub]: https://hub.docker.com/r/favware/graphql-pokemon\n[dexa]: https://github.com/favware/dexa\n[dragonite]: https://github.com/favware/dragonite\n[showdown-github]: https://github.com/smogon/pokemon-showdown/\n[serebii]: https://www.serebii.net/\n[bulbapedia]: https://bulbapedia.bulbagarden.net/wiki/Main_Page\n[magidoc]: https://github.com/magidoc-org/magidoc\n[docs]: https://graphql-pokemon.js.org/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffavware%2Fgraphql-pokemon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffavware%2Fgraphql-pokemon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffavware%2Fgraphql-pokemon/lists"}