what they say: https://www.dinafem.org/en/blog/best-time-harvest-cannabis/
Therefore, to decide on the optimal time to harvest, you'll need to confirm that...
The resin production has peaked
The flowers have stopped growing
The secondary leaves have begun to lose colour, and most of the main leaves have fallen
Observing the trichomes with a magnifying glass, most of them are milky white, and some are amber