{"id":19881375,"url":"https://github.com/overblog/graphqlphpgenerator","last_synced_at":"2025-10-07T09:11:51.945Z","repository":{"id":54149210,"uuid":"56864132","full_name":"overblog/GraphQLPhpGenerator","owner":"overblog","description":"GraphQL PHP types generator...","archived":false,"fork":false,"pushed_at":"2021-03-07T18:19:52.000Z","size":100,"stargazers_count":29,"open_issues_count":1,"forks_count":10,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-10-06T04:30:25.473Z","etag":null,"topics":["generator","graphql","graphql-php","php"],"latest_commit_sha":null,"homepage":"","language":"PHP","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/overblog.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-04-22T15:07:35.000Z","updated_at":"2024-05-10T15:26:00.000Z","dependencies_parsed_at":"2022-08-13T07:40:24.488Z","dependency_job_id":null,"html_url":"https://github.com/overblog/GraphQLPhpGenerator","commit_stats":null,"previous_names":[],"tags_count":23,"template":false,"template_full_name":null,"purl":"pkg:github/overblog/GraphQLPhpGenerator","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overblog%2FGraphQLPhpGenerator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overblog%2FGraphQLPhpGenerator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overblog%2FGraphQLPhpGenerator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overblog%2FGraphQLPhpGenerator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/overblog","download_url":"https://codeload.github.com/overblog/GraphQLPhpGenerator/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overblog%2FGraphQLPhpGenerator/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278747788,"owners_count":26038775,"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-10-07T02:00:06.786Z","response_time":59,"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":["generator","graphql","graphql-php","php"],"created_at":"2024-11-12T17:14:01.242Z","updated_at":"2025-10-07T09:11:51.893Z","avatar_url":"https://github.com/overblog.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"OverblogGraphQLPhpGenerator\n===========================\n\n\nGraphQL PHP types generator...\n\n[![Code Coverage](https://scrutinizer-ci.com/g/overblog/GraphQLPhpGenerator/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/overblog/GraphQLPhpGenerator/?branch=master)\n[![Build Status](https://travis-ci.org/overblog/GraphQLPhpGenerator.svg?branch=master)](https://travis-ci.org/overblog/GraphQLPhpGenerator)\n\nInstallation\n------------\n\n```bash\ncomposer require overblog/graphql-php-generator\n```\n\nUsage\n-----\n\n```php\n\u003c?php\n$loader = require __DIR__.'/vendor/autoload.php';\n\nuse GraphQL\\Schema;\nuse Overblog\\GraphQLGenerator\\Generator\\TypeGenerator;\nuse Symfony\\Component\\ExpressionLanguage\\Expression;\n\n$configs = [\n    'Character' =\u003e [\n        'type' =\u003e 'interface',\n        'config' =\u003e [\n            'description' =\u003e new Expression('\\'A character\\' ~ \\' in the Star Wars Trilogy\\''),\n            'fields' =\u003e [\n                'id' =\u003e ['type' =\u003e 'String!', 'description' =\u003e 'The id of the character.'],\n                'name' =\u003e ['type' =\u003e 'String', 'description' =\u003e 'The name of the character.'],\n                'friends' =\u003e ['type' =\u003e '[Character]', 'description' =\u003e 'The friends of the character.'],\n                'appearsIn' =\u003e ['type' =\u003e '[Episode]', 'description' =\u003e 'Which movies they appear in.'],\n            ],\n            'resolveType' =\u003e 'Overblog\\\\GraphQLGenerator\\\\Tests\\\\Resolver::resolveType',\n        ],\n    ],\n    /*...*/\n    'Query' =\u003e [\n        'type' =\u003e 'object',\n        'config' =\u003e [\n            'description' =\u003e 'A humanoid creature in the Star Wars universe or a faction in the Star Wars saga.',\n            'fields' =\u003e [\n                'hero' =\u003e [\n                    'type' =\u003e 'Character',\n                    'args' =\u003e [\n                        'episode' =\u003e [\n                            'type' =\u003e 'Episode',\n                            'description' =\u003e 'If omitted, returns the hero of the whole saga. If provided, returns the hero of that particular episode.',\n                        ],\n                    ],\n                    'resolve' =\u003e ['Overblog\\\\GraphQLGenerator\\\\Tests\\\\Resolver', 'getHero'],\n                ],\n            ],\n        ],\n        /*...*/\n    ],\n];\n\n$typeGenerator = new TypeGenerator('\\\\My\\\\Schema\\\\NP');\n$classesMap = $typeGenerator-\u003egenerateClasses($configs, __DIR__ . '/cache/types');\n\n$loader-\u003eaddClassMap($classesMap);\n\n$schema = new Schema(\\My\\Schema\\NP\\QueryType::getInstance());\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foverblog%2Fgraphqlphpgenerator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foverblog%2Fgraphqlphpgenerator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foverblog%2Fgraphqlphpgenerator/lists"}