koala It has a header with GZIP00 in it, but it does not seem to be a .gz archive?
From memory, TVH uses an internal compression library when saving the EPG database. You can bypass this by browsing to the TVH server and navigating to 'Configuration -> General -> Base'. Look for 'EPG Settings' and then disable 'Compress EPG database'. Next time the EPG database is saved, it will be in an uncompressed format.
koala Alternatively, what format is epgdb.v2 in?
Don't quote me, but the internal database structure is just a stream of HTSP messages, one for each EPG record. There is a Python2 script somewhere on the system that can dump this data to the console.
tvheadend/tvheadendblob/master/support/epgdump
koala I've been playing with /api/epg/events/grid?limit=9999999999999999999999
There are also a number of filtering parameters that may be helpful.
https://docs.tvheadend.org/documentation/development/json-api/api-description/epg
Also, what version of TVH are you using? The latest uses epgdb.v3.