Skip to content

berkibap/todo-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Todo Application

A simple Todo application built with Java, Spring Boot, and Maven. This application allows users to manage tasks, including creating, updating, deleting, and searching tasks. Tasks can also be associated with tags for better organization.

Features

  • CRUD Operations: Create, read, update, and delete tasks.
  • Tag Management: Associate tasks with tags.
  • Search Functionality: Search tasks by title or completion status.
  • RESTful API: Exposes endpoints for interacting with tasks and tags.
  • Validation: Ensures required fields are provided when creating or updating tasks.

Technologies Used

  • Java: Programming language.
  • Spring Boot: Framework for building the application.
  • Maven: Dependency management and build tool.
  • Jakarta Persistence API (JPA): For database interaction.
  • Jakarta Validation: For input validation.
  • Lombok: To reduce boilerplate code.
  • H2 Database: In-memory database for development and testing.

Installation

  1. Clone the repository:
    git clone https://github.com/berkaygunduz/todo-app.git
    cd todo-app
  2. Ensure you have Java JDK 17 or later installed.
  3. Build the project using Maven:
    mvn clean install
  4. Run the application:
     mvn spring-boot:run
  5. Access the application at http://localhost:8080.
  6. Use tools like Postman or cURL to interact with the RESTful API endpoints.
  7. For example, to create a new task, send a POST request to http://localhost:8080/api/tasks with a JSON body containing the task details.
  8. To view all tasks, send a GET request to http://localhost:8080/api/tasks.

API Endpoints

Tasks

  • GET /api/tasks: Retrieve all tasks.
  • GET /api/tasks/{id}: Retrieve a specific task by ID.
  • POST /api/tasks: Create a new task.
  • PUT /api/tasks/{id}: Update an existing task by ID.
  • DELETE /api/tasks/{id}: Delete a task by ID.
  • GET /api/tasks/search: Search tasks by title or completion status.

Tag Management

Tags are managed automatically when creating tasks with the tags field in the TaskDTO. Tags are provided as a comma-separated string.

Example Request

Create Task Example

{
  "title": "Complete project documentation",
  "description": "Write and review the project documentation",
  "completed": false,
  "tags": "documentation,project"
}

Contributing

Contributions are welcome! If you find a bug or have a feature request, please open an issue. You can also submit a pull request with your changes.

License

This project is licensed under the MIT License. See the LICENSE file for details.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages