我使用 Exchange Server 2010 托管 EWS 托管 API。当我执行请求 FindItem 时,我从服务器收到错误 - “ErrorIncorrectSchemaVersion” “请求有效,但未在 RequestServerVersion SOAP 标头中指定正确的服务器版本。确保使用正确的 RequestServerVersionValue 设置 RequestServerVersion SOAP 标头。” 但在 XML 中,我将 RequestServerVersionValue 指定为 Exchange2010。我还尝试指定 Exchange2007、Exchange2007_SP1、Exchange2010_SP1,但没有任何改变。
<?xml version="1.0" ?>
- <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <SOAP-ENV:Body>
- <FindItem xmlns="http://schemas.microsoft.com/exchange/services/2006/messages" Traversal="Shallow">
- <ItemShape>
<BaseShape xmlns="http://schemas.microsoft.com/exchange/services/2006/types">IdOnly</BaseShape>
</ItemShape>
<IndexedPageItemView MaxEntriesReturned="100" Offset="0" BasePoint="Beginning" />
- <ParentFolderIds>
- <DistinguishedFolderId xmlns="http://schemas.microsoft.com/exchange/services/2006/types" Id="calendar">
- <Mailbox>
<EmailAddress>test@test1.com</EmailAddress>
</Mailbox>
</DistinguishedFolderId>
</ParentFolderIds>
</FindItem>
- <ExchangeImpersonation xmlns="http://schemas.microsoft.com/exchange/services/2006/types">
- <ConnectingSID>
<PrimarySmtpAddress>test@test1.com</PrimarySmtpAddress>
</ConnectingSID>
</ExchangeImpersonation>
<MailboxCulture xmlns="http://schemas.microsoft.com/exchange/services/2006/types">US-en</MailboxCulture>
<RequestServerVersion xmlns="http://schemas.microsoft.com/exchange/services/2006/types" Version="Exchange2010" />
- <TimeZoneContext xmlns="http://schemas.microsoft.com/exchange/services/2006/types">
- <TimeZoneDefinition Id="FLE Standard Time">
- <Periods>
<Period Id="FLE Standard Time" />
</Periods>
</TimeZoneDefinition>
</TimeZoneContext>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>