cmink-alone / simplerestfulapi
RestFull Api PHP
Installs: 4
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:webservice
This package is auto-updated.
Last update: 2024-09-19 21:35:57 UTC
README
RESTful API sederhana menggunakan PHP, konsep MVC & PSR-4 Autoloading Standard,
masih tahap pengembangan, belum ada Authentication, API Key, Hash Token, dll :D
fitur yang sudah ada
- Routing
- Request Method Handler (GET, POST, PUT, DELETE)
- Http Response Code Handler
- JSON Output (View)
- PDO Integration (Model)
- PSR-4 Autoloading Standard (Controller)
Contoh penggunaan API
test menggunakan Postman [https://www.getpostman.com/]
Semua Artikel
Endpoint = http://localhost/api/public/artikel
Method = GET
1 Artikel
Endpoint = http://localhost/api/public/artikel/{id}
Method = GET
Tambah Artikel Baru
Endpoint = http://localhost/api/public/artikel
Method = POST
Ubah Artikel
Endpoint = http://localhost/api/public/artikel/{id}
Method = PUT
Hapus Artikel
Endpoint = http://localhost/api/public/artikel/{id}
Method = DELETE