@shipengine/connect-carrier-api 4.26.3 → 4.26.5

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.
Files changed (37) hide show
  1. package/lib/models/addresses/address-base-schema.js +14 -2
  2. package/lib/models/addresses/address-base-schema.js.map +1 -1
  3. package/lib/models/addresses/address-base.d.ts +30 -2
  4. package/lib/models/addresses/address-base.js +27 -2
  5. package/lib/models/addresses/address-base.js.map +1 -1
  6. package/lib/models/addresses/index.d.ts +0 -1
  7. package/lib/models/addresses/index.js +0 -1
  8. package/lib/models/addresses/index.js.map +1 -1
  9. package/lib/models/addresses/pudo-location-schema.js +0 -10
  10. package/lib/models/addresses/pudo-location-schema.js.map +1 -1
  11. package/lib/models/addresses/pudo-location.d.ts +3 -16
  12. package/lib/models/addresses/pudo-location.js +3 -16
  13. package/lib/models/addresses/pudo-location.js.map +1 -1
  14. package/lib/models/documents/uploads/document-upload-shipment.d.ts +2 -0
  15. package/lib/models/documents/uploads/document-upload-shipment.js +2 -0
  16. package/lib/models/documents/uploads/document-upload-shipment.js.map +1 -1
  17. package/lib/models/documents/uploads/document-upload-type.d.ts +3 -1
  18. package/lib/models/documents/uploads/document-upload-type.js +2 -0
  19. package/lib/models/documents/uploads/document-upload-type.js.map +1 -1
  20. package/package.json +1 -1
  21. package/spec.json +7 -1
  22. package/src/models/addresses/address-base-schema.ts +14 -2
  23. package/src/models/addresses/address-base.ts +28 -2
  24. package/src/models/addresses/index.ts +0 -1
  25. package/src/models/addresses/pudo-location-schema.ts +0 -10
  26. package/src/models/addresses/pudo-location.ts +3 -16
  27. package/src/models/documents/uploads/document-upload-shipment.ts +2 -0
  28. package/src/models/documents/uploads/document-upload-type.ts +2 -0
  29. package/tsconfig.tsbuildinfo +1 -1
  30. package/lib/models/addresses/address-common-schema.d.ts +0 -2
  31. package/lib/models/addresses/address-common-schema.js +0 -21
  32. package/lib/models/addresses/address-common-schema.js.map +0 -1
  33. package/lib/models/addresses/address-common.d.ts +0 -31
  34. package/lib/models/addresses/address-common.js +0 -33
  35. package/lib/models/addresses/address-common.js.map +0 -1
  36. package/src/models/addresses/address-common-schema.ts +0 -17
  37. package/src/models/addresses/address-common.ts +0 -30
