Script/program/tool for iterative Activities extraction via API

Robert_Kelen3
Level 4

Script/program/tool for iterative Activities extraction via API

I'm wondering if folks have preferred tools for doing something similar to David Everly​'s excellent shell script for retrieving activity data via API? That script actually does everything I'd like to accomplish (with support for both any activity type, and narrowing by listId), yet jq regularly fails on certain undesirables in Marketo JSON data ('parse error: Invalid string: control characters from U+0000 through U+001F...').

This python tool GitHub - kioy/MarketoExportActivities: Exporting lead activities via Marketo REST API is also quite useful, but is currently coded to only handle certain activity types.

Thanks.

Robert

2 REPLIES 2
SanfordWhiteman
Level 10 - Community Moderator

Re: Script/program/tool for iterative Activities extraction via API

yet jq regularly fails on certain undesirables in Marketo JSON data ('parse error: Invalid string: control characters from U+0000 through U+001F...').

It's not valid JSON if it has unescaped control characters. Are you sure this is actually coming from Marketo? Can you post a raw HTTP trace that has these characters in the response?

Robert_Kelen3
Level 4

Re: Script/program/tool for iterative Activities extraction via API