mailchimp-api-v3.0

Calling MailChimp API v3.0 with .Net

跟風遠走 提交于 2019-11-28 23:50:59
I'm trying to access our MailChimp account via the new 3.0 REST API. I've done the following: using(var http = new HttpClient()) { var creds = Convert.ToBase64String(Encoding.ASCII.GetBytes("username:mailchimpapikey-us1")); http.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Basic", creds); string content = await http.GetStringAsync(@"https://us1.api.mailchimp.com/3.0/lists"); Console.WriteLine(content); } However, when I run this code, I get a 401 error with the following json details: {"type":"http://kb.mailchimp.com/api/error-docs/401-api-key-invalid","title":"API Key

Calling MailChimp API v3.0 with .Net

陌路散爱 提交于 2019-11-27 21:25:54
问题 I'm trying to access our MailChimp account via the new 3.0 REST API. I've done the following: using(var http = new HttpClient()) { var creds = Convert.ToBase64String(Encoding.ASCII.GetBytes("username:mailchimpapikey-us1")); http.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Basic", creds); string content = await http.GetStringAsync(@"https://us1.api.mailchimp.com/3.0/lists"); Console.WriteLine(content); } However, when I run this code, I get a 401 error with the

Create a basic MailChimp signup form using their API

非 Y 不嫁゛ 提交于 2019-11-27 10:04:51
I'm new to MailChimp and need some help. With their basic newsletter signup form... you simply embed some prepackaged HTML into your page. However the problem with this is that clicking on submit redirects to a MailChimp page. ( I don't want to redirect to MailChimp, I want the user to stay on own website after hitting submit. ) They provide an API and plenty of documentation but just about zero useful examples. The API is supposed to allow me to do a full integration with my site or application. It seems that when I read something in their docs that applies to me, I click the link to get more

Adding subscribers to a list using Mailchimp's API v3

点点圈 提交于 2019-11-26 23:41:37
I'm trying to add users to a list I've created in Mailchimp but I can't find any code examples anywhere. I've tried figuring out how to use the API but I'm very much a "Look at an example and learn" kind of person. I've tried using version 2 of the API but nothing seems to be working despite working from examples on the net and Mailchimp says the following about earlier versions of their API on their website: Versions 2.0 and earlier are deprecated. Only minimal support—bug fixes, security patches—will be available for those versions. UPDATE 1 : I did some further research based on TooMuchPete

Create a basic MailChimp signup form using their API

十年热恋 提交于 2019-11-26 17:54:57
问题 I'm new to MailChimp and need some help. With their basic newsletter signup form... you simply embed some prepackaged HTML into your page. However the problem with this is that clicking on submit redirects to a MailChimp page. ( I don't want to redirect to MailChimp, I want the user to stay on own website after hitting submit. ) They provide an API and plenty of documentation but just about zero useful examples. The API is supposed to allow me to do a full integration with my site or