
Security News
Crates.io Users Targeted by Phishing Emails
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
@tdengine/rest
Advanced tools
The rest Node.js for TDengine 3.0 version and above. But it is unmaintained. Please use @tdengine/websocket for future development.
This is a TDengine's RESTful connector in TypeScript. It's depend on node-fetch v2. Using fetch(url,options)
to send sql statement and receive response.
The rest Node.js for TDengine 3.0 version and above. But it is unmaintained. Please use @tdengine/websocket for future development.
npm i @tdengine/rest
import { options, connect } from '@tdengine/rest'
// From v3.0.0 path is '/rest/sql', and this path will return timestamp in RFC3339.
// This config step can be skipped.
options.path='/rest/sql';
// set host
options.host='localhost';
// set other options like user/passwd
let conn = connect(options);
let cursor = conn.cursor();
(async()=>{
let result = await cursor.query('show databases');
// optional:
// let result = await cursor.query('show databases',pure=false);
// Get Result object, return Result object.
console.log(result.getResult());
// Get status, return 'succ'|'error'.
console.log(result.getStatus());
// Get head,return response head (Array<any>|undefined,when execute failed this is undefined).
console.log(result.getHead());
// Get Meta data, return Meta[]|undefined(when execute failed this is undefined).
console.log(result.getMeta());
// Get data,return Array<Array<any>>|undefined(when execute failed this is undefined).
console.log(result.getData());
// Get affect rows,return number|undefined(when execute failed this is undefined).
console.log(result.getAffectRows());
// Get command,return SQL send to server(need to `query(sql,false)`,set 'pure=false',default true).
console.log(result.getCommand());
// Get error code ,return number|undefined(when execute failed this is undefined).
console.log(result.getErrCode());
// Get error string,return string|undefined(when execute failed this is undefined).
console.log(result.getErrStr());
})()
FAQs
The rest Node.js for TDengine 3.0 version and above. But it is unmaintained. Please use @tdengine/websocket for future development.
The npm package @tdengine/rest receives a total of 248 weekly downloads. As such, @tdengine/rest popularity was classified as not popular.
We found that @tdengine/rest demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
Product
Socket now lets you customize pull request alert headers, helping security teams share clear guidance right in PRs to speed reviews and reduce back-and-forth.
Product
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.