0

ARAMEX 回应

{http://ws.aramex.net/ShippingAPI/v1/}Shipment() 有一个意外的关键字参数“TransportType”。签名:Reference1: xsd:string, Reference2: xsd:string, Reference3: xsd:string, Shipper: {http://ws.aramex.net/ShippingAPI/v1/}Party, Consignee: {http://ws.aramex.net/ShippingAPI/v1/}Party, ThirdParty: {http://ws.aramex.net/ShippingAPI/v1/}Party, ShippingDateTime: xsd:dateTime, DueDate: xsd:dateTime, Comments: xsd:string, PickupLocation: xsd:string, OperationsInstructions: xsd:string, AccountingInstrcutions: xsd:string, Details: {http://ws.aramex.net/ShippingAPI/v1/}ShipmentDetails, Attachments: {http://ws.aramex.net/ShippingAPI/v1/}ArrayOfAttachment, ForeignHAWB: xsd:string, TransportType_x0020_: xsd:int, PickupGUID: xsd:string, Number: xsd:string, ScheduledDelivery: {http://ws.aramex.net/ShippingAPI/v1/}ScheduledDelivery

请求数据

request_data = {"Shipments":{"Shipment":{"Shipper":{"Reference1":"123","Reference2":"","AccountNumber":"20016","PartyAddress":{"Line1":"44 rue ariana","Line2":"","Line3":"","City":"ariana","StateOrProvinceCode":"","PostCode":"","CountryCode":"TN"},"Contact":{"Department":"","PersonName":"Tiktak","Title":"","CompanyName":"Tiktak","PhoneNumber1":"50487183","PhoneNumber1Ext":"","PhoneNumber2":"22554777","PhoneNumber2Ext":"","FaxNumber":"","CellPhone":"50487183","EmailAddress":"bouhejbazied@gmail.com","Type":""}},"Consignee":{"Reference1":"100","Reference2":"","AccountNumber":"","PartyAddress":{"Line1":"adresse","Line2":"","Line3":"","City":"tunis","StateOrProvinceCode":"","PostCode":"","CountryCode":"TN"},"Contact":{"Department":"","PersonName":"Ali","Title":"","CompanyName":"Ali","PhoneNumber1":"48777999","PhoneNumber1Ext":"","PhoneNumber2":"","PhoneNumber2Ext":"","FaxNumber":"","CellPhone":"48777999","EmailAddress":"bouhejbazied@gmail.com","Type":""}},"ThirdParty":{"Reference1":"","Reference2":"","AccountNumber":"","PartyAddress":{"Line1":"","Line2":"","Line3":"","City":"","StateOrProvinceCode":"","PostCode":"","CountryCode":""},"Contact":{"Department":"","PersonName":"","Title":"","CompanyName":"","PhoneNumber1":"","PhoneNumber1Ext":"","PhoneNumber2":"","PhoneNumber2Ext":"","FaxNumber":"","CellPhone":"","EmailAddress":"","Type":""}},"Reference1":"1","Reference2":"","Reference3":"","ForeignHAWB":"","TransportType":0,"ShippingDateTime":1604504020,"DueDate":1604504020,"PickupLocation":"","PickupGUID":"","Comments":"","AccountingInstrcutions":"","OperationsInstructions":"","Details":{"Dimensions":{"Length":"1","Width":"1","Height":"0.1","Unit":"cm"},"ActualWeight":{"Value":"0.5","Unit":"kg"},"ProductGroup":"DOM","ProductType":"FIX","PaymentType":"P","PaymentOptions":"","Services":"CODS","NumberOfPieces":1,"DescriptionOfGoods":"","GoodsOriginCountry":"TN","CashOnDeliveryAmount":{"Value":"99.8","CurrencyCode":"TND"},"InsuranceAmount":{"Value":0,"CurrencyCode":""},"CollectAmount":{"Value":"","CurrencyCode":""},"CashAdditionalAmount":{"Value":0,"CurrencyCode":""},"CashAdditionalAmountDescription":"","CustomsValueAmount":{"Value":0,"CurrencyCode":""},"Items":[]}}},"ClientInfo":{"AccountCountryCode":"JO","AccountEntity":"AMM","AccountNumber":"20016","AccountPin":"331421","UserName":"reem@reem.com","Password":"123456789","Version":"v1.0"},"Transaction":{"Reference1":"1","Reference2":"","Reference3":"","Reference4":"","Reference5":""},"LabelInfo":{"ReportID":9737,"ReportType":"URL"}}

WSDL 使用 https://ws.dev.aramex.net/ShippingAPI.V2/Shipping/Service_1_0.svc?wsdl

使用 ZEEP 包发送的请求

client = Client(wsdl)
response = client.service['CreateShipments'](**request_data) ```
4

0 回答 0