These forums have been archived and are now read-only.

The new forums are live and can be found at https://forums.eveonline.com/

EVE Technology Lab

 
  • Topic is locked indefinitely.
 

[EveLib] A .NET library for EveXML, CREST, EveCentral, and more

First post
Author
SCORPl0
Foundation Cutting-Edge
#61 - 2014-06-02 15:03:56 UTC
Hey there,

Thanks for your api that will be definitely our choice for create a new alliance website.

Any idea of an existing simple C# forum that we can easily modify and incorporate api calls?

If someone used already this api for forums eve related functions.

Thanks anyway.
Icahmura Hasaki
Perkone
Caldari State
#62 - 2014-06-02 17:30:16 UTC
I cant help with any C# forums, as I've never used one. Please let me know if you run into any issues with the API though, or any issues in combining it with a forum, and I'll help you figure out a solution :)

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#63 - 2014-06-03 18:36:40 UTC
A beta version of 2.0 is tagged and available on github. I'm using it in production and it's stable thus far. It isn't fully backwards compatible with version 1, but it shouldn't require too many changes to swap.

New features include async variations of all endpoint methods, better tracing, ApiKey class that can be used for keys when you don't know in advance if it's a corporation or character key, and other minor improvements.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#64 - 2014-06-04 11:20:56 UTC
I've added support for the newest endpoints as stated here:

Quote:
2014/06/03:

Added the new /corp/CustomsOffices endpoint to the EVE API
New POCO endpoint requires a Director or CEO corporation API key with the asset list access mask
A new Wars resource was added to public CREST with /wars/, /wars/war_id/, and /wars/war_id/killmails/all/
Removed WH systems from the maps/kills endpoint.



I've also made some major improvements to the caching, but had to slightly change the IEveCache interface to accommodate async if anyone has made custom caching.

And I've added lots of tracing statements, mostly in the cache implementation, but a few others too. If you wish to trace, define a System.Diagnostics listening source for "EveLib". This is part of the .NET framework and there is lots of documentation available, or you can ask me for assistance. Smile

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#65 - 2014-06-11 15:49:33 UTC
I've just pushed a fix to a major bug with the caching, introduced with the "improved" caching in 2.0. Anyone using 2.0 beta should update as soon as possible, as caching would not work correctly in most cases.

Developer of EveLib and EveAuthUtility

Hel O'Ween
Men On A Mission
#66 - 2014-06-12 16:24:20 UTC
SCORPl0 wrote:

Any idea of an existing simple C# forum that we can easily modify and incorporate api calls?


You could try YetAnotherForum.NET.

Fun fact: that's the forum software you're using in this very moment, as the EVE forums are based on YAF (and to which CCP contribute back, when they modified it to their need).

EVEWalletAware - an offline wallet manager.

Icahmura Hasaki
Perkone
Caldari State
#67 - 2014-06-13 13:51:29 UTC
So, I've had another go at version 2, and made a few additions to the API. I will be writing a new readme for version 2 as soon as possible.

In other news, I've finally found the time to fiddle with NuGet. I've just uploaded EveLib 2.0-beta2 to NuGet, available here.

I've never used NuGet before so there might be something I've missed, but I think it should work correctly. I've also uploaded PDBs and sources to SymbolSource, which can be set up in VS.

Hopefully this should make it easier to install and use. And as always let me know if there are any issues.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#68 - 2014-06-17 16:40:55 UTC  |  Edited by: Icahmura Hasaki
Another update, quite big this time. There are no changes to the public API though.

Implemented proper CREST support for all endpoints. No more dynamic objects.
Added an EveCrestException, with the exception data returned by CREST.
Added comments to the public methods in EveCrest, and some other places.
I've added some missing Code Contract statements, and I've configured it properly for release and debugging.
Fixed many issues with the Nuget package. It should now include all XML documentation, as well as Code Contract assemblies for all dlls.

I've also moved the Nuget package, to eZet.EveLib. The old ID has a dependency that links to the new package, but you should uninstall the old package, and install the new one. I'm sorry for any inconveniences this causes, but EveLib was a bit too generic of a name, and there seems to already be other libraries using it.

I haven't really had any bug reports on version 2 of the library at all, so I'm expecting a proper release of it soon unless something comes up.

Also, if anyone wants to help me develop or maintain this, please let me know. There are a lot of features and improvements that can be added still, and you're welcome to contribute. The documentation also needs improvement, if that's your cup of tea.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#69 - 2014-06-18 10:54:39 UTC
Apparently, there was a small bug with the PI endpoints, and as I don't have any PI characters this hasn't been tested until now. A kind soul has given me his API key, I've fixed the bugs and added proper unit tests and static deserialization tests. The fix is pushed to git and will be on nuget shortly.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#70 - 2014-06-18 16:13:03 UTC  |  Edited by: Icahmura Hasaki
I've added full support for the ZKillboard API, including caching, proper model classes and corresponding unit tests.

I've also made quite a few changes internally, which affects anyone who've made their own implementations of IRequestHandler or IHttpRequester. In short, I've removed IHttpRequester and it's implementations, and moved it's functionality into the RequestHandler.

The implementation of HttpRequester can mostly be replaced by a static call to HttpRequestHelper.RequestAsync(uri), it should be easy to make the required changes if you look at the new source.

The reason for this is to have more control in the RequestHandler, so that you can easier retrieve http headers and the like, which is needed for caching. The HttpRequester did very little anyways, and I don't think any alternative implementations are likely or necessary.

