Skip to content

byumov/tinkoff_investing_exporter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tinkoff investing exporter for Prometheus

.github/workflows/mail.yml Docker Pulls Docker Cloud Automated build Docker Cloud Build Status

Usage

First, get token from Tinkoff: https://tinkoffcreditsystems.github.io/invest-openapi/auth/

Docker

docker run -d -p 2112:2112 -e TCS_TOKEN="YOUR_TOKEN" byumov/prometheus_tcs
curl 127.0.0.1:2112/metrics

Binary

TCS_TOKEN="YOUR_TOKEN" ./tinkoff_investing_exporter

Configuration via env variables

TCS_UPDATE_INTERVAL in seconds, 120 by default. Be careful, Tinkoff API has a limit 120 requests\min

TCS_DEBUG, set with any value for more verbosity

TCS_LISTEN_PORT, 2112 by default

Example dashboard

Example dashboard

How to build

Binary

git clone https://github.com/byumov/tinkoff_investing_exporter.git
cd tinkoff_investing_exporter
GOOS="linux" GOARCH="amd64" go build .

For other OS see GOOS and GOARCH values in go documentation.

Docker image

git clone https://github.com/byumov/tinkoff_investing_exporter.git
cd tinkoff_investing_exporter
docker build .