Quantcast
Channel: Topliners: Message List
Viewing all articles
Browse latest Browse all 3431

Bulk API 2.0 Returning 400 Error {"failures":[{"field":"fields","value":"ActivityID"}]}

$
0
0

I've read through the documentation and can't find out why I keep getting this error. My Python code is below, and the error I keep getting is: {"failures":[{"field":"fields","value":"ActivityID"}]}

 

If anyone has any suggestions, I would greatly appreciate it!

 

 

CODE:

 

import requests

 

auth_string = 'MyCompany\MyUserName:MyPassword'

auth = auth_string.encode('base64','strict')

 

url='https://secure.p03.eloqua.com/api/bulk/2.0/activities/exports'

 

data= {

"name":"Activity Export Test",

"fields":{

  "ActivityID":"{{Activity.Id}}"

  },

"filter":"'{{Activity.Type}}'='EmailOpen'"

}

 

headers = {'Authorization': "Basic %s" % auth}

r = requests.post(url, data=data, headers=headers)

 

print r.status_code

print r.text


Viewing all articles
Browse latest Browse all 3431

Trending Articles