Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for
Search instead for
Did you mean:
Constant Contact wants to help you succeed! We’re celebrating our professional service programs on the Constant Contact Community this month and you have a chance to try one of the services for free! Learn more.
Thanks, that's the info I came across along with some others to generate what I have. I'm searching for the v2 documentation now. If you have some preferred/recommended links to get me started please pass them along.
... View more
Thanks but that still didn't work, this is frustrating. Not opposed to using JSON but trying to find any examples that actually work is difficult. The XML was the only one I fount that was complete and had active links. Most Google searches turn up results that are 5+ years old and contain dead links within them. It'd be nice if, like other API's, there was thorough documentation that outlined exact steps with examples, options and parameters. It seems the API's for Contstant Contact are catered towards serious developers with in depth knolwedge of JSON, XML, etc. Are there any links that are active, regarding JSON, for ASP.net, and complete (as in working examples that I don't need to have multiple windows open to deipher what is being stated or that will lead me to more questions)?
... View more
I feel like I'm getting close. I've gotten some code from various sources and thus far am able to verify that I can successfully log in and as far as I can tell have the correct list id. I got that from https://constantcontact.mashery.com/io-docs. Below is my code, hoping someone can see what may be causing the error. Been working on it for a few hours, was hoping it would be simpler than this. Any assistance, ideas, active links would be appreciated. I'm translating everything to VB.net from C# Try
Dim xml As String
xml = "<?xml version='1.0' encoding='utf-8' ?>" & _
"<entry xmlns='http://www.w3.org/2005/Atom'>" & _
"<title type='text'></title>" & _
"<updated>2008-07-23T14:21:06.407Z</updated>" & _
"<author></author>" & _
"<id>data:,none</id>" & _
"<summary type='text'>Contact</summary>" & _
"<content type='application/vnd.ctct+xml'>" & _
"<Contact xmlns='http://ws.constantcontact.com/ns/1.0/'>" & _
"<EmailAddress>" & Me.txtEmail.Text.Trim & "</EmailAddress>" & _
"<OptInSource>ACTION_BY_VISITOR</OptInSource>" & _
"<ContactLists>" & _
"<ContactList id='http://api.constantcontact.com/ws/customers/[Username]/lists/[listid]'></ContactLists>" & _
"</Contact>" & _
"</content>" & _
' Set up the request
Dim request As HttpWebRequest
request = CType(WebRequest.Create("https://api.constantcontact.com/ws/customers/[Username]/contacts"), HttpWebRequest)
Dim byteData As Byte() = UTF8Encoding.UTF8.GetBytes(xml.ToString())
request.Method = "POST"
request.ContentType = "application/atom+xml"
request.ContentLength = byteData.Length
request.Credentials = New NetworkCredential("[API Key]%[Username]", "[Password]")
' Send the request
Dim postStream As Stream
postStream = request.GetRequestStream()
postStream.Write(byteData, 0, byteData.Length)
Dim response As HttpWebResponse
response = CType(request.GetResponse(), HttpWebResponse)
Catch ex As WebException
... View more