voodooism / randomuser-api-client
Client for randomuser API
1.0.1
2021-08-11 12:06 UTC
Requires
- php: ^7.4
- guzzlehttp/guzzle: ^7.3
- jms/serializer: ^3.14
Requires (Dev)
- ext-json: *
- friendsofphp/php-cs-fixer: ^3.0
- phpunit/phpunit: ^8.0 || ^9.0
- vimeo/psalm: ^4.9
This package is auto-updated.
Last update: 2024-11-11 19:31:52 UTC
README
PHP client for https://randomuser.me API
Installation
composer require voodooism/randomuser-api-client
Usage
$serializer = SerializerBuilder::create()->build(); $options = new ClientOptions('https://randomuser.me'); $client = new Client($serializer, new HttpClient(), $options); //One user $user = $this->client->getRandomUser(); //Array of users $users = $this->client->getRandomUsers(10);