https://github.com/evilfreelancer/samp-api-php
GTA San Andreas Multiplayer PHP client for work with remote console
https://github.com/evilfreelancer/samp-api-php
api-client samp samp-client socket-client udp-client
Last synced: 3 months ago
JSON representation
GTA San Andreas Multiplayer PHP client for work with remote console
- Host: GitHub
- URL: https://github.com/evilfreelancer/samp-api-php
- Owner: EvilFreelancer
- Created: 2020-04-13T17:39:52.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-04-13T22:38:16.000Z (almost 6 years ago)
- Last Synced: 2025-02-09T15:15:34.514Z (11 months ago)
- Topics: api-client, samp, samp-client, socket-client, udp-client
- Language: PHP
- Size: 6.84 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SAMP API PHP client
Simple PHP client for San Andreas Multiplayer server for
executing commands on remote console.
composer require evilfreelancer/samp-api-php
## How to use
```php
'localhost',
'port' => '7777',
'password' => '12345',
]);
$client = new \SampApi\Rcon($config);
// Get list of vars (only this method is ready for right now)
$response = $client->getVarlist();
dump($response);
// Another way
$response = $client->send('varlist');
dump($response);
// Yet another way, OOP style
$client->responseModel = true;
$response = $client->getVarlist();
dump($response);
```
List of all available commands can be found [here](https://wiki.sa-mp.com/wiki/RCON#RCON_Commands).
## Links
Documentation and some important links
* https://wiki.sa-mp.com/wiki/User:Westie/stuff/Query_Mechanism
* https://www.sa-mp.com/
Alternatives
* https://forum.sa-mp.com/showthread.php?t=104299
* https://github.com/Mielnik/samp-api