Class: BittrexEnterprise::Withdrawals

Inherits:
Object
  • Object
show all
Includes:
ApiHelpers
Defined in:
lib/bittrex-enterprise/withdrawals.rb

Class Method Summary collapse

Methods included from ApiHelpers

included

Class Method Details

.by_tx_id(withdrawal_id) ⇒ Object

————————————— RETRIEVE ——————————————- Retrieve information on a specified withdrawal.

—— PARAMS —— withdrawal_id - string - required - (guid-formatted string) - ID of withdrawal to retrieve




64
65
66
# File 'lib/bittrex-enterprise/withdrawals.rb', line 64

def self.by_tx_id(tx_id)
  get_signed 'withdrawals/ByTxId/{txId}', txId: tx_id
end

.cancel(withdrawal_id) ⇒ Object

—————————————- CANCEL ——————————————– Cancel an order.

—— PARAMS —— withdrawal_id - string - required - (guid-formatted string) - ID of withdrawal to cancel




86
87
88
# File 'lib/bittrex-enterprise/withdrawals.rb', line 86

def self.cancel(withdrawal_id)
  delete_signed 'withdrawals/{withdrawalId}', withdrawalId: withdrawal_id
end

.closed(params = {}) ⇒ Object

—————————————- CLOSED ——————————————– List closed withdrawals. StartDate and EndDate filters apply to the CompletedAt field. Pagination and the sort order of the results are in inverse order of the CompletedAt field.

—— PARAMS —— PARAMS MUST BE PASSED AS KEY VALUE PAIRS status - string enum: [COMPLETED, CANCELLED] - optional - filter by an open withdrawal status

currencySymbol - string - optional - filter by currency

nextPageToken - string - The unique identifier of the item that the resulting query result

should start after, in the sort order of the given endpoint. Used for traversing
a paginated set in the forward direction. (May only be specified if PreviousPageToken
is not specified.)

previousPageToken - string - The unique identifier of the item that the resulting query

result should end before, in the sort order of the given endpoint. Used for traversing
a paginated set in the reverse direction. (May only be specified if NextPageToken is
not specified.)

pageSize - integer - maximum number of items to retrieve – default 100, minimum 1, maximum 200

startDate - string(date-time) - Filters out results before this timestamp. In ISO 8601 format

(e.g., "2019-01-02T16:23:45Z"). Precision beyond one second is not supported. Use
pagination parameters for more precise filtering.

endDate - string(date-time) - Filters out result after this timestamp. Uses the same format

as StartDate. Either, both, or neither of StartDate and EndDate can be set. The only
constraint on the pair is that, if both are set, then EndDate cannot be before StartDate.



53
54
55
# File 'lib/bittrex-enterprise/withdrawals.rb', line 53

def self.closed(params={})
  get_signed 'withdrawals/closed', params
end

.create(new_withdrawal) ⇒ Object

—————————————- CREATE ——————————————– Create a new withdrawal.

—— PARAMS —— NewWithdrawal - object - required - information specifying the withdrawal to create

      {
        "id": "string (uuid)",
        "currencySymbol": "string",
        "quantity": "number (double)",
        "cryptoAddress": "string",
        "cryptoAddressTag": "string",
        "txCost": "number (double)",
        "txId": "string",
        "status": "string",
        "createdAt": "string (date-time)",
        "completedAt": "string (date-time)"
      }
*** REQUIRED - id, currencySymbol, quantity, cryptoAddress, status, createdAt  ***



110
111
112
# File 'lib/bittrex-enterprise/withdrawals.rb', line 110

def self.create(new_withdrawal)
  post_signed 'withdrawals', new_withdrawal
end

.open(params = {}) ⇒ Object

—————————————– OPEN ——————————————— List open withdrawals. Results are sorted in inverse order of the CreatedAt field, and are limited to the first 1000.

—— PARAMS —— PARAMS MUST BE PASSED AS KEY VALUE PAIRS status - string enum: [REQUESTED, AUTHORIZED, PENDING, ERROR_INVALID_ADDRESS] - optional -

filter by an open withdrawal status

currencySymbol - string - optional - filter by currency




19
20
21
# File 'lib/bittrex-enterprise/withdrawals.rb', line 19

def self.open(params={})
  get_signed 'withdrawals/open', params
end