Get tile count from exported json file

You can probably use the tilecount property on the Tileset object. It stores the total number of tiles in the tileset.

Just note that in case of “image collection” tilesets, this does not indicate the largest local tile ID, since when tiles are removed from a tileset their IDs are not reused, creating gaps in the sequence of tile IDs.