Class: CryptoApis::XRPRippleApi

Inherits:
Object
  • Object
show all
Defined in:
lib/crypto_apis/api/xrp_ripple_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ XRPRippleApi

Returns a new instance of XRPRippleApi.



19
20
21
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 19

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#get_latest_mined_xrp__ripple_block(network, opts = {}) ⇒ GetLatestMinedXRPRippleBlockR

Get Latest Mined XRP (Ripple) Block Through this endpoint customers can fetch the last mined XRP block in the blockchain, along with its details. These could include the hash of the specific, the previous and the next block, its transactions count, its height, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - "mainnet" is the live network with actual data while networks like "testnet", "ropsten" are test networks.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. `context` is specified by the user.

Returns:



28
29
30
31
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 28

def get_latest_mined_xrp__ripple_block(network, opts = {})
  data, _status_code, _headers = get_latest_mined_xrp__ripple_block_with_http_info(network, opts)
  data
end

#get_latest_mined_xrp__ripple_block_with_http_info(network, opts = {}) ⇒ Array<(GetLatestMinedXRPRippleBlockR, Integer, Hash)>

Get Latest Mined XRP (Ripple) Block Through this endpoint customers can fetch the last mined XRP block in the blockchain, along with its details. These could include the hash of the specific, the previous and the next block, its transactions count, its height, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 39

