0.2.2 • Published 5 years ago

@delucis/reading-data-instapaper v0.2.2

Weekly downloads
-
License
GPL-3.0
Repository
github
Last release
5 years ago

@delucis/reading-data-instapaper

Build Status Coverage Status npm (scoped)

A plugin for @delucis/reading-data that fetches bookmarks from the Instapaper API.

Installation

npm install --save @delucis/reading-data-instapaper

Usage

To use this module, you will need to request tokens to use Instapaper’s API and have log-in details for an Instapaper user.

const RD = require('@delucis/reading-data')
const RD_INSTAPAPER = require('@delucis/reading-data-instapaper')

RD.use(RD_INSTAPAPER, {
  scope: 'instapaper',
  apiKey: '????????????????????????',
  apiSecret: '????????????????????????',
  userKey: 'instapaper.user@gmail.com',
  userSecret: 'goldfish123'
})

RD.run().then((res) => {
  console.log(res.data.instapaper)
})

Options

reading-data-instapaper can be used with various options, some of which are required for it to work.

nametypedefaultrequired?description
apiKeyString✔︎an Instapaper API consumer key
apiSecretString✔︎an Instapaper API consumer secret
apiVersionNumber1.1the version of the Instapaper API to use (1 or 1.1)
fetchTextBooleanfalseshould the fetch() method try to retrieve the full text of bookmarks
folder_idString'archive'the Instapaper folder to request bookmarks from
limitNumber5the maximum number of bookmarks requested from Instapaper (max: 500)
scopeString'instapaper'the scope under which reading-data will store this plugin’s data
useCacheBooleanfalseshould the fetch() method try to use preloaded or existing data
userKeyString✔︎an Instapaper user’s e-mail address
userSecretString✔︎an Instapaper user’s password