giordanocardillo/slim-restapi

基于Slim框架的简单Rest API

1.0.12 2018-04-28 13:25 UTC

This package is not auto-updated.

Last update: 2024-09-28 20:40:52 UTC


README

Code Climate Codacy Grade Packagist

基于Slim框架的RESTful API,采用异常驱动编程。

目录结构

+-- app                Contains app files
|  +-- RestAPI         Contains core files
|  |  +-- Exceptions   Contains custom exception classes
|  |  +-- Utils        Contains utilities
|  +-- routes          Contains the routes
|  +-- config.json     Configuration file
+-- public_html        Public web folder
|  +-- index.php       Main slim page
+-- database.sql        The database structure file   

如何配置它

要配置RestAPI,在app文件夹内有一个config.json文件。它很直观。

如何使用它

此项目使用composer,所以您只需执行以下命令

composer create-project giordanocardillo/slim-restapi .

然后使用提供的database.sql文件导入数据库

用户认证工作流程

待办事项