Skip to content

Arkitektum/N5Auth.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

N5Auth.js

NOARK 5 API - JavaScript Authentication library (BETA)

How to use it

Initialize and configure endpoints:

N5Auth.Init({
    urlAuthorizeEndpoint: "https://identity.arkitektum.no/core/connect/authorize",
    urlCertificateStore: "https://identity.arkitektum.no/core/.well-known/jwks"
});

Are you authenticated?

var isAuthenticated = N5Auth.CheckAuthentication();
if (isAuthenticated) {
  console.log("id token" + N5Auth.authdata.id_token_json);
  console.log("access token" + N5Auth.authdata.access_token_json);
}
else {
  N5Auth.Authorize();
}

Remember: Your client application has to be registered with the identity server before authentication can be performed.

About

NOARK 5 API - JavaScript Authentication library

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published