Wondering what’s next for npm?Check out our public roadmap! »

    @cimpress/node-looker

    1.0.2 • Public • Published

    node-looker

    Introduction

    This package is being developed since belt (v4.3) endpoints will not work with Looker.

    Getting Started

     
    var looker = require('@cimpress/node-looker')({
      clientId: 'yourclientid',
      clientSecret: 'yourclientsecret',
      // the rest are optional
      baseUrl: 'https://api.looker.cimba.cimpress.io:19999/api/3.0/', // default
      ttlOffset: 60, // expires the cached access token 60 seconds before it actually expires (default = 60)
      timeout: 60000, // number of milliseconds before timing out a looker query
      loginTimeout: 60000 // number of milliseconds before timing out a looker login request
    });
     
    looker({
      uri: '/user'
    })
    .then(res => {
      console.log(res.body);
    });
     

    Testing

    Install dependencies yarn install, then run yarn run gulp.

     
    ➜  ct-node-looker git:(master) ✗ yarn run gulp
    [14:15:57] Using gulpfile ~/git/ct-node-looker/gulpfile.js
    [14:15:57] Starting 'test'...
    [14:15:57] Finished 'test' after 7.78 ms
    [14:15:57] Starting 'default'...
    [14:15:57] Finished 'default' after 9.56 μs
     
     
      LookerClient
        ✓ should login only once
     
     
      1 passing (48ms)
     
    ➜  ct-node-looker git:(master) ✗
     

    Keywords

    none

    Install

    npm i @cimpress/node-looker

    DownloadsWeekly Downloads

    102

    Version

    1.0.2

    License

    Apache-2.0

    Last publish

    Collaborators

    • avatar
    • avatar
    • avatar
    • avatar
    • avatar