Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Payments API

A sample payments API service used as the running example in the Kargo book.

This service is intentionally simple: it stores payments in memory and exposes a REST API. The focus is on demonstrating Kargo's continuous promotion workflows, not on building a production payment system.

Endpoints

Method Path Description
GET /healthz Liveness probe
GET /readyz Readiness probe
GET /version Build version and commit SHA
GET /api/v1/payments List all payments
POST /api/v1/payments Create a payment
GET /api/v1/payments/{id} Get a payment by ID

Quick Start

# Run locally
make run

# Run tests
make test

# Build Docker image
make docker-build VERSION=1.0.0

Environment Variables

Variable Default Description
PORT 8080 HTTP listen port

Container Image

Published to ghcr.io/kargobook/payments-api on every push to main and on semver tags.

docker run -p 8080:8080 ghcr.io/kargobook/payments-api:latest

Related Repos

Book Chapters

This example is referenced throughout the book, including:

  • Chapter 4 — Introducing Kargo (Warehouse and Stage concepts)
  • Chapter 6 — Your First Promotion
  • Chapter 7 — Warehouses and Artifact Lineage
  • Chapter 8 — Stage Graph Modeling
  • Chapter 9 — Automatic and Manual Promotion
  • Chapter 11 — Multi-Service Promotion (with auth-service)
  • Chapter 12 — Multi-Team and Platform Patterns
  • Chapter 14 — Enterprise Governance and RBAC
  • Chapter 15 — Enterprise Integrations

License

MIT

About

payments-api example app

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages