Code Monkey home page Code Monkey logo

zetamarkets-py's Introduction

Zeta Python SDK ๐Ÿ

PyPI version Documentation Status License Discord Chat

Installation

Install from PyPI

pip install zetamarkets_py

Install from Source

You can add optional dependencies for running trading examples or docs using the --with flag.

poetry install [--with examples, docs]

Usage

Setting up a Solana wallet

Please follow the Solana wallet creation docs to set up a wallet if you don't already have one locally. By default the SDK will look for the wallet at ~/.config/solana/id.json

Running the examples

Run the various code examples provided in the examples directory.

Development

Formatting and Linting

We use black with isort for formatting and ruff for linting

poetry format
poetry lint

zetamarkets-py's People

Contributors

0xtristan avatar benedictbrady avatar filipzeta avatar kelvinlau20100 avatar xjcaa avatar yassinekachrad avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

zetamarkets-py's Issues

Incorrect Query Results for RNDR Positions

Description:
When the Client is initialized with the parameter asset = [Asset.RNDR] and the fetch_margin_state method is called, the query results only include 'SOL' positions. However, there are RNDR positions that should be returned. This discrepancy indicates a bug in the query logic, as the expected result should include RNDR positions when specified.

Expected Behavior:
When asset = [Asset.RNDR] is set, the fetch_margin_state method should return positions for RNDR.

Actual Behavior:
The method returns positions only for 'SOL', ignoring the specified RNDR positions.

Steps to Reproduce:

  1. Initialize the Zeta Client with asset = [Asset.RNDR].
  2. Call the fetch_margin_state method.
  3. Observe that the returned positions only include 'SOL' and exclude RNDR.

Impact:

This issue leads to incomplete and incorrect position data being retrieved, affecting any functionality or decisions based on these results.

Request:
Please investigate and fix this bug to ensure that the fetch_margin_state method correctly returns positions for the specified assets, including RNDR.

Thank you for addressing this issue.

Additional Examples

Can you add additional examples? Discord says that trigger orders such as SL/TP can be done, but I'm having trouble seeing how to do this. Thank you!

Trade history?

I did a brief pass through the API, I didn't see a way to extract my historical trades. It helps to pay my taxes :)

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.