douya2982 2018-11-27 08:08
浏览 66

获取消息ID作为响应 - SendGrid API v3

I am getting this response when I submit an email, as I am working on the API of SendGrid I need to grab the stats of each mail i sent.. for that purpose I want the Message-ID in response so I could save that in db.. I have looked over the docs but unable to make any progress.. Thanks in Advance

P.S : does X-Message-Id could help in this ? if yes than how.. below is the url of doc from where we can retrive mails

https://sendgrid.api-docs.io/v3.0/email-activity/filter-all-messages

  1. Array
  2. (
  3. [0] => HTTP/1.1 202 Accepted
  4. [1] => Server: nginx
  5. [2] => Date: Tue, 27 Nov 2018 15:59:04 GMT
  6. [3] => Content-Type: text/plain; charset=utf-8
  7. [4] => Content-Length: 0
  8. [5] => Connection: keep-alive
  9. [6] => X-Message-Id: -ekBjiGXRNi7l5OdjBRcRA
  10. [7] => Access-Control-Allow-Origin: https://sendgrid.api-docs.io
  11. [8] => Access-Control-Allow-Methods: POST
  12. [9] => Access-Control-Allow-Headers: Authorization, Content-Type, On-behalf-of, x-sg-elas-acl
  13. [10] => Access-Control-Max-Age: 600
  14. [11] => X-No-CORS-Reason: https://sendgrid.com/docs/Classroom/Basics/API/cors.html
  15. [12] =>
  16. [13] =>
  17. )
  • 写回答

1条回答 默认 最新

  • dsla94915 2019-05-05 19:57
    关注

    It is exactly what you're looking for. Use the X-Message-Id header.

    评论
    编辑
    预览

    报告相同问题?

    手机看
    程序员都在用的中文IT技术交流社区

    程序员都在用的中文IT技术交流社区

    专业的中文 IT 技术社区,与千万技术人共成长

    专业的中文 IT 技术社区,与千万技术人共成长

    关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

    关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

    客服 返回
    顶部