PHPackages                             hearst-hatchery/graphql-php-query-builder - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. hearst-hatchery/graphql-php-query-builder

AbandonedArchivedLibrary[API Development](/categories/api)

hearst-hatchery/graphql-php-query-builder
=========================================

PHP Query Builder for GraphQL

0.2.1(5y ago)13051MITPHPPHP ^7.1

Since Oct 25Pushed 5y ago59 watchersCompare

[ Source](https://github.com/Hearst-Hatchery/graphql-php-query-builder)[ Packagist](https://packagist.org/packages/hearst-hatchery/graphql-php-query-builder)[ RSS](/packages/hearst-hatchery-graphql-php-query-builder/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (4)Dependencies (3)Versions (5)Used By (0)

graphql-php-query-builder
=========================

[](#graphql-php-query-builder)

[![Build Status](https://camo.githubusercontent.com/b1869c1cbd98a14fe1b0297d8c3aff8be8e9ba98d51c5dd9778b55e1f0bfd38b/68747470733a2f2f7472617669732d63692e636f6d2f4865617273742d48617463686572792f6772617068716c2d7068702d71756572792d6275696c6465722e7376673f6272616e63683d6d6173746572)](https://travis-ci.com/Hearst-Hatchery/graphql-php-query-builder)

Simple QueryBuilder to deconstruct array and return GraphQL string can be used to request GraphQL server

Build a QueryBuilder object:

```
$query = new QueryBuilder();

```

Build query, set Requesting field, arguments and query type:

```
$query->setField('content');
$query->setArguments(['id' => '123']);
$query->setType('query');
$query->setObject([
    'id',
    'data',
    'detail' => [
        'name',
        'model',
        'year'
        ]
]);

```

Render query and format the string:

```
$queryString= $query->buildQuery();

```

Results in:

```
query{
    content(id: "123") {
        id
        data
        detail {
            name
            model
            year
        }
    }
}

```

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community20

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 86.7% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~303 days

Total

4

Last Release

1851d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/23240?v=4)[felton](/maintainers/felton)[@felton](https://github.com/felton)

![](https://www.gravatar.com/avatar/9aa1759a450d636ec3eea60900494416f8c03c9e1358959ff86baa33bf38ce37?d=identicon)[dee2716](/maintainers/dee2716)

---

Top Contributors

[![dee2716](https://avatars.githubusercontent.com/u/37081175?v=4)](https://github.com/dee2716 "dee2716 (26 commits)")[![cjander18](https://avatars.githubusercontent.com/u/5534015?v=4)](https://github.com/cjander18 "cjander18 (2 commits)")[![felton](https://avatars.githubusercontent.com/u/23240?v=4)](https://github.com/felton "felton (1 commits)")[![lfre](https://avatars.githubusercontent.com/u/1093848?v=4)](https://github.com/lfre "lfre (1 commits)")

###  Code Quality

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/hearst-hatchery-graphql-php-query-builder/health.svg)

```
[![Health](https://phpackages.com/badges/hearst-hatchery-graphql-php-query-builder/health.svg)](https://phpackages.com/packages/hearst-hatchery-graphql-php-query-builder)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
