How to trigger Google Analytics events from Python?

后端 未结 6 1291
礼貌的吻别
礼貌的吻别 2020-12-15 05:06

I\'m developing a site that has a REST API and I\'d like to track the API usage using Google Analytics events. Is there a straightforward way to trigger GA events from Pyth

6条回答
  •  难免孤独
    2020-12-15 05:22

    There is an open source implementation of Google-Analytics for Mobile in python available here: http://github.com/b1tr0t/Google-Analytics-for-Mobile--python-

    You can probably integrate this into your own setup by importing 'track_page_view' and providing it with the appropriate WSGI request environment.

提交回复
热议问题