Download the PHP package qcyx/laravel-api without Composer

On this page you can find all versions of the php package qcyx/laravel-api. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-api

基于Laravel设计的Restful风格api三方包

该扩展包实现了 自动curd,场景验证,自定义异常,统一json返回等

安装说明:

为了不破坏框架现有的功能,不增加额外学习成本,使用了继承的方式,可随意覆盖或者选择性继承

前提: 在项目composer.json根节点下添加如下自定义仓库配置:

  1. composer require qcs/laravel-api
  2. laravel 5.5以上自动发现服务提供者,无需操作,5.5以下版本请手动添加
  3. 发布配置文件 php artisan vendor:publish --provider="QCS\LaravelApi\Providers\LaravelApiProvider",
  4. 继承基础控制器BaseController(命名空间:QCS\LaravelApi\Controllers)
  5. 继承基础异常类BaseHandler (命名空间:QCS\LaravelApi\Exceptions)
  6. 继承基础模型类 BaseModel (命名空间:QCS\LaravelApi\Models)
  7. 继承基础验证类 BaseValidate (命名空间:QCS\LaravelApi\Validates)

自动curd: 基于restful api的控制器继承基类之后,并且需要建立对应的模型与验证类,注入到控制器中,无需书写index,update,show,destroy,store方法,可自动处理基本的curd需求,自动处理验证请求。

统一json返回: 在需要返回处 引入ResultTrait, 调用对应的this->success,this->error,this->noData 可统一返回json格式响应,实现了自定义异常,可处理相关逻辑


All versions of laravel-api with dependencies

PHP Build Version
Package Version
Requires php Version ^7.0
overtrue/laravel-lang Version ^5.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package qcyx/laravel-api contains the following files

Loading the files please wait ....