Skip to content

[Question]: API Difference b/w /api/events and /api/events/summary #11343

Closed Answered by eridon-pro
eridon-pro asked this question in Question
Discussion options

You must be logged in to vote

Just decided to use just events API for last one hour instead of summary of the day as below. Somehow, it seems the output is accurate when it runs every 1 hour.

http://localhost:5000/api/events?cameras=$CAM&after=$(date +%s -d '1 hour ago')&before=$(date +%s)" | jq -c --arg now "$(date +'%Y/%m/%d %H:%M:%S')" '[{"Date/Time": $now}] + (group_by(.label) | map({label: .[0].label, count: length}))'

Replies: 3 comments 3 replies

Comment options

You must be logged in to vote
3 replies
@NickM-27
Comment options

NickM-27 May 12, 2024
Collaborator Sponsor

@eridon-pro
Comment options

@NickM-27
Comment options

NickM-27 May 13, 2024
Collaborator Sponsor

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by eridon-pro
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
2 participants