edit:
I've also added 3 properties to ZKillboard and EveOnline modules
EnableCacheLoad, EnableCacheStore and IsCacheHandler.
First two gets or sets if data can be loaded from/stored in the cache. In short, you can force it to fetch data from the API.
IsCacheHandler returns true if the current RequestHandler supports caching, as if it doesn't the two other properties have no effect and will always be false.

Developer of EveLib and EveAuthUtility

Lien Rollard
Imperial Academy
Amarr Empire
#71 - 2014-06-18 19:26:38 UTC
Awesome work so far. I've been looking into several small projects to do (all the documentation and scope first) and I'll probably begin coding tomorrow.

One work I do have is if you have a timer on when the implementation of the new Crius Industry API will begin? (Merely because several of my small projects include industry).
Icahmura Hasaki
Perkone
Caldari State
#72 - 2014-06-18 19:44:39 UTC
It should be ready when Crius is released, or shortly after. :)

Developer of EveLib and EveAuthUtility

Lien Rollard
Imperial Academy
Amarr Empire
#73 - 2014-06-18 20:18:31 UTC
Ah, I was asking because they apparently opened the API up for testing (in their latest Dev Blog).
Icahmura Hasaki
Perkone
Caldari State
#74 - 2014-06-19 12:40:20 UTC
I've added full support for the EveWho API, which means all APIs I initially intended to include, have been implemented. If there are any requests for others, please let me know.

I've also just started looking at the new industry API, but I do not have any sisi keys with industry jobs/history available. If someone could be kind enough to share an API key, or even a simple copy/paste of the xml response, that would be greatly appreciated. In the case of a key, I won't need it for very long.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#75 - 2014-06-19 15:53:58 UTC  |  Edited by: Icahmura Hasaki
I've pushed a new NuGet package, some of the changes are:

  • Support for the new industry endpoints
  • Support for EveWho.com API
  • Cleaner exception handling
  • Fixed IsValidKey and it's async variant
  • Improved documentation comments


It does however make some changes to the public API, as I've renamed some of the classes that is being returned, to include an indicator of which module the class belongs to. This does not affect the EveOnline module.

To test the new industry endpoints, set the BaseUri property on whichever object your invoking methods on, before use, (corporation, character, keys) with new Uri("http://api.testeveonline.com/");

I've also added quite a lot to the readme on github over the last few days, so might be worth looking at that again.

edit:
The rename changes are as follows:
All returned classes from EveCrest are now prefixed with EveCrest.
I've removed the Collection postfix from relevant EveCrest classes, as they are not actually Collections but rather contain collections.
All returned classes from EveMarketData are now prefixed with Emd.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#76 - 2014-06-21 16:31:41 UTC
A new release is up...again. Available on nuget and github.


  • Added support for the new CREST industry endpoints, /teams/ and /specialities/
  • Changed type of BaseUri from Uri to string.
  • Changed EveCrest data model prefix to just Crest.
  • Added a large amount of comments, especially to the EveCrest module.
  • Added some more debug traces.
  • Other minor tweaks and fixes.


The library seems very stable and a stable release will be coming shortly. There should be no more changes to the existing API after that point.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#77 - 2014-06-26 11:42:32 UTC
EveLib 2.0 has been released and is considered stable. I'll consider any feature requests and update bugs as soon as they are reported, but there shouldn't be any changes other than that.

As a final small feature I've added an EveLib class in Core with RequestJson and RequestXml, which lets you request content from any arbitrary uri, and have it deserialized and returned as dynamic expando objects, using the same error/exception handling as the rest of the library. Maybe someone will find it useful for APIs that aren't supported directly.

Hope the library will be useful to some, and I'd greatly appreciate any feedback, good or bad, what you'll be using it for and so on. Smile

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#78 - 2014-07-05 11:12:21 UTC
I've updated the library with the most recent changes to sisi. The package is available on github, and as a pre release on nuget. Make sure you allow pre-release updates through nuget if you want to test this.

Developer of EveLib and EveAuthUtility

Icahmura Hasaki
Perkone
Caldari State
#79 - 2014-07-22 13:15:32 UTC
I've released version 2.0.1, which adds support for all the new endpoints that came with Crius. The old GetIndustryJobs has been replaced by the new version, mirroring the way CCP has replaced their endpoint with the new one. This means that the new version isn't compatible with the old, but since the old endpoint itself is removed that shouldn't matter.

Developer of EveLib and EveAuthUtility

Squornshellous Zeta
BioDyne
#80 - 2014-07-26 18:58:56 UTC
Hey there,

I'm trying to use your libraries to get the System Cost Index using CREST and I seem to be having some difficulties.

I am able to make the CREST request, but when I check the results, there are no items in the SolarSystems list.

Here is the code I'm using to test:
Quote:
Dim crest As EveCrest
Dim lstSystems As Models.CrestIndustrySystems = Nothing
Dim objSystemEntry As Models.CrestIndustrySystems.SolarSystemEntry

Try
crest = New EveCrest
lstSystems = crest.GetIndustrySystems()

If Not lstSystems.SolarSystems Is Nothing Then
For Each objSystemEntry In lstSystems.SolarSystems
Debug.Print(objSystemEntry.SolarSystem.Name)
Next
End If

Catch ex As Exception
Debug.Print(ex.Message)
End Try

When I run this, the crest.GetIndustrySystems() call works fine, but if I check the lstSystems.SolarSystems, it's Nothing. Interestingly enough, the lstSystems.TotalCount is correct at 5431, which is the same if I do the HTTP request manually.

I did turn on the tracing, but I didn't see anything unsual or any errors. I can provide the tracing information if it would be helpful.

Thanks for any help you can provide. I definitely like what you've got so far and I look forward to using it a lot more! Big smile

- SZ