The Mexican-American War started when:
1) Mexican forces attacked American troops north of the Rio Grande.
In April 1846, Mexican forces crossed the Rio Grande River and attacked a group of American soldiers in a disputed area between the Nueces River and the Rio Grande. This attack, known as the Thornton Affair, marked the beginning of the Mexican-American War. The United States claimed the border was the Rio Grande, while Mexico argued it was the Nueces River, leading to tensions and eventually the outbreak of war.
This event is considered the immediate cause of the Mexican-American War as it triggered a series of events that culminated in a full-scale conflict between the two nations.