JERUSALEM — Israel relented slightly on Friday after barring Representative Rashida Tlaib under pressure from President Trump, and said she could visit her 90-year-old grandmother, who lives in the occupied West Bank.

Israel acted after Ms. Tlaib, an outspoken Palestinian-American in her first term, agreed in writing not to promote boycotts against Israel during the trip. But Ms. Tlaib, facing criticism by Palestinians and other opponents of the Israeli occupation, quickly reversed course herself, saying she could not make the trip under “these oppressive conditions.”

“Silencing me & treating me like a criminal is not what she wants for me,” she said of her grandmother in a Twitter post. “It would kill a piece of me.”

The day’s switchbacks and recriminations appeared to lock in the political effects, in Israel and abroad, of Prime Minister Benjamin Netanyahu’s decision Thursday to bar the planned official visit by Ms. Tlaib, of Michigan, and another Democratic lawmaker, Representative Ilhan Omar of Minnesota, citing their support for the anti-Israel Boycott, Divestment and Sanctions movement.