【问题标题】:How can i get the sharedmailbox mails from EWS api?如何从 EWS api 获取共享邮箱邮件?
【发布时间】:2023-03-18 15:40:02
【问题描述】:

我可以通过这个 C# 代码获取共享邮箱邮件,但我想要相同的 api。EWS 服务器是否提供这样的。

FolderId SharedMailbox = new FolderId(WellKnownFolderName.Inbox,"Shared@domain.com");
ItemView itemView = new ItemView(1000);
service.FindItems(SharedMailbox,itemView);

我看到有一些东西可以提供我的邮箱详细信息

https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/findconversation-operation

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xmlns:xsd="http://www.w3.org/2001/XMLSchema"
               xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
               xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types"
               xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages">
  <soap:Header>
    <t:RequestServerVersion Version="Exchange2010_SP1" />
  </soap:Header>
  <soap:Body>
    <m:FindConversation>
      <m:IndexedPageItemView BasePoint="Beginning" MaxEntriesReturned="1" Offset="0"/>
      <m:ParentFolderId>
        <t:DistinguishedFolderId Id ="inbox"/>
      </m:ParentFolderId>
    </m:FindConversation>
  </soap:Body>
</soap:Envelope>

我希望我的共享邮箱邮件也一样。

共享邮箱有没有类似的api?

【问题讨论】:

  • 请检查您的措辞,因为它没有意义。问题的标题与内容中的问题不匹配。

标签: c# exchange-server exchangewebservices exchange-server-2010 exchange-server-2013


【解决方案1】:

你可以使用它。您可以这样提及共享邮箱。

<?xml version="1.0" encoding="utf-8"?>
      <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                     xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"
                     xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types"
                     xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
        <soap:Header>
          <t:RequestServerVersion Version="Exchange2013" />
        </soap:Header>
        <soap:Body>
          <m:FindConversation>
            <m:IndexedPageItemView MaxEntriesReturned="1" Offset="0" BasePoint="End" />
            <m:ParentFolderId>
              <t:DistinguishedFolderId Id="inbox" >
               <t:Mailbox>
                  <t:EmailAddress>sharedmail@mail.com</t:EmailAddress>
                </t:Mailbox>
              </t:DistinguishedFolderId>
            </m:ParentFolderId>
          </m:FindConversation>
        </soap:Body>
      </soap:Envelope>

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多