{"id":22004017,"url":"https://github.com/opengsq/opengsq-php","last_synced_at":"2025-05-05T17:23:02.483Z","repository":{"id":219510233,"uuid":"744794718","full_name":"opengsq/opengsq-php","owner":"opengsq","description":"PHP library designed for querying game servers. It supports 4 different query protocols.","archived":false,"fork":false,"pushed_at":"2024-04-24T17:26:32.000Z","size":13850,"stargazers_count":3,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-04-24T19:31:18.047Z","etag":null,"topics":["game","game-server-query","opengsq","php","server-query"],"latest_commit_sha":null,"homepage":"https://php.opengsq.com/","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/opengsq.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null},"funding":{"github":"BattlefieldDuck"}},"created_at":"2024-01-18T02:36:00.000Z","updated_at":"2024-03-12T04:56:35.000Z","dependencies_parsed_at":"2024-04-24T18:39:14.429Z","dependency_job_id":null,"html_url":"https://github.com/opengsq/opengsq-php","commit_stats":null,"previous_names":["opengsq/opengsq-php"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opengsq%2Fopengsq-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opengsq%2Fopengsq-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opengsq%2Fopengsq-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opengsq%2Fopengsq-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/opengsq","download_url":"https://codeload.github.com/opengsq/opengsq-php/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227239684,"owners_count":17752498,"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":["game","game-server-query","opengsq","php","server-query"],"created_at":"2024-11-30T00:12:03.520Z","updated_at":"2024-11-30T00:12:04.091Z","avatar_url":"https://github.com/opengsq.png","language":"PHP","funding_links":["https://github.com/sponsors/BattlefieldDuck"],"categories":[],"sub_categories":[],"readme":"# OpenGSQ PHP Library\n\n[![PHP Composer](https://github.com/opengsq/opengsq-php/actions/workflows/php.yml/badge.svg)](https://github.com/opengsq/opengsq-php/actions/workflows/php.yml)\n[![GitHub license](https://img.shields.io/github/license/opengsq/opengsq-php)](https://github.com/opengsq/opengsq-php/blob/main/LICENSE)\n[![Packagist Version](https://img.shields.io/packagist/v/opengsq/opengsq-php.svg)](https://packagist.org/packages/opengsq/opengsq-php)\n[![Packagist Downloads](https://img.shields.io/packagist/dt/opengsq/opengsq-php.svg)](https://packagist.org/packages/opengsq/opengsq-php)\n\nThe OpenGSQ PHP library provides a convenient way to query servers from applications written in the PHP language.\n\n## Documentation\n\nDetailed documentation is available at [https://php.opengsq.com](https://php.opengsq.com).\n\n## System Requirements\n\n- [PHP 8.1.2](https://www.php.net) or higher\n\n## Installation\n\nThe recommended way to install the OpenGSQ PHP library is through Composer, a tool for dependency management in PHP. You can install it by running the following command in your terminal:\n\n```sh\ncomposer require opengsq/opengsq-php\n```\n\n## Basic Usage\n\nHere’s a quick example of how you can use the OpenGSQ library to query a server using the VCMP protocol:\n\n```php\n\u003c?php\n\n// Include the Composer autoloader\nrequire_once '../vendor/autoload.php';\n\n// Import the Vcmp class from the OpenGSQ\\Protocols namespace\nuse OpenGSQ\\Protocols\\Vcmp;\n\n// Create a new Vcmp object with the specified host and port\n$vcmp = new Vcmp('123.123.123.123', 8114);\n\n// Get the status of the server\n$status = $vcmp-\u003egetStatus();\n\n// Output the status information\nvar_dump($status);\n\n// Get the players on the server\n$players = $vcmp-\u003egetPlayers();\n\n// Output the player information\nvar_dump($players);\n```\n\nIn this example, we first include the Composer autoloader and import the `Vcmp` class. We then create a new `Vcmp` object, specifying the host and port of the server we want to query. Finally, we call the `getStatus` and `getPlayers` methods to retrieve and output information about the server and its players.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](https://github.com/opengsq/opengsq-php/blob/main/LICENSE) file for details.\n\n## Stargazers over time\n\n[![Stargazers over time](https://starchart.cc/opengsq/opengsq-php.svg?variant=adaptive)](https://starchart.cc/opengsq/opengsq-php)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopengsq%2Fopengsq-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopengsq%2Fopengsq-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopengsq%2Fopengsq-php/lists"}