# techschool/simplebank

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/techschool-simplebank).**

6,495 stars · 1,098 forks · Go · MIT

## Links

- GitHub: https://github.com/techschool/simplebank
- awesome-repositories: https://awesome-repositories.com/repository/techschool-simplebank.md

## Topics

`backend` `docker` `gin` `go` `golang` `grpc` `grpc-go` `http-server` `kubernetes`

## Description

Simplebank is a financial services backend application built with Go that manages bank accounts and transfers. It utilizes a dual-protocol interface, providing both gRPC and REST APIs via Protocol Buffers to support different client communication requirements.

The system implements a PostgreSQL data layer with versioned schema migrations and type-safe query generation. It handles financial operations through atomic fund transfers and balance change tracking to maintain consistent audit trails.

The architecture includes an asynchronous task worker system using a message queue to offload long-running processes and middleware for token-based user authentication and role-based request authorization. The project also employs interface-based mock injection for unit testing and is packaged for deployment on Kubernetes clusters using containerization.

## Tags

### Business & Productivity Software

- [Bank Account Management](https://awesome-repositories.com/f/business-productivity-software/bank-account-management.md) — Provides a financial services backend for managing bank accounts and fund transfers. ([source](https://github.com/techschool/simplebank#readme))
- [Banking Backends](https://awesome-repositories.com/f/business-productivity-software/banking-backends.md) — Provides a complete financial services backend for managing bank accounts and funds transfers.
- [Inter-Account Fund Transfers](https://awesome-repositories.com/f/business-productivity-software/inter-account-fund-transfers.md) — Executes the movement of funds between bank accounts using atomic transactions. ([source](https://github.com/techschool/simplebank#readme))

### Data & Databases

- [Balance Tracking](https://awesome-repositories.com/f/data-databases/balance-specifications/balance-tracking.md) — Maintains a complete audit trail by recording every fund addition or subtraction as a distinct entry. ([source](https://github.com/techschool/simplebank#readme))
- [PostgreSQL Database Clients](https://awesome-repositories.com/f/data-databases/connection-pools/postgresql-database-clients.md) — Implements a persistent data layer with connection management and SQL generation for PostgreSQL.
- [Atomic Transactions](https://awesome-repositories.com/f/data-databases/database-management-systems/database-systems-management/connection-transaction-management/atomic-transactions.md) — Wraps multiple balance updates in atomic transactions to ensure financial consistency and prevent partial updates.
- [Financial Transaction Processing](https://awesome-repositories.com/f/data-databases/financial-transaction-processing.md) — Implements a system for recording and managing financial payments and account balances.
- [Schema Migration Scripts](https://awesome-repositories.com/f/data-databases/data-schema-management/schema-versioning/schema-migration-scripts.md) — Tracks and applies incremental database changes through ordered scripts to synchronize data structures.
- [Database Schema Migrations](https://awesome-repositories.com/f/data-databases/database-management-systems/database-systems-management/database-management/database-schema-migrations.md) — Automates the application of versioned updates to database schemas using migration scripts. ([source](https://github.com/techschool/simplebank#readme))
- [Type-Safe Database Clients](https://awesome-repositories.com/f/data-databases/type-safe-database-clients.md) — Generates strongly-typed Go interfaces for database operations to ensure compile-time safety. ([source](https://github.com/techschool/simplebank/blob/master/sqlc.yaml))

### Networking & Communication

- [Multi-Protocol Routing](https://awesome-repositories.com/f/networking-communication/network-transport-protocols/multi-protocol-routing.md) — Routes both gRPC and RESTful HTTP requests through a single unified gateway interface. ([source](https://github.com/techschool/simplebank/blob/master/README.md))
- [API Gateway](https://awesome-repositories.com/f/networking-communication/proxy-protocols/protocol-translation/api-gateway.md) — Implements a gateway that maps web requests to both gRPC and HTTP backend service protocols.
- [REST-to-gRPC Gateways](https://awesome-repositories.com/f/networking-communication/rest-to-grpc-gateways.md) — Supports diverse client needs by serving functionality through both gRPC and RESTful HTTP interfaces. ([source](https://github.com/techschool/simplebank/blob/master/main.go))
- [gRPC Code Generators](https://awesome-repositories.com/f/networking-communication/distributed-systems-p2p/distributed-computing/communication-protocols/websocket-implementations/websocket-clients-and-servers/grpc-code-generators.md) — Automatically generates typed Go code for gRPC clients and servers from .proto files.

### Security & Cryptography

- [Authorization Middleware](https://awesome-repositories.com/f/security-cryptography/authorization-middleware.md) — Intercepts API calls using middleware to verify security tokens and enforce role-based access controls.
- [Request-Level Role Authorization](https://awesome-repositories.com/f/security-cryptography/identity-access-management/identity-management/user-management/user-role-management/request-level-role-authorization.md) — Enforces role-based permissions on each API request to block unauthorized actions. ([source](https://github.com/techschool/simplebank/blob/master/README.md))
- [Password Hashing Utilities](https://awesome-repositories.com/f/security-cryptography/security/cryptography-and-secrets/cryptographic-primitives-management/password-hashing-utilities.md) — Uses specialized hashing algorithms to securely transform passwords into irreversible hashes. ([source](https://github.com/techschool/simplebank#readme))
- [User Authentication Systems](https://awesome-repositories.com/f/security-cryptography/user-authentication-systems.md) — Implements frameworks for verifying user identity and controlling access to sensitive financial resources.
- [Dual Protocol APIs](https://awesome-repositories.com/f/security-cryptography/grpc-security/grpc-and-http-tls-securings/dual-protocol-apis.md) — Provides an API that is accessible via both gRPC and REST protocols for flexible client integration.

### Development Tools & Productivity

- [API Code Generators](https://awesome-repositories.com/f/development-tools-productivity/api-code-generators.md) — Produces server stubs and client libraries from Protocol Buffer interface definitions. ([source](https://github.com/techschool/simplebank/blob/master/Makefile))

### DevOps & Infrastructure

- [Asynchronous Task Processing](https://awesome-repositories.com/f/devops-infrastructure/automation-orchestration/task-execution-frameworks/task-job-management/task-queues/asynchronous-task-processing.md) — Offloads long-running jobs to background workers via a message queue to maintain responsiveness.
- [Application Containerization](https://awesome-repositories.com/f/devops-infrastructure/container-orchestration/container-runtimes/runtime-configuration-interfaces/docker-socket-orchestrators/docker-target-configurators/docker-container-deployments/application-containerizers/application-containerization.md) — Packages binaries and configurations into portable container images for consistent deployment. ([source](https://github.com/techschool/simplebank/blob/master/Dockerfile))
- [Kubernetes Application Deployments](https://awesome-repositories.com/f/devops-infrastructure/kubernetes-application-deployments.md) — Orchestrates the deployment of containerized services and their dependencies on Kubernetes clusters.
- [Kubernetes Application Deployments](https://awesome-repositories.com/f/devops-infrastructure/kubernetes-deployments/kubernetes-application-deployments.md) — Orchestrates the deployment of containerized services to Kubernetes clusters with ingress routing. ([source](https://github.com/techschool/simplebank/blob/master/README.md))
- [Message Queue Workers](https://awesome-repositories.com/f/devops-infrastructure/message-queue-workers.md) — Offloads time-consuming background tasks to a separate worker system using a message queue.

### Programming Languages & Runtimes

- [Go Code Generators](https://awesome-repositories.com/f/programming-languages-runtimes/go-code-generators.md) — Translates database schemas and raw queries into type-safe Go code to eliminate manual boilerplate.

### Software Engineering & Architecture

- [Asynchronous Task Queues](https://awesome-repositories.com/f/software-engineering-architecture/asynchronous-task-queues.md) — Executes long-running processes in the background via a task queue to keep the request loop non-blocking. ([source](https://github.com/techschool/simplebank/blob/master/main.go))

### Testing & Quality Assurance

- [Interface-Based Test Doubles](https://awesome-repositories.com/f/testing-quality-assurance/software-testing/dependency-mocking/automated-mock-generation/dynamic-mock-objects/multi-interface-mocks/interface-based-test-doubles.md) — Utilizes Go interfaces to inject mock objects for isolated unit testing of business logic.
