2 Replies Latest reply on Nov 3, 2014 9:08 PM by 53504

    Using the REST API to update leads, got "field not found" error

      We have custom fields for leads like UTM Source and UTM Medium.

      I want to use the REST API to update these fields for leads.

      I tried using the /rest/v1/leads.json endpoint with this request:

      POST /rest/v1/leads.json HTTP/1.1
      Content-Type: application/json
      Authorization: Bearer TOKEN
      {"action":"updateOnly","lookupField":"id","input":[{"id":LEAD_ID,"UTM Medium":"MEDIUM","UTM Source":"SOURCE"}]}

      But I got this response saying the fields were not found:

      {"requestId"=>"143e9#1497880b900",
       "result"=>
        [{"status"=>"skipped",
          "reasons"=>
           [{"code"=>"1006", "message"=>"Field 'UTM Medium' not found"},
            {"code"=>"1006", "message"=>"Field 'UTM Source' not found"}]}],
       "success"=>true}