
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Sapi is a Sensis API node.js client.
This is handy when you want to use Sensis API service from a Node.js application. Sapi module provides a chainable interface to set the endpoint parameters.
Tested with Sensis API version ob-20110511.
npm install sapi
or as a dependency in package.json file:
"dependencies": {
"sapi": "x.y.z"
}
var Sapi = require('sapi'),
sapi = new Sapi('apikey', {
url: 'http://api.sensis.com.au/ob-20110511/test/',
proxy: 'http://user:pass@proxy:8080'
});
You can apply for Sensis API key from Sensis Developer Centre.
Parameters can then be chained to an endpoint:
sapi
.param1('value1')
.param2('value2')
.param3('value3')
.endpoint(function (err, result) {
...
});
Search for restaurants in Melbourne:
sapi
.query('restaurants')
.location('Melbourne')
.search(function (err, result) {
...
});
Get listing details by ID:
sapi
.query('12345')
.getByListingId(function (err, result) {
...
});
Retrieve categories metadata:
sapi
.dataType('categories')
.metadata(function (err, result) {
...
});
Send report events:
sapi
.userIp('192.1.2.3')
.id('VyY2UiOi')
.content('(03) 1234 5678')
.report(function (err, result) {
...
});
Check out Sensis API documentation for further details of the endpoints, a list of parameters, and response message structure:
FAQs
Sensis API node.js client
The npm package sapi receives a total of 10 weekly downloads. As such, sapi popularity was classified as not popular.
We found that sapi 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
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.