Marketo REST API - CustomObjects filtering not working as expected | Community
Skip to main content
Level 2
August 13, 2024
Question

Marketo REST API - CustomObjects filtering not working as expected

  • August 13, 2024
  • 1 reply
  • 644 views

Filtering CustomObjects with multiple values using the "input" parameter results in duplicate records.

Example:

Executing this request, where the value "myTestLC" is provided twice  results in 3 custom object results, 2 of which are duplicates.

 

{ "fields": ["CreatedAt","MarketoGUID","UpdatedAt","Check123"], "filterType": "Check123", "input": [ { "Check123": "myTestLC" }, { "Check123": "myTestLC" }, { "Check123": "myTestLC2" } ] }

 

 Results:

 

{ "requestId": "5ac3#19136337ab7", "result": [ { "seq": 0, "marketoGUID": "f2b54589-f283-49cc-a891-e0324fc4ad65", "check123": "myTestLC", "createdAt": "2024-08-09T08:12:04Z", "updatedAt": "2024-08-09T08:12:04Z" }, { "seq": 1, "marketoGUID": "f2b54589-f283-49cc-a891-e0324fc4ad65", "check123": "myTestLC", "createdAt": "2024-08-09T08:12:04Z", "updatedAt": "2024-08-09T08:12:04Z" }, { "seq": 2, "marketoGUID": "f1f677bd-0960-4d12-a4e0-f418d4d71b6f", "check123": "myTestLC2", "createdAt": "2024-08-09T08:12:16Z", "updatedAt": "2024-08-09T08:12:16Z" } ], "success": true }

 

 

Is this expected behavior that we should consider, or a bug in the API?
Note: other endpoints behave properly when filtering with multiple values and do not return duplicate records.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

SanfordWhiteman
Level 10
August 13, 2024
That's expected behavior. You didn't deduplicate first, so you shouldn't expect deduped results. Some endpoints behave differently from others, but the outcome is unknown if you don't dedupe.