projectgoav / E.Deezer

Unoffical asynchronous Deezer .NET API
17 stars 11 forks source link

DeezerSession does not have a "CreateNew()" method #92

Closed 420tech closed 3 years ago

420tech commented 3 years ago

I was trying to follow your docs. There is no CreateNew in DeezerSession. So either a doc bug or.....

projectgoav commented 3 years ago

Hi there,

The documentation here should apply to 2.X.X.X -> 4.X.X.X verisons of E.Deezer. I've marked the 5.X.X.X packages as pre-release until I have time to complete outstanding work and the accompanying documentation.

I'm assuming that you are using a 5.X.X.X package which is why you aren't seeing a CreateNew() method.

I believe you are wanting something like:

var httpHandler = new HttpClientHandler(); // Or whatever implementation you want here...
var session = new DeezerSession(httpHandler);

// .. Continue using 'session' to access Deezer API

You may find this example app I have written around the library as a helpful reference; https://github.com/projectgoav/E.ExploreDeezer

(DeezerSession is constructed in E.ExploreDeezer.Core.ServiceRegistry ctr, Line 38)

420tech commented 3 years ago

Perfect! Thank you!