- PHP
- Laravel
- MySQL
note: jangan lupa menambahkan Accept => application/json
di header
- Get all contacts :
GET /api/contacts
- Post a contacts :
POST /api/contacts
- Update a contacts :
PUT /api/contacts/{id}
- Delete a contacts :
DELETE /api/contacts/{id}
- sign up :
POST /api/register
- sign in :
POST /api/signin
- sign out :
DELETE /api/signout
- unique validation for create or update
'phone' => ['required', 'numeric', 'digits_between:10,15', Rule::unique('contacts')->ignore($this->contact)]