@shipengine/connect-carrier-api 4.7.0 → 4.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ import Joi from 'joi';
2
+ export declare const CustomsSchema: Joi.ObjectSchema<any>;
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CustomsSchema = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const joi_1 = tslib_1.__importDefault(require("joi"));
6
+ const customs_content_types_schema_1 = require("../customs/customs-content-types-schema");
7
+ const customs_non_delivery_schema_1 = require("../customs/customs-non-delivery-schema");
8
+ const customs_item_schema_1 = require("../customs/customs-item-schema");
9
+ const connect_carrier_api_1 = require("@shipengine/connect-carrier-api");
10
+ const terms_of_trade_code_schema_1 = require("../inconterms/terms-of-trade-code-schema");
11
+ const importer_of_record_schema_1 = require("../importer-records/importer-of-record-schema");
12
+ const customs_charges_schema_1 = require("../customs/customs-charges-schema");
13
+ exports.CustomsSchema = joi_1.default.object({
14
+ contents: customs_content_types_schema_1.CustomsContentTypesSchema.optional(),
15
+ non_delivery: customs_non_delivery_schema_1.CustomsNonDeliverySchema.optional(),
16
+ customs_items: joi_1.default.array().items(customs_item_schema_1.CustomsItemSchema).required(),
17
+ buyer_shipping_amount_paid: connect_carrier_api_1.CurrencySchema.optional(),
18
+ duties_paid: connect_carrier_api_1.CurrencySchema.optional(),
19
+ declaration: joi_1.default.string().optional(),
20
+ terms_of_trade_code: terms_of_trade_code_schema_1.TermsOfTradeCodeSchema.optional(),
21
+ importer_of_record: importer_of_record_schema_1.ImporterOfRecordSchema.optional(),
22
+ invoice_additional_details: customs_charges_schema_1.CustomsChargesSchema.optional(),
23
+ contents_explanation: joi_1.default.string().optional(),
24
+ export_declaration_number: joi_1.default.string().optional(),
25
+ });
26
+ //# sourceMappingURL=manifest-customs-schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"manifest-customs-schema.js","sourceRoot":"","sources":["../../../src/models/manifests/manifest-customs-schema.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AACtB,0FAAoF;AACpF,wFAAkF;AAClF,wEAAmE;AACnE,yEAAiE;AACjE,yFAAkF;AAClF,6FAAuF;AACvF,8EAAyE;AAE5D,QAAA,aAAa,GAAG,aAAG,CAAC,MAAM,CAAC;IACtC,QAAQ,EAAE,wDAAyB,CAAC,QAAQ,EAAE;IAC9C,YAAY,EAAE,sDAAwB,CAAC,QAAQ,EAAE;IACjD,aAAa,EAAE,aAAG,CAAC,KAAK,EAAE,CAAC,KAAK,CAAC,uCAAiB,CAAC,CAAC,QAAQ,EAAE;IAC9D,0BAA0B,EAAE,oCAAc,CAAC,QAAQ,EAAE;IACrD,WAAW,EAAE,oCAAc,CAAC,QAAQ,EAAE;IACtC,WAAW,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACpC,mBAAmB,EAAE,mDAAsB,CAAC,QAAQ,EAAE;IACtD,kBAAkB,EAAE,kDAAsB,CAAC,QAAQ,EAAE;IACrD,0BAA0B,EAAE,6CAAoB,CAAC,QAAQ,EAAE;IAC3D,oBAAoB,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7C,yBAAyB,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACnD,CAAC,CAAC"}
@@ -0,0 +1,29 @@
1
+ import { Currency, CustomsContentTypes, CustomsItem, CustomsNonDelivery } from '@shipengine/connect-carrier-api';
2
+ import { TermsOfTradeCode } from '../inconterms/terms-of-trade-code';
3
+ import { ImporterOfRecord } from '../importer-records/importer-of-record';
4
+ import { CustomsCharges } from '../customs/customs-charges';
5
+ /** @description Basic structure for a customs declaration for manifest */
6
+ export declare class ManifestCustoms {
7
+ /** @description Indicates the type of contents associated with this shipment */
8
+ contents?: CustomsContentTypes;
9
+ /** @description Indicates what the seller would like done in case of an issue with delivery */
10
+ non_delivery?: CustomsNonDelivery;
11
+ /** @description A list of customs items to declare */
12
+ customs_items: CustomsItem[];
13
+ /** @description Indicates how much the buyer paid for shipping, if any. This amount may be different than the shipping cost billed to the shipper. */
14
+ buyer_shipping_amount_paid?: Currency;
15
+ /** @description The amount of duties paid by the shipper, if any. This is generally only necessary for DDP (bill_duties_to_sender) shipments. */
16
+ duties_paid?: Currency;
17
+ /** @description Declaration statement to be placed on the commercial invoice */
18
+ declaration?: string;
19
+ /** @description Incoterms specify who is responsible for paying for and managing the shipment*/
20
+ terms_of_trade_code?: TermsOfTradeCode;
21
+ /** @description The owner or purchaser of the products being imported into a destination country.*/
22
+ importer_of_record?: ImporterOfRecord;
23
+ /** @description The charges related with customs.*/
24
+ invoice_additional_details?: CustomsCharges;
25
+ /**@description: text explanation for the content */
26
+ contents_explanation?: string;
27
+ /**@description: An EDN is a number which is nine alphanumeric characters long and issued by the Australian Customs (Australian Border Force) in exchange for the information that an exporter shares with them. */
28
+ export_declaration_number?: string;
29
+ }
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ManifestCustoms = void 0;
4
+ /** @description Basic structure for a customs declaration for manifest */
5
+ class ManifestCustoms {
6
+ /** @description Indicates the type of contents associated with this shipment */
7
+ contents;
8
+ /** @description Indicates what the seller would like done in case of an issue with delivery */
9
+ non_delivery;
10
+ /** @description A list of customs items to declare */
11
+ customs_items;
12
+ /** @description Indicates how much the buyer paid for shipping, if any. This amount may be different than the shipping cost billed to the shipper. */
13
+ buyer_shipping_amount_paid;
14
+ /** @description The amount of duties paid by the shipper, if any. This is generally only necessary for DDP (bill_duties_to_sender) shipments. */
15
+ duties_paid;
16
+ /** @description Declaration statement to be placed on the commercial invoice */
17
+ declaration;
18
+ /** @description Incoterms specify who is responsible for paying for and managing the shipment*/
19
+ terms_of_trade_code;
20
+ /** @description The owner or purchaser of the products being imported into a destination country.*/
21
+ importer_of_record;
22
+ /** @description The charges related with customs.*/
23
+ invoice_additional_details;
24
+ /**@description: text explanation for the content */
25
+ contents_explanation;
26
+ /**@description: An EDN is a number which is nine alphanumeric characters long and issued by the Australian Customs (Australian Border Force) in exchange for the information that an exporter shares with them. */
27
+ export_declaration_number;
28
+ }
29
+ exports.ManifestCustoms = ManifestCustoms;
30
+ //# sourceMappingURL=manifest-customs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"manifest-customs.js","sourceRoot":"","sources":["../../../src/models/manifests/manifest-customs.ts"],"names":[],"mappings":";;;AAUA,0EAA0E;AAC1E,MAAa,eAAe;IAC1B,gFAAgF;IAChF,QAAQ,CAAuB;IAC/B,+FAA+F;IAC/F,YAAY,CAAsB;IAClC,sDAAsD;IACtD,aAAa,CAAiB;IAC9B,sJAAsJ;IACtJ,0BAA0B,CAAY;IACtC,iJAAiJ;IACjJ,WAAW,CAAY;IACvB,gFAAgF;IAChF,WAAW,CAAU;IACrB,gGAAgG;IAChG,mBAAmB,CAAoB;IACvC,oGAAoG;IACpG,kBAAkB,CAAoB;IACtC,oDAAoD;IACpD,0BAA0B,CAAkB;IAC5C,oDAAoD;IACpD,oBAAoB,CAAU;IAC9B,oNAAoN;IACpN,yBAAyB,CAAU;CACpC;AAvBD,0CAuBC"}
@@ -1,6 +1,8 @@
1
1
  import { ShippedShipment } from '../pickup/shipped-shipment';
