Whenever there are minor/major injury to blood vessels, the platelets, fibrin, thrombin, etc. are recruited. They then seal the wound and block bleeding.
What tells them that their job is done?
Exposed collagen at the site of vessel damage simultaneously initiates plates aggregation and the clotting cascade. So, when the wound is sealed and no more collagen is exposed, which is the main factor to activate the cascade, the blood clothing cascade stops.