sunnykk/reqres

package that provides a service for retrieving users via a remote API

Installs: 7

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

Type:n

pkg:composer/sunnykk/reqres

dev-main 2022-12-22 08:15 UTC

This package is auto-updated.

Last update: 2025-12-22 15:00:43 UTC


README

"# reqres" A method to retrieve a single user by ID

A method to retrieve a paginated list of users

The service should convert the returned data to a simple, JSON serializable user model for consumption by the user of the package.

Installation

This project using composer.

composer require sunnykk/reqres:dev-main

** Usage **

require_once DIR . '/vendor/autoload.php'; // Autoload files using Composer autoload

use reqres\Reqres;

$Reqres = new Reqres();

echo $getuserbyID = $Reqres->GetUserById(2);

echo $getuserbyID = $Reqres->PaginatedListOfUsers();

You can check the index file , Where I have added the same code to show the json result :