AnsweredAssumed Answered

Push Lead to Marketo API endpoint - format?

Question asked by 400a4f0782eb3328af3a4b79643916824d80e02c on Sep 28, 2016
Latest reply on Sep 29, 2016 by 400a4f0782eb3328af3a4b79643916824d80e02c

Hi guys

 

I'm really struggling to write to a Marketo custom field using the "Push Lead to Marketo" REST API endpoint here: http://developers.marketo.com/rest-api/endpoint-reference/lead-database-endpoint-reference/#!/Leads/pushToMarketoUsingPO…

 

I'm using Postman for the request, with this format:

 

POST request: https://(our endpoint)/rest/v1/leads/push.json?access_token=(token values here)&(field name to update)=(value for field)

 

In my headers I have: content-type application/json

For my raw body I have:

{

  "input": [

    {

      "id": 10042475

       }

  ]

,

  "programName": "(name of the program)"

}

 

I get the following error message:

 

{

  "requestId": "10a9b#157714c3515",

  "result": [

    {

      "status": "skipped",

      "reasons": [

        {

          "code": "1003",

          "message": "Field 'id' not allowed"

        }

      ]

    }

  ],

  "success": true

}

 

Why would the field "id" not be allowed? What am I missing here? Apologies, I'm not a coder by profession so I'm feeling my way around here.

 

As a side note, the documentation says that "programName" is optional, so I'm not sure why I need that (but when I remove it, I get an error that it is required).

 

Thanks, any help appreciated.

 

Phil

Outcomes