mirror of https://github.com/zulip/zulip.git
Count /api/*/external/* messages as "sent" in /realm_activity.
This makes it easier to see how many messages are being sent by webhook bots. This assumes a 1:1 relationship between hitting webhook endpoints and sending messages, which is probably valid enough in the near future. (imported from commit eb272cd38b9cabd54d317ce2dfdf12099d302fce)
This commit is contained in:
parent
cbdb7152de
commit
14ae79b311
|
@ -617,7 +617,7 @@ def get_user_activity_summary(records):
|
||||||
update('desktop', record)
|
update('desktop', record)
|
||||||
if client == 'website':
|
if client == 'website':
|
||||||
update('website', record)
|
update('website', record)
|
||||||
if 'send_message' in query:
|
if ('send_message' in query) or re.search('/api/.*/external/.*', query):
|
||||||
update('send', record)
|
update('send', record)
|
||||||
if query in ['/json/update_pointer', '/api/v1/update_pointer']:
|
if query in ['/json/update_pointer', '/api/v1/update_pointer']:
|
||||||
update('pointer', record)
|
update('pointer', record)
|
||||||
|
|
Loading…
Reference in New Issue