2
+ import { ManifestCustoms } from './manifest-customs';
2
3
  export declare class ManifestRequestShipment extends ShippedShipment {
3
4
  manifest_request_shipment_id: string;
4
5
  ship_datetime?: string;
5
6
  reference?: string;
7
+ manifest_customs?: ManifestCustoms;
6
8
  }
@@ -6,6 +6,7 @@ class ManifestRequestShipment extends shipped_shipment_1.ShippedShipment {
6
6
  manifest_request_shipment_id;
7
7
  ship_datetime;
8
8
  reference;
9
+ manifest_customs;
9
10
  }
10
11
  exports.ManifestRequestShipment = ManifestRequestShipment;
11
12
  //# sourceMappingURL=manifest-request-shipment.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"manifest-request-shipment.js","sourceRoot":"","sources":["../../../src/models/manifests/manifest-request-shipment.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAE7D,MAAa,uBAAwB,SAAQ,kCAAe;IAC1D,4BAA4B,CAAU;IACtC,aAAa,CAAU;IACvB,SAAS,CAAU;CACpB;AAJD,0DAIC"}
1
+ {"version":3,"file":"manifest-request-shipment.js","sourceRoot":"","sources":["../../../src/models/manifests/manifest-request-shipment.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAG7D,MAAa,uBAAwB,SAAQ,kCAAe;IAC1D,4BAA4B,CAAU;IACtC,aAAa,CAAU;IACvB,SAAS,CAAU;IACnB,gBAAgB,CAAmB;CACpC;AALD,0DAKC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shipengine/connect-carrier-api",
3
- "version": "4.7.0",
3
+ "version": "4.8.1",
4
4
  "description": "This is the typescript/javascript definitions for carrier api",
5
5
  "homepage": "https://connect.shipengine.com",
6
6
  "main": "./lib/index.js",
package/spec.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "info": {
4
4
  "title": "Shipping API",
5
5
  "description": "This API specification describes the canonical ShipEngine Shipping API connector module.",
6
- "version": "1.21.0"
6
+ "version": "1.22.1"
7
7
  },
8
8
  "paths": {
9
9
  "/Register": {
@@ -2514,6 +2514,9 @@
2514
2514
  "description": "The maximum number of service points to return",
2515
2515
  "format": "int32",
2516
2516
  "nullable": true
2517
+ },
2518
+ "shipment": {
2519
+ "$ref": "#/components/schemas/ServicePointShipment"
2517
2520
  }
2518
2521
  },
2519
2522
  "additionalProperties": false
@@ -2812,6 +2815,83 @@
2812
2815
  "additionalProperties": false,
2813
2816
  "description": "This model represents a single manifest created with a shipping provider."
2814
2817
  },
2818
+ "ManifestCustoms": {
2819
+ "type": "object",
2820
+ "properties": {
2821
+ "contents": {
2822
+ "$ref": "#/components/schemas/CustomsContentTypes"
2823
+ },
2824
+ "non_delivery": {
2825
+ "$ref": "#/components/schemas/CustomsNonDelivery"
2826
+ },
2827
+ "buyer_shipping_amount_paid": {
2828
+ "required": [
2829
+ "currency",
2830
+ "amount"
2831
+ ],
2832
+ "type": "object",
2833
+ "properties": {
2834
+ "amount": {
2835
+ "type": "string",
2836
+ "description": "Decimal currency value, as a string."
2837
+ },
2838
+ "currency": {
2839
+ "type": "string",
2840
+ "description": "Alpha-3 currency code complying with ISO 4217."
2841
+ }
2842
+ },
2843
+ "description": "Indicates how much the buyer paid for shipping, if any. This amount may be different than the shipping cost billed\r\nto the shipper.",
2844
+ "nullable": true
2845
+ },
2846
+ "duties_paid": {
2847
+ "required": [
2848
+ "currency",
2849
+ "amount"
2850
+ ],
2851
+ "type": "object",
2852
+ "properties": {
2853
+ "amount": {
2854
+ "type": "string",
2855
+ "description": "Decimal currency value, as a string."
2856
+ },
2857
+ "currency": {
2858
+ "type": "string",
2859
+ "description": "Alpha-3 currency code complying with ISO 4217."
2860
+ }
2861
+ },
2862
+ "description": "The amount of duties paid by the shipper, if any. This is generally only necessary for DDP\r\n(bill_duties_to_sender) shipments.",
2863
+ "nullable": true
2864
+ },
2865
+ "bill_duties_to": {
2866
+ "$ref": "#/components/schemas/BillTo"
2867
+ },
2868
+ "declaration": {
2869
+ "type": "string",
2870
+ "description": "Declaration statement to be placed on the commercial invoice",
2871
+ "nullable": true
2872
+ },
2873
+ "terms_of_trade_code": {
2874
+ "$ref": "#/components/schemas/TermsOfTradeCode"
2875
+ },
2876
+ "importer_of_record": {
2877
+ "$ref": "#/components/schemas/ImporterOfRecord"
2878
+ },
2879
+ "invoice_additional_details": {
2880
+ "$ref": "#/components/schemas/CustomCharges"
2881
+ },
2882
+ "contents_explanation": {
2883
+ "type": "string",
2884
+ "description": "Text explanation for the content",
2885
+ "nullable": true
2886
+ },
2887
+ "export_declaration_number": {
2888
+ "type": "string",
2889
+ "description": "An EDN is a number which is nine alphanumeric characters long and issued by the Australian Customs (Australian Border Force) in exchange for the information that an exporter shares with them.",
2890
+ "nullable": true
2891
+ }
2892
+ },
2893
+ "additionalProperties": false
2894
+ },
2815
2895
  "ManifestError": {
2816
2896
  "type": "object",
2817
2897
  "properties": {
@@ -2854,6 +2934,9 @@
2854
2934
  "type": "string",
2855
2935
  "description": "Shipment reference number.",
2856
2936
  "nullable": true
2937
+ },
2938
+ "customs": {
2939
+ "$ref": "#/components/schemas/ManifestCustoms"
2857
2940
  }
2858
2941
  },
2859
2942
  "additionalProperties": false
@@ -3820,6 +3903,15 @@
3820
3903
  },
