Sendgrid邮件新c#客户端已损坏?

Sendgrid邮件新c#客户端已损坏?,c#,sendgrid,C#,Sendgrid,我理解这一突破性的变化: 使用新的SendGridMessage()而不是SendGrid.GetInstance() 但是,在执行以下操作时: var transportWeb = Web.GetInstance(credentials); 我被告知GetInstance不存在 发生什么事了?我遗漏了什么吗?对不起,在更新的文档中遗漏了这个。您还需要使用Web类型的构造函数,而不是旧的工厂方法 // Create an Web transport for sending email. var

我理解这一突破性的变化:

使用新的SendGridMessage()而不是SendGrid.GetInstance()

但是,在执行以下操作时:

var transportWeb = Web.GetInstance(credentials);
我被告知GetInstance不存在


发生什么事了?我遗漏了什么吗?

对不起,在更新的文档中遗漏了这个。您还需要使用
Web
类型的构造函数,而不是旧的工厂方法

// Create an Web transport for sending email.
var transportWeb = new Web(credentials);
这个问题现在也解决了。谢谢