Controtto
📊 コントロット
Go、HTML、 JavaScriptなしで作成された、セルフホスト型の損益トラッカーです。Controttoは、トランザクションを追跡してSQLiteファイルに保存し、以下のような様々な計算結果を返します。
平均購入価格
現在の資産価値
取引履歴
輸入/輸出取引(サンプル参照)
損益
資産の価格を取得するために、Controtto は主に 4 つの API に依存しています (コードを参照)。
Binance - パブリック API、トークンは不要です。
BingX - パブリック API、トークンは必要ありません。
Alpha Vantage - 株式、無料ですがレート制限が短いです。(トークンを取得して
CONTROTTO_AVANTAGE_TOKENを設定してください)Tiingo - 株式、暗号通貨、外国為替。(アカウント/トークンを作成し、
CONTROTTO_TIINGO_TOKENを設定してください)
デモ
また、 demo.contre.ioでデモを確認することもできます。データベースは 1 時間ごとにリセットされます。
https://github.com/user-attachments/assets/28bf8782-6118-47c0-a94b-085e1a7045b2
すべての設定は.envファイルで設定され、環境変数として渡されます。変数CONTROTTO_PORTとCONTROTTO_DB_PATHが利用可能です。
# Install the dependencies
go mod tidy
# Set the .env
mv .env.example .env
# Source the env variables
. <(cat .env | grep -v -e '^$' | grep -v "#" | awk '{}')Related MCP server: gograph
ビルドと実行
go run ./cmd/main.go # go build ./cmd/main.go to just build it開発環境
go install github.com/cosmtrek/air@latest # Download air
air -c air.tomlそしてlocalhost:3000にアクセスします
ポッドマンで走る
コンテナイメージはDockerのパブリックレジストリから入手できます。Dockerを使用する場合は、 podmanをdockerに置き換えるだけです。
mkdir data
podman container run --rm -p 8000:8000 -v $(pwd)/data:/data contre95/controttoテストを実行する
go test -cover ./...
# Expected result
# ? controtto/cmd [no test files]
# ? controtto/src/app/managing [no test files]
# ? controtto/src/domain/pnl [no test files]
# ? controtto/src/gateways/markets [no test files]
# ? controtto/src/gateways/sqlite [no test files]
# ? controtto/src/presenters [no test files]
# ok controtto/src/app/querying 0.003s coverage: 40.7% of statementsやるべきこと
さらなるテスト
ログとメトリックのラッパーも便利です。
総純資産を追跡するためにアカウントを追加します。
すべての CSS を削除し、カスタム
style.css+ Tailwind CDN を使用します。
This server cannot be deployed
Maintenance
Related MCP Connectors
Design domain models and generate deterministic multi-stack code, driven by your coding agent.
Enforces architectural invariants and code quality rules inside your AI agent's edit loop.
AI Agent with Architectural Memory. Impact analysis (free), tests and code from the graph (pro).
Code intelligence for coding agents: semantic, AST, graph, and full-text search. 279+ languages.
Related MCP Servers
- AlicenseAqualityDmaintenanceStrict AI code reviewer powered by Groq. Finds bugs, vulnerabilities and security issues in your code. Supports analyze, compare versions, explain code, generate tests, and HTML reports.73MIT
- AlicenseAqualityAmaintenanceA local AST and type-aware Go repository context indexer that uses CHA to map symbols, call graphs, dependencies, and architecture patterns. Built for AI coding agents that need to navigate and reason about large Go codebases without reading raw files.68230MIT
- FlicenseNot gradedqualityDmaintenanceAutomates project scaffolding for Domain-Driven Design and Clean Architecture, providing professional naming, structure verification, and bilingual documentation generation.-
- AlicenseNot gradedqualityCmaintenanceReal-time architecture governance tool that enforces Clean Architecture, DDD, SOLID, TDD, and Security rules across 8 languages using 11 specialized agents.1 npmMIT
Appeared in Searches
- Information about the Go programming language
- Gin web framework for Go programming language
- Tips for Naming Variables and Functions in Go Programming Language
- Using separate agents for schema validation, code standards, and directory structure enforcement in development workflows
- How to compile code in Visual Studio