3821
3904
  "additionalProperties": false
3822
3905
  },
3906
+ "ServicePointShipment": {
3907
+ "type": "object",
3908
+ "properties": {
3909
+ "total_weight": {
3910
+ "$ref": "#/components/schemas/WeightDetails"
3911
+ }
3912
+ },
3913
+ "additionalProperties": false
3914
+ },
3823
3915
  "ShipFrom": {
3824
3916
  "required": [
3825
3917
  "postal_code",
@@ -4889,4 +4981,4 @@
4889
4981
  "description": "Given inbound data, such as a webhook with tracking updates, return normalized information."
4890
4982
  }
4891
4983
  ]
4892
- }
4984
+ }
@@ -0,0 +1,22 @@
1
+ import Joi from 'joi';
2
+ import { CustomsContentTypesSchema } from '../customs/customs-content-types-schema';
3
+ import { CustomsNonDeliverySchema } from '../customs/customs-non-delivery-schema';
4
+ import { CustomsItemSchema } from '../customs/customs-item-schema';
5
+ import { CurrencySchema } from '@shipengine/connect-carrier-api';
6
+ import { TermsOfTradeCodeSchema } from '../inconterms/terms-of-trade-code-schema';
7
+ import { ImporterOfRecordSchema } from '../importer-records/importer-of-record-schema';
8
+ import { CustomsChargesSchema } from '../customs/customs-charges-schema';
9
+
10
+ export const CustomsSchema = Joi.object({
11
+ contents: CustomsContentTypesSchema.optional(),
12
+ non_delivery: CustomsNonDeliverySchema.optional(),
13
+ customs_items: Joi.array().items(CustomsItemSchema).required(),
14
+ buyer_shipping_amount_paid: CurrencySchema.optional(),
15
+ duties_paid: CurrencySchema.optional(),
16
+ declaration: Joi.string().optional(),
17
+ terms_of_trade_code: TermsOfTradeCodeSchema.optional(),
18
+ importer_of_record: ImporterOfRecordSchema.optional(),
19
+ invoice_additional_details: CustomsChargesSchema.optional(),
20
+ contents_explanation: Joi.string().optional(),
21
+ export_declaration_number: Joi.string().optional(),
22
+ });
@@ -0,0 +1,35 @@
1
+ import {
2
+ Currency,
3
+ CustomsContentTypes,
4
+ CustomsItem,
5
+ CustomsNonDelivery,
6
+ } from '@shipengine/connect-carrier-api';
7
+ import { TermsOfTradeCode } from '../inconterms/terms-of-trade-code';
8
+ import { ImporterOfRecord } from '../importer-records/importer-of-record';
9
+ import { CustomsCharges } from '../customs/customs-charges';
10
+
11
+ /** @description Basic structure for a customs declaration for manifest */
12
+ export class ManifestCustoms {
13
+ /** @description Indicates the type of contents associated with this shipment */
14
+ contents?: CustomsContentTypes;
15
+ /** @description Indicates what the seller would like done in case of an issue with delivery */
16
+ non_delivery?: CustomsNonDelivery;
17
+ /** @description A list of customs items to declare */
18
+ customs_items!: CustomsItem[];
19
+ /** @description Indicates how much the buyer paid for shipping, if any. This amount may be different than the shipping cost billed to the shipper. */
20
+ buyer_shipping_amount_paid?: Currency;
21
+ /** @description The amount of duties paid by the shipper, if any. This is generally only necessary for DDP (bill_duties_to_sender) shipments. */
22
+ duties_paid?: Currency;
23
+ /** @description Declaration statement to be placed on the commercial invoice */
24
+ declaration?: string;
25
+ /** @description Incoterms specify who is responsible for paying for and managing the shipment*/
26
+ terms_of_trade_code?: TermsOfTradeCode;
27
+ /** @description The owner or purchaser of the products being imported into a destination country.*/
28
+ importer_of_record?: ImporterOfRecord;
29
+ /** @description The charges related with customs.*/
30
+ invoice_additional_details?: CustomsCharges;
31
+ /**@description: text explanation for the content */
32
+ contents_explanation?: string;
33
+ /**@description: An EDN is a number which is nine alphanumeric characters long and issued by the Australian Customs (Australian Border Force) in exchange for the information that an exporter shares with them. */
34
+ export_declaration_number?: string;
35
+ }
@@ -1,7 +1,9 @@
1
1
  import { ShippedShipment } from '../pickup/shipped-shipment';
2
+ import { ManifestCustoms } from './manifest-customs';
2
3
 
3
4
  export class ManifestRequestShipment extends ShippedShipment {
4
5
  manifest_request_shipment_id!: string;
5
6
  ship_datetime?: string;
6
7
  reference?: string;
8
+ manifest_customs?: ManifestCustoms;
7
9
  }