Here my code:
from sseclient import SSEClient
import json
messages = SSEClient('https://api.particle.io/v1/devices/events?access_token=[token get in settings in build section]')
for msg in messages:
if(msg.event == "yourEventName"):
print("New custom event arrived: " + msg.data)
eventContent = json.loads(msg.data)
print(eventContent["data"])
Then you have to process the data with the InfluxDB Python interface. If someone needs help, please contact me.