SOLVED

Re: Unsubscribe Filter

Go to solution
Carlis
Level 1

Unsubscribe Filter

The endpoint I'm using is /bulk/v1/leads/export/create.json.  Below is my json for the POST body.  Everything in it is working except the Unsubscribed filter.  What do I have wrong in the json.  The resulting csv file is returning TRUE and FALSE in the Unsubscribed column.

{
"fields":["email", "unsubscribed"],
"format":"CSV",
"columnHeaderNames":{"email":"Email Address", "unsubscribed":"Unsubscribed Status"},
"filter":{
"createdAt":{"startAt":"2022-03-27T01:29:19-05:00", "endAt":"2022-04-27T01:29:19-05:00"},
"Unsubscribed":true}
}

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
SanfordWhiteman
Level 10 - Community Moderator

Re: Unsubscribe Filter

Bulk Export doesn’t like system Smart Lists (which is what this looks like from your screenshot). Create a custom SL. Note once you’re using a SL you don’t need to worry about having multiple filter criteria as those can go in the SL itself — it’s far more flexible.

View solution in original post

Darshil_Shah1
Level 10 - Community Advisor + Adobe Champion

Re: Unsubscribe Filter

Based on your earlier question, if I'm not wrong, @Carlis, you're pretty new to Marketo! Per Sandy's point I've made some notes below for you to help you get started with setting up the custom SL in Marketo for use in the bulk extract project - 

 

You can create custom SL in Marketing Activities section or Database section per this article on the product documentation, if you have multiple person partitions, ensure that you create the SL in the correct workspace.

 

You can define the SL filters by adding one or more filters for filtering people based on the selected conditions - in your case you'll probably need Unsubscribed is TRUE filter along with "Person was Created" b/w date ranges filters in the AND condition (there are other operators too apart from between e.g., in past, is, is not, etc. You may also search and drag in more filters as you want from the right pane as per your need to further filter down the people in the SL.

 

Below is a reference snapshot on how the SL can be set up:

 

Darshil_Shah1_0-1651115994799.png

 

You can directly use the SL name as the value for the smartListName parameter in the create bulk extract job endpoint's payload.

 

Hope you find this helpful. 🙂

 

View solution in original post

5 REPLIES 5
Darshil_Shah1
Level 10 - Community Advisor + Adobe Champion

Re: Unsubscribe Filter

Unfortunately, the filter attribute in the bulk export create job API endpoint does not accept the filter values based on the filed and its value (i.e., something like "Unsubscribed":true isn't supported in the payload)

Below are the accepted filter parameters that you can filter on:

1. createdAt

2. updatedAt

3. staticListName

4. staticListId

5. smartListName

6. smartListId

One way to extract only unsubscribed records is to use the smart list in Marketo with Unsubscribed = TRUE filter and use that as a filter in the payload for extracting the data programmatically via the bulk extract API.

Carlis
Level 1

Re: Unsubscribe Filter

I have an Unsubscribed Smart List.  I've tried smartListName = "Unsubscribed People" and smartListName = "Unsubscribed".  Neither work.  I don't know how to get the smartListId.

 

Carlis_0-1651088143888.png

 

Darshil_Shah1
Level 10 - Community Advisor + Adobe Champion

Re: Unsubscribe Filter

Well, Marketo's infrastructure supports only one filter type per export job (should've mentioned in the previous comment probably). You may be getting the results based on the first filter type i.e., createdAt filter. You can filter people based on the createdAt filter if that's more important for your use-case, and then strip-out the rows with Unsubscribed Status = false from the response.

SanfordWhiteman
Level 10 - Community Moderator

Re: Unsubscribe Filter

Bulk Export doesn’t like system Smart Lists (which is what this looks like from your screenshot). Create a custom SL. Note once you’re using a SL you don’t need to worry about having multiple filter criteria as those can go in the SL itself — it’s far more flexible.

Darshil_Shah1
Level 10 - Community Advisor + Adobe Champion

Re: Unsubscribe Filter

Based on your earlier question, if I'm not wrong, @Carlis, you're pretty new to Marketo! Per Sandy's point I've made some notes below for you to help you get started with setting up the custom SL in Marketo for use in the bulk extract project - 

 

You can create custom SL in Marketing Activities section or Database section per this article on the product documentation, if you have multiple person partitions, ensure that you create the SL in the correct workspace.

 

You can define the SL filters by adding one or more filters for filtering people based on the selected conditions - in your case you'll probably need Unsubscribed is TRUE filter along with "Person was Created" b/w date ranges filters in the AND condition (there are other operators too apart from between e.g., in past, is, is not, etc. You may also search and drag in more filters as you want from the right pane as per your need to further filter down the people in the SL.

 

Below is a reference snapshot on how the SL can be set up:

 

Darshil_Shah1_0-1651115994799.png

 

You can directly use the SL name as the value for the smartListName parameter in the create bulk extract job endpoint's payload.

 

Hope you find this helpful. 🙂