Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
earnshark-sdk
Advanced tools
This is a JavaScript SDK to call https://app.earnshark.com API. Contains methods to call the EarnShark API making the application integration fast.
npm install earnshark-sdk
Then you will be able to access the EarnShark API through your code.
After installation require the EarnShark npm through: var earnsharknpm = require('earnshark-sdk');
##Usage Sample
To Switch between Debug and Live modes use the following function,
earnsharknpm.isTest(true);
Initialize the ID's needed
var earnsharknpm = require('earnshark-sdk');
var key = 'YOUR KEY FROM EarnShark Dashboard';
var account_id = 'ACCOUNT_ID';
var product_id = 'PRODUCT_ID;` // integer
###To retrieve the account information###
earnsharknpm.getAccountInformation(product_id,key,account_id).then(function(data){
console.log(data)
},function(err){
console.log(err)
});
###To get the information related to a license###
var license_id = 'ID'; // integer
var license_token = 'YOUR LICENSE TOKEN'
earnsharknpm.getLicenseInformation(product_id, license_token, license_id).then(function(data) {
console.log(data)
}, function(err) {
console.log(err)
});
###To get all the product licenses###
earnsharknpm.getAllLicensesOfProduct(product_id, key).then(function(data) {
console.log(data)
}, function(err) {
console.log(err)
});
###To create a new user account###
var body = {
"account":{
"name":"Account Name",
"email":"Account@example.com",
"accountID":"123456",
"start_date":"01/01/2016"
},
"license_id":0,
"enableNotifications" : false,
"sendInvoiceNow" : true
}
earnsharknpm.addNewSubscription(product_id, key, body).then(function(data) {
console.log(data)
}, function(err) {
console.log(err)
})
FAQs
Earnshark client SDK for JavaScript
The npm package earnshark-sdk receives a total of 0 weekly downloads. As such, earnshark-sdk popularity was classified as not popular.
We found that earnshark-sdk demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.