Skip to main content
Level 2
October 26, 2022
Solved

Bulk API-Activities: Not filtering ActivityTypeids

all,

 

I am trying to pull the activities data using bulk api, as a parameter I am supplying few activityTypeIds and expecting API should bring only those id's but what I am seeing it's bringing everything!   not sure what  I am doing wrong.   here the api request.   does anyone faced this issue?    how to solve this.  note : i do not want to use normal api call, must use bulk api.

headers = {'Authorization': 'Bearer ' + token}
params = {
"activityTypeId": [1,2,3,6,7,8,9,10,11,12],
"format": "CSV",
"filter": {
"createdAt": {
"startAt": startAt, # "2022-10-02T23:59:59-00:00",
"endAt": endAt # "2022-10-03T23:59:59-00:00"
}
}
}
resp = requests.post(host + '/bulk/v1/activities/export/create.json', headers=headers, json=params)

  

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
SanfordWhiteman
SanfordWhitemanAccepted solution
Level 10
October 27, 2022

Well, it’s only spelled one way: activityTypeIds. and it goes inside the "filter" property, not outside, as shown in the docs.

 

In general you shouldn’t supply code in any particular language, what matters is the JSON payload.

4 replies

SanfordWhiteman
Level 10
October 26, 2022
as a parameter I am supplying few activityTypeIds

I would argue that you’re supplying a few activityTypeId. And that’s the problem. 🙂

Translate
kajal_dasAuthor
Level 2
October 26, 2022

i did passed with activityTypeIds also.  

Translate
SanfordWhiteman
SanfordWhitemanAccepted solution
Level 10
October 27, 2022

Well, it’s only spelled one way: activityTypeIds. and it goes inside the "filter" property, not outside, as shown in the docs.

 

In general you shouldn’t supply code in any particular language, what matters is the JSON payload.

Translate