ExactTarget REST API – Error Code 10006, no details

I’m trying to post data into an DX using the Fuel API, specifically as described here. This worked for a prior DX, but I was asked to change to a different one, where I’m receiving a rather unhelpful error message.

Headers

{'Content-Length': u'133', 'accept-language': 'en-us', 'Accept-Encoding':
'gzip, deflate, compress', 'accept': '*/*', 'User-Agent':
'python-requests/1.2.3 CPython/2.7.6 Darwin/14.0.0', 'content-type':
'application/json', 'Authorization': 'Bearer bearer-token-goes-here'}

Body

[
  {
    "keys": {
      "email": "<a href="https://getridbug.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="ed87828583c3898288ad99889e99c38e8280">[email protected]</a>"
    },
    "values": {
      "lastName": "Doe",
      "IP_Address": "127.0.0.1",
      "firstName": "John"
    }
  }
]

Response (400/Bad Request)

{
  "message": "Unable to save rows for data extension ID
dx-id-goes-here",
  "errorcode": 10006,
  "documentation": ""
}

An error code of 10006 is unfortunately missing from their documentation, and there is no further message in the body. I accept that the issue may be in what I’m sending or my DX configuration, but I’m able to update it with the same data manually via Marketing Cloud UI, and at any rate am given really nowhere to look next.

Answers:

Thank you for visiting the Q&A section on Magenaut. Please note that all the answers may not help you solve the issue immediately. So please treat them as advisements. If you found the post helpful (or not), leave a comment & I’ll get back to you as soon as possible.

Method 1

After speaking with support, the error was due to the API key I have not having rights to the context/business unit where the Data Extension lived (I didn’t set it up and from what I can tell the business unit can’t be seen/edited once created). I created a new API client app in App Center with the correct business unit and this resolves the issue!

Method 2

Updated link to error docs in their Marketing Cloud API (ExactTarget was renamed to Marketing Cloud when Salesforce made the acquisition)

The code now exists in their docs. It means ‘there are other errors in the response’ that you can check. I’m not always seeing other errors to in the response as it claims. But, when there are other errors, it is reporting (in my case) that I have a data type issue with one of my variables.


All methods was sourced from stackoverflow.com or stackexchange.com, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0

0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x