Git Product home page Git Product logo

foliojs's People

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

foliojs's Issues

Provide access to short-term session token

@dcrossleyau writes:

Is it possible to still set the this.token when doing new style login? I use this library to make a simple login script which exports an environment variable. I then use that token environment variable to follow-up with a couple of 'httpie' or 'curl' command-line api calls. Crude, i know, but effective.

Should be easy enougj to do by poking through the headers, even though the tokens do not appear in the response body.

Provide a way to request old-style authentication

FOLIO is transitioning from old-style token-bases authentication to new-style cookie-based authentication with session expiry. The FolioJS library implements both, favouring the new style when the back-end support it.

We should have a way for client code to request that old-style authentication is used. This might be an extra parameter to the session.login method (and a corresponding extra parameter to the service.login method). Or perhaps an environment variables would be better.

@dcrossleyau @wafschneider @funkymalc @ihardy Which would be more useful for you?

Make re-authentication timeout configurable

At present, re-authentication happens when half of the session's TTL has expired โ€” which means every five minutes, since FOLIO is hardwired to expire tokens after ten minutes.

That's usually fine, but when developing and testing (e.g. to work on okapi-auth-proxy) it's sometimes convenient to have a much shorter timeout.

We should introduce an environment variable for overriding this default.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.