Giter VIP home page Giter VIP logo

nfex-api's Introduction

NFEX API

bot.py

This simple bot fetch mark price from API, add 2% on top of it and posts new order.

The order is limit order, open short, cross margin and leverage 5x (in testnet 10x minimum)

X seconds after posts new order, it again fetch mark price from API, add 2% on top of it and posts new order.

The process will repeat until interrupt by keyboard.

  1. Create Python environment

python3 -m venv env

  1. Activate the environment

source env/bin/activate

  1. Install dependencies

pip install -r requirements.txt

  1. Create a .env file and insert PRIVATE_KEY=private key here

  2. Edit input in === user interact section === and run script

python3 bot.py

api.py

Examples to call NFEX API

python3 api.py

trade id - name

main env

1001 - AZUKI/ETH

1002 - BAYC/ETH

1003 - MAYC/ETH

1004 - CLONEX/ETH

1005 - MOONBI/ETH

1006 - DOODLE/ETH

1007 - PENGUI/ETH

1008 - NAKAMI/ETH

1009 - OTHERD/ETH

1010 - PUNKS/ETH

1011 - DEGODS/ETH

1012 - MILADY/ETH

1013 - KODA/ETH

1014 - CAPT/ETH

1015 - POTATO/ETH

1016 - BAKC/ETH

1017 - BEANZ/ETH

1018 - PIXELM/ETH

1019 - MEEBIT/ETH

1021 - REMILI/ETH

1024 - KUBZ/ETH

1026 - MFERS/ETH

test env

1001 - AZUKI/ETH

1003 - MAYC/ETH

1004 - CLONEX/ETH

1006 - DOODLE/ETH

1008 - OTHERD/ETH

1009 - PUNK/ETH

1010 - NAKAMI/ETH

1012 - DEGODS/ETH

1013 - MILADY/ETH

1018 - BAKC/ETH

1019 - BEANZ/ETH

1022 - GEMESIS/ETH

1023 - LFPEPE/ETH

1027 - REMILI/ETH

1029 - KPANDA/ETH

1031 - KUBZ/ETH

1032 - 0N1/ETH

1033 - MFERS/ETH

1034 - OPEPEN/ETH

ed25519 keypair

This script generate random keypair for ed25519 locally, which contain public key & private key of ed25519 for the API.

python3 keypair.py

Public key to give NFEX team, together with EOA that reload ETH, for whitelist purpose.

Private key to insert into .env file to use the API, after NFEX team whitelisted successfully.

UI Url

Main: https://www.nfex.io/trade/BAYC

Test: https://web-uat.nfexinsider.com/trade/BAYC

API docs in nfex-api.html

nfex-api's People

Contributors

siewchongche avatar anibaiweng avatar

Watchers

 avatar

Forkers

anibaiweng

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.