findata.org

Ruby

You can use the blpwrapper classes from within JRuby, here’s a hello world:

require 'java'

$CLASSPATH << 'C:\\blp\\API\\APIv3\\JavaAPI\\v3.3.1.0\\lib\\blpapi3.jar'
$CLASSPATH << "blpwrapper.jar"

include_class "org.findata.blpwrapper.Connection"

conn = Connection.new

securities = ["GOOG US Equity", "OCN US Equity"].to_java(:string)
fields = ["NAME", "PX_LAST", "TIME"].to_java(:string)

result = conn.blp(securities, fields)
puts result.getData.to_a.inspect

This will output:

[["GOOGLE INC-CL A", "472.2", "16:52:23"], ["OCWEN FINANCIAL CORP", "10.23", "16:51:59"]]