npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

eid

v1.1.2

Published

Module for simple integration to electronic identities

Downloads

35

Readme

NPM version stability-stable version maintained maintainer License

eid (previously eid-provider)

This module is developed to enable rapid deployment of identity based authentication for Node.js by creating a common interface to most of the suppliers for official electronic identification and it allows you to mix and match your suppliers. This is a reusability code port of code that I have contributed to teams-app-eid with some smart addons and international support.

Simple to use

Regardless of which backend service you use the basic usage is the same. Some backends require more configuration than others. However the classes expose same interface and responses so code is easy to use. You can read details of the interface or see some more practical examples

const eid = require('eid');

var config = eid.configFactory({clientType: 'frejaeid', enviroment: 'testing'});
var client = eid.clientFactory(config);

client.doRequest({id: '200101011212'}).then(function(endResult){
    console.log(endResult)
});

or the more backwards compatible

const eid = require('eid');

var config = eid.configFactory({clientType: 'frejaeid', enviroment: 'testing'});
var client = eid.clientFactory(config);

client.authRequest('200101011212').then(function(endResult) {
    console.log(endResult)
});

Built-in clients

Clients are the classes that manage communication with the backend services. The library supports a bunch of clients out of the box, but additional clients can easily be added to make sure that the one interface strategy works.

| Client | ID Types | Vendor | Authentication | Signing | Markets | | --- | --- | --- | --- | --- | --- | | FrejaEID | Freja eID | Freja eID AB | :heavy_check_mark: | :heavy_check_mark: | :sweden: :denmark: :norway: :finland: | | BankID | BankID | Finansiell ID-Teknik AB | :heavy_check_mark: | :heavy_check_mark: | :sweden: | | GRP2 | Freja eID, BankID | Funktionstjänster/CGI | :heavy_check_mark: | :heavy_check_mark: | :sweden: | | GrandID | Freja eID, BankID, Mobile SiTHS | Svensk E-Identitet AB | :heavy_check_mark: | :heavy_check_mark: | :sweden: | | Signicat | BankID | Signicat | :heavy_check_mark: | | :sweden: | | IDKollen | BankID | IDkollen i Sverige AB | :heavy_check_mark: | :heavy_check_mark: | :sweden: |

The configuration options should be quite obvious as what they do. If you are unsure your supplier will most probably be able to determine what information you need. Most modules have sane values, certificates etc for most testing services and production services however there is no production credentials and you need to strike an agreement with the services yourself to obtain these.