1.0.3 • Published 5 years ago

labarchives-js v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
5 years ago

LabArchives API wrapper for JavaScript

Client for LabArchives' API. Uses Axios, which is Promise-based.

This package is currently incomplete as it lacks support for most of the options that LabArchives offers through its API. Feel free to contribute by requesting or implementing the functionalities you'd like to use.

Installation

Available from npm:

npm install labarchives-js

Usage

User's figures retrieval

Retrieve all of a user's image entries and get URLs of thumbnails and attachments.

const LabArchives = require('labarchives-js');
const client = new LabArchives({
    accessKeyId: 'myAkid',
    accessPassword: 'myPassword',
});

async () => {
    await client.login('username', 'password');
    
    let entryID = await client.getFigureEntryIDs()[0];
    
    let thumbnailUrl = await client.getThumbnailUrlOf(entryID);
    let attachmentUrl = await client.getAttachmentUrlOf(entryID);
}

License

This package is open-source software licensed under the MIT license.

1.0.3

5 years ago

1.0.2

5 years ago

1.0.0

5 years ago

0.2.0

5 years ago

1.0.1

5 years ago