https://github.com/itolosa/orionx-api-client
Python Orionx API Client (http://orionx.io)
https://github.com/itolosa/orionx-api-client
api-client bitcoin bitcoin-api cryptocurrency exchange orionx python python3
Last synced: about 1 year ago
JSON representation
Python Orionx API Client (http://orionx.io)
- Host: GitHub
- URL: https://github.com/itolosa/orionx-api-client
- Owner: itolosa
- License: mit
- Created: 2017-12-27T06:20:04.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-10-18T01:09:13.000Z (over 2 years ago)
- Last Synced: 2025-04-19T22:02:47.494Z (about 1 year ago)
- Topics: api-client, bitcoin, bitcoin-api, cryptocurrency, exchange, orionx, python, python3
- Language: Python
- Homepage: https://pypi.python.org/pypi/orionx-api-client/
- Size: 396 KB
- Stars: 17
- Watchers: 5
- Forks: 4
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Orionx Api Client
[](https://pypi.python.org/pypi/orionx-api-client/) [](https://pypi.org/project/orionx-api-client/)
[](https://pypi.python.org/pypi/orionx-api-client/) [](https://pepy.tech/project/orionx-api-client) [](https://codecov.io/gh/itolosa/orionx-api-client)
Orionx Api Client is a GraphQL Client for Orionx Exchange (orionx.com)
It is able to make transactions and show market information
# Install
Using pip:
```
pip install orionx-api-client
```
Using poetry:
```
poetry add orionx-api-client
```
## Usage example
To execute the examples you have to setup an `API KEY` and a `SECRET KEY`
You can obtain them by following this tutorial: [link](https://docs.orionx.com/docs#creaci%C3%B3n-de-api-keys).
```python
from orionx_api_client import Orionx
client = Orionx("", "")
with client as session:
ds = session.dsl()
query = ds.Query.marketStats.args(
marketCode="BTCCLP",
aggregation="h1"
).select(
ds.MarketStatsPoint.open
)
print(session.execute(query))
```
For additional details check the `examples` directory in this repository
## Query batching
You can send multiple requests at once using [query batching](https://www.apollographql.com/blog/apollo-client/performance/batching-client-graphql-queries/).
Check the file `examples/using_batcher.py` for an example.
## Contributions
You're welcome to contribute to this project! Just open a PR!