2017 © Pedro Peláez
 

library laravel-rest-client

Package Rest Full Client for Laravel 5.6

image

prusmarcin/laravel-rest-client

Package Rest Full Client for Laravel 5.6

  • Tuesday, April 10, 2018
  • by prusmarcin
  • Repository
  • 0 Watchers
  • 0 Stars
  • 1 Installations
  • HTML
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

laravel-rest-server

Package Rest Full API client for Laravel, (*1)

You can see package Server API package laravel-rest-server for use on a separate Laravel installation, (*2)

Total Downloads Latest Stable Version License, (*3)

Installation

To install this package you will need:, (*4)

Laravel 5 (see compatibility table)
PHP 7.0 +

Install via composer - edit your composer.json to require the package., (*5)

``` json { "require": { "prusmarcin/laravel-rest-client": "dev-master" } }, (*6)


Then run `composer update` in your terminal to pull it in. Or via the command line in the root of your application installation. ``` bash $ composer require prusmarcin/laravel-rest-client

Once this has finished, you will need to add the service provider to the providers array in your app.php config as follows:, (*7)

``` php \Restclient\RestclientServiceProvider::class,, (*8)


Then execute this command ``` bash $ php artisan vendor:publish

Select provider from lists Provider: Restclient\RestclientServiceProvider and confirm., (*9)

Then enter the config directory in your Laravel installation and open the restclient.php file. Edit url value where your Rest Full API server is located., (*10)

``` php return [, (*11)

/*
|--------------------------------------------------------------------------
| URL Rest Server API
|--------------------------------------------------------------------------
*/

'url' => 'http://127.0.0.1:8000/api/'

]; ```, (*12)

And you're done!, (*13)

Usage

Run this url in browser http://localhost/laravelzadanie/test/public/products, (*14)

WHERE http://localhost/laravelzadanie/test/public/ <- is source your installation Laravel, (*15)

If everything works, you'll see what's on the screenshot, (*16)

Screenshot, (*17)

To view all products just enter http://localhost/laravelzadanie/test/public/products/available, (*18)

You'll see, (*19)

Screenshot, (*20)

Author

License

The MIT License (MIT). Please see License File for more information., (*21)

The Versions

10/04 2018

dev-master

9999999-dev

Package Rest Full Client for Laravel 5.6

  Sources   Download

MIT

The Requires