1.0.2 • Published 5 years ago

psn-live-async v1.0.2

Weekly downloads
4
License
ISC
Repository
github
Last release
5 years ago

Asynchronous Node Playstation-Network API

es6 js introduced arrow functions, asynchronous flows and classes. I've written a psn api wrapper in node to be able to use this functionality for a cleaner code in your project.

Requires a valid playstation account.

Instructions:

  1. Get the ticket_uuid(login_token) and code according to these instructions below https://tusticles.com/psn-php/first_login.html

  2. Import the library var psn = require('psn-live-async'); OR if supported import psn from 'psn-live-async';

  3. Run getCookie function alone. You will get an npsso token you need to use for the rest of the calls. psn.getCookie(ticket_uuid, code_you_got_on_your_mobile_device).then(npsso => console.log(npsso));

  4. Create an object const psnObj = new psn.PSNHandler(npsso);

  5. Call endpoint to retreive a user's Playstation Network User Id. psnObj.getUserIdPSN('Ninja').then(resp => console.log(resp))