2011-04-27 75 views

回答

14

在PerceptiveMCAPI看看CodePlex上:

PerceptiveMCAPI - 一個.NET友好 包裝爲MailChimp API中的C#通過感知邏輯寫 。

http://perceptivemcapi.codeplex.com/

+1

這裏是一個使用ASP.NET MVC 3和PerceptiveMCAPI一個例子起始站點:https://github.com/otint/MailChimp-MVC3-PerceptiveMCAPI – Omri 2012-03-16 18:18:45

+0

我覺得PerceptiveMCAPI似乎不支持MCAPI 1.3。 ..有沒有更好的選擇...? – bhargav 2012-04-03 10:08:34

+0

PerceptiveMCAPI 1.3.0支持MCAPI 1.3,它已經在一年多的時間裏進行了兩次修訂,並且運行良好。 – furtive 2012-09-06 22:53:50

4

你可以在CodePlex上試試這個:

mcapinet

5

嘗試使用mailchimp的最新服務 - 山魈(事務的電子郵件服務)

您可以通過標準的SMTP使用它或api。

http://mandrillapp.com/

15

下面的例子將發送一個選擇的電子郵件:

首先安裝NuGet包:安裝,包裝mcapi.net

static void Main(string[] args) 
    { 
     const string apiKey = "6ea5e2e61844608937376d514-us2"; // Replace it before 
     const string listId = "y657cb2495";      // Replace it before 

     var options = new List.SubscribeOptions(); 
     options.DoubleOptIn = true; 
     options.EmailType = List.EmailType.Html; 
     options.SendWelcome = false; 

     var mergeText = new List.Merges("[email protected]", List.EmailType.Text) 
        { 
         {"FNAME", "John"}, 
         {"LNAME", "Smith"} 
        }; 
     var merges = new List<List.Merges> { mergeText }; 

     var mcApi = new MCApi(apiKey, false); 
     var batchSubscribe = mcApi.ListBatchSubscribe(listId, merges, options); 

     if (batchSubscribe.Errors.Count > 0) 
      Console.WriteLine("Error:{0}", batchSubscribe.Errors[0].Message); 
     else 
      Console.WriteLine("Success"); 

     Console.ReadKey(); 
    } 
+1

這應該是正確的答案。迄今爲止最快和最簡單的方法。 – 2013-07-23 03:25:14

+1

我不認爲這是可能了,不幸的是... – 2015-06-29 13:50:15

+0

提琴手錶示這是發送到v1.3的API和3.0現在住現有的版本將不會在2016年後支持。哦,它沒有出現工作無論如何 – wal 2016-10-19 12:17:03

2

通過丹 - 執行 - 檢查出https://github.com/danesparza/MailChimp.NET Esparza 您可以使用軟件包管理器控制檯安裝軟件包

Install-Package MailChimp.NET

代碼示例

MailChimpManager mc = new MailChimpManager("YourApiKeyHere-us2"); 
ListResult lists = mc.GetLists();

對於電子郵件發送和統計,Mailchimp提供山魈通過肖恩·麥克萊恩https://github.com/shawnmclean/Mandrill-dotnet

您可以使用山魈安裝

Install-Package Mandrill

代碼示例

MandrillApi api = new MandrillApi("xxxxx-xxxx-xxxx-xxxx"); 
UserInfo info = await api.UserInfo();
+0

Dan Esparza現在在該項目頁面上有一個註釋,用於檢查Brandon Seydel的v3(由Pranav的回答指出),因爲這僅適用於已棄用的v2.0 API。 – ahwm 2017-05-26 16:31:19

4

的支持最新郵件黑猩猩3.0 API的,你可以找到包裝爲.NET:

MailChimp.Net - 郵件黑猩猩3。0包裝

https://github.com/brandonseydel/MailChimp.Net

+1

支持最新的API和100%的覆蓋率,謝謝 – 2017-02-21 15:09:17