November 2019
Beginner
436 pages
8h 52m
English
So far, we have generated a new license, and we've received the license ID in our confirmation email. Now, it's time to validate this ID in the application code:
Nucleus.checkLicense('556e3bb5e9f5e230d884', (err, license) => { if (err) return console.error(err); if (license.valid) { console.log('License is valid :) Using policy ' + license.policy); } else { console.log('License is invalid :('); }});
Here, we're using the Nucleus.checkLicense function to get a callback with two parameters: an err, which provides any error details, and license, which provides details about the license.
For the sake of simplicity, we're ...
Read now
Unlock full access