oeml-sdk/ruby/lib/openapi_client/api/positions_api.rb
def v1_positions_get_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: PositionsApi.v1_positions_get ...'
      end
      # resource path
      local_var_path = '/v1/positions'

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

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

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

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

      # return_type
      return_type = opts[:return_type] || 'Array<Position>' 

      # auth_names
      auth_names = opts[:auth_names] || []

      new_options = opts.merge(
        :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: PositionsApi#v1_positions_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end
# Get open positions
# Get current open positions across all or single exchange.
# @param [Hash] opts the optional parameters
# @option opts [String] :exchange_id Filter the balances to the specific exchange.
# @return [Array<(Array<Position>, Integer, Hash)>] Array<Position> data, response status code and response headers
Get open positions
Get current open positions across all or single exchange.
Get open positions Get current open positions across all or single exchange .
def v1_positions_get_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: PositionsApi.v1_positions_get ...'
      end
      local_var_path = '/v1/positions'
      query_params = opts[:query_params] || {}
      query_params[:'exchange_id'] = opts[:'exchange_id'] if !opts[:'exchange_id'].nil?
      header_params = opts[:header_params] || {}
      header_params['Accept'] = @api_client.select_header_accept(['application/json', 'appliction/json'])
      form_params = opts[:form_params] || {}
      post_body = opts[:body] 
      return_type = opts[:return_type] || 'Array<Position>' 
      auth_names = opts[:auth_names] || []
      new_options = opts.merge(
        :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: PositionsApi#v1_positions_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end
def v1_positions_get_with_http_info ( opts = { } ) if @api_client . config . debugging @api_client . config . logger . debug 'Calling API: PositionsApi.v1_positions_get ...' end local_var_path = '/v1/positions' query_params = opts [ :query_params ] || { } query_params [ :' exchange_id ' ] = opts [ :' exchange_id ' ] if ! opts [ :' exchange_id ' ] . nil? header_params = opts [ :header_params ] || { } header_params [ 'Accept' ] = @api_client . select_header_accept ( [ 'application/json' , 'appliction/json' ] ) form_params = opts [ :form_params ] || { } post_body = opts [ :body ] return_type = opts [ :return_type ] || 'Array<Position>' auth_names = opts [ :auth_names ] || [ ] new_options = opts . merge ( :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: PositionsApi#v1_positions_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data , status_code , headers end
Get open positions
Get current open positions across all or single exchange.
Get open positions Get current open positions across all or single exchange .
# resource path # query parameters # header parameters # HTTP header 'Accept' (if needed) # form parameters # http body (model) # return_type # auth_names
Array data, response status code and response headers
Array data response status code and response headers
Array<(Array<Position>, Integer, Hash)>
opts
:exchange_id Filter the balances to the specific exchange.
: exchange_id Filter the balances to the specific exchange .
opts the optional parameters
opts the optional parameters