Exposes Israel postal service API
Kind: global class
Author: Benny Megidish
- IPS
- .calculateShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒
Promise.<ResponseParser> - .calculateBulkShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒
Promise.<ResponseParser> .calculateAbroadShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒Promise.<ResponseParser>.calculateLocalShippingRate(weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒Promise.<ResponseParser>.calculateAbroadBulkShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒Promise.<ResponseParser>.calculateLocalBulkShippingRate(weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒Promise.<ResponseParser>- .preloadDestinations(shipmentMethod)
- .getAllDestinations(shipmentType) ⇒
Array.<string> - .isEligibleForExpressShipment(shipmentType, destination) ⇒
boolean - .isEligibleForEconomicShipment(shipmentType, destination) ⇒
boolean
- .calculateShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒
IPS.calculateShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒ Promise.<ResponseParser>
calculate shipping rate for regular (non bulk) shipments
Kind: instance method of IPS
Returns: Promise.<ResponseParser> - a promise with the parsed shipment data (@see {@class ResponseParser})
| Param | Type | Default | Description |
|---|---|---|---|
| destination | string |
destination country name (in CamelCase English) | |
| weight | float |
weight of the shipment in grams | |
| shipmentType | string |
type of shipment (as defines in {@class Options}) | |
| shipmentSubtype | object |
subtype of shipment (as define in the shipmentType {@class Options}) | |
| serviceOption | string |
null |
additional service options (nullable) |
| quantity | integer |
1 |
amount of packages |
IPS.calculateBulkShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒ Promise.<ResponseParser>
calculate shipping rate for bulk shipments
Kind: instance method of IPS
Returns: Promise.<ResponseParser> - a promise with the parsed shipment data (@see {@class ResponseParser})
| Param | Type | Default | Description |
|---|---|---|---|
| destination | string |
destination country name (in CamelCase English) | |
| weight | float |
weight of the shipment in grams | |
| shipmentType | string |
type of shipment (as defines in {@class Options}) | |
| shipmentSubtype | object |
subtype of shipment (as define in the shipmentType {@class Options}) | |
| serviceOption | string |
null |
additional service options (nullable) |
| quantity | integer |
1 |
amount of packages |
IPS.calculateAbroadShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒ Promise.<ResponseParser>
Promise.<ResponseParser>Deprecated
calculate shipping rate for abroad shipments
Kind: instance method of IPS
Returns: Promise.<ResponseParser> - a promise with the parsed shipment data (@see {@class ResponseParser})
| Param | Type | Default | Description |
|---|---|---|---|
| destination | string |
destination country name (in CamelCase English) | |
| weight | float |
weight of the shipment in grams | |
| shipmentType | string |
type of shipment (as defines in {@class Options}) | |
| shipmentSubtype | object |
subtype of shipment (as define in the shipmentType {@class Options}) | |
| serviceOption | string |
null |
additional service options (nullable) |
| quantity | integer |
1 |
amount of packages |
IPS.calculateLocalShippingRate(weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒ Promise.<ResponseParser>
Promise.<ResponseParser>Deprecated
calculate shipping rate for local shipments (in Israel)
Kind: instance method of IPS
Returns: Promise.<ResponseParser> - a promise with the parsed shipment data (@see {@class ResponseParser})
| Param | Type | Default | Description |
|---|---|---|---|
| weight | float |
weight of the shipment in grams | |
| shipmentType | string |
type of shipment (as defines in {@class Options}) | |
| shipmentSubtype | object |
subtype of shipment (as define in the shipmentType {@class Options}) | |
| serviceOption | string |
null |
additional service options (nullable) |
| quantity | integer |
1 |
amount of packages |
IPS.calculateAbroadBulkShippingRate(destination, weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒ Promise.<ResponseParser>
Promise.<ResponseParser>Deprecated
calculate bulk shipping rate for abroad bulk shipments
Kind: instance method of IPS
Returns: Promise.<ResponseParser> - a promise with the parsed shipment data (@see {@class ResponseParser})
| Param | Type | Default | Description |
|---|---|---|---|
| destination | string |
destination country name (in CamelCase English) | |
| weight | float |
weight of the shipment in grams | |
| shipmentType | string |
type of shipment (as defines in {@class Options}) | |
| shipmentSubtype | object |
subtype of shipment (as define in the shipmentType {@class Options}) | |
| serviceOption | string |
null |
additional service options (nullable) |
| quantity | integer |
1 |
amount of packages |
IPS.calculateLocalBulkShippingRate(weight, shipmentType, shipmentSubtype, serviceOption, quantity) ⇒ Promise.<ResponseParser>
Promise.<ResponseParser>Deprecated
calculate bulk shipping rate for local bulk shipments (in Israel)
Kind: instance method of IPS
Returns: Promise.<ResponseParser> - a promise with the parsed shipment data (@see {@class ResponseParser})
| Param | Type | Default | Description |
|---|---|---|---|
| weight | float |
weight of the shipment in grams | |
| shipmentType | string |
type of shipment (as defines in {@class Options}) | |
| shipmentSubtype | object |
subtype of shipment (as define in the shipmentType {@class Options}) | |
| serviceOption | string |
null |
additional service options (nullable) |
| quantity | integer |
1 |
amount of packages |
pre-loads the destinations for the requested shipment method by default, the destinations are loaded lazily on-demand
Kind: instance method of IPS
| Param | Type | Description |
|---|---|---|
| shipmentMethod | string |
method of shipment as defined in the {@class Options#ShipmentMethods} class |
return all the available destinations for the shipment type
Kind: instance method of IPS
Returns: Array.<string> - array that contains all the available destination for the shipment type
| Param | Type | Description |
|---|---|---|
| shipmentType | string |
type of shipment as defined in the {@class Options} class |
verify if the shipment is eligible for economic shipment
Kind: instance method of IPS
Returns: boolean - true, if the shipment is eligible for economic shipment, otherwise, false
| Param | Type | Description |
|---|---|---|
| shipmentType | string |
type of shipment as defined in the {@class Options} class |
| destination | string |
destination country name (in CamelCase English) |
verify if the shipment is eligible for economic shipment
Kind: instance method of IPS
Returns: boolean - true, if the shipment is eligible for economic shipment, otherwise, false
| Param | Type | Description |
|---|---|---|
| shipmentType | string |
type of shipment as defined in the {@class Options} class |
| destination | string |
destination country name (in CamelCase English) |