Recurly demo

node v10.15.3
version: 1.0.0
endpointsharetweet
var Recurring = require('recurring'); var recurly = new Recurring(); recurly.setAPIKey(process.env.api_testkey_recurly); recurly.setRateLimit(400); //recurly.setCache(false);
var account = recurly.Account(); account.id = process.env.account_code_recurly; account.fetch(function(err) { account.fetchSubscriptions(function(err, subscriptions) { console.log(subscriptions[0]); for (i = 0; i < subscriptions.length; i++) { console.log("Number of licences: " + subscriptions[i].quantity); console.log("Trial ends at: " + subscriptions[i].trial_ends_at); } }); });
Loading…

no comments

    sign in to comment