Skip to content
This repository has been archived by the owner on Nov 25, 2021. It is now read-only.

Latest commit

 

History

History
78 lines (57 loc) · 2.52 KB

LinearMarketApi.md

File metadata and controls

78 lines (57 loc) · 2.52 KB

LinearMarketApi

All URIs are relative to https://api.bybit.com

Method HTTP request Description
linearMarketTrading GET /public/linear/recent-trading-records Get recent trades

linearMarketTrading

Object linearMarketTrading(symbol, limit)

Get recent trades

This will get recent trades

Example

// Import classes:
//import io.swagger.client.ApiClient;
//import io.swagger.client.ApiException;
//import io.swagger.client.Configuration;
//import io.swagger.client.auth.*;
//import io.swagger.client.api.LinearMarketApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

// Configure API key authorization: apiSignature
ApiKeyAuth apiSignature = (ApiKeyAuth) defaultClient.getAuthentication("apiSignature");
apiSignature.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiSignature.setApiKeyPrefix("Token");

// Configure API key authorization: timestamp
ApiKeyAuth timestamp = (ApiKeyAuth) defaultClient.getAuthentication("timestamp");
timestamp.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//timestamp.setApiKeyPrefix("Token");

LinearMarketApi apiInstance = new LinearMarketApi();
String symbol = "symbol_example"; // String | Contract type.
String limit = "limit_example"; // String | Contract type.
try {
    Object result = apiInstance.linearMarketTrading(symbol, limit);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling LinearMarketApi#linearMarketTrading");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
symbol String Contract type.
limit String Contract type. [optional]

Return type

Object

Authorization

apiKey, apiSignature, timestamp

HTTP request headers

  • Content-Type: application/json, application/x-www-form-urlencoded
  • Accept: application/json