- A simple TodoList application written in Go that allows users to view and manage their tasks through HTTP endpoints.
- This project is a basic web server that provides endpoints to display a list of tasks and greet the user. It demonstrates basic HTTP handling and string manipulation in Go.
-
Clone the repository:
git clone https://github.com/ahmedalaa14/Go-Web-API.git cd Go-Web-API -
Install Go: Ensure you have Go installed on your machine. You can download it from here.
-
Run the application:
go run main.go
Once the application is running, you can interact with it using a web browser or tools like curl.
-
Home Page:
curl http://localhost:8080/
This will return a welcome message.
-
Show Tasks:
curl http://localhost:8080/show-tasks
This will return the list of tasks.
GET /: Returns a welcome message.GET /show-tasks: Returns the list of tasks.
- Fork the repository.
- Create a new branch (
git checkout -b feature-branch). - Make your changes.
- Commit your changes (
git commit -am 'Add new feature'). - Push to the branch (
git push origin feature-branch). - Create a new Pull Request.