Package Data | |
---|---|
Maintainer Username: | spitoglou |
Maintainer Contact: | s.pitoglou@csl.gr (Stavros Pitoglou) |
Package Create Date: | 2016-04-10 |
Package Last Update: | 2016-04-13 |
Home Page: | |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-14 15:15:32 |
Package Statistics | |
---|---|
Total Downloads: | 31 |
Monthly Downloads: | 2 |
Daily Downloads: | 0 |
Total Stars: | 0 |
Total Watchers: | 3 |
Total Forks: | 0 |
Total Open Issues: | 0 |
Laravel 5.2 Multi Api Package
This package was initially developed for personal (and colleague) use.
It provides the necessary functionality to produce api responses in JSON, XML or HTML (simple table) formats. The api consumer determines the format of the response he/she needs by setting the "Accept" header of the request accordingly ("application/json", "application/custom+xml","application/text" respectively).
Via Composer
$ composer require spitoglou/multi-api
$array = [["name"=>"Stavros", "surname"=>"Pitoglou],["name"=>"John", "surname"=>"Doe"];
$sender = new Spitoglou\MultiApi\Sender($array);
$sender->finalSend();
$array = ["errorCode"=>"654987", "errorDescription"=>"Some Exotic Error]
$sender = new Spitoglou\MultiApi\Sender($array);
$sender->sendError(500);
Please see CHANGELOG for more information what has changed recently.
Have Not Added Tests yet...
If you discover any security related issues, please email s.pitoglou@csl.gr instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.