modulepackage
0.0.0-20230312123154-6cc47cf928dd
Repository: https://github.com/burakaktna/gorestapi.git
Documentation: pkg.go.dev
# README
GoRestAPI
This is a simple RESTful API written in Go. It allows you to perform CRUD (Create, Read, Update, Delete) operations on articles, tags and article tags.
Installation
To run this project, you need to have Docker and Docker Compose installed on your system. Then, run the following command:
docker-compose up -d --build
This will start the API server on port 8096.
Usage
To use the API, you can send HTTP requests to the following endpoints:
Articles
GET /articles
: Get all articlesPOST /articles
: Create a new articleGET /articles/:id
: Get an article by IDPUT /articles/:id
: Update an article by IDDELETE /articles/:id
: Delete an article by ID
Tags
GET /tags
: Get all tagsPOST /tags
: Create a new tagGET /tags/:id
: Get a tag by IDPUT /tags/:id
: Update a tag by IDDELETE /tags/:id
: Delete a tag by ID
Article Tags
GET /article_tags
: Get all article tagsPOST /article_tags
: Create a new article tagGET /article_tags/:id
: Get an article tag by IDPUT /article_tags/:id
: Update an article tag by IDDELETE /article_tags/:id
: Delete an article tag by ID
The API accepts and returns JSON data.
Contributing
If you would like to contribute to this project, feel free to fork the repository and submit a pull request.
License
This project is licensed under the MIT License. See the LICENSE
file for more information.
# Packages
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author