def get_latest_mined_xrp__ripple_block_with_http_info(network, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.get_latest_mined_xrp__ripple_block ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.get_latest_mined_xrp__ripple_block"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/blocks/last'.sub('{' + 'network' + '}', CGI.escape(network.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'GetLatestMinedXRPRippleBlockR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.get_latest_mined_xrp__ripple_block",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#get_latest_mined_xrp__ripple_block\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_xrp__ripple_address_details(network, address, opts = {}) ⇒ GetXRPRippleAddressDetailsR

Get XRP (Ripple) Address Details Through this endpoint the customer can receive basic information about a given XRP address based on confirmed/synced blocks only. In the case where there are any incoming or outgoing unconfirmed transactions for the specific address, they **will not** be counted or calculated here. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, are test networks.

  • address (String)

    Represents the public address, which is a compressed and shortened form of a public key.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



100
101
102
103
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 100

def get_xrp__ripple_address_details(network, address, opts = {})
  data, _status_code, _headers = get_xrp__ripple_address_details_with_http_info(network, address, opts)
  data
end

#get_xrp__ripple_address_details_with_http_info(network, address, opts = {}) ⇒ Array<(GetXRPRippleAddressDetailsR, Integer, Hash)>

Get XRP (Ripple) Address Details Through this endpoint the customer can receive basic information about a given XRP address based on confirmed/synced blocks only. In the case where there are any incoming or outgoing unconfirmed transactions for the specific address, they **will not** be counted or calculated here. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, are test networks.

  • address (String)

    Represents the public address, which is a compressed and shortened form of a public key.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:

  • (Array<(GetXRPRippleAddressDetailsR, Integer, Hash)>)

    GetXRPRippleAddressDetailsR data, response status code and response headers



112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 112

def get_xrp__ripple_address_details_with_http_info(network, address, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.get_xrp__ripple_address_details ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.get_xrp__ripple_address_details"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'address' is set
  if @api_client.config.client_side_validation && address.nil?
    fail ArgumentError, "Missing the required parameter 'address' when calling XRPRippleApi.get_xrp__ripple_address_details"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/addresses/{address}'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'address' + '}', CGI.escape(address.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'GetXRPRippleAddressDetailsR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.get_xrp__ripple_address_details",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#get_xrp__ripple_address_details\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_xrp__ripple_block_details_by_block_hash(network, block_hash, opts = {}) ⇒ GetXRPRippleBlockDetailsByBlockHashR

Get XRP (Ripple) Block Details By Block Hash Through this endpoint customers can obtain basic information about a given XRP block (a block on the XRP blockchain), specifically by using the ‘hash` parameter. These block details could include the hash of the specific, the previous and the next block, the number of included transactions, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • block_hash (String)

    Represents the hash of the block, which is its unique identifier. It represents a cryptographic digital fingerprint made by hashing the block header twice through the SHA256 algorithm.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



177
178
179
180
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 177

def get_xrp__ripple_block_details_by_block_hash(network, block_hash, opts = {})
  data, _status_code, _headers = get_xrp__ripple_block_details_by_block_hash_with_http_info(network, block_hash, opts)
  data
end

#get_xrp__ripple_block_details_by_block_hash_with_http_info(network, block_hash, opts = {}) ⇒ Array<(GetXRPRippleBlockDetailsByBlockHashR, Integer, Hash)>

Get XRP (Ripple) Block Details By Block Hash Through this endpoint customers can obtain basic information about a given XRP block (a block on the XRP blockchain), specifically by using the &#x60;hash&#x60; parameter. These block details could include the hash of the specific, the previous and the next block, the number of included transactions, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • block_hash (String)

    Represents the hash of the block, which is its unique identifier. It represents a cryptographic digital fingerprint made by hashing the block header twice through the SHA256 algorithm.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 189

def get_xrp__ripple_block_details_by_block_hash_with_http_info(network, block_hash, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.get_xrp__ripple_block_details_by_block_hash ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.get_xrp__ripple_block_details_by_block_hash"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'block_hash' is set
  if @api_client.config.client_side_validation && block_hash.nil?
    fail ArgumentError, "Missing the required parameter 'block_hash' when calling XRPRippleApi.get_xrp__ripple_block_details_by_block_hash"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/blocks/hash/{blockHash}'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'blockHash' + '}', CGI.escape(block_hash.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'GetXRPRippleBlockDetailsByBlockHashR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.get_xrp__ripple_block_details_by_block_hash",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#get_xrp__ripple_block_details_by_block_hash\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_xrp__ripple_block_details_by_block_height(network, block_height, opts = {}) ⇒ GetXRPRippleBlockDetailsByBlockHeightR

Get XRP (Ripple) Block Details By Block Height Through this endpoint customers can obtain basic information about a given XRP block (a block on the XRP blockchain), specifically by using the ‘height` parameter. These block details could include the hash of the specific, the previous and the next block, its transactions count, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, are test networks.

  • block_height (String)

    Represents the number of blocks in the blockchain preceding this specific block. Block numbers have no gaps. A blockchain usually starts with block 0 called the &quot;Genesis block&quot;.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



254
255
256
257
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 254

def get_xrp__ripple_block_details_by_block_height(network, block_height, opts = {})
  data, _status_code, _headers = get_xrp__ripple_block_details_by_block_height_with_http_info(network, block_height, opts)
  data
end

#get_xrp__ripple_block_details_by_block_height_with_http_info(network, block_height, opts = {}) ⇒ Array<(GetXRPRippleBlockDetailsByBlockHeightR, Integer, Hash)>

Get XRP (Ripple) Block Details By Block Height Through this endpoint customers can obtain basic information about a given XRP block (a block on the XRP blockchain), specifically by using the &#x60;height&#x60; parameter. These block details could include the hash of the specific, the previous and the next block, its transactions count, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, are test networks.

  • block_height (String)

    Represents the number of blocks in the blockchain preceding this specific block. Block numbers have no gaps. A blockchain usually starts with block 0 called the &quot;Genesis block&quot;.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 266

def get_xrp__ripple_block_details_by_block_height_with_http_info(network, block_height, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.get_xrp__ripple_block_details_by_block_height ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.get_xrp__ripple_block_details_by_block_height"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'block_height' is set
  if @api_client.config.client_side_validation && block_height.nil?
    fail ArgumentError, "Missing the required parameter 'block_height' when calling XRPRippleApi.get_xrp__ripple_block_details_by_block_height"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/blocks/height/{blockHeight}'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'blockHeight' + '}', CGI.escape(block_height.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'GetXRPRippleBlockDetailsByBlockHeightR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.get_xrp__ripple_block_details_by_block_height",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#get_xrp__ripple_block_details_by_block_height\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_xrp__ripple_transaction_details_by_transaction_id(network, transaction_hash, opts = {}) ⇒ GetXRPRippleTransactionDetailsByTransactionIDR

Get XRP (Ripple) Transaction Details By Transaction ID Through this endpoint customers can obtain details about a XRP transaction by the transaction’s unique identifier. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • transaction_hash (String)

    Represents the same as &#x60;transactionId&#x60; for account-based protocols like Ethereum, while it could be different in UTXO-based protocols like Bitcoin. E.g., in UTXO-based protocols &#x60;hash&#x60; is different from &#x60;transactionId&#x60; for SegWit transactions.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



331
332
333
334
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 331

def get_xrp__ripple_transaction_details_by_transaction_id(network, transaction_hash, opts = {})
  data, _status_code, _headers = get_xrp__ripple_transaction_details_by_transaction_id_with_http_info(network, transaction_hash, opts)
  data
end

#get_xrp__ripple_transaction_details_by_transaction_id_with_http_info(network, transaction_hash, opts = {}) ⇒ Array<(GetXRPRippleTransactionDetailsByTransactionIDR, Integer, Hash)>

Get XRP (Ripple) Transaction Details By Transaction ID Through this endpoint customers can obtain details about a XRP transaction by the transaction&#39;s unique identifier. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • transaction_hash (String)

    Represents the same as &#x60;transactionId&#x60; for account-based protocols like Ethereum, while it could be different in UTXO-based protocols like Bitcoin. E.g., in UTXO-based protocols &#x60;hash&#x60; is different from &#x60;transactionId&#x60; for SegWit transactions.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

Returns:



343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 343

def get_xrp__ripple_transaction_details_by_transaction_id_with_http_info(network, transaction_hash, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.get_xrp__ripple_transaction_details_by_transaction_id ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.get_xrp__ripple_transaction_details_by_transaction_id"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'transaction_hash' is set
  if @api_client.config.client_side_validation && transaction_hash.nil?
    fail ArgumentError, "Missing the required parameter 'transaction_hash' when calling XRPRippleApi.get_xrp__ripple_transaction_details_by_transaction_id"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/transactions/{transactionHash}'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'transactionHash' + '}', CGI.escape(transaction_hash.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'GetXRPRippleTransactionDetailsByTransactionIDR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.get_xrp__ripple_transaction_details_by_transaction_id",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#get_xrp__ripple_transaction_details_by_transaction_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#list_xrp__ripple_transactions_by_address(network, address, opts = {}) ⇒ ListXRPRippleTransactionsByAddressR

List XRP (Ripple) Transactions by Address This endpoint will list XRP transactions by a attribute ‘address`. The transactions listed will detail additional information such as hash, height, time of creation in Unix timestamp, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • address (String)

    Represents the public address, which is a compressed and shortened form of a public key.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

  • :transaction_type (String)

Returns:



411
412
413
414
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 411

def list_xrp__ripple_transactions_by_address(network, address, opts = {})
  data, _status_code, _headers = list_xrp__ripple_transactions_by_address_with_http_info(network, address, opts)
  data
end

#list_xrp__ripple_transactions_by_address_and_time_range(network, address, from_timestamp, to_timestamp, opts = {}) ⇒ ListXRPRippleTransactionsByAddressAndTimeRangeR

List XRP (Ripple) Transactions By Address And Time Range Тhis endpoint lists XRP transactions by the attribute ‘address` and the query parameters `fromTimestamp` and `toTimestamp` which gives customers the opportunity to filter the results by a specified time period.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • address (String)

    Represents the public address, which is a compressed and shortened form of a public key.

  • from_timestamp (Integer)

    Defines the specific time/date from which the results will start being listed.

  • to_timestamp (Integer)

    Defines the specific time/date to which the results will be listed.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

  • :transaction_type (String)

    Defines the transaction type.

Returns:



503
504
505
506
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 503

def list_xrp__ripple_transactions_by_address_and_time_range(network, address, from_timestamp, to_timestamp, opts = {})
  data, _status_code, _headers = list_xrp__ripple_transactions_by_address_and_time_range_with_http_info(network, address, from_timestamp, to_timestamp, opts)
  data
end

#list_xrp__ripple_transactions_by_address_and_time_range_with_http_info(network, address, from_timestamp, to_timestamp, opts = {}) ⇒ Array<(ListXRPRippleTransactionsByAddressAndTimeRangeR, Integer, Hash)>

List XRP (Ripple) Transactions By Address And Time Range Тhis endpoint lists XRP transactions by the attribute &#x60;address&#x60; and the query parameters &#x60;fromTimestamp&#x60; and &#x60;toTimestamp&#x60; which gives customers the opportunity to filter the results by a specified time period.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • address (String)

    Represents the public address, which is a compressed and shortened form of a public key.

  • from_timestamp (Integer)

    Defines the specific time/date from which the results will start being listed.

  • to_timestamp (Integer)

    Defines the specific time/date to which the results will be listed.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

  • :transaction_type (String)

    Defines the transaction type.

Returns:



520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 520

def list_xrp__ripple_transactions_by_address_and_time_range_with_http_info(network, address, from_timestamp, to_timestamp, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.list_xrp__ripple_transactions_by_address_and_time_range ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.list_xrp__ripple_transactions_by_address_and_time_range"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'address' is set
  if @api_client.config.client_side_validation && address.nil?
    fail ArgumentError, "Missing the required parameter 'address' when calling XRPRippleApi.list_xrp__ripple_transactions_by_address_and_time_range"
  end
  # verify the required parameter 'from_timestamp' is set
  if @api_client.config.client_side_validation && from_timestamp.nil?
    fail ArgumentError, "Missing the required parameter 'from_timestamp' when calling XRPRippleApi.list_xrp__ripple_transactions_by_address_and_time_range"
  end
  # verify the required parameter 'to_timestamp' is set
  if @api_client.config.client_side_validation && to_timestamp.nil?
    fail ArgumentError, "Missing the required parameter 'to_timestamp' when calling XRPRippleApi.list_xrp__ripple_transactions_by_address_and_time_range"
  end
  allowable_values = ["account-set", "account-delete", "check-cancel", "check-cash", "check-create", "deposit-preauth", "escrow-cancel", "escrow-create", "escrow-finish", "offer-cancel", "offer-create", "payment", "payment-channel-claim", "payment-channel-create", "payment-channel-fund", "set-regular-key", "signer-list-set", "ticket-create", "trust-set"]
  if @api_client.config.client_side_validation && opts[:'transaction_type'] && !allowable_values.include?(opts[:'transaction_type'])
    fail ArgumentError, "invalid value for \"transaction_type\", must be one of #{allowable_values}"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/addresses/{address}/transactions-by-time-range'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'address' + '}', CGI.escape(address.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'fromTimestamp'] = from_timestamp
  query_params[:'toTimestamp'] = to_timestamp
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
  query_params[:'transactionType'] = opts[:'transaction_type'] if !opts[:'transaction_type'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'ListXRPRippleTransactionsByAddressAndTimeRangeR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.list_xrp__ripple_transactions_by_address_and_time_range",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#list_xrp__ripple_transactions_by_address_and_time_range\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#list_xrp__ripple_transactions_by_address_with_http_info(network, address, opts = {}) ⇒ Array<(ListXRPRippleTransactionsByAddressR, Integer, Hash)>

List XRP (Ripple) Transactions by Address This endpoint will list XRP transactions by a attribute &#x60;address&#x60;. The transactions listed will detail additional information such as hash, height, time of creation in Unix timestamp, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • address (String)

    Represents the public address, which is a compressed and shortened form of a public key.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

  • :transaction_type (String)

Returns:



426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 426

def list_xrp__ripple_transactions_by_address_with_http_info(network, address, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.list_xrp__ripple_transactions_by_address ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.list_xrp__ripple_transactions_by_address"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'address' is set
  if @api_client.config.client_side_validation && address.nil?
    fail ArgumentError, "Missing the required parameter 'address' when calling XRPRippleApi.list_xrp__ripple_transactions_by_address"
  end
  allowable_values = ["account-set", "account-delete", "check-cancel", "check-cash", "check-create", "deposit-preauth", "escrow-cancel", "escrow-create", "escrow-finish", "offer-cancel", "offer-create", "payment", "payment-channel-claim", "payment-channel-create", "payment-channel-fund", "set-regular-key", "signer-list-set", "ticket-create", "trust-set"]
  if @api_client.config.client_side_validation && opts[:'transaction_type'] && !allowable_values.include?(opts[:'transaction_type'])
    fail ArgumentError, "invalid value for \"transaction_type\", must be one of #{allowable_values}"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/addresses/{address}/transactions'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'address' + '}', CGI.escape(address.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
  query_params[:'transactionType'] = opts[:'transaction_type'] if !opts[:'transaction_type'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'ListXRPRippleTransactionsByAddressR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.list_xrp__ripple_transactions_by_address",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#list_xrp__ripple_transactions_by_address\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#list_xrp__ripple_transactions_by_block_hash(network, block_hash, opts = {}) ⇒ ListXRPRippleTransactionsByBlockHashR

List XRP (Ripple) Transactions By Block Hash This endpoint will list transactions by an attribute ‘blockHash`. The transactions listed will detail additional information such as hash, addresses, time of creation in Unix timestamp, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • block_hash (String)

    Represents the hash of the block, which is its unique identifier. It represents a cryptographic digital fingerprint made by hashing the block header twice through the SHA256 algorithm.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

Returns:



604
605
606
607
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 604

def list_xrp__ripple_transactions_by_block_hash(network, block_hash, opts = {})
  data, _status_code, _headers = list_xrp__ripple_transactions_by_block_hash_with_http_info(network, block_hash, opts)
  data
end

#list_xrp__ripple_transactions_by_block_hash_with_http_info(network, block_hash, opts = {}) ⇒ Array<(ListXRPRippleTransactionsByBlockHashR, Integer, Hash)>

List XRP (Ripple) Transactions By Block Hash This endpoint will list transactions by an attribute &#x60;blockHash&#x60;. The transactions listed will detail additional information such as hash, addresses, time of creation in Unix timestamp, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • block_hash (String)

    Represents the hash of the block, which is its unique identifier. It represents a cryptographic digital fingerprint made by hashing the block header twice through the SHA256 algorithm.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

Returns:



618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 618

def list_xrp__ripple_transactions_by_block_hash_with_http_info(network, block_hash, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.list_xrp__ripple_transactions_by_block_hash ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.list_xrp__ripple_transactions_by_block_hash"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'block_hash' is set
  if @api_client.config.client_side_validation && block_hash.nil?
    fail ArgumentError, "Missing the required parameter 'block_hash' when calling XRPRippleApi.list_xrp__ripple_transactions_by_block_hash"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/blocks/hash/{blockHash}/transactions'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'blockHash' + '}', CGI.escape(block_hash.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'ListXRPRippleTransactionsByBlockHashR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.list_xrp__ripple_transactions_by_block_hash",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#list_xrp__ripple_transactions_by_block_hash\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#list_xrp__ripple_transactions_by_block_height(network, block_height, opts = {}) ⇒ ListXRPRippleTransactionsByBlockHeightR

List XRP (Ripple) Transactions By Block Height This endpoint will list transactions by an attribute ‘blockHeight`. The transactions listed will detail additional information such as hash, addresses, time of creation in Unix timestamp, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn’t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • block_height (Integer)
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

Returns:



687
688
689
690
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 687

def list_xrp__ripple_transactions_by_block_height(network, block_height, opts = {})
  data, _status_code, _headers = list_xrp__ripple_transactions_by_block_height_with_http_info(network, block_height, opts)
  data
end

#list_xrp__ripple_transactions_by_block_height_with_http_info(network, block_height, opts = {}) ⇒ Array<(ListXRPRippleTransactionsByBlockHeightR, Integer, Hash)>

List XRP (Ripple) Transactions By Block Height This endpoint will list transactions by an attribute &#x60;blockHeight&#x60;. The transactions listed will detail additional information such as hash, addresses, time of creation in Unix timestamp, etc. Since XRP is a different blockchain than Bitcoin and Ethereum, it isn&#39;t unified.

Parameters:

  • network (String)

    Represents the name of the blockchain network used; blockchain networks are usually identical as technology and software, but they differ in data, e.g. - &quot;mainnet&quot; is the live network with actual data while networks like &quot;testnet&quot;, &quot;ropsten&quot; are test networks.

  • block_height (Integer)
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :context (String)

    In batch situations the user can use the context to correlate responses with requests. This property is present regardless of whether the response was successful or returned as an error. &#x60;context&#x60; is specified by the user.

  • :limit (Integer)

    Defines how many items should be returned in the response per page basis. (default to 50)

  • :offset (Integer)

    The starting index of the response items, i.e. where the response should start listing the returned items. (default to 0)

Returns:



701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
# File 'lib/crypto_apis/api/xrp_ripple_api.rb', line 701

def list_xrp__ripple_transactions_by_block_height_with_http_info(network, block_height, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XRPRippleApi.list_xrp__ripple_transactions_by_block_height ...'
  end
  # verify the required parameter 'network' is set
  if @api_client.config.client_side_validation && network.nil?
    fail ArgumentError, "Missing the required parameter 'network' when calling XRPRippleApi.list_xrp__ripple_transactions_by_block_height"
  end
  # verify enum value
  allowable_values = ["mainnet", "testnet"]
  if @api_client.config.client_side_validation && !allowable_values.include?(network)
    fail ArgumentError, "invalid value for \"network\", must be one of #{allowable_values}"
  end
  # verify the required parameter 'block_height' is set
  if @api_client.config.client_side_validation && block_height.nil?
    fail ArgumentError, "Missing the required parameter 'block_height' when calling XRPRippleApi.list_xrp__ripple_transactions_by_block_height"
  end
  # resource path
  local_var_path = '/blockchain-data/xrp-specific/{network}/blocks/height/{blockHeight}/transactions'.sub('{' + 'network' + '}', CGI.escape(network.to_s)).sub('{' + 'blockHeight' + '}', CGI.escape(block_height.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'context'] = opts[:'context'] if !opts[:'context'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'ListXRPRippleTransactionsByBlockHeightR'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['ApiKey']

  new_options = opts.merge(
    :operation => :"XRPRippleApi.list_xrp__ripple_transactions_by_block_height",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XRPRippleApi#list_xrp__ripple_transactions_by_block_height\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end