Project

eveapi

0.0
No commit activity in last 3 years
No release in over 3 years
ruby API Client for the space based MMO EVEOnline
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 0.10
~> 10.0
~> 3.0
~> 0.34
~> 2.9
~> 0.8

Runtime

~> 0.4
~> 0.45
 Project Readme

DEPRECATED!

see: https://developers.eveonline.com/blog/article/a-eulogy-for-xml-crest

EVEApi for ruby

Gem Version Build Status Code Climate Test Coverage

TOC

  • Description
  • Documentation
  • Install
  • Working methods
    • Client
    • Character
    • Alliance
    • Crest
  • CREST
  • Features
  • Examples
  • Requirements
  • Contributing

Description

EVE Online API Client for ruby

Documentation

Install

$ gem install eveapi

Working methods

Working Client methods names can be listed by calling EVEApi::Client#working_methods.

Check out rubydoc.info for the documentation.

Legacy methods are available here

Client

Character

Crest

Alliance

CREST

Rudimentary CREST support is added via the EVEApi::Crest class. Working mehtods

a = Crest.new.alliances.select { |a| a.name == "Goonswarm Federation" }.first
=> #<EVEApi::Alliance:0x007fd511c48248 ...>
a.to_h
=> {
          :href => "https://public-crest.eveonline.com/alliances/1354830081/",
        :id_str => "1354830081",
    :short_name => "CONDI",
          :name => "Goonswarm Federation",
            :id => 1354830081
}
a.info['url']
=> "http://www.goonfleet.com"
a.info.keys
=> [
    [ 0] "startDate",
    [ 1] "corporationsCount",
    [ 2] "description",
    [ 3] "executorCorporation",
    [ 4] "primeHour_str",
    [ 5] "primeHour",
    [ 6] "deleted",
    [ 7] "corporationsCount_str",
    [ 8] "creatorCorporation",
    [ 9] "url",
    [10] "id_str",
    [11] "creatorCharacter",
    [12] "capitalSystem",
    [13] "corporations",
    [14] "shortName",
    [15] "id",
    [16] "name"
]

Features

Uses excon, crack, method_missing and a couple of rescue blocks to automate access to EVE Online API.

  • returns results as Hash or Array
  • raises exceptions with messages from the API itself
  • converts ruby methods like account_api_info to an EVE Online API request like GET /account/APIKeyInfo.xml.aspx along with query params.

Examples

Getting Implant names for character

require 'eveapi'
# initialize the client with key_id, vcode, character_id
client = Client.new(4278167, "supersecretstuff", 95512059)
# => #<EVEApi::Client:0x007fe349ad0d48 ... >
client.characters.first.character_sheet[:implants].map { |i| i[:type_name] }
# => [
#     [0] "Social Adaptation Chip - Basic",
#     [1] "Cybernetic Subprocessor - Standard",
#     [2] "Memory Augmentation - Standard",
#     [3] "Neural Boost - Standard",
#     [4] "Ocular Filter - Standard"
# ]

Server status

require 'eveapi'
client.server_status
# => {
#        :server_open => "True",
#     :online_players => "32500"
# }

Showing accounts characters

require 'eveapi'
client = EVEApi::Client.new
client.key_id = 4278167
client.vcode = "7QJg6p5BZNpDBp2FIz39dGwa7jnNaXAuYyLUVitlTQ3rY60VPBcaTpJVfYIkiW5l"
client.characters
# => {
#                 :name => "Quint Slade",
#         :character_id => "95512059",
#     :corporation_name => "Imperial Academy",
#       :corporation_id => "1000166",
#          :alliance_id => "0",
#        :alliance_name => "",
#           :faction_id => "0",
#         :faction_name => ""
# }

Requirements

excon and crack automatically installed as dependencies during gem install, or bundle install in development.

Copyright

Copyright (c) 2015 Adam Ladachowski

See LICENSE.txt for details.