Python Fire base API not fetching all data with the GET and listen function

Viewed 34

enter image description here

I am using Zapier to retrieve data and upload it to Firebase (Real-time storage). the data is formatted: path/... {'Key':{'data_field_1': 'data', 'data_field_2': 'data'}. I am using a python script to retrieve the data from the database but it is behaving a bit weird. When I manually input the data from the firebase real-time database GUI in the web browser, it returns: {'Key':{'data_field_1': 'data', 'data_field_2': 'data'} (via PUT method). But when I send the data using zapier, it only returns {'data_field_1': 'data', 'data_field_2': 'data'} (via PATCH method) and does not include the 'Key'. For reference, here is a snippet of my code:

def listener(event):
    print(event.data) # prints the data

firebase_admin.db.reference("path/").listen(listener)
0 Answers
Related