【问题标题】:Set a custom header with Outlook/Office 365 REST使用 Outlook/Office 365 REST 设置自定义标题
【发布时间】:2016-07-06 08:46:26
【问题描述】:

我知道get the headers from an email with this Outlook REST 是可能的,但是我们也可以设置自定义标题吗?我似乎找不到任何文档。

【问题讨论】:

    标签: office365 outlook-restapi


    【解决方案1】:

    尝试在消息对象上设置SingleValueExtendedProperties。您可以尝试使用 PS_INTERNET_HEADERS 的属性 ID - {00020386-0000-0000-C000-000000000046}。

    使用自定义标头创建新消息可能如下所示:

    POST https://outlook.office.com/api/beta/me/messages
    
    Content-Type: application/json
    {
        ...,
        "SingleValueExtendedProperties": [
            {
                "PropertyId":"String {00020386-0000-0000-C000-000000000046} Name x-my-custom-header",
                "Value":"Some Value"
            }
        ]
    }
    

    【讨论】:

    • 工作就像一个魅力 - 只是希望这在他们的办公室 api 文档中被突出显示而不是被隐藏得很深......
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2015-10-19
    • 1970-01-01
    • 1970-01-01
    • 2023-03-26
    • 1970-01-01
    • 1970-01-01
    • 2020-01-18
    相关资源
    最近更新 更多