1.0.0 • Published 6 years ago
ntpy v1.0.0
ntpy 
NTP client for Node.js.
Install
npm install ntpyUsage
const ntpy = require("ntpy");
(async () => {
const { receiveTimestamp } = await ntpy("pool.ntp.org");
console.log("The date is: ", receiveTimestamp);
})();API
ntpy(url, options?)
url
Type: string
The url of a NTP server to use.
options
Type: object
port
Type: number\
Default: 123
The port to use when connecting to the NTP server.
timeout
Type: number | false\
Default: 10000
The timeout in milliseconds for the request to complete. Set to false to disable.
