Я пытаюсь реализовать API FedEx.Я успешно запустил PickupAvailability с версией v17, но при создании создания возникла ошибка аутентификации с той же схемой.
Я использую XML, созданный с использованием документов, и отправляю его в Postman.Код:
<ns:CreatePickupRequest xsi:schemaLocation ="https://www.fedex.com/us/developer/downloads/xml/2018/advanced/ShipService_v23.xsd" xmlns:ns ="http://fedex.com/ws/pickup/v17" xmlns:xsi ="http://www.w3.org/2001/XMLSchema-instance">
<ns:WebAuthenticationDetail>
<ns:UserCredential>
<ns:Key>XXXXXX</ns:Key>
<ns:Password>XXXX</ns:Password>
</ns:UserCredential>
</ns:WebAuthenticationDetail>
<ns:ClientDetail>
<ns:AccountNumber>XXX</ns:AccountNumber>
<ns:MeterNumber>XXXX</ns:MeterNumber>
<ns:Localization>
<ns:LanguageCode>EN</ns:LanguageCode>
<ns:LocaleCode>ES</ns:LocaleCode>
</ns:Localization>
</ns:ClientDetail>
<ns:TransactionDetail>
<ns:CustomerTransactionId>123456789</ns:CustomerTransactionId>
<ns:Localization>
<ns:LanguageCode>EN</ns:LanguageCode>
<ns:LocaleCode>ES</ns:LocaleCode>
</ns:Localization>
</ns:TransactionDetail>
<ns:Version>
<ns:ServiceId>pickup</ns:ServiceId>
<ns:Major>17</ns:Major>
<ns:Intermediate>0</ns:Intermediate>
<ns:Minor>0</ns:Minor>
</ns:Version>
<ns:OriginDetail>
<ns:PickupLocation>
<ns:Contact>
<ns:ContactId>123456</ns:ContactId>
<ns:PersonName>XXX</ns:PersonName>
<ns:Title>Mr.</ns:Title>
<ns:CompanyName>XXXX</ns:CompanyName>
<ns:PhoneNumber>XXXXXX</ns:PhoneNumber>
<ns:EMailAddress>XXXX</ns:EMailAddress>
</ns:Contact>
<ns:Address>
<ns:StreetLines>My Address</ns:StreetLines>
<ns:City>My City</ns:City>
<ns:StateOrProvinceCode>MD</ns:StateOrProvinceCode>
<ns:PostalCode>XX</ns:PostalCode>
<ns:CountryCode>US</ns:CountryCode>
</ns:Address>
</ns:PickupLocation>
<ns:PackageLocation>FRONT</ns:PackageLocation>
<ns:BuildingPart>DEPARTMENT</ns:BuildingPart>
<ns:BuildingPartDescription>BuildingPartDescription</ns:BuildingPartDescription>
<ns:ReadyTimestamp>T17:41:24-06:00</ns:ReadyTimestamp>
<ns:CompanyCloseTime>17:00:00</ns:CompanyCloseTime>
<ns:Location>NQAA</ns:Location>
<ns:SuppliesRequested>SuppliesRequested</ns:SuppliesRequested>
</ns:OriginDetail>
<ns:PackageCount>1</ns:PackageCount>
<ns:TotalWeight>
<ns:Units>LB</ns:Units>
<ns:Value>5</ns:Value>
</ns:TotalWeight>
<ns:CarrierCode>FDXE</ns:CarrierCode>
<ns:OversizePackageCount>0</ns:OversizePackageCount>
<ns:Remarks>test remark</ns:Remarks>
<ns:CommodityDescription>TEST ENVIRONMENT -PLEASE DO NOT PROCESS PICKUP</ns:CommodityDescription>
<ns:CountryRelationship>DOMESTIC</ns:CountryRelationship>
</ns:CreatePickupRequest>
ответ: -
<v17:CreatePickupReply xmlns:v17="http://fedex.com/ws/pickup/v17">
<v17:HighestSeverity>ERROR</v17:HighestSeverity>
<v17:Notifications>
<v17:Severity>ERROR</v17:Severity>
<v17:Source>prof</v17:Source>
<v17:Code>1000</v17:Code>
<v17:Message>Authentication Failed</v17:Message>
</v17:Notifications>
<v17:TransactionDetail>
<v17:CustomerTransactionId>123456789</v17:CustomerTransactionId>
<v17:Localization>
<v17:LanguageCode>EN</v17:LanguageCode>
<v17:LocaleCode>ES</v17:LocaleCode>
</v17:Localization>
</v17:TransactionDetail>
<v17:Version>
<v17:ServiceId>pickup</v17:ServiceId>
<v17:Major>17</v17:Major>
<v17:Intermediate>0</v17:Intermediate>
<v17:Minor>0</v17:Minor>
</v17:Version>
Я пытаюсь аутентифицироваться так же, как PickupAvailability