All URIs are relative to https://api.bybit.com
Method | HTTP request | Description |
---|---|---|
funding_my_last_fee | GET /open-api/funding/prev-funding | Funding settlement occurs every 8 hours at 00:00 UTC, 08:00 UTC and 16:00 UTC. The current interval's fund fee settlement is based on the previous interval's fund rate. For example, at 16:00, the settlement is based on the fund rate generated at 8:00. The fund rate generated at 16:00 will be used at 0:00 on the next day. |
funding_predicted | GET /open-api/funding/predicted-funding | Get predicted funding rate and funding fee. |
funding_prev_rate | GET /open-api/funding/prev-funding-rate | Get predicted funding rate and funding fee. |
Object funding_my_last_fee(symbol)
Funding settlement occurs every 8 hours at 00:00 UTC, 08:00 UTC and 16:00 UTC. The current interval's fund fee settlement is based on the previous interval's fund rate. For example, at 16:00, the settlement is based on the fund rate generated at 8:00. The fund rate generated at 16:00 will be used at 0:00 on the next day.
# load the gem
require 'swagger_client'
# setup authorization
SwaggerClient.configure do |config|
# Configure API key authorization: apiKey
config.api_key['api_key'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['api_key'] = 'Bearer'
# Configure API key authorization: apiSignature
config.api_key['sign'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['sign'] = 'Bearer'
# Configure API key authorization: timestamp
config.api_key['timestamp'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['timestamp'] = 'Bearer'
end
api_instance = SwaggerClient::FundingApi.new
symbol = 'symbol_example' # String | Contract type.
begin
#Funding settlement occurs every 8 hours at 00:00 UTC, 08:00 UTC and 16:00 UTC. The current interval's fund fee settlement is based on the previous interval's fund rate. For example, at 16:00, the settlement is based on the fund rate generated at 8:00. The fund rate generated at 16:00 will be used at 0:00 on the next day.
result = api_instance.funding_my_last_fee(symbol)
p result
rescue SwaggerClient::ApiError => e
puts "Exception when calling FundingApi->funding_my_last_fee: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
symbol | String | Contract type. |
Object
apiKey, apiSignature, timestamp
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json
Object funding_predicted(symbol)
Get predicted funding rate and funding fee.
# load the gem
require 'swagger_client'
# setup authorization
SwaggerClient.configure do |config|
# Configure API key authorization: apiKey
config.api_key['api_key'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['api_key'] = 'Bearer'
# Configure API key authorization: apiSignature
config.api_key['sign'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['sign'] = 'Bearer'
# Configure API key authorization: timestamp
config.api_key['timestamp'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['timestamp'] = 'Bearer'
end
api_instance = SwaggerClient::FundingApi.new
symbol = 'symbol_example' # String | Contract type.
begin
#Get predicted funding rate and funding fee.
result = api_instance.funding_predicted(symbol)
p result
rescue SwaggerClient::ApiError => e
puts "Exception when calling FundingApi->funding_predicted: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
symbol | String | Contract type. |
Object
apiKey, apiSignature, timestamp
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json
Object funding_prev_rate(symbol)
Get predicted funding rate and funding fee.
# load the gem
require 'swagger_client'
# setup authorization
SwaggerClient.configure do |config|
# Configure API key authorization: apiKey
config.api_key['api_key'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['api_key'] = 'Bearer'
# Configure API key authorization: apiSignature
config.api_key['sign'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['sign'] = 'Bearer'
# Configure API key authorization: timestamp
config.api_key['timestamp'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['timestamp'] = 'Bearer'
end
api_instance = SwaggerClient::FundingApi.new
symbol = 'symbol_example' # String | Contract type.
begin
#Get predicted funding rate and funding fee.
result = api_instance.funding_prev_rate(symbol)
p result
rescue SwaggerClient::ApiError => e
puts "Exception when calling FundingApi->funding_prev_rate: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
symbol | String | Contract type. |
Object
apiKey, apiSignature, timestamp
- Content-Type: application/json, application/x-www-form-urlencoded
- Accept: application/json