https://github.com/wastingnotime/contacts-backend-go-echo
This repository maintain a golang/echo application that is part of "contacts" project, an initiative to explore technologies features.
https://github.com/wastingnotime/contacts-backend-go-echo
crud-api echo golang gorm migrations sqlite
Last synced: 4 months ago
JSON representation
This repository maintain a golang/echo application that is part of "contacts" project, an initiative to explore technologies features.
- Host: GitHub
- URL: https://github.com/wastingnotime/contacts-backend-go-echo
- Owner: wastingnotime
- License: mit
- Created: 2020-06-17T13:06:41.000Z (about 6 years ago)
- Default Branch: main
- Last Pushed: 2025-11-20T10:37:32.000Z (7 months ago)
- Last Synced: 2026-01-12T05:27:12.981Z (5 months ago)
- Topics: crud-api, echo, golang, gorm, migrations, sqlite
- Language: Go
- Homepage:
- Size: 58.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# contacts-backend-go-echo
**contacts-backend-go-echo** is part of "contacts" project that is an initiative where we try to explore frontend and backend implementations in order to better understand it cutting-edge features. This repository presents a golang rest API sample.
## status
This repository belongs to the Contacts reference initiative started in 2020.
Its purpose was to understand how different stacks shape design decisions around the same domain model.
As of 2026, this project is frozen.
The exploration phase has been completed.
My current focus is depth, invariants, and system coherence rather than stack comparison.
This code remains as historical reference.
## stack
* golang 1.24
* echo
* sqlite
* gorm
## features
* migrations
* high concurrent
* small footprint
## get started (linux only)
### option 1 - use latest docker image from dockerhub
execute the remote docker image
```
docker run -p 8010:8010 wastingnotime/contacts-backend-go-echo:0.1.0-alpha
```
### option 2 - build and run a local docker image
build a local docker image
```
docker build --tag contacts.backend.go.echo .
```
execute the local docker image
```
docker run -p 8010:8010 contacts.backend.go.echo
```
### option 3 - execute from source code
- first, install golang 1.24+, if you don't have it on your computer: [how to install golang](https://go.dev/doc/install)
- go to root of solution and execute the commands below
set environment for development
```
cp .env_example .env
```
update deps
```
go get -u -v
go mod tidy
```
and then run the application
```
go run .
```
## testing
create a new contact
```
curl --request POST \
--url http://localhost:8010/contacts \
--header 'Content-Type: application/json' \
--data '{
"firstName": "Albert",
"lastName": "Einstein",
"phoneNumber": "2222-1111"
}'
```
retrieve existing contacts
```
curl --request GET \
--url http://localhost:8010/contacts
```
more examples and details about requests on (link) *to be defined