The Mexican-American War

Does Mexico deserve any of the blame for the Mexican-American War? Did the Mexican government feel it had any other choice but to pursue war?