Security News
38% of CISOs Fear They’re Not Moving Fast Enough on AI
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
usps-webtools-promise
Advanced tools
This package was forked from MadisonReed/usps-webtools, but it has been modernized with Typescript and Promises (async/await). Note: This is a drop-in replacement for MadisonReed/usps-webtools, it produces the same output.
npm install usps-webtools-promise
Initializing the usps model with a user id.
Example:
const USPS = require('usps-webtools-promise').default;
// or
import USPS from "usps-webtools-promise";
const usps = new USPS({
// This can be created by going to https://www.usps.com/business/web-tools-apis/ and registering for an id
userId: 'USPS User id',
// USPS returns ALL CAPS, this boolean turns on Proper Caps for both Street lines and City. This is an optional item.
properCase: boolean
});
Verify takes one parameter: object
object: street1, street2, city, state, zip
Example
usps.verify({
street1: '322 3rd st.',
street2: 'Apt 2',
city: 'San Francisco',
state: 'CA',
zip: '94103'
}).then(address => {
console.log(address);
});
zipCodeLookup takes one parameter: object.
object: street1, street2, city, state
Example
const address = await usps.zipCodeLookup({
street1: '322 3rd st.',
street2: 'Apt 2',
city: 'San Francisco',
state: 'CA'
});
console.log(address);
cityStateLookup takes one parameter: zipcode.
zipcode: 5 digit zipcode as a string
Example
const result = await usps.cityStateLookup('94107');
console.log(result);
FAQs
API wrapper for the USPS Web-Tools, with Promises!
The npm package usps-webtools-promise receives a total of 445 weekly downloads. As such, usps-webtools-promise popularity was classified as not popular.
We found that usps-webtools-promise 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
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.
Security News
Company News
Socket is joining TC54 to help develop standards for software supply chain security, contributing to the evolution of SBOMs, CycloneDX, and Package URL specifications.