2017 © Pedro Peláez
 

library laravel-api

A package that makes developing APIs in Laravel (Lumen too) very very easy

image

asahasrabuddhe/laravel-api

A package that makes developing APIs in Laravel (Lumen too) very very easy

  • Friday, June 15, 2018
  • by asahasrabuddhe
  • Repository
  • 0 Watchers
  • 0 Stars
  • 34 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 5 Forks
  • 2 Open issues
  • 7 Versions
  • 100 % Grown

The README.md

Laravel API

A powerful package designed to make developing APIs very easy. This package takes care of all the boiler-plate code to provide support for routes, controller methods and associated logic out of the box., (*1)

Please note, this package is still in development and the documentation below is subject to change in ways which can make it incompatible with previous versions. Please DO NOT use in production until 1.0 release., (*2)

Installation

The package is currently under development and hence is not available on composer. Please use the following method to install and help build this package., (*3)

Clone the repository inside your Laravel installation as follows:, (*4)

git clone https://github.com/asahasrabuddhe/laravel-api packages/asahasrabuddhe/laravelapi

Add the following lines in your composer.json file to help install the package, (*5)

"repositories": [
        {
            "type": "path",
            "url": "packages/asahasrabuddhe/laravel-api",
            "options": {
                "symlink": true
            }
        }
    ],

Then, add the following lines in the require section of your composer file and run composer update., (*6)

"asahasrabuddhe/laravel-api": "dev-master"

You are now ready to use the package., (*7)

Basic Usage

  1. To enable using this package, replace the following: >>>a. Models: Replace all instances of use Illuminate\Database\Eloquent\Model; with use Asahasrabuddhe\LaravelAPI\BaseModel;. For the Laravel default user model, replace use Illuminate\Foundation\Auth\User as Authenticatable; with use Asahasrabuddhe\LaravelAPI\BaseUser as Authenticatable;

b. Controllers: Add the following line to the top of your controller: use Asahasrabuddhe\LaravelAPI\BaseController as Controller, (*8)

2.Routing: Please define the routes as following in routes/api.php file:, (*9)

ApiRoute::group([
    'middleware' => ['api'],
    'namespace' => 'App\Http\Controllers'], function () {
        ApiRoute::resource('user', 'UserController');
        ApiRoute::resource(<route>, <controller>);
    }
);

The Versions

15/06 2018

dev-master

9999999-dev

A package that makes developing APIs in Laravel (Lumen too) very very easy

  Sources   Download

The Development Requires

by Ajitem Sahasrabuddhe

05/06 2018

0.2.1-beta

0.2.1.0-beta

A package that makes developing APIs in Laravel (Lumen too) very very easy

  Sources   Download

The Development Requires

by Ajitem Sahasrabuddhe

12/05 2018

0.2.0-beta

0.2.0.0-beta

A package that makes developing APIs in Laravel (Lumen too) very very easy

  Sources   Download

The Development Requires

by Ajitem Sahasrabuddhe

12/05 2018

dev-testing

dev-testing

A package that makes developing APIs in Laravel (Lumen too) very very easy

  Sources   Download

The Development Requires

by Ajitem Sahasrabuddhe

24/04 2018

dev-staging

dev-staging

A package that makes developing APIs in Laravel (Lumen too) very very easy

  Sources   Download

by Ajitem Sahasrabuddhe

24/04 2018

0.1.1-beta

0.1.1.0-beta

A package that makes developing APIs in Laravel (Lumen too) very very easy

  Sources   Download

by Ajitem Sahasrabuddhe

24/04 2018

0.1-beta

0.1.0.0-beta

A package that makes developing APIs in Laravel (Lumen too) very very easy

  Sources   Download

by Ajitem Sahasrabuddhe