Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/finbourne/lusid-python-tools
Utility functions and a Command Line Interface (CLI) for interacting with LUSID by FINBOURNE.
https://github.com/finbourne/lusid-python-tools
Last synced: 4 days ago
JSON representation
Utility functions and a Command Line Interface (CLI) for interacting with LUSID by FINBOURNE.
- Host: GitHub
- URL: https://github.com/finbourne/lusid-python-tools
- Owner: finbourne
- License: mit
- Created: 2019-11-15T15:50:19.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2024-09-06T11:17:49.000Z (4 months ago)
- Last Synced: 2024-12-26T09:07:49.738Z (12 days ago)
- Language: Python
- Homepage:
- Size: 2.21 MB
- Stars: 10
- Watchers: 9
- Forks: 11
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: docs/CONTRIBUTING.md
- License: LICENSE
- Code of conduct: docs/CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
![LUSID_by_Finbourne](./resources/Finbourne_Logo_Teal.svg)
# Python tools for LUSID
This package contains a set of utility functions and a Command Line Interface (CLI) for interacting with [LUSID by FINBOURNE](https://www.finbourne.com/lusid-technology). To use it you'll need a LUSID account. [Sign up for free at lusid.com](https://www.lusid.com/app/signup)
![PyPI](https://img.shields.io/pypi/v/lusidtools?color=blue)
![Daily build](https://github.com/finbourne/lusid-python-tools/workflows/Daily%20build/badge.svg)
![Build and test](https://github.com/finbourne/lusid-python-tools/workflows/Build%20and%20test/badge.svg)
![Commit hook](https://github.com/finbourne/lusid-python-tools/workflows/commit-hook/badge.svg)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=finbourne_lusid-python-tools&metric=alert_status)](https://sonarcloud.io/dashboard?id=finbourne_lusid-python-tools)For more details see the lusid-python-tools [wiki](https://github.com/finbourne/lusid-python-tools/wiki).
## Installation
The PyPi package for lusid-python-tools can installed globally on your machine using the following command:
```sh
$ pip install lusidtools
```or if you are running as a non privileged user you may prefer to install specifically for your user account:
```sh
$ pip install --user lusidtools
```## CLI usage
You will need to create a secrets file and supply its location using the `secrets-file` parameter (or alternatively lusidtools will pick up a file called `secrets.json` in the current directory). The steps to do this are covered in [Getting started with the LUSID API and SDKs](https://support.finbourne.com/getting-started-with-apis-sdks).
Make sure that the Python `bin` folder is on your search path before trying the following examples. This is typically found under following locations:
* Windows: C:\Users\[userid]\AppData\Local\Programs\Python\[version]
* macOS: /Users/[userid]/Library/Python/[version]/bin
* Linux: /usr/local/bin/pythonTo see a full list of the available commands, run the following:
```sh
lusidtools --help
```### Examples:
#### List configured instrument identifier types
``` sh
lusidtools instr_id --secrets-file /path/to/secrets.json
```#### List instruments
``` sh
lusidtools instr_list -l 10 --secrets-file /path/to/secrets.json
```#### List scopes
``` sh
lusidtools scopes --secrets-file /path/to/secrets.json
```#### List portfolios in a scope
``` sh
lusidtools portfolios "" --secrets-file /path/to/secrets.json
```#### List holdings
```sh
lusidtools hld "" "" --secrets-file /path/to/secrets.json
```#### List transactions
```sh
lusidtools txn "" "" --secrets-file /path/to/secrets.json
```#### Reconcile holdings
```sh
lusidtools rec \
"" "" "YYYY-MM-DD" \
"" "" "YYYY-MM-DD" \
--secrets-file /path/to/secrets.json
```You can reconcile a portfolio against itself by specifying the same values for `` / `` and ` and then providing different effective dates.
## Contributing
We welcome contributions from our community. See our [contributing guide](docs/CONTRIBUTING.md) for information on how to contribute to and report issues with the Python tools for LUSID repository.
## Upgrading
To upgrade lusidtools run one of the commands below
```sh
$ pip install lusidtools -U
```or
```sh
$ pip install lusidtools -U --user
```