Module: BitflyerApi::Methods::Private::AccountStatement

Included in:
Client
Defined in:
lib/bitflyer_api/methods/private/account_statement.rb

Instance Method Summary collapse

Instance Method Details

#my_addressesObject



3
4
5
6
# File 'lib/bitflyer_api/methods/private/account_statement.rb', line 3

def my_addresses
  res = conn.get("/v1/me/getaddresses")
  res.body
end

#my_bank_accounts(count: 100, before: nil, after: nil) ⇒ Object



30
31
32
33
34
35
36
37
38
39
# File 'lib/bitflyer_api/methods/private/account_statement.rb', line 30

def my_bank_accounts(count: 100, before: nil, after: nil)
  query = prepare_query(
    count: count,
    before: before,
    after: after
  )

  res = conn.get("/v1/me/getbankaccounts", query)
  res.body
end

#my_coin_ins(count: 100, before: nil, after: nil) ⇒ Object



8
9
10
11
12
13
14
15
16
17
# File 'lib/bitflyer_api/methods/private/account_statement.rb', line 8

def my_coin_ins(count: 100, before: nil, after: nil)
  query = prepare_query(
    count: count,
    before: before,
    after: after
  )

  res = conn.get("/v1/me/getcoinins", query)
  res.body
end

#my_coin_outs(count: 100, before: nil, after: nil) ⇒ Object



19
20
21
22
23
24
25
26
27
28
# File 'lib/bitflyer_api/methods/private/account_statement.rb', line 19

def my_coin_outs(count: 100, before: nil, after: nil)
  query = prepare_query(
    count: count,
    before: before,
    after: after
  )

  res = conn.get("/v1/me/getcoinouts", query)
  res.body
end

#my_deposits(count: 100, before: nil, after: nil) ⇒ Object



41
42
43
44
45
46
47
48
49
50
# File 'lib/bitflyer_api/methods/private/account_statement.rb', line 41

def my_deposits(count: 100, before: nil, after: nil)
  query = prepare_query(
    count: count,
    before: before,
    after: after
  )

  res = conn.get("/v1/me/getdeposits", query)
  res.body
end

#my_withdraw(currency_code: "JPY", bank_account_id:, amount:, code: nil) ⇒ Object



52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# File 'lib/bitflyer_api/methods/private/account_statement.rb', line 52

def my_withdraw(currency_code: "JPY", bank_account_id:, amount:, code: nil)
  body = "{
    'currency_code': \"#{currency_code}\",
    'bank_account_id': \"#{}\",
    'amount': \"#{amount}\",
    'code': \"#{code}\",
  }"

  res = conn.post do |req|
    req.url "/v1/me/withdraw"
    req.body = body
  end

  res.body
end

#my_withdrawals(count: 100, before: nil, after: nil) ⇒ Object



68
69
70
71
72
73
74
75
76
77
# File 'lib/bitflyer_api/methods/private/account_statement.rb', line 68

def my_withdrawals(count: 100, before: nil, after: nil)
  query = prepare_query(
    count: count,
    before: before,
    after: after
  )

  res = conn.get("/v1/me/getwithdrawals", query)
  res.body
end