Golang Gin Framework CRUD RestAPI with MySQL for music records.

web-service-gin

Golang Gin Framework CRUD RestAPI with MySQL for music records.

Installation

This application runs on Go version 1.18.1. You can install Go directly or by using Homebrew.

Using Homebrew:

brew install go

For additional details see https://formulae.brew.sh/formula/go.

Getting started with Go: https://go.dev/doc/tutorial/getting-started.

For information on how to download and install Go without using Homebrew see https://go.dev/doc/install.

Getting Started

To run the application simply run the following command:

go run .

MySQL Database Setup

Make sure to setup a database with your own credentials following the format provided within the database directory.

Initial queries to get you started:

CREATE TABLE albums ( albumID int NOT NULL, title varchar(64) NOT NULL, artist varchar(64) NOT NULL, price double(4,2), PRIMARY KEY (albumID) );

Insert into albums (albumID, title, artist, price) VALUES (1, 'Blue Train', 'John Coltrane', 56.99);
Insert into albums (albumID, title, artist, price) VALUES (2, 'Jeru', 'Gerry Mulligan', 17.99);
Insert into albums (albumID, title, artist, price) VALUES (3, 'Sarah Vaughan and Clifford Brown', 'Sarah Vaughan', 33.99);

The table should have albumID, title, artist, and price where albumId is considered the primary key.

You may also create a recordsDB.sql file containing these queries.

Similar Resources

A ToDoList Demo based on Vue+Gin+Gorm+mysql

A ToDoList Demo based on Vue+Gin+Gorm+mysql

bubble清单 一个基于gin+gorm开发的练手小项目,通过该项目可初识go web开发该有的姿势。 前端页面基于vue和ElementUI开发,对前端不熟悉的童鞋可直接下载templates和static文件夹下的内容使用。 使用指南 下载 [email protected]:mao888/GoWe

Mar 16, 2022

Go-gin-ddd-cqrs - Clean api rest with Go, Gin and GORM

Go-gin-ddd-cqrs - Clean api rest with Go, Gin and GORM

GOLANG API REST Clean api rest with Go, Gin and GORM. Clean Architecture with DD

Oct 21, 2022

Gin-boilerplate - Gin boilerplate preconfigured with basic rest api features

Gin Boilerplate Build apis with gin faster with this template Features Validatio

Jun 24, 2022

Salmon - A music tracking web server

Salmon - A music tracking web server

Salmon is a music tracking server that connects with different sources to displa

Jan 19, 2022

Example golang using gin framework everything you need, i create this tutorial special for beginner.

Golang Gin Framework Fundamental Example golang using gin framework everything you need, i create this tutorial special for beginner. Feature Containe

Dec 16, 2022

Simple control panel for Golang based on Gin framework and MongoDB

Simple control panel for Golang based on Gin framework and MongoDB

Summer panel Simple control panel for Golang based on Gin framework and MongoDB How To Install go install github.com/night-codes/summer/summerGen@late

Dec 16, 2022

Golang Gin Framework Fundamental

Golang Gin Framework Fundamental Example golang using gin framework everything you need, i create this tutorial special for beginner. Feature Containe

Nov 9, 2022

Using golang framework (Gin) to create a web-application

News feeder Using golang framework (Gin) to create a web-application. This simpl

Aug 22, 2022

Backend developer with gin framework (Golang)

Backend developer with golang Install Packages : $ go get -u github.com/gin-gonic/gin $ Building from source Install a Go compiler. Install Goland ide

Nov 21, 2022
Gin-errorhandling - Gin Error Handling Middleware is a middleware for the popular Gin framework

Gin Error Handling Middleware Gin Error Handling Middleware is a middleware for

Sep 19, 2022
Go (Golang) API REST with Gin FrameworkGo (Golang) API REST with Gin Framework

go-rest-api-aml-service Go (Golang) API REST with Gin Framework 1. Project Description Build REST APIs to support AML service with the support of exte

Nov 21, 2021
Gin-boilerplate - This repository contains boilerplate code of a REST service using Gin (golang) framework.

Boilerplate REST service using Gin web framework (golang) Introduction This repository contains a boilerplate REST API service using Gin web framework

Apr 28, 2022
Api-go-gin-viper - Simple representaion on how to implement CRUD functionality in API using Go programming language

Simple API implementaion in Go To Get Started Clone repo Run the command to clon

Feb 18, 2022
GoCondor is a golang web framework with an MVC like architecture, it's based on Gin framework
GoCondor is a golang web framework with an MVC like architecture, it's based on Gin framework

GoCondor is a golang web framework with an MVC like architecture, it's based on Gin framework, it features a simple organized directory structure for your next project with a pleasant development experience, made for developing modern APIs and microservices.

Dec 29, 2022
Golang : Use gorm with mysql in gin

Golang : Use gorm with mysql in gin This repository guides to how ORM can be implemented in Golang. After cloning the code, follow below steps to let

Dec 9, 2021
Gin-easy-todo - golang 의 RESTful API 프레임워크 gin 을 활용해 아주 간단한 Todo 애플리케이션을 만들어보자.
Gin-easy-todo - golang 의 RESTful API 프레임워크 gin 을 활용해 아주 간단한 Todo 애플리케이션을 만들어보자.

목차 1. 요약 2. 목표 3. API 목록 4. 프로젝트 구조 5. 패키지 별 기능과 관계 6. 사전 작업 6.1. DB, Table 생성 6.2. 모듈 생성 6.3. 패키지 다운로드 7. Gin 작성 7.1. 데이터베이스 설정 7.2. 테이블, 스키마 정의 7.3.

Jan 2, 2022
Go-service-gin - Simple Web api application developed in Golang and Gin

Simple Web api application developed in Golang and Gin Initial Tutorial URL http

Jan 4, 2022
Go-gin-mongo-api - A backend RESTful API built using golang, gin and mongoDB

go-gin-mongo-API This is a RESTful backend API which is developed using the gola

Jul 19, 2022
A barebones URL Shortener implementation in Go using Gin and MySQL. Also features a basic frontend.

URL Shortener in Go This is a barebones URL Shortener implementation in Go using the Gin web framework and MySQL. Also features a basic frontend. Loca

Dec 22, 2021