- Method: GET
- URI: /api/user
- Description: Endpoint to retrieve the authenticated user.
- Middleware: auth:sanctum
- Controller Method: Closure
- Method: POST
- URI: /api/notes
- Description: Endpoint to create a new note.
- Middleware: None (assuming authentication is handled globally)
- Controller Method: NoteController@store
- Method: GET
- URI: /api/notes
- Description: Endpoint to retrieve all notes.
- Middleware: None (assuming authentication is handled globally)
- Controller Method: NoteController@index
- Method: GET
- URI: /api/notes/{note}
- Description: Endpoint to retrieve a single note by ID.
- Middleware: None (assuming authentication is handled globally)
- Controller Method: NoteController@show
- Method: PUT
- URI: /api/notes/{note}
- Description: Endpoint to update a note by ID.
- Middleware: None (assuming authentication is handled globally)
- Controller Method: NoteController@update
- Method: DELETE
- URI: /api/notes/{note}
- Description: Endpoint to delete a note by ID.
- Middleware: None (assuming authentication is handled globally)
- Controller Method: NoteController@destroy
This API provides endpoints for user registration and authentication.
- Endpoint:
POST /api/register - Description: Registers a new user.
name: User's nameemail: User's email addresspassword: User's password
user: Newly registered user
- Endpoint:
POST /api/login - Description: Logs in an existing user.
email: User's email addresspassword: User's password
token: Authentication token for the logged-in user