@shipengine/connect-carrier-api 4.1.0 → 4.1.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.
|
@@ -8,7 +8,7 @@ export declare class ImporterOfRecord {
|
|
|
8
8
|
/** @description Indicates Company Name of the owner or purchaser of the products being imported into a destination country*/
|
|
9
9
|
company_name?: string;
|
|
10
10
|
/** @description Indicates address line one of the owner or purchaser of the products being imported into a destination country*/
|
|
11
|
-
address_line1
|
|
11
|
+
address_line1?: string;
|
|
12
12
|
/** @description Indicates address of the owner or purchaser of the products being imported into a destination country*/
|
|
13
13
|
address_line2?: string;
|
|
14
14
|
/** @description Indicates City or Locality of the owner or purchaser of the products being imported into a destination country */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shipengine/connect-carrier-api",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.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",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
"@types/sanitize-html": "^2.6.2",
|
|
35
35
|
"prettier": "^2.8.8",
|
|
36
36
|
"typescript": "^4.9.5",
|
|
37
|
+
"vite": "^4.3.9",
|
|
37
38
|
"vitest": "^0.23.4"
|
|
38
39
|
},
|
|
39
40
|
"optionalDependencies": {
|
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.
|
|
6
|
+
"version": "1.18.1"
|
|
7
7
|
},
|
|
8
8
|
"paths": {
|
|
9
9
|
"/Register": {
|
|
@@ -576,7 +576,7 @@
|
|
|
576
576
|
"tags": [
|
|
577
577
|
"Tracking"
|
|
578
578
|
],
|
|
579
|
-
"description": "This method
|
|
579
|
+
"description": "This method should yield imported tracking events for a connection. It should\r\nonly be implemented if you support importing tracking data in bulk via file\r\nexchange or API requests.\r\nAny information needed to retrieve tracking data for a connection should be\r\ncollected in your registration form and will be made available as metadata in\r\nthe request.\r\nSee the [Tracking Overview](https://connect.shipengine.com/shipping/tracking/)\r\nfor implementation details.",
|
|
580
580
|
"operationId": "ImportTrackingEvents",
|
|
581
581
|
"requestBody": {
|
|
582
582
|
"description": "An object containing information about the connection to import tracking events for.",
|
|
@@ -604,6 +604,37 @@
|
|
|
604
604
|
}
|
|
605
605
|
}
|
|
606
606
|
}
|
|
607
|
+
},
|
|
608
|
+
"/ValidateShipment": {
|
|
609
|
+
"post": {
|
|
610
|
+
"tags": [
|
|
611
|
+
"Validations"
|
|
612
|
+
],
|
|
613
|
+
"description": "This method validates a shipment against carrier constraints for selected service.",
|
|
614
|
+
"operationId": "ValidateShipment",
|
|
615
|
+
"requestBody": {
|
|
616
|
+
"description": "An object containing information about the shipment and selected services to validate.",
|
|
617
|
+
"content": {
|
|
618
|
+
"application/json": {
|
|
619
|
+
"schema": {
|
|
620
|
+
"$ref": "#/components/schemas/ValidateShipmentRequest"
|
|
621
|
+
}
|
|
622
|
+
}
|
|
623
|
+
}
|
|
624
|
+
},
|
|
625
|
+
"responses": {
|
|
626
|
+
"200": {
|
|
627
|
+
"description": "This object model represents the response from a successful validate shipment request.",
|
|
628
|
+
"content": {
|
|
629
|
+
"application/json": {
|
|
630
|
+
"schema": {
|
|
631
|
+
"$ref": "#/components/schemas/ValidateShipmentResponse"
|
|
632
|
+
}
|
|
633
|
+
}
|
|
634
|
+
}
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
}
|
|
607
638
|
}
|
|
608
639
|
},
|
|
609
640
|
"components": {
|
|
@@ -819,6 +850,39 @@
|
|
|
819
850
|
},
|
|
820
851
|
"additionalProperties": false
|
|
821
852
|
},
|
|
853
|
+
"BillTo": {
|
|
854
|
+
"required": [
|
|
855
|
+
"postal_code",
|
|
856
|
+
"country_code"
|
|
857
|
+
],
|
|
858
|
+
"type": "object",
|
|
859
|
+
"allOf": [
|
|
860
|
+
{
|
|
861
|
+
"$ref": "#/components/schemas/AddressWithContact"
|
|
862
|
+
}
|
|
863
|
+
],
|
|
864
|
+
"properties": {
|
|
865
|
+
"bill_to_party": {
|
|
866
|
+
"$ref": "#/components/schemas/BillToParty"
|
|
867
|
+
},
|
|
868
|
+
"account_number": {
|
|
869
|
+
"type": "string",
|
|
870
|
+
"description": "Specified if there is an account number associated with the Bill To Party, and the Bill To Party is\r\nnot the account holder.",
|
|
871
|
+
"nullable": true
|
|
872
|
+
}
|
|
873
|
+
},
|
|
874
|
+
"additionalProperties": false,
|
|
875
|
+
"description": "Bill to is a generic object used for billing a part of the shipment, duties, taxes, or otherwise to a party\r\nother than the shipper (the shipper is considered the default party responsible). CarrierApi.Common.Request.CarrierApi.Common.Models.BillTo\r\nextends CarrierApi.Common.Models.Addresses.AddressWithContact since address fields are often required when associating billing to\r\nanother account. Additionally, this allows for a contact to be specified, if necessary."
|
|
876
|
+
},
|
|
877
|
+
"BillToParty": {
|
|
878
|
+
"enum": [
|
|
879
|
+
"shipper",
|
|
880
|
+
"recipient",
|
|
881
|
+
"third_party_account"
|
|
882
|
+
],
|
|
883
|
+
"type": "string",
|
|
884
|
+
"description": "The type of party responsible for a given category of charges associated with a shipment, such as shipping charges or import duties."
|
|
885
|
+
},
|
|
822
886
|
"BillingCategories": {
|
|
823
887
|
"enum": [
|
|
824
888
|
"uncategorized",
|
|
@@ -838,7 +902,9 @@
|
|
|
838
902
|
"oversize",
|
|
839
903
|
"returns",
|
|
840
904
|
"notifications",
|
|
841
|
-
"tip"
|
|
905
|
+
"tip",
|
|
906
|
+
"duties_and_taxes",
|
|
907
|
+
"brokerage_fee"
|
|
842
908
|
],
|
|
843
909
|
"type": "string"
|
|
844
910
|
},
|
|
@@ -889,76 +955,6 @@
|
|
|
889
955
|
},
|
|
890
956
|
"additionalProperties": false
|
|
891
957
|
},
|
|
892
|
-
"BillTo": {
|
|
893
|
-
"required": [
|
|
894
|
-
"postal_code",
|
|
895
|
-
"country_code"
|
|
896
|
-
],
|
|
897
|
-
"type": "object",
|
|
898
|
-
"allOf": [
|
|
899
|
-
{
|
|
900
|
-
"$ref": "#/components/schemas/AddressWithContact"
|
|
901
|
-
}
|
|
902
|
-
],
|
|
903
|
-
"properties": {
|
|
904
|
-
"bill_to_party": {
|
|
905
|
-
"$ref": "#/components/schemas/BillToParty"
|
|
906
|
-
},
|
|
907
|
-
"account_number": {
|
|
908
|
-
"type": "string",
|
|
909
|
-
"description": "Specified if there is an account number associated with the Bill To Party, and the Bill To Party is\r\nnot the account holder.",
|
|
910
|
-
"nullable": true
|
|
911
|
-
}
|
|
912
|
-
},
|
|
913
|
-
"additionalProperties": false,
|
|
914
|
-
"description": "Bill to is a generic object used for billing a part of the shipment, duties, taxes, or otherwise to a party\r\nother than the shipper (the shipper is considered the default party responsible). CarrierApi.Common.Request.CarrierApi.Common.Models.BillTo\r\nextends CarrierApi.Common.Models.Addresses.AddressWithContact since address fields are often required when associating billing to\r\nanother account. Additionally, this allows for a contact to be specified, if necessary."
|
|
915
|
-
},
|
|
916
|
-
"BillToParty": {
|
|
917
|
-
"enum": [
|
|
918
|
-
"shipper",
|
|
919
|
-
"recipient",
|
|
920
|
-
"third_party_account"
|
|
921
|
-
],
|
|
922
|
-
"type": "string",
|
|
923
|
-
"description": "The type of party responsible for a given category of charges associated with a shipment, such as shipping charges or import duties."
|
|
924
|
-
},
|
|
925
|
-
"CancellationDetails": {
|
|
926
|
-
"required": [
|
|
927
|
-
"reason"
|
|
928
|
-
],
|
|
929
|
-
"type": "object",
|
|
930
|
-
"properties": {
|
|
931
|
-
"reason": {
|
|
932
|
-
"$ref": "#/components/schemas/CancellationReason"
|
|
933
|
-
},
|
|
934
|
-
"cancellation_options": {
|
|
935
|
-
"type": "object",
|
|
936
|
-
"additionalProperties": {
|
|
937
|
-
"type": "string"
|
|
938
|
-
},
|
|
939
|
-
"description": "Additional properties about the cancellation",
|
|
940
|
-
"nullable": true
|
|
941
|
-
},
|
|
942
|
-
"remarks": {
|
|
943
|
-
"type": "string",
|
|
944
|
-
"description": "Remarks about why the customer is cancelling the pickup",
|
|
945
|
-
"nullable": true
|
|
946
|
-
}
|
|
947
|
-
},
|
|
948
|
-
"additionalProperties": false,
|
|
949
|
-
"description": "This model contains the explanation of why a user is cancelling a pickup."
|
|
950
|
-
},
|
|
951
|
-
"CancellationReason": {
|
|
952
|
-
"enum": [
|
|
953
|
-
"other",
|
|
954
|
-
"not_ready",
|
|
955
|
-
"cost_too_high",
|
|
956
|
-
"service_too_slow",
|
|
957
|
-
"carrier_failed_pickup"
|
|
958
|
-
],
|
|
959
|
-
"type": "string",
|
|
960
|
-
"description": "An enumeration of common reasons cancellations occur"
|
|
961
|
-
},
|
|
962
958
|
"CancelNotificationRequest": {
|
|
963
959
|
"required": [
|
|
964
960
|
"transaction_id"
|
|
@@ -1092,6 +1088,44 @@
|
|
|
1092
1088
|
"additionalProperties": false,
|
|
1093
1089
|
"description": "This model represents a response for a successful cancel pickup request."
|
|
1094
1090
|
},
|
|
1091
|
+
"CancellationDetails": {
|
|
1092
|
+
"required": [
|
|
1093
|
+
"reason"
|
|
1094
|
+
],
|
|
1095
|
+
"type": "object",
|
|
1096
|
+
"properties": {
|
|
1097
|
+
"reason": {
|
|
1098
|
+
"$ref": "#/components/schemas/CancellationReason"
|
|
1099
|
+
},
|
|
1100
|
+
"cancellation_options": {
|
|
1101
|
+
"type": "object",
|
|
1102
|
+
"additionalProperties": {
|
|
1103
|
+
"type": "string",
|
|
1104
|
+
"nullable": true
|
|
1105
|
+
},
|
|
1106
|
+
"description": "Additional properties about the cancellation",
|
|
1107
|
+
"nullable": true
|
|
1108
|
+
},
|
|
1109
|
+
"remarks": {
|
|
1110
|
+
"type": "string",
|
|
1111
|
+
"description": "Remarks about why the customer is cancelling the pickup",
|
|
1112
|
+
"nullable": true
|
|
1113
|
+
}
|
|
1114
|
+
},
|
|
1115
|
+
"additionalProperties": false,
|
|
1116
|
+
"description": "This model contains the explanation of why a user is cancelling a pickup."
|
|
1117
|
+
},
|
|
1118
|
+
"CancellationReason": {
|
|
1119
|
+
"enum": [
|
|
1120
|
+
"other",
|
|
1121
|
+
"not_ready",
|
|
1122
|
+
"cost_too_high",
|
|
1123
|
+
"service_too_slow",
|
|
1124
|
+
"carrier_failed_pickup"
|
|
1125
|
+
],
|
|
1126
|
+
"type": "string",
|
|
1127
|
+
"description": "An enumeration of common reasons cancellations occur"
|
|
1128
|
+
},
|
|
1095
1129
|
"CodPaymentType": {
|
|
1096
1130
|
"enum": [
|
|
1097
1131
|
"any",
|
|
@@ -1821,6 +1855,14 @@
|
|
|
1821
1855
|
"additionalProperties": false,
|
|
1822
1856
|
"description": "This model represents the dimensions for a package represented in its original unit, inches, and centimeters."
|
|
1823
1857
|
},
|
|
1858
|
+
"DimensionUnit": {
|
|
1859
|
+
"enum": [
|
|
1860
|
+
"inches",
|
|
1861
|
+
"centimeters"
|
|
1862
|
+
],
|
|
1863
|
+
"type": "string",
|
|
1864
|
+
"description": "This model represents the supported units for dimensions."
|
|
1865
|
+
},
|
|
1824
1866
|
"Dimensions": {
|
|
1825
1867
|
"type": "object",
|
|
1826
1868
|
"properties": {
|
|
@@ -1846,14 +1888,6 @@
|
|
|
1846
1888
|
"additionalProperties": false,
|
|
1847
1889
|
"description": "This model represents the measurements for dimensions."
|
|
1848
1890
|
},
|
|
1849
|
-
"DimensionUnit": {
|
|
1850
|
-
"enum": [
|
|
1851
|
-
"inches",
|
|
1852
|
-
"centimeters"
|
|
1853
|
-
],
|
|
1854
|
-
"type": "string",
|
|
1855
|
-
"description": "This model represents the supported units for dimensions."
|
|
1856
|
-
},
|
|
1857
1891
|
"DisplayScheme": {
|
|
1858
1892
|
"enum": [
|
|
1859
1893
|
"label",
|
|
@@ -2311,6 +2345,18 @@
|
|
|
2311
2345
|
"additionalProperties": false,
|
|
2312
2346
|
"description": "A key value pair, allowing custom properties to be stored."
|
|
2313
2347
|
},
|
|
2348
|
+
"ImportTrackingEventsRequest": {
|
|
2349
|
+
"required": [
|
|
2350
|
+
"transaction_id"
|
|
2351
|
+
],
|
|
2352
|
+
"type": "object",
|
|
2353
|
+
"allOf": [
|
|
2354
|
+
{
|
|
2355
|
+
"$ref": "#/components/schemas/BaseRequest"
|
|
2356
|
+
}
|
|
2357
|
+
],
|
|
2358
|
+
"additionalProperties": false
|
|
2359
|
+
},
|
|
2314
2360
|
"ImportedTrackingEvent": {
|
|
2315
2361
|
"type": "object",
|
|
2316
2362
|
"properties": {
|
|
@@ -2405,18 +2451,6 @@
|
|
|
2405
2451
|
"additionalProperties": false,
|
|
2406
2452
|
"description": "Basic structure for a Importer Record"
|
|
2407
2453
|
},
|
|
2408
|
-
"ImportTrackingEventsRequest": {
|
|
2409
|
-
"required": [
|
|
2410
|
-
"transaction_id"
|
|
2411
|
-
],
|
|
2412
|
-
"type": "object",
|
|
2413
|
-
"allOf": [
|
|
2414
|
-
{
|
|
2415
|
-
"$ref": "#/components/schemas/BaseRequest"
|
|
2416
|
-
}
|
|
2417
|
-
],
|
|
2418
|
-
"additionalProperties": false
|
|
2419
|
-
},
|
|
2420
2454
|
"InboundDataContentTypes": {
|
|
2421
2455
|
"enum": [
|
|
2422
2456
|
"tracking"
|
|
@@ -3430,6 +3464,29 @@
|
|
|
3430
3464
|
"additionalProperties": false,
|
|
3431
3465
|
"description": "The address that should be displayed as the return address, only if the shipping provider supports\r\nthis functionality."
|
|
3432
3466
|
},
|
|
3467
|
+
"ShipTo": {
|
|
3468
|
+
"required": [
|
|
3469
|
+
"postal_code",
|
|
3470
|
+
"country_code"
|
|
3471
|
+
],
|
|
3472
|
+
"type": "object",
|
|
3473
|
+
"allOf": [
|
|
3474
|
+
{
|
|
3475
|
+
"$ref": "#/components/schemas/AddressWithContact"
|
|
3476
|
+
}
|
|
3477
|
+
],
|
|
3478
|
+
"properties": {
|
|
3479
|
+
"tax_identifiers": {
|
|
3480
|
+
"type": "array",
|
|
3481
|
+
"items": {
|
|
3482
|
+
"$ref": "#/components/schemas/TaxIdentifier"
|
|
3483
|
+
},
|
|
3484
|
+
"description": "Tax IDs associated with the consignee.",
|
|
3485
|
+
"nullable": true
|
|
3486
|
+
}
|
|
3487
|
+
},
|
|
3488
|
+
"additionalProperties": false
|
|
3489
|
+
},
|
|
3433
3490
|
"ShipmentIdentifier": {
|
|
3434
3491
|
"type": "object",
|
|
3435
3492
|
"properties": {
|
|
@@ -3548,29 +3605,6 @@
|
|
|
3548
3605
|
"additionalProperties": false,
|
|
3549
3606
|
"description": "This model represents a shipment that has already been shipped, and contains\r\nsummary information about the shipment."
|
|
3550
3607
|
},
|
|
3551
|
-
"ShipTo": {
|
|
3552
|
-
"required": [
|
|
3553
|
-
"postal_code",
|
|
3554
|
-
"country_code"
|
|
3555
|
-
],
|
|
3556
|
-
"type": "object",
|
|
3557
|
-
"allOf": [
|
|
3558
|
-
{
|
|
3559
|
-
"$ref": "#/components/schemas/AddressWithContact"
|
|
3560
|
-
}
|
|
3561
|
-
],
|
|
3562
|
-
"properties": {
|
|
3563
|
-
"tax_identifiers": {
|
|
3564
|
-
"type": "array",
|
|
3565
|
-
"items": {
|
|
3566
|
-
"$ref": "#/components/schemas/TaxIdentifier"
|
|
3567
|
-
},
|
|
3568
|
-
"description": "Tax IDs associated with the consignee.",
|
|
3569
|
-
"nullable": true
|
|
3570
|
-
}
|
|
3571
|
-
},
|
|
3572
|
-
"additionalProperties": false
|
|
3573
|
-
},
|
|
3574
3608
|
"StandardizedStatusCodes": {
|
|
3575
3609
|
"enum": [
|
|
3576
3610
|
"UN",
|
|
@@ -3981,6 +4015,85 @@
|
|
|
3981
4015
|
"additionalProperties": false,
|
|
3982
4016
|
"description": "This model represents the successful response from a validate inbound data request."
|
|
3983
4017
|
},
|
|
4018
|
+
"ValidateShipmentError": {
|
|
4019
|
+
"type": "object",
|
|
4020
|
+
"properties": {
|
|
4021
|
+
"field_name": {
|
|
4022
|
+
"type": "string",
|
|
4023
|
+
"description": "This is validated field name.",
|
|
4024
|
+
"nullable": true,
|
|
4025
|
+
"example": "ship_to.postal_code"
|
|
4026
|
+
},
|
|
4027
|
+
"field_value": {
|
|
4028
|
+
"type": "string",
|
|
4029
|
+
"description": "This is a validated field value.",
|
|
4030
|
+
"nullable": true,
|
|
4031
|
+
"example": "85001"
|
|
4032
|
+
},
|
|
4033
|
+
"carrier_error_code": {
|
|
4034
|
+
"$ref": "#/components/schemas/ValidationErrorCodes"
|
|
4035
|
+
},
|
|
4036
|
+
"message": {
|
|
4037
|
+
"type": "string",
|
|
4038
|
+
"description": "A user friendly message about this error.",
|
|
4039
|
+
"nullable": true,
|
|
4040
|
+
"example": "Receiver postal code cannot be null"
|
|
4041
|
+
}
|
|
4042
|
+
},
|
|
4043
|
+
"additionalProperties": false,
|
|
4044
|
+
"description": "This model represented a validation error"
|
|
4045
|
+
},
|
|
4046
|
+
"ValidateShipmentRequest": {
|
|
4047
|
+
"required": [
|
|
4048
|
+
"service_code",
|
|
4049
|
+
"ship_datetime",
|
|
4050
|
+
"is_return_label",
|
|
4051
|
+
"is_residential",
|
|
4052
|
+
"packages",
|
|
4053
|
+
"ship_to",
|
|
4054
|
+
"ship_from",
|
|
4055
|
+
"transaction_id"
|
|
4056
|
+
],
|
|
4057
|
+
"type": "object",
|
|
4058
|
+
"allOf": [
|
|
4059
|
+
{
|
|
4060
|
+
"$ref": "#/components/schemas/CreateLabelRequest"
|
|
4061
|
+
}
|
|
4062
|
+
],
|
|
4063
|
+
"additionalProperties": false
|
|
4064
|
+
},
|
|
4065
|
+
"ValidateShipmentResponse": {
|
|
4066
|
+
"type": "object",
|
|
4067
|
+
"allOf": [
|
|
4068
|
+
{
|
|
4069
|
+
"$ref": "#/components/schemas/BaseResponse"
|
|
4070
|
+
}
|
|
4071
|
+
],
|
|
4072
|
+
"properties": {
|
|
4073
|
+
"validation_errors": {
|
|
4074
|
+
"type": "array",
|
|
4075
|
+
"items": {
|
|
4076
|
+
"$ref": "#/components/schemas/ValidateShipmentError"
|
|
4077
|
+
},
|
|
4078
|
+
"description": "This is the validation results list contains list of carrier data constrain issues for requested service.",
|
|
4079
|
+
"nullable": true
|
|
4080
|
+
}
|
|
4081
|
+
},
|
|
4082
|
+
"additionalProperties": false,
|
|
4083
|
+
"description": "This model represents the successful response from carrier validate shipment data request."
|
|
4084
|
+
},
|
|
4085
|
+
"ValidationErrorCodes": {
|
|
4086
|
+
"enum": [
|
|
4087
|
+
"unspecified",
|
|
4088
|
+
"field_value_required",
|
|
4089
|
+
"invalid_field_value",
|
|
4090
|
+
"invalid_string_length",
|
|
4091
|
+
"invalid_date",
|
|
4092
|
+
"return_label_not_supported"
|
|
4093
|
+
],
|
|
4094
|
+
"type": "string",
|
|
4095
|
+
"description": "A list of standard validation error identifiers for errors the module can return"
|
|
4096
|
+
},
|
|
3984
4097
|
"VoidLabelsRequest": {
|
|
3985
4098
|
"required": [
|
|
3986
4099
|
"void_requests",
|
|
@@ -4185,6 +4298,10 @@
|
|
|
4185
4298
|
"name": "Account Setup",
|
|
4186
4299
|
"description": ""
|
|
4187
4300
|
},
|
|
4301
|
+
{
|
|
4302
|
+
"name": "Validations",
|
|
4303
|
+
"description": ""
|
|
4304
|
+
},
|
|
4188
4305
|
{
|
|
4189
4306
|
"name": "Rating",
|
|
4190
4307
|
"description": ""
|
|
@@ -9,7 +9,7 @@ export class ImporterOfRecord {
|
|
|
9
9
|
/** @description Indicates Company Name of the owner or purchaser of the products being imported into a destination country*/
|
|
10
10
|
company_name?: string;
|
|
11
11
|
/** @description Indicates address line one of the owner or purchaser of the products being imported into a destination country*/
|
|
12
|
-
address_line1
|
|
12
|
+
address_line1?: string;
|
|
13
13
|
/** @description Indicates address of the owner or purchaser of the products being imported into a destination country*/
|
|
14
14
|
address_line2?: string;
|
|
15
15
|
/** @description Indicates City or Locality of the owner or purchaser of the products being imported into a destination country */
|