SOLVED

Unperseable JSON value for the Bulk Export of activity - Unsubscribe Email/Fill Out Form

Go to solution
Highlighted

Unperseable JSON value for the Bulk Export of activity - Unsubscribe Email/Fill Out Form

Getting unparseable json for the attribute "Form Fields"  while calling API for the activity - Unsubscribe Email/Fill Out Form.

Example-

ActivityTypeId - 2,9

API - /bulk/v1/activities/export/{exportId}/file.json

method - GET

Response - CSV

 This contains one column called - "attributes" which contains below json-

{
   "Client IP Address": "Masked IP",
   "Query Parameters": "",
   "Referrer URL": "Masked URL",
   "User Agent": "Masked User Agent",
   "Webpage ID": 1,
     "Form Fields": "a:5:{s:6:\"module\";s:11:\"something\";s:6:\"action\";s:5:\"some action\";s:9:\"FirstName\";s:6:\"Some       First Name\";s:8:\"LastName\";s:5:\"Some Last       Name\";s:13:\"_mktoReferrer\";s:59:\"https://some.something.com/abc.html\";}"
}

  • Please let us know how to parse this value of Form Fields to a json.
  • Is there any parser or sample code available in marketo for this?
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Level 10 - Community Moderator

Re: Unperseable JSON value for the Bulk Export of activity - Unsubscribe Email/Fill Out Form

That's a valid JSON string (so I wouldn't refer to this as "unparseable JSON", it never claims to be JSON-in-JSON).

Internally it's in PHP object serialization format. There is likely a decoder for your language, if you search Github.

View solution in original post

3 REPLIES 3
Highlighted
Level 10 - Community Moderator

Re: Unperseable JSON value for the Bulk Export of activity - Unsubscribe Email/Fill Out Form

That's a valid JSON string (so I wouldn't refer to this as "unparseable JSON", it never claims to be JSON-in-JSON).

Internally it's in PHP object serialization format. There is likely a decoder for your language, if you search Github.

View solution in original post

Highlighted

Re: Unperseable JSON value for the Bulk Export of activity - Unsubscribe Email/Fill Out Form

Thanks for the quick response.

your answer will solve my query.

Highlighted
Level 10 - Community Moderator

Re: Unperseable JSON value for the Bulk Export of activity - Unsubscribe Email/Fill Out Form

Cool, could you mark my answer above as Correct?