GithubHelp home page GithubHelp logo

sergezabrockiy / invest-python Goto Github PK

View Code? Open in Web Editor NEW

This project forked from wiseplat/invest-python

0.0 0.0 0.0 1.41 MB

Tinkoff Invest Python gRPC client

Home Page: https://tinkoff.github.io/invest-python/

License: Apache License 2.0

Python 99.77% Makefile 0.23%

invest-python's Introduction

Tinkoff Invest

PyPI PyPI - Python Version

Данный репозиторий предоставляет клиент для взаимодействия с торговой платформой Тинькофф Инвестиции на языке Python.

Начало работы

$ pip install tinkoff-investments

Возможности

  • ☑ Синхронный и асинхронный GRPC клиент
  • ☑ Возможность отменить все заявки
  • ☑ Выгрузка истории котировок "от" и "до"
  • ☑ Кеширование данных
  • ☑ Торговая стратегия

Как пользоваться

Получить список аккаунтов

from tinkoff.invest import Client

TOKEN = 'token'

with Client(TOKEN) as client:
    print(client.users.get_accounts())

Переопределить target

В Tinkoff Invest API есть два контура - "боевой", предназначенный для исполнения ордеров на бирже и "песочница", предназначенный для тестирования API и торговых гипотез, заявки с которого не выводятся на биржу, а исполняются в эмуляторе.

Переключение между контурами реализовано через target, INVEST_GRPC_API - "боевой", INVEST_GRPC_API_SANDBOX - "песочница"

from tinkoff.invest import Client
from tinkoff.invest.constants import INVEST_GRPC_API

TOKEN = 'token'

with Client(TOKEN, target=INVEST_GRPC_API) as client:
    print(client.users.get_accounts())

⚠️ Не публикуйте токены в общедоступные репозитории


Остальные примеры доступны в examples.

Contribution

Для тех, кто хочет внести свои изменения в проект.

License

Лицензия The Apache License.

invest-python's People

Contributors

wiseplat avatar irusland avatar daxartio avatar github-actions[bot] avatar sergezabrotskiy avatar 0dminnimda avatar martins0n avatar b1ng0o avatar grasth avatar terekhinao avatar sourinjir avatar therb1 avatar kordimsan avatar ddmitiy avatar anta-semenov avatar alexandervolkovtcs avatar gt-volk avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.