Sha256: 89761cb242a9bdac032247ba9c99b9b52c0d9b4d990573bebe17ba2fea67cf50

Contents?: true

Size: 825 Bytes

Versions: 1

Compression:

Stored size: 825 Bytes

Contents

module EveOnline
  module XML
    # https://eveonline-third-party-documentation.readthedocs.io/en/latest/xmlapi/character/char_contracts.html
    class CharacterContracts < Base
      API_ENDPOINT = 'https://api.eveonline.com/char/Contracts.xml.aspx'.freeze

      ACCESS_MASK = 67_108_864

      # attr_reader :key_id, :v_code, :character_id, :contract_id
      attr_reader :key_id, :v_code, :character_id

      # def initialize(key_id, v_code, character_id, contract_id = nil)
      def initialize(key_id, v_code, character_id)
        super()
        @key_id = key_id
        @v_code = v_code
        @character_id = character_id
      end

      def url
        # TODO: add support for contract_id
        "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }&characterID=#{ character_id }"
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
eve_online-0.12.0 lib/eve_online/xml/character_contracts.rb