When the blood vessel is injured, so is the endothelium, so it releases the endothelium tissue factor (TF), which complexes with factor VII, activating it, which then activates factor X and IX and the rest of the cascade continues.
Collagen is also exposed to a molecular, called high molecular weight kininogen (HMWK), prekallikrein and Hageman factor (factor XII), forming a complex. Prekallikrein is converted to Kallikrein and factor XII is activated to produced factor XIIa, which then activates factor XI and then factor X (the common factor between those two pathways), and the rest of the cascade continues, till the formation of the blood clot.