-
Notifications
You must be signed in to change notification settings - Fork 15
Making Requests
Ben Sherred edited this page Dec 1, 2019
·
4 revisions
To make a request to the API, you can use one the following methods on an instance of Client:
$client->player(int $id): PlayerRequest$client->bans(int $id): BanRequest$client->servers(): ServerRequest$client->gameTime(): GameTimeRequest$client->companies(): CompaniesRequest$client->company(int $id): CompanyRequest$client->version(): VersionRequest$client->rules(): RuleRequest
Each request will either return a corresponding model or a collection of models. To get the model or collection you may call the get() method on the request.
-
$client->player('76561198154335536')->get()- this will return an instance thePlayermodel -
$client->servers()->get()- this will return an instance ofServerCollection
If you have any questions about the library, you can create a topic on our forum.
This package is open-source and is licensed under the MIT license.