'use strict'; var api = require('./index.js').api; var OAUTH3 = require('../../assets/org.oauth3/'); // these all auto-register require('../../assets/org.oauth3/oauth3.domains.js'); require('../../assets/org.oauth3/oauth3.dns.js'); require('../../assets/org.oauth3/oauth3.tunnel.js'); OAUTH3._hooks = require('../../assets/org.oauth3/oauth3.node.storage.js'); api.tunnel( { OAUTH3: OAUTH3 , options: { device: { hostname: 'test.local' , id: '' } } } // OAUTH3.hooks.session.get('oauth3.org').then(function (result) { console.log(result) }); , require('./test.session.json') );