Go News API using Zero One Group's monorepo template
https://github.com/sglkc/01-monorepo.git
Zero One Group News API made using Go, Echo, PostgreSQL, and documented by Swagger.
For generated Swagger JSON and additional documentations, see /docs directory.
Entity Relationship Diagram
Swagger
Endpoints
flowchart TD
Root["/api"] --> Version["/v1"]
Version --> Articles["/articles"] & Topics["/topics"]
Topics --> TopicsGet["GET"] & TopicsPost["POST"] & TopicId["/:topic_id"]
TopicId --> TopicIdGet["GET"] & TopicIdPatch["PUT"] & TopicIdDelete["DELETE"] & TopicArticles["/articles"]
TopicArticles --> TopicArticlesGet["GET"]
Articles --> ArticlesGet["GET"] & ArticlesPost["POST"] & ArticleId["/:article_id"]
ArticleId --> ArticleIdGet["GET"] & ArticleIdPatch["PUT"] & ArticleIdDelete["DELETE"] & ArticleTopics["/topics"]
ArticleTopics --> ArticleTopicsGet["GET"] & ArticleTopicsPut["PUT"] & ArticleTopicsId["/:topic_id"]
ArticleTopicsId --> ArticleTopicsIdPost["POST"] & ArticleTopicsIdDelete["DELETE"]
Root:::Sky
Root:::Aqua
Version:::Sky
Version:::Aqua
Articles:::Aqua
Articles:::Sky
Topics:::Aqua
Topics:::Sky
TopicId:::Rose
TopicArticles:::Peach
ArticleId:::Rose
ArticleTopics:::Peach
ArticleTopicsId:::Ash
classDef Aqua stroke-width:1px, stroke-dasharray:none, stroke:#46EDC8, fill:#DEFFF8, color:#378E7A
classDef Sky stroke-width:1px, stroke-dasharray:none, stroke:#374D7C, fill:#E2EBFF, color:#374D7C
classDef Rose stroke-width:1px, stroke-dasharray:none, stroke:#FF5978, fill:#FFDFE5, color:#8E2236
classDef Peach stroke-width:1px, stroke-dasharray:none, stroke:#FBB35A, fill:#FFEFDB, color:#8F632D
classDef Ash stroke-width:1px, stroke-dasharray:none, stroke:#999999, fill:#EEEEEE, color:#000000
git clone https://github.com/sglkc/01-monorepo.git
cd 01-monorepo
pnpm install
cp .env.example .env
pnpm compose:up # Start local development server
pnpm compose:down # Stop local development server
pnpm compose:cleanup # Remove all local development server data
moon run tidy
moon zog-news:migration-up
moon zog-news:dev
/swagger/index.htmlmoon zog-news:test
moon zog-news:build