@@ -3,9 +3,21 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AddressBaseSchema = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const joi_1 = tslib_1.__importDefault(require("joi"));
6
- const address_common_schema_1 = require("./address-common-schema");
7
- exports.AddressBaseSchema = address_common_schema_1.AddressCommonSchema.keys({
6
+ exports.AddressBaseSchema = joi_1.default.object({
7
+ name: joi_1.default.string().optional().empty(),
8
+ first_name: joi_1.default.string().optional().empty(),
9
+ last_name: joi_1.default.string().optional().empty(),
10
+ email: joi_1.default.string().email().optional().empty(),
11
+ phone_number: joi_1.default.string().optional().empty(),
12
+ company_name: joi_1.default.string().optional().empty(),
13
+ address_lines: joi_1.default.array().items(joi_1.default.string()).optional(),
14
+ city_locality: joi_1.default.string().optional().empty(),
15
+ state_province: joi_1.default.string().optional().empty(),
8
16
  postal_code: joi_1.default.string().required(),
9
17
  country_code: joi_1.default.string().required(),
18
+ address_residential_indicator: joi_1.default.string().optional().empty(),
19
+ is_eu: joi_1.default.boolean().optional(),
20
+ address_metadata: joi_1.default.object().optional().empty(),
21
+ instructions: joi_1.default.string().optional().empty(),
10
22
  });
11
23
  //# sourceMappingURL=address-base-schema.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"address-base-schema.js","sourceRoot":"","sources":["../../../src/models/addresses/address-base-schema.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AACtB,mEAA8D;AAEjD,QAAA,iBAAiB,GAAG,2CAAmB,CAAC,IAAI,CAAC;IACxD,WAAW,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACpC,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACtC,CAAC,CAAC"}
1
+ {"version":3,"file":"address-base-schema.js","sourceRoot":"","sources":["../../../src/models/addresses/address-base-schema.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AAET,QAAA,iBAAiB,GAAG,aAAG,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IACrC,UAAU,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC3C,SAAS,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC1C,KAAK,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC9C,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC7C,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC7C,aAAa,EAAE,aAAG,CAAC,KAAK,EAAE,CAAC,KAAK,CAAC,aAAG,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACzD,aAAa,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC9C,cAAc,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC/C,WAAW,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACpC,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACrC,6BAA6B,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IAC9D,KAAK,EAAE,aAAG,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IAC/B,gBAAgB,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;IACjD,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE;CAC9C,CAAC,CAAC"}
@@ -1,7 +1,35 @@
1
- import { AddressCommon } from './address-common';
2
- export declare class AddressBase extends AddressCommon {
1
+ import { AddressResidentialIndicator } from './address-residential-indicator';
2
+ export declare class AddressBase {
3
+ /** @description The full name of the contact contact associated with the address */
4
+ name?: string;
5
+ /** @description The first name of the contact associated with the address */
6
+ first_name?: string;
7
+ /** @description The last name of the contact associated with the address */
8
+ last_name?: string;
9
+ /** @description The email of the contact associated with the address */
10
+ email?: string;
11
+ /** @description The phone number of the contact associated with the address (No Newline Characters) */
12
+ phone_number?: string;
13
+ /** @description The name of the company associated with this address (No Newline Characters) max length 100 characters */
14
+ company_name?: string;
15
+ /** @description The address lines of the address (No Newline Characters) max length 100 characters */
16
+ address_lines?: string[];
17
+ /** @description City or locality (No Newline Characters) */
18
+ city_locality?: string;
19
+ /** @description State or province (No Newline Characters) */
20
+ state_province?: string;
3
21
  /** @description Zip or postal code (No Newline Characters) */
4
22
  postal_code: string;
5
23
  /** @description ISO 3166-1 two-letter country code max length 2 characters */
6
24
  country_code: string;
25
+ /** @description Whether the address is residential or commercial */
26
+ address_residential_indicator?: AddressResidentialIndicator;
27
+ /** @description Whether the country of the shipment address is a member of the EU */
28
+ is_eu?: boolean;
29
+ /** @description Additional metadata provided for specific requests */
30
+ address_metadata?: {
31
+ [key: string]: string;
32
+ };
33
+ /** @description Instructions to help the carrier navigate to the address */
34
+ instructions?: string;
7
35
  }
@@ -1,12 +1,37 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AddressBase = void 0;
4
- const address_common_1 = require("./address-common");
5
- class AddressBase extends address_common_1.AddressCommon {
4
+ class AddressBase {
5
+ /** @description The full name of the contact contact associated with the address */
6
+ name;
7
+ /** @description The first name of the contact associated with the address */
8
+ first_name;
9
+ /** @description The last name of the contact associated with the address */
10
+ last_name;
11
+ /** @description The email of the contact associated with the address */
12
+ email;
13
+ /** @description The phone number of the contact associated with the address (No Newline Characters) */
14
+ phone_number;
15
+ /** @description The name of the company associated with this address (No Newline Characters) max length 100 characters */
16
+ company_name;
17
+ /** @description The address lines of the address (No Newline Characters) max length 100 characters */
18
+ address_lines;
19
+ /** @description City or locality (No Newline Characters) */
20
+ city_locality;
21
+ /** @description State or province (No Newline Characters) */
22
+ state_province;
6
23
  /** @description Zip or postal code (No Newline Characters) */
7
24
  postal_code;
8
25
  /** @description ISO 3166-1 two-letter country code max length 2 characters */
9
26
  country_code;
27
+ /** @description Whether the address is residential or commercial */
28
+ address_residential_indicator;
29
+ /** @description Whether the country of the shipment address is a member of the EU */
30
+ is_eu;
31
+ /** @description Additional metadata provided for specific requests */
32
+ address_metadata;
33
+ /** @description Instructions to help the carrier navigate to the address */
34
+ instructions;
10
35
  }
11
36
  exports.AddressBase = AddressBase;
12
37
  //# sourceMappingURL=address-base.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"address-base.js","sourceRoot":"","sources":["../../../src/models/addresses/address-base.ts"],"names":[],"mappings":";;;AAAA,qDAAiD;AAEjD,MAAa,WAAY,SAAQ,8BAAa;IAC5C,8DAA8D;IAC9D,WAAW,CAAU;IACrB,+EAA+E;IAC/E,YAAY,CAAU;CACvB;AALD,kCAKC"}
1
+ {"version":3,"file":"address-base.js","sourceRoot":"","sources":["../../../src/models/addresses/address-base.ts"],"names":[],"mappings":";;;AAEA,MAAa,WAAW;IACtB,oFAAoF;IACpF,IAAI,CAAU;IACd,6EAA6E;IAC7E,UAAU,CAAU;IACpB,4EAA4E;IAC5E,SAAS,CAAU;IACnB,wEAAwE;IACxE,KAAK,CAAU;IACf,uGAAuG;IACvG,YAAY,CAAU;IACtB,0HAA0H;IAC1H,YAAY,CAAU;IACtB,sGAAsG;IACtG,aAAa,CAAY;IACzB,4DAA4D;IAC5D,aAAa,CAAU;IACvB,6DAA6D;IAC7D,cAAc,CAAU;IACxB,8DAA8D;IAC9D,WAAW,CAAU;IACrB,+EAA+E;IAC/E,YAAY,CAAU;IACtB,oEAAoE;IACpE,6BAA6B,CAA+B;IAC5D,qFAAqF;IACrF,KAAK,CAAW;IAChB,sEAAsE;IACtE,gBAAgB,CAA6B;IAC7C,4EAA4E;IAC5E,YAAY,CAAU;CACvB;AA/BD,kCA+BC"}
@@ -1,5 +1,4 @@
1
1
  export * from './address-base';
2
- export * from './address-common';
3
2
  export * from './address-residential-indicator';
4
3
  export * from './ship-from';
5
4
  export * from './ship-from-display';
@@ -2,7 +2,6 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  tslib_1.__exportStar(require("./address-base"), exports);
5
- tslib_1.__exportStar(require("./address-common"), exports);
6
5
  tslib_1.__exportStar(require("./address-residential-indicator"), exports);
7
6
  tslib_1.__exportStar(require("./ship-from"), exports);
8
7
  tslib_1.__exportStar(require("./ship-from-display"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/models/addresses/index.ts"],"names":[],"mappings":";;;AAAA,yDAA+B;AAC/B,2DAAiC;AACjC,0EAAgD;AAChD,sDAA4B;AAC5B,8DAAoC;AACpC,oDAA0B;AAC1B,0DAAgC;AAChC,iEAAuC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/models/addresses/index.ts"],"names":[],"mappings":";;;AAAA,yDAA+B;AAC/B,0EAAgD;AAChD,sDAA4B;AAC5B,8DAAoC;AACpC,oDAA0B;AAC1B,0DAAgC;AAChC,iEAAuC"}
@@ -7,15 +7,5 @@ const address_base_schema_1 = require("./address-base-schema");
7
7
  exports.PudoLocationSchema = address_base_schema_1.AddressBaseSchema.keys({
8
8
  carrier_code: joi_1.default.string().optional(),
9
9
  location_id: joi_1.default.string().optional(),
10
- postal_code: joi_1.default.string().when('location_id', {
11
- is: joi_1.default.exist(),
12
- then: joi_1.default.optional().allow(''),
13
- otherwise: joi_1.default.required(),
14
- }),
15
- country_code: joi_1.default.string().when('location_id', {
16
- is: joi_1.default.exist(),
17
- then: joi_1.default.optional().allow(''),
18
- otherwise: joi_1.default.required(),
19
- }),
20
10
  });
21
11
  //# sourceMappingURL=pudo-location-schema.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pudo-location-schema.js","sourceRoot":"","sources":["../../../src/models/addresses/pudo-location-schema.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AACtB,+DAA0D;AAE7C,QAAA,kBAAkB,GAAG,uCAAiB,CAAC,IAAI,CAAC;IACvD,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACrC,WAAW,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACpC,WAAW,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC,aAAa,EAAE;QAC5C,EAAE,EAAE,aAAG,CAAC,KAAK,EAAE;QACf,IAAI,EAAE,aAAG,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC;QAC9B,SAAS,EAAE,aAAG,CAAC,QAAQ,EAAE;KAC1B,CAAC;IACF,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC,aAAa,EAAE;QAC7C,EAAE,EAAE,aAAG,CAAC,KAAK,EAAE;QACf,IAAI,EAAE,aAAG,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC;QAC9B,SAAS,EAAE,aAAG,CAAC,QAAQ,EAAE;KAC1B,CAAC;CACH,CAAC,CAAC"}
1
+ {"version":3,"file":"pudo-location-schema.js","sourceRoot":"","sources":["../../../src/models/addresses/pudo-location-schema.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AACtB,+DAA0D;AAE7C,QAAA,kBAAkB,GAAG,uCAAiB,CAAC,IAAI,CAAC;IACvD,YAAY,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACrC,WAAW,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACrC,CAAC,CAAC"}
@@ -1,21 +1,8 @@
1
- import { AddressCommon } from './address-common';
1
+ import { AddressBase } from './address-base';
2
2
  /** @description Pickup/Dropoff location used by carriers */
3
- export declare class PudoLocation extends AddressCommon {
4
- /**
5
- * @description Zip or postal code (No Newline Characters)
6
- * Required if `location_id` is not provided
7
- */
8
- postal_code?: string;
9
- /**
10
- * @description ISO 3166-1 two-letter country code max length 2 characters
11
- * Required if `location_id` is not provided
12
- */
13
- country_code?: string;
3
+ export declare class PudoLocation extends AddressBase {
14
4
  /** @description Standardized carrier code the location id belongs to */
15
5
  carrier_code?: string;
16
- /**
17
- * @description Location id needed to look up the location.
18
- * Required if `postal_code` or `country_code` is not provided.
19
- */
6
+ /** @description Location id needed to look up the location */
20
7
  location_id?: string;
21
8
  }
@@ -1,25 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.PudoLocation = void 0;
4
- const address_common_1 = require("./address-common");
4
+ const address_base_1 = require("./address-base");
5
5
  /** @description Pickup/Dropoff location used by carriers */
6
- class PudoLocation extends address_common_1.AddressCommon {
7
- /**
8
- * @description Zip or postal code (No Newline Characters)
9
- * Required if `location_id` is not provided
10
- */
11
- postal_code;
12
- /**
13
- * @description ISO 3166-1 two-letter country code max length 2 characters
14
- * Required if `location_id` is not provided
15
- */
16
- country_code;
6
+ class PudoLocation extends address_base_1.AddressBase {
17
7
  /** @description Standardized carrier code the location id belongs to */
18
8
  carrier_code;
19
- /**
20
- * @description Location id needed to look up the location.
21
- * Required if `postal_code` or `country_code` is not provided.
22
- */
9
+ /** @description Location id needed to look up the location */
23
10
  location_id;
24
11
  }
25
12
  exports.PudoLocation = PudoLocation;
@@ -1 +1 @@
1
- {"version":3,"file":"pudo-location.js","sourceRoot":"","sources":["../../../src/models/addresses/pudo-location.ts"],"names":[],"mappings":";;;AAAA,qDAAiD;AAEjD,4DAA4D;AAC5D,MAAa,YAAa,SAAQ,8BAAa;IAC7C;;;OAGG;IACH,WAAW,CAAU;IACrB;;;OAGG;IACH,YAAY,CAAU;IACtB,wEAAwE;IACxE,YAAY,CAAU;IACtB;;;OAGG;IACH,WAAW,CAAU;CACtB;AAlBD,oCAkBC"}
1
+ {"version":3,"file":"pudo-location.js","sourceRoot":"","sources":["../../../src/models/addresses/pudo-location.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAE7C,4DAA4D;AAC5D,MAAa,YAAa,SAAQ,0BAAW;IAC3C,wEAAwE;IACxE,YAAY,CAAU;IACtB,8DAA8D;IAC9D,WAAW,CAAU;CACtB;AALD,oCAKC"}
@@ -6,4 +6,6 @@ export declare class DocumentUploadShipment {
6
6
  origin_country_code: string;
7
7
  /** @description The destination country code */
8
8
  destination_country_code: string;
9
+ /** @description The shipment service code */
10
+ service_code: string;
9
11
  }
@@ -9,6 +9,8 @@ class DocumentUploadShipment {
9
9
  origin_country_code;
10
10
  /** @description The destination country code */
11
11
  destination_country_code;
12
+ /** @description The shipment service code */
13
+ service_code;
12
14
  }
13
15
  exports.DocumentUploadShipment = DocumentUploadShipment;
14
16
  //# sourceMappingURL=document-upload-shipment.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"document-upload-shipment.js","sourceRoot":"","sources":["../../../../src/models/documents/uploads/document-upload-shipment.ts"],"names":[],"mappings":";;;AAAA,yEAAyE;AACzE,MAAa,sBAAsB;IACjC,yCAAyC;IACzC,QAAQ,CAAU;IAClB,2CAA2C;IAC3C,mBAAmB,CAAU;IAC7B,gDAAgD;IAChD,wBAAwB,CAAU;CACnC;AAPD,wDAOC"}
1
+ {"version":3,"file":"document-upload-shipment.js","sourceRoot":"","sources":["../../../../src/models/documents/uploads/document-upload-shipment.ts"],"names":[],"mappings":";;;AAAA,yEAAyE;AACzE,MAAa,sBAAsB;IACjC,yCAAyC;IACzC,QAAQ,CAAU;IAClB,2CAA2C;IAC3C,mBAAmB,CAAU;IAC7B,gDAAgD;IAChD,wBAAwB,CAAU;IAClC,6CAA6C;IAC7C,YAAY,CAAU;CACvB;AATD,wDASC"}
@@ -31,5 +31,7 @@ export declare enum DocumentUploadType {
31
31
  /** @description A shipper's letter of instruction */
32
32
  ShippersLetterOfInstruction = "shippers_letter_of_instruction",
33
33
  /** @description A declaration document */
34
- Declaration = "declaration"
34
+ Declaration = "declaration",
35
+ /** @description Section 232 customs affidavit */
36
+ Section232CustomsAffidavit = "section_232_customs_affidavit"
35
37
  }
@@ -36,5 +36,7 @@ var DocumentUploadType;
36
36
  DocumentUploadType["ShippersLetterOfInstruction"] = "shippers_letter_of_instruction";
37
37
  /** @description A declaration document */
38
38
  DocumentUploadType["Declaration"] = "declaration";
39
+ /** @description Section 232 customs affidavit */
40
+ DocumentUploadType["Section232CustomsAffidavit"] = "section_232_customs_affidavit";
39
41
  })(DocumentUploadType || (exports.DocumentUploadType = DocumentUploadType = {}));
40
42
  //# sourceMappingURL=document-upload-type.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"document-upload-type.js","sourceRoot":"","sources":["../../../../src/models/documents/uploads/document-upload-type.ts"],"names":[],"mappings":";;;AAAA,+CAA+C;AAC/C,IAAY,kBAiCX;AAjCD,WAAY,kBAAkB;IAC5B,sMAAsM;IACtM,8DAAwC,CAAA;IACxC,2CAA2C;IAC3C,mEAA6C,CAAA;IAC7C,sEAAsE;IACtE,sHAAgG,CAAA;IAChG,mDAAmD;IACnD,kFAA4D,CAAA;IAC5D,uCAAuC;IACvC,2DAAqC,CAAA;IACrC,uCAAuC;IACvC,qCAAe,CAAA;IACf,yCAAyC;IACzC,8DAAwC,CAAA;IACxC,mDAAmD;IACnD,iFAA2D,CAAA;IAC3D,qCAAqC;IACrC,sDAAgC,CAAA;IAChC,oCAAoC;IACpC,oDAA8B,CAAA;IAC9B,gDAAgD;IAChD,qDAA+B,CAAA;IAC/B,gDAAgD;IAChD,2DAAqC,CAAA;IACrC,kCAAkC;IAClC,kDAA4B,CAAA;IAC5B,iEAAiE;IACjE,kDAA4B,CAAA;IAC5B,qDAAqD;IACrD,oFAA8D,CAAA;IAC9D,0CAA0C;IAC1C,iDAA2B,CAAA;AAC7B,CAAC,EAjCW,kBAAkB,kCAAlB,kBAAkB,QAiC7B"}
1
+ {"version":3,"file":"document-upload-type.js","sourceRoot":"","sources":["../../../../src/models/documents/uploads/document-upload-type.ts"],"names":[],"mappings":";;;AAAA,+CAA+C;AAC/C,IAAY,kBAmCX;AAnCD,WAAY,kBAAkB;IAC5B,sMAAsM;IACtM,8DAAwC,CAAA;IACxC,2CAA2C;IAC3C,mEAA6C,CAAA;IAC7C,sEAAsE;IACtE,sHAAgG,CAAA;IAChG,mDAAmD;IACnD,kFAA4D,CAAA;IAC5D,uCAAuC;IACvC,2DAAqC,CAAA;IACrC,uCAAuC;IACvC,qCAAe,CAAA;IACf,yCAAyC;IACzC,8DAAwC,CAAA;IACxC,mDAAmD;IACnD,iFAA2D,CAAA;IAC3D,qCAAqC;IACrC,sDAAgC,CAAA;IAChC,oCAAoC;IACpC,oDAA8B,CAAA;IAC9B,gDAAgD;IAChD,qDAA+B,CAAA;IAC/B,gDAAgD;IAChD,2DAAqC,CAAA;IACrC,kCAAkC;IAClC,kDAA4B,CAAA;IAC5B,iEAAiE;IACjE,kDAA4B,CAAA;IAC5B,qDAAqD;IACrD,oFAA8D,CAAA;IAC9D,0CAA0C;IAC1C,iDAA2B,CAAA;IAC3B,iDAAiD;IACjD,kFAA4D,CAAA;AAC9D,CAAC,EAnCW,kBAAkB,kCAAlB,kBAAkB,QAmC7B"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shipengine/connect-carrier-api",
3
- "version": "4.26.3",
3
+ "version": "4.26.5",
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
@@ -2445,6 +2445,11 @@
2445
2445
  "type": "string",
2446
2446
  "description": "The destination country code.",
2447
2447
  "nullable": true
2448
+ },
2449
+ "service_code": {
2450
+ "type": "string",
2451
+ "description": "The shipment service code.",
2452
+ "nullable": true
2448
2453
  }
2449
2454
  },
2450
2455
  "additionalProperties": false,
@@ -2467,7 +2472,8 @@
2467
2472
  "packing_list",
2468
2473
  "sed_document",
2469
2474
  "shippers_letter_of_instruction",
2470
- "declaration"
2475
+ "declaration",
2476
+ "section_232_customs_affidavit"
2471
2477
  ],
2472
2478
  "type": "string"
2473
2479
  },
@@ -1,7 +1,19 @@
1
1
  import Joi from 'joi';
2
- import { AddressCommonSchema } from './address-common-schema';
3
2
 
4
- export const AddressBaseSchema = AddressCommonSchema.keys({
3
+ export const AddressBaseSchema = Joi.object({
4
+ name: Joi.string().optional().empty(),
5
+ first_name: Joi.string().optional().empty(),
6
+ last_name: Joi.string().optional().empty(),
7
+ email: Joi.string().email().optional().empty(),
8
+ phone_number: Joi.string().optional().empty(),
9
+ company_name: Joi.string().optional().empty(),
10
+ address_lines: Joi.array().items(Joi.string()).optional(),
11
+ city_locality: Joi.string().optional().empty(),
12
+ state_province: Joi.string().optional().empty(),
5
13
  postal_code: Joi.string().required(),
6
14
  country_code: Joi.string().required(),
15
+ address_residential_indicator: Joi.string().optional().empty(),
16
+ is_eu: Joi.boolean().optional(),
17
+ address_metadata: Joi.object().optional().empty(),
18
+ instructions: Joi.string().optional().empty(),
7
19
  });
@@ -1,8 +1,34 @@
1
- import { AddressCommon } from './address-common';
1
+ import { AddressResidentialIndicator } from './address-residential-indicator';
2
2
 
3
- export class AddressBase extends AddressCommon {
3
+ export class AddressBase {
4
+ /** @description The full name of the contact contact associated with the address */
5
+ name?: string;
6
+ /** @description The first name of the contact associated with the address */
7
+ first_name?: string;
8
+ /** @description The last name of the contact associated with the address */
9
+ last_name?: string;
10
+ /** @description The email of the contact associated with the address */
11
+ email?: string;
12
+ /** @description The phone number of the contact associated with the address (No Newline Characters) */
13
+ phone_number?: string;
14
+ /** @description The name of the company associated with this address (No Newline Characters) max length 100 characters */
15
+ company_name?: string;
16
+ /** @description The address lines of the address (No Newline Characters) max length 100 characters */
17
+ address_lines?: string[];
18
+ /** @description City or locality (No Newline Characters) */
19
+ city_locality?: string;
20
+ /** @description State or province (No Newline Characters) */
21
+ state_province?: string;
4
22
  /** @description Zip or postal code (No Newline Characters) */
5
23
  postal_code!: string;
6
24
  /** @description ISO 3166-1 two-letter country code max length 2 characters */
7
25
  country_code!: string;
26
+ /** @description Whether the address is residential or commercial */
27
+ address_residential_indicator?: AddressResidentialIndicator;
28
+ /** @description Whether the country of the shipment address is a member of the EU */
29
+ is_eu?: boolean;
30
+ /** @description Additional metadata provided for specific requests */
31
+ address_metadata?: { [key: string]: string };
32
+ /** @description Instructions to help the carrier navigate to the address */
33
+ instructions?: string;
8
34
  }
@@ -1,5 +1,4 @@
1
1
  export * from './address-base';
2
- export * from './address-common';
3
2
  export * from './address-residential-indicator';
4
3
  export * from './ship-from';
5
4
  export * from './ship-from-display';
@@ -4,14 +4,4 @@ import { AddressBaseSchema } from './address-base-schema';
4
4
  export const PudoLocationSchema = AddressBaseSchema.keys({
5
5
  carrier_code: Joi.string().optional(),
6
6
  location_id: Joi.string().optional(),
7
- postal_code: Joi.string().when('location_id', {
8
- is: Joi.exist(),
9
- then: Joi.optional().allow(''),
10
- otherwise: Joi.required(),
11
- }),
12
- country_code: Joi.string().when('location_id', {
13
- is: Joi.exist(),
14
- then: Joi.optional().allow(''),
15
- otherwise: Joi.required(),
16
- }),
17
7
  });
@@ -1,22 +1,9 @@
1
- import { AddressCommon } from './address-common';
1
+ import { AddressBase } from './address-base';
2
2
 
3
3
  /** @description Pickup/Dropoff location used by carriers */
4
- export class PudoLocation extends AddressCommon {
5
- /**
6
- * @description Zip or postal code (No Newline Characters)
7
- * Required if `location_id` is not provided
8
- */
9
- postal_code?: string;
10
- /**
11
- * @description ISO 3166-1 two-letter country code max length 2 characters
12
- * Required if `location_id` is not provided
13
- */
14
- country_code?: string;
4
+ export class PudoLocation extends AddressBase {
15
5
  /** @description Standardized carrier code the location id belongs to */
16
6
  carrier_code?: string;
17
- /**
18
- * @description Location id needed to look up the location.
19
- * Required if `postal_code` or `country_code` is not provided.
20
- */
7
+ /** @description Location id needed to look up the location */
21
8
  location_id?: string;
22
9
  }
@@ -6,4 +6,6 @@ export class DocumentUploadShipment {
6
6
  origin_country_code!: string;
7
7
  /** @description The destination country code */
8
8
  destination_country_code!: string;
9
+ /** @description The shipment service code */
10
+ service_code!: string;
9
11
  }
@@ -32,4 +32,6 @@ export enum DocumentUploadType {
32
32
  ShippersLetterOfInstruction = 'shippers_letter_of_instruction',
33
33
  /** @description A declaration document */
34
34
  Declaration = 'declaration',
35
+ /** @description Section 232 customs affidavit */
36
+ Section232CustomsAffidavit = 'section_232_customs_affidavit',
35
37
  }