Master email marketing fundamentals. Join the Ready, Set, Send Challenge Week 2!

409 conflict error even when passing in unmodified data

SOLVED
Go to solution
WalterB41
Rookie
0 Votes

I successfully replicated this problem using the API tester:

 

I use the "Retrieve a contact with a specified Contact ID" endpoint:

https://api.constantcontact.com/v2/contacts/xxxxx?api_key=yyyyyy

 

In most cases, I can copy the result body and paste it in (unmodified!) as the request body for the endpoint "Modify a contact with specific Contact ID"

 

https://api.constantcontact.com/v2/contacts/xxxxx?action_by=ACTION_BY_OWNER&api_key=yyyyyy

 

In about 90% of test cases, this works successfully.  In the remaining 10%, I get:

Response StatusSelect content

409 Conflict

Response HeadersSelect content

Cache-Control: private, no-cache, no-store, max-age=0, must-revalidate, no-cache="Set-Cookie"
Content-Type: application/json
Date: Thu, 17 Mar 2016 01:09:53 GMT
Pragma: no-cache
Server: Apache
Vary: Accept-Encoding,User-Agent
X-Mashery-Responder: prod-j-worker-us-east-1e-114.mashery.com
X-Powered-By: 
Content-Length: 130
Connection: keep-alive

Response BodySelect content

[{
   
"error_key": "http.status.conflict",
   
"error_message": "There was a conflict between the supplied data and the existing resource."
}]

 Is there a reason why this would be?  My actual use case is more complex, but I created this simple test case to eliminate any other variables.

 

Jon

1 ACCEPTED SOLUTION
Elijah_G
Marketing Legend

Hello,

 

In the case of a conflict when sending unmodified data, the most likely cause is a contact in a Confirmed state. This is because the PUT action always updates a field, even if the input is the same as the previous value, and the email address of a Confirmed contact can only be changed with an action by that contact. If you're working on an implementation that handles groups of contacts, I would definitely advise making use of our bulk APIs, as they do not have this same limitation as a result of being unable to change email addresses.

 

You can find information about our bulk APIs here: http://developer.constantcontact.com/docs/bulk_activities_api/bulk-activities-import-contacts.html

 

Sincerely,

Elijah G.
API Support Engineer

View solution in original post

1 REPLY 1
Elijah_G
Marketing Legend

Hello,

 

In the case of a conflict when sending unmodified data, the most likely cause is a contact in a Confirmed state. This is because the PUT action always updates a field, even if the input is the same as the previous value, and the email address of a Confirmed contact can only be changed with an action by that contact. If you're working on an implementation that handles groups of contacts, I would definitely advise making use of our bulk APIs, as they do not have this same limitation as a result of being unable to change email addresses.

 

You can find information about our bulk APIs here: http://developer.constantcontact.com/docs/bulk_activities_api/bulk-activities-import-contacts.html

 

Sincerely,

Elijah G.
API Support Engineer
Resources
Developer Portal

View API documentation, code samples, get your API key.

Visit Page

Announcements

API Updates

Join our list to be notified of new features and updates to our V3 API.

Sign Up