Recommend this page to a friend! |
Download .zip |
Info | Example | View files (23) | Download .zip | Reputation | Support forum | Blog | Links |
Last Updated | Ratings | Unique User Downloads | Download Rankings | |||||
2024-01-27 (19 hours ago) | Not yet rated by the users | Total: Not yet counted | Not yet ranked |
Version | License | PHP version | Categories | |||
api_framework 1.0 | Custom (specified... | 5 | Web services, PHP 7 |
Description | Author | |
This package can be used to create new APIs using controller classes. |
<?php |
A PHP Framework for creating APIs
<a href="http://jwt.io"> <img src="http://jwt.io/img/badge-compatible.svg" /> </a>
This project is created using PHP 8.0+
Coding Standard is PSR-12
$ composer update
$ composer dump-autoload
Import api.sql to your phpmyadmin
Generate 256-bit key from here allkeysgenerator
Update .env file
The system has 2 authentication methods
After that just create an account using /register endpoint and POST method
$ httpie post http://localhost/api/register name="Root" username="admin" password="admin"
or
Use the example to create an account
You can reuse the example for any project you want
Enjoy
TaskController.php
TaskGateway.php
Are an example project to show how the system work
Also you can reuse the code in it and change it to your specifications
MIT
2022 - fariscode
Files |
File | Role | Description | ||
---|---|---|---|---|
api (3 files) | ||||
example (2 files) | ||||
src (1 directory) | ||||
api.sql | Data | Auxiliary data | ||
composer.json | Data | Auxiliary data | ||
delete-expired-refresh-tokens.php | Example | Example script | ||
envfile | Data | Auxiliary data | ||
LICENSE | Lic. | License text | ||
README.md | Doc. | Documentation |
Files | / | api |
File | Role | Description |
---|---|---|
.htaccess | Data | Auxiliary data |
bootstrap.php | Example | Example script |
index.php | Example | Example script |
Files | / | example |
File | Role | Description |
---|---|---|
index.html | Doc. | Documentation |
register.php | Example | Example script |
Files | / | src | / | MY_Framework |
File | Role | Description | ||
---|---|---|---|---|
Exceptions (2 files) | ||||
Auth.php | Class | Class source | ||
BaseController.php | Class | Class source | ||
Database.php | Class | Class source | ||
ErrorHandler.php | Class | Class source | ||
JWTCodec.php | Class | Class source | ||
RefreshTokenGateway.php | Class | Class source | ||
TaskController.php | Class | Class source | ||
TaskGateway.php | Class | Class source | ||
UserController.php | Class | Class source | ||
UserGateway.php | Class | Class source |
Files | / | src | / | MY_Framework | / | Exceptions |
File | Role | Description |
---|---|---|
InvalidSignatureException.php | Class | Class source |
TokenExpiredException.php | Class | Class source |
Version Control | Unique User Downloads | |||||||
100% |
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.