New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

yggdrasil

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

yggdrasil

Mojang authentication (Yggdrasil) client

  • 0.0.4
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
6.7K
decreased by-33.14%
Maintainers
1
Weekly downloads
 
Created
Source

yggdrasil

Build Status

A Node.js client for doing requests to yggdrasil, the Mojang authentication system, used for Minecraft and Scrolls. There's already one other client out there (at the time of writing) but I don't like it, so I wrote this one.

Usage

$ npm install yggdrasil

Client

//init
var ygg = require('yggdrasil')({
    //Optional settings object
    host: 'https://authserver.mojang.com' //Optional custom host. No trailing slash.
});

//Authenticate a user
ygg.auth({
    token: '', //Optional. Client token.
    agent: '', //Agent name. Defaults to 'Minecraft'
    version: 1, //Agent version. Defaults to 1
    user: '', //Username
    pass: '' //Password
}, function(err, data){});

//Refresh an accessToken
ygg.refresh(oldtoken, clienttoken, function(err, newtoken, responce body){});

//Validate an accessToken
ygg.validate(token, function(isvalid, err){});

//Invalidate all accessTokens
ygg.signout(username, password, function(worked, err));

Server

//todo Read the source code for now.

Further Reading

Keywords

FAQs

Package last updated on 04 Jun 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc