Jetstream SDK for javascript in Node.js. See full Jetstream documentation at https://jetstreamrfid.com/Documentation
var client = new Jetstream.Application("jetstream.tersosolutions.com", "MyAccessKey");
var params = {};
client.getDeviceDefinitions(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully retrieved the device definitions\n" + data);
}
});
params = {
logicalDeviceId : "LogicalDeviceId01",
deviceSerialNumber : "DeviceSerialNumber01",
region : "US",
deviceDefinitionId : "10ee5fa4-15b6-4e00-a4ad-08ebeef99b79"
};
client.addLogicalDevice(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully added the logical device.\n" + data);
}
});
queueDeviceSpecificCommand
queueGetConfigValuesCommand
queueGetEPCListCommand
queueResetCommand
queueSetConfigValuesCommand
addDeviceToPolicy
addLogicalDevice
addPolicy
getConfiguration
getDeviceDefinitions
getPolicies
removeDeviceFromPolicy
removeLogicalDevice
removePolicy
Examples
var params = {
commandName : "GetPasses",
logicalDeviceId : "LogicalDeviceId01"
};
client.queueDeviceSpecificCommand(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully queued a DeviceSpecificCommand.\n" + data);
}
});
Examples
var params = {
logicalDeviceId : "LogicalDeviceId01"
};
client.queueGetConfigValuesCommand(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully queued a GetConfigValuesCommand.\n" + data);
}
});
Examples
var params = {
logicalDeviceId : "LogicalDeviceId01"
};
client.queueGetEPCListCommand(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully queued a GetEPCListCommand.\n" + data);
}
});
Examples
var params = {
logicalDeviceId : "LogicalDeviceId01"
};
client.queueResetCommand(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully queued a ResetCommand.\n" + data);
}
});
Examples
var params = {
logicalDeviceId : "LogicalDeviceId01",
ip : "10.6.20.241",
subnet : "255.255.255.0"
};
client.queueSetConfigValuesCommand(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully queued a SetConfigValuesCommand.\n" + data);
}
});
Examples
var params = {
policyId : "4954d361-84ff-468d-9b6e-69429cae6aff",
logicalDeviceId : "LogicalDeviceId01"
};
client.addDeviceToPolicy(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully added the device to the policy.\n" + data);
}
});
Examples
var params = {
logicalDeviceId : "LogicalDeviceId01",
deviceSerialNumber : "DeviceSerialNumber01",
region : "US",
deviceDefinitionId : "10ee5fa4-15b6-4e00-a4ad-08ebeef99b79"
};
client.addLogicalDevice(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully added the logical device.\n" + data);
}
});
Examples
var params = {
deviceDefinitionId : "10ee5fa4-15b6-4e00-a4ad-08ebeef99b79",
name : "Policy " + Math.floor((Math.random()*1000)+1),
aggregateeventscancount : 2,
aggregateeventscantime : 10,
antenna1rxsensitivity :50,
antenna1txpower :30,
antenna2rxsensitivity :50,
antenna2txpower :30,
antenna3rxsensitivity :50,
antenna3txpower :30,
antenna4rxsensitivity:50,
antenna4txpower :30,
commandpollinterval :60,
dns :"0.0.0.0",
dooropentimelimit :300,
gateway :"0.0.0.0",
ip :"0.0.0.0",
jetstreamdeviceurl :"https://us-device.tersosolutions.com/v1.0/device/",
lockdownhightemp :127,
lockdownonacpowerfailure :0,
lockdownonhightemp :0,
lockdownonreaderfailure :0,
logentryeventhightemp :127,
logentryeventlowtemp :-128,
logentrylevel : "warning",
numberofantennas :4,
objecteventscancount :2,
objecteventscantime :10,
subnet :"0.0.0.0"
};
client.addPolicy(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully added the policy.\n" + data);
}
});
Examples
var params = {};
client.getConfiguration(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully called GetConfiguration.\n" + data);
}
});
Examples
var params = {};
client.getDeviceDefinitions(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully retrieved the device definitions\n" + data);
}
});
Examples
var params = {};
client.getPolicies(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully called GetPolicies.\n" + data);
}
});
Examples
var params = {
logicalDeviceId : "LogicalDeviceId01"
};
client.removeDeviceFromPolicy(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully called RemoveDeviceFromPolicy.\n" + data);
}
});
Examples
var params = {
logicalDeviceId : "LogicalDeviceId02"
};
client.removeLogicalDevice(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully called RemoveLogicalDevice.\n" + data);
}
});
Examples
var params = {
policyId : "bd7462ed-997b-4f62-9359-652b6d6ef94f"
};
client.removePolicy(params, function(err, data){
if (err){
console.log(err);
}
else{
console.log("successfully called RemovePolicy.\n" + data);
}
});