Skip to main content

Indodax

PyPI version 1.3.2 Modul ini untuk trading di indodax

Install

pip install indodax

Cara Penggunaan

Melihat Harga

$ python
Python 3.8.5 (default, Jul 28 2020, 12:59:40) 
[GCC 9.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from indodax import indodax
>>> indodax.get_price('btc') #contoh melihat harga BTC
{'ticker': {'high': '186608000', 'low': '173463000', 'vol_btc': '277.39109788', 'vol_idr': '49592483275', 'last':   '186306000', 'buy': '186305000', 'sell': '186306000', 'server_time': 1603298398}}

Melihat Info Saldo

pertama anda harus mengambil key dan secret di akun anda, jika sudah ada silahkan ikuti instruksi ini sebagai langkah awal:

>>> key = 'YOUR_KEY'
>>> secret = b'YOUR_SECRET'
>>> a = indodax(key, secret)
>>> a.get_info() # anggap saja ini adalah informasi saldo dan alamat qurenncy anda
{ "succses": '1',
...

Melihat History

>>> a.history() # Anggap saja history anda sudah ada
...

Melihat Order Baru/Di Tahan

idr_or_btc adalah variable dimana anda membeli/menjual dengan BTC atau IDR pilihannya hanya 2 saja, tetapi default adalah IDR. jika anda membeli/menjual dengan IDR maka idr_or_btc abaikan saja.

>>> a.open_order('btc', idr_or_btc='idr') # Contoh saya membeli BTC, disini anda akn melihat order id anda
...

Melihat Riwayat Order

>>> a.order_history('btc') # Anggap saja semua order terlihat
...

Trade Buy/Sell

Pemanggilan fungsi trade, fungsi trade ada 2 yaitu trade_buy(coin, diharga, jumlah, idr_or_btc='idr') dan trade_sell(coin, diharga, jumlah, idr_or_btc='idr'). variable coin adalah jenis qurency, variable diharga adalah harga qurency-nya, variable jumlah adalah nilai pembelian/penjualan, idr_or_btc='idr' abaikan jika IDR

Buy

>>> a.trade_buy('btc', '186306000', '50000') # ini jika anda membeli dengan IDR
...

Sell

>>> a.trade_sell('btc', '190000000', '0.005') # anggap saja saya menjual BTC di harga 190Juta
...

Instan Order

instan_trade(coin, jumlah, type) digunakan untuk order secara instan. cara penggunaan instan_trade("trx", 10000, 'buy or sell')

Cancel Order

Disini menggunakan 2 fungsi yaitu cancel_order_buy(coin, order_id, idr_or_btc='idr') dan cancel_order_sell(coin, order_id, idr_or_btc='idr'). order_id dari open_order(...).

Buy

>>> a.cancel_order_buy('btc', '12345') # Kalau order id-nya benar, akan ada result succses = 1
...

Sell

>>> a.cancel_order_sell('btc', '12345') # Hampir sama dengan Buy, tapi tergantung type pembelian atau penjualan
...

Withdraw

fungsi withdraw withdraw(coin, address, amount, memo='', req_id=''). Fungsi ini membutuhkan urlcallback agar dapat bekerja dengan baik.

>>> a.withdraw('doge', 'D7rzpq91xmUVkER6E1ndfinRjRS4jvBkgV', '100') # memo hanya untuk address yg menggunakan memo
...

Donate

Jika anda suka dengan modul ini anda bisa donasi di bawah ini

BTC : 3BqqfUGaARBBCkMN6w6nV7hYjikvac3dJ4

BCHABC : qzdt37fmnftrm8xr50vxza640f48sfnlyqlsfjpyzk

DOGE : D7rzpq91xmUVkER6E1ndfinRjRS4jvBkgV

LTC : M9nQQZXwHQaoNStJrBcr6UfdCqx2RJHz5e

Metadata

Release files for indodax 1.3.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for indodax 1.3.2
File Size Uploaded
indodax-1.3.2.tar.gz 4.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for indodax 1.3.2
File Interpreter ABI Platform
indodax-1.3.2-py3-none-any.whl Python 3 none any Details

Total release size: 10.2 kB

Release files / indodax-1.3.2.tar.gz

Download URL indodax-1.3.2.tar.gz
Size 4.8 kB
Tags Source
SHA-256 checksum
How to use checksums
aa06d9d12712260e0e4f813e31e1c8a0f5e49dafb95720aa1f42609ebb759ed3
BLAKE2b-256 checksum
How to use checksums
3f06af07e3977c71f2283417a786d36da8fb6c45da80f30795240613d7b8f294
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.11.6

Release files / indodax-1.3.2-py3-none-any.whl

Download URL indodax-1.3.2-py3-none-any.whl
Size 5.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
da2b2dd9a9efdd37c1f6b8aefe8deb0740a5849be4c2da97f8bb2fdf74d4ddd1
BLAKE2b-256 checksum
How to use checksums
94fad371ef585416cf5c5ed7a02588a03882d2f81bfa6df3928ede04ce7d9763
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.11.6

Release history Release notifications | RSS feed

This release

1.3.2 This release

2 release files

1.3.1

2 release files

1.3

1 release file

1.2

2 release files

1.1

2 release files

1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page