-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbtcturk-examples.py
67 lines (43 loc) · 1.32 KB
/
btcturk-examples.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
import btcturk-python
#Create Order Example
pairSymbol = "BTC_TRY"
price = "53000"
quantity = "0.01"
orderType = "buy"
orderMethod = "limit"
stopPrice = "0"
createOrder(pairSymbol , price , quantity , orderType , orderMethod , stopPrice)
#Check Balances Example
checkBalances(pairSymbol)
#Delete Order Example
orderId = 1234567890
deleteOrder(orderId)
#Check Open Orders Example
checkOpenOrders(pairSymbol)
#Print OrderBook (last 10 orders) Example
orderBook(pairSymbol, 10, 1):
#Print OrderBook (last 30 orders) Example
orderBook(pairSymbol, 30, 1):
#Get User Transactions Example (buy orders)
numerator = "BTC"
denominator = "TRY"
orderType = "buy"
userTransactions(numerator, denominator, orderType)
#Get User Transactions Example (sell orders)
numerator = "BTC"
denominator = "TRY"
orderType = "sell"
userTransactions(numerator, denominator, orderType)
#Get User Transactions Example (all order types)
numerator = "BTC"
denominator = "TRY"
orderType = "all"
userTransactions(numerator, denominator, orderType)
#Get User Transactions Example (Only crypto pair transactions)
numerator = "crypto"
orderType = "all"
userTransactions(numerator, denominator, orderType)
#Get User Transactions Example (All pairs, both buy/sell transactions)
numerator = "all"
orderType = "all"
userTransactions(numerator, denominator, orderType)