karrio-sapient 2025.5rc12__py3-none-any.whl → 2025.5rc14__py3-none-any.whl
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.
- karrio/providers/sapient/shipment/create.py +15 -14
- {karrio_sapient-2025.5rc12.dist-info → karrio_sapient-2025.5rc14.dist-info}/METADATA +1 -1
- {karrio_sapient-2025.5rc12.dist-info → karrio_sapient-2025.5rc14.dist-info}/RECORD +6 -6
- {karrio_sapient-2025.5rc12.dist-info → karrio_sapient-2025.5rc14.dist-info}/WHEEL +0 -0
- {karrio_sapient-2025.5rc12.dist-info → karrio_sapient-2025.5rc14.dist-info}/entry_points.txt +0 -0
- {karrio_sapient-2025.5rc12.dist-info → karrio_sapient-2025.5rc14.dist-info}/top_level.txt +0 -0
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"""Karrio SAPIENT shipment API implementation."""
|
|
2
2
|
|
|
3
|
+
from re import L
|
|
3
4
|
import karrio.schemas.sapient.shipment_requests as sapient
|
|
4
5
|
import karrio.schemas.sapient.shipment_response as shipping
|
|
5
6
|
|
|
@@ -112,12 +113,12 @@ def shipment_request(
|
|
|
112
113
|
),
|
|
113
114
|
Shipper=sapient.ShipperType(
|
|
114
115
|
Address=sapient.AddressType(
|
|
115
|
-
ContactName=shipper.contact or "N/A",
|
|
116
|
-
CompanyName=shipper.company_name,
|
|
116
|
+
ContactName=lib.text(shipper.contact or "N/A", max=40),
|
|
117
|
+
CompanyName=lib.text(shipper.company_name, max=40),
|
|
117
118
|
ContactEmail=shipper.email,
|
|
118
119
|
ContactPhone=shipper.phone_number,
|
|
119
|
-
Line1=shipper.address_line1,
|
|
120
|
-
Line2=shipper.address_line2,
|
|
120
|
+
Line1=lib.text(shipper.address_line1, max=40),
|
|
121
|
+
Line2=lib.text(shipper.address_line2, max=40),
|
|
121
122
|
Line3=None,
|
|
122
123
|
Town=shipper.city,
|
|
123
124
|
Postcode=shipper.postal_code,
|
|
@@ -129,7 +130,7 @@ def shipment_request(
|
|
|
129
130
|
or options.connection_config.mailer_id.state
|
|
130
131
|
),
|
|
131
132
|
ShippingLocationId=None,
|
|
132
|
-
Reference1=payload.reference,
|
|
133
|
+
Reference1=lib.text(payload.reference, max=30),
|
|
133
134
|
DepartmentNumber=None,
|
|
134
135
|
EoriNumber=customs.options.eori_number.state,
|
|
135
136
|
VatNumber=lib.identity(
|
|
@@ -138,12 +139,12 @@ def shipment_request(
|
|
|
138
139
|
),
|
|
139
140
|
Destination=sapient.DestinationType(
|
|
140
141
|
Address=sapient.AddressType(
|
|
141
|
-
ContactName=recipient.contact or "N/A",
|
|
142
|
-
CompanyName=recipient.company_name,
|
|
142
|
+
ContactName=lib.text(recipient.contact or "N/A", max=40),
|
|
143
|
+
CompanyName=lib.text(recipient.company_name, max=40),
|
|
143
144
|
ContactEmail=recipient.email,
|
|
144
145
|
ContactPhone=recipient.phone_number,
|
|
145
|
-
Line1=recipient.address_line1,
|
|
146
|
-
Line2=recipient.address_line2,
|
|
146
|
+
Line1=lib.text(recipient.address_line1, max=40),
|
|
147
|
+
Line2=lib.text(recipient.address_line2, max=40),
|
|
147
148
|
Line3=None,
|
|
148
149
|
Town=recipient.city,
|
|
149
150
|
Postcode=recipient.postal_code,
|
|
@@ -170,12 +171,12 @@ def shipment_request(
|
|
|
170
171
|
ReturnToSender=lib.identity(
|
|
171
172
|
sapient.ReturnToSenderType(
|
|
172
173
|
Address=sapient.AddressType(
|
|
173
|
-
ContactName=return_address.contact or "N/A",
|
|
174
|
-
CompanyName=return_address.company_name,
|
|
174
|
+
ContactName=lib.text(return_address.contact or "N/A", max=40),
|
|
175
|
+
CompanyName=lib.text(return_address.company_name, max=40),
|
|
175
176
|
ContactEmail=return_address.email,
|
|
176
177
|
ContactPhone=return_address.phone_number,
|
|
177
|
-
Line1=return_address.address_line1,
|
|
178
|
-
Line2=return_address.address_line2,
|
|
178
|
+
Line1=lib.text(return_address.address_line1, max=40),
|
|
179
|
+
Line2=lib.text(return_address.address_line2, max=40),
|
|
179
180
|
Line3=None,
|
|
180
181
|
Town=return_address.city,
|
|
181
182
|
Postcode=return_address.postal_code,
|
|
@@ -217,7 +218,7 @@ def shipment_request(
|
|
|
217
218
|
HSCode=item.hs_code,
|
|
218
219
|
CountryOfOrigin=item.origin_country,
|
|
219
220
|
)
|
|
220
|
-
for
|
|
221
|
+
for item in commodities
|
|
221
222
|
],
|
|
222
223
|
Customs=lib.identity(
|
|
223
224
|
sapient.CustomsType(
|
|
@@ -13,15 +13,15 @@ karrio/providers/sapient/pickup/create.py,sha256=5S-h9qQuDFqxvqrmd2l0-SGQMi86O38
|
|
|
13
13
|
karrio/providers/sapient/pickup/update.py,sha256=rG4du0Ey_w3AaA2db46nKLMPKTCYokZlfofRQwZ83P0,2796
|
|
14
14
|
karrio/providers/sapient/shipment/__init__.py,sha256=DMPIljx1L1FvlatOITGSsfSGovv-NLW7ydT7SDlDIEE,231
|
|
15
15
|
karrio/providers/sapient/shipment/cancel.py,sha256=4p1KyMmyasy5wKCfVGGW2I0AWClbX5FbjhhkYD0zymc,1698
|
|
16
|
-
karrio/providers/sapient/shipment/create.py,sha256=
|
|
16
|
+
karrio/providers/sapient/shipment/create.py,sha256=dd5zperC7oLu9thXe__vqlQKTL757bIc-YvBtgC6g4c,10018
|
|
17
17
|
karrio/schemas/sapient/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
18
18
|
karrio/schemas/sapient/error_response.py,sha256=43gmiRdi5y2I1qn1OfuR9f30JTld6I5lgtzpjIOEUpQ,384
|
|
19
19
|
karrio/schemas/sapient/pickup_request.py,sha256=gzZZ3Bxr_pYWxw28vDRr-aDgtzJIQptUkaTEzXhX96g,235
|
|
20
20
|
karrio/schemas/sapient/pickup_response.py,sha256=xcl3ofB2L2RNksMSRccvFbBdBcK1hVDDPVB-oAu4I54,195
|
|
21
21
|
karrio/schemas/sapient/shipment_requests.py,sha256=roKQ4iFkm6BKzI_b8TL39ZcsKWU61LVN7oRh_lyb75k,4574
|
|
22
22
|
karrio/schemas/sapient/shipment_response.py,sha256=457ULt-exxAJ0Drqn2Pnj9pl_4JWMZ-cesuJW9NWBAs,702
|
|
23
|
-
karrio_sapient-2025.
|
|
24
|
-
karrio_sapient-2025.
|
|
25
|
-
karrio_sapient-2025.
|
|
26
|
-
karrio_sapient-2025.
|
|
27
|
-
karrio_sapient-2025.
|
|
23
|
+
karrio_sapient-2025.5rc14.dist-info/METADATA,sha256=6TY3iN5_K3ps7LSWshahH2RCx-2APL8pQCcwiFN5ggk,993
|
|
24
|
+
karrio_sapient-2025.5rc14.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
25
|
+
karrio_sapient-2025.5rc14.dist-info/entry_points.txt,sha256=rPF-WjVKk-3suhX4-zi9hTkwr0Qxb4ZW-Tjoyzi_Cy8,59
|
|
26
|
+
karrio_sapient-2025.5rc14.dist-info/top_level.txt,sha256=FZCY8Nwft8oEGHdl--xku8P3TrnOxu5dETEU_fWpRSM,20
|
|
27
|
+
karrio_sapient-2025.5rc14.dist-info/RECORD,,
|
|
File without changes
|
{karrio_sapient-2025.5rc12.dist-info → karrio_sapient-2025.5rc14.dist-info}/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|