@ghbountybot/github-graphql-client
v0.1.6
Published
A strongly-typed GitHub GraphQL API client
Maintainers
Readme
GitHub GraphQL Client
A strongly-typed GitHub GraphQL API client for TypeScript/JavaScript applications.
Installation
# Using pnpm
pnpm add @andrewgazelka/github-graphql-client
# Using npm
npm install @andrewgazelka/github-graphql-client
# Using yarn
yarn add @andrewgazelka/github-graphql-clientUsage
First, you'll need to set up a GitHub Personal Access Token with the necessary permissions.
import { createClient } from '@andrewgazelka/github-graphql-client';
const client = createClient({
token: 'your-github-token'
});
// Example: Fetch repository information
const { repository } = await client.getRepository({
owner: 'octocat',
name: 'Hello-World'
});Features
- 🚀 Fully typed GitHub GraphQL API client
- 📦 Generated types from GitHub's GraphQL schema
- 🔒 Type-safe query building
- 🌟 Modern ESM package
Development
- Clone the repository
- Install dependencies:
pnpm install - Generate types:
pnpm run codegen - Build:
pnpm run build
License
MIT
