Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

israel-postal-service-api

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

israel-postal-service-api

Israel postal office pricing calculator

  • 3.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3
decreased by-57.14%
Maintainers
1
Weekly downloads
 
Created
Source

Israel Postal Service API

An API for Israel postal service - query shipment price easily. Supports both NodeJS and browser environments.

licence npm version Dependencies status Documentation



Installation

npm install --save israel-postal-service-api

Usage

Import library:

import { IPS, Options } from 'israel-postal-service-api';

Define Package Characteristics:

// define package shipment characteristics
let weightInGrams = 20;
let serviceType = Options.AbroadMailOptions.LETTER.shipmentType;
let serviceSubtype = Options.AbroadMailOptions.LETTER.shipmentSubtypes.regular;
let option = serviceSubtype.options.signed;

// initialize service
let postalService = new IPS();

Calculate Shipping Rate:

// calculate package shipping rate asynchronously
let response = await postalService.calculateAbroadShippingRate(
    "Spain", weightInGrams, serviceType, serviceSubtype, option);

// see {@class ResponseParser} API to discover the response structure
console.log(response.getTotalPrice()); 

Supported Environments

  • 💻 Browser (including browserify / webpack based environments [such as Angular])
  • 🖥 Node.js

Documentation

Support

If you're having any problem, please raise an issue on GitHub and we'll be happy to help.

Contribute

Before submitting a pull request, please make sure that you include tests, and that jshint runs without any warnings: Download VSCode extension.

Test

Run the test suite by executing:

$ npm test

Note: This API was create as an open source service for makers and entrepreneurs. This is not an official API for Israel Post service.

Author: Benny Megidish.

Keywords

FAQs

Package last updated on 08 Oct 2021

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc