A full-stack travel destination discovery and trip planner built with the Beego Framework (Go). Explore countries, discover attractions, and manage your personal travel wishlist
Screenshots of the running app.
TravelSphere is a Beego MVC web application that lets users:
- Discover countries and their details (flag, capital, population, currency, languages)
- Explore tourist attractions and landmarks powered by OpenTripMap
- Manage a personal travel wishlist with statuses:
PlannedorVisited
The app uses Server-Side Rendering (SSR) for navigable pages and AJAX partial updates for dynamic interactions , no full page reloads for search, wishlist actions, or dashboard refresh.
| Layer | Technology |
|---|---|
| Language | Go (Golang) |
| Web Framework | Beego |
| Live Reload (Dev) | Bee Tool |
| Templating | Beego .tpl templates (SSR) |
| Frontend | Vanilla JavaScript + Fetch API (AJAX) |
| Countries API | REST Countries v5 |
| Attractions API | OpenTripMap |
| Wishlist Storage | In-memory Go map (no database) |
| Testing | Testify |
| Containerization | Docker |
- Search destinations with AJAX (updates results without page reload)
- Featured countries listing
- Popular attractions section
- Navigation menu
- Server-rendered default country list on page load
- Search box and region filter
- AJAX-powered search — only
#country-resultsupdates, no page reload - Each country card links to its SSR detail page
- Full SSR page with country info: flag, capital, population, currency, languages
- Tourist attractions, museums, and landmarks via OpenTripMap
- Current weather and travel conditions via WeatherAPI (bonus)
- AJAX "Add to Wishlist" — only
#wishlist-feedbackupdates
- Add, edit, and remove destinations
- Edit notes per destination
- Mark destinations as
PlannedorVisited
TravelSphere stores wishlist data entirely in application memory using a Go map. No database or external storage is used for this assessment.
| Behaviour | Detail |
|---|---|
| Speed | Extremely fast — all reads and writes happen in RAM, no disk I/O |
| Persistence | None — all wishlist data is lost on every application restart |
bee run reload |
Hot-reload triggered by file changes will reset the wishlist |
| Terminal close | Closing the terminal or stopping the process clears all entries |
This is intentional per the assessment requirements (no database). For production use, replace wishlistStore with a persistent store (database, Redis, or a JSON file).
Make sure you have the following installed:
# Go 1.21+
go version
# Bee tool for live reload
go install github.com/beego/bee/v2@latest
# Verify bee is on your PATH
bee versiongit clone https://github.com/Parisa-Reza/travelSphere
cd travelSpherego mod tidytouch .envconfigure .env file with
OPENTRIPMAP_KEY= your api key
RESTCOUNTRIES_KEY = your api key
RUN_MODE=dev
cp conf/app.conf.example conf/app.confconfigure .app.conf file with your keys
bee runThe app will start at: http://localhost:8080
Bee watches for file changes and automatically recompiles and restarts the server. Note that a restart clears the in-memory wishlist.
docker-compose up --buildthe app will start at: http://localhost:8080
# Run all tests
go test ./...
# Run a specific package
go test ./services/... -v
# total code coverage
go test -coverprofile=total_coverage.out ./... && go tool cover -func=total_coverage.out| Method | Route | Template | Description |
|---|---|---|---|
GET |
/ |
home.tpl |
Home page |
GET |
/countries |
countries.tpl |
Country Explorer |
GET |
/countries/:slug |
destination.tpl |
Country detail page |
GET |
/wishlist |
wishlist.tpl |
Wishlist page (protected) |
GET |
/dashboard |
dashboard.tpl |
Dashboard (protected) |
| Method | Route | Description |
|---|---|---|
GET |
/api/countries |
Country list; supports ?search= and ?region= |
GET |
/api/countries/:slug |
Single country detail |
GET |
/api/attractions |
Attractions by country/coordinates |
GET |
/api/wishlist |
Get all wishlist entries |
POST |
/api/wishlist |
Create a wishlist entry |
PUT |
/api/wishlist/:id |
Update note or status |
DELETE |
/api/wishlist/:id |
Delete a wishlist entry |
- add debounce for searching
- implement dashboard
- increasing code coverage
This project is for learning purpose assigned by W3 Engineers Ltd.