About • Pre requirements • How to use • Technologies • Author
This is a project that addresses an API in pure PHP in a simple way. The objective was to create a user control system that has a CRUD and a login method, and these functions can be accessed when the API is properly authenticated.
🔹 It is also necessary to have an API Client Platform. In this project Insomnia was used. This software can be found at the follow address: https://insomnia.rest/download
🔹 You have to create the project database. You have to go to database folder, copy the sql code and paste in into the database manager of your choice (In this project SQLyog Communit software was used, you can find it in https://code.google.com/archive/p/sqlyog/wikis/Downloads.wiki). Press CTRL + A to select all SQL code and press to run. You will have two tables: user and log_change_user as the following images.
🔹 To run the API it is necessary to have the Apache server and PHP connected.
🔹 Go to the documentation/documents folder and open the index.html file in the browser of your choice. This file shows how to use each of the API endpoints. You can see a endpoint documentation example in the following image:
🔹 Note that it is necessary to put the project path before the endpoint in the URL inside Insomnia. See the example:
🔹 With the server and PHP working, you can use Insomnia to access the API functions, all the details are in the documentation mentioned in the previous topic.
The following tools were used in the construction of the project:
Dayane Cordeiro
Made with ❤️ by Dayane Cordeiro!
✔ Computer Engineering student at PUC Minas
✔ PHP Developer
✔ Passionate about computer architecture and learning.