bartve / disconnect

An easy to use Node.js client with OAuth support to connect with the discogs.com API v2.0
MIT License
453 stars 79 forks source link

Need more usage examples. It's a real struggle to decipher. #59

Open cyrusadkisson opened 4 years ago

cyrusadkisson commented 4 years ago

At first, I thought the documentation for this library was going to be really good. The README.md shows how to instantiate the client, make a simple request, set output format, authenticate a few different ways and then...

... it just sort of drops off, leaving the user completely hanging. I've had to dig into the source code (including test files) to figure out how to make certain requests. But there's a lot of discogs API functionality that is a complete mystery.

A little bit of usage documentation would go a very long way. Specifically,

I think this library could be useful and helpful to me, but without documentation, I may have to simply homebrew a client direct to the URLs in the Discogs main documentation so I can tell what I'm doing. Which would really be a shame since this library/utility is sitting here begging to be used.

edit: The name of the repo is unfortunate, too. Try googling "disconnect documentation" and see how far that gets you.

bartve commented 4 years ago

One can never have too much documentation. The database functions were written to be as easy to understand as possible (so the source code IS actually the documentation) and a readme to help you get started.

As for the queue, it's not something you'd actively use. It's an internal function exposed to use at your own risk.

As for the name, well, it was available in npm at the time and I thought it was kinda cool/ironic/nerdy whatever. Not much I can (and want) to do about that.

For the last couple of years work and family have been very demanding on my time and I first want to get the ES6 re-write released before undertaking anything else. I'm always open to neatly formatted (in the style of README.md) pull requests for a DOCUMENTATION.md that explains all features with code examples.

blabtonic commented 4 years ago

when I first came upon this project I had my own cheat sheet of the databases calls that I was using that list the database calls and what their value was suppose to be from the API Something like below. I have still have the file and can upload it. Its not something that was very I just needed something that help explain what I was doing

Release

The Release resource represents a particular physical or digital object released by one or more Artists

GET

    db.getArtist = function(artist, callback) {
        return client.get('/artists/' + artist, callback);
    };
hems commented 4 years ago

@cyrusadkisson I think your points are valid and useful, but I think you're being a bit too negative considering this is free and open-source work!

Instead of rolling your own code you could as well do a PR and try to help ( :

🍻