init
This commit is contained in:
commit
87f07ee7dc
5 files changed
+2831
No files matched your search
@@ -0,0 +1,22 @@
|
||||
import fs from 'fs/promises';
|
||||
import { Client as DiscogsClient } from 'disconnect';
|
||||
|
||||
const TOKEN = 'wRTXuYZGOPsIQgKRGKCAkUkidGtvpSfQgPWkYIpD';
|
||||
|
||||
async function start() {
|
||||
await
|
||||
const discogs = new DiscogsClient({ userToken: TOKEN });
|
||||
const db = discogs.database();
|
||||
const list = await discogs.user().wantlist().getReleases('margh');
|
||||
|
||||
return db.getRelease(list.wants[0].id);
|
||||
// const releases = await Promise.all(list.wants.map(l => db.getRelease(l.id)));
|
||||
// return releases;
|
||||
}
|
||||
|
||||
start()
|
||||
.then(r => console.log(r))
|
||||
.catch(e => {
|
||||
console.error(e);
|
||||
process.exit(1);
|
||||
});
|
||||
Reference in new issue
Block a user