8

Trying to update a data field on a lead record in Marketo. Using C#. I send:

{"action":"updateOnly","input":[{"email":"dfranks@gmail.com","leadQuality":"Hot"}]}

And get back:

{"requestId":"d98e#14b2d7dd1f3","success":false,"errors":[{"code":"612","message":"Invalid Content Type"}]}

Why the Invalid Content type message? The field leadQuality is legit. The email address exists. I've tried a number of different fields and always the same message. Access token is good too.

StephenKing
  • 36,187
  • 11
  • 83
  • 112
Dean Wooldridge
  • 223
  • 1
  • 3
  • 5

2 Answers2

6

Content-Type is a HTTP header. Usually, you set it to application/json for REST calls.

You should do this in the code where you generate the HTTP request or REST call.

I found text/json as Content-Type and Accept header value in one of the marketo examples. You might try one of the two choices.

StephenKing
  • 36,187
  • 11
  • 83
  • 112
0

Here are a couple of things to check:

  1. As @StephenKing mentioned, I would check that your Content-Type HTTP Header is set to "application/json".

  2. I would also confirm that the custom field you created for "leadQuality" has a String data type.

enter image description here

Murtza Manzur
  • 1,224
  • 1
  • 8
  • 12