March 13 (UPI) -- A State Department official was barred on Friday from going to Brazil because of a proposed visit to jailed former Brazilian President Jair Bolsonaro, who is in prison for plotting a coup four years ago.

The official, Darren Beattie, was approved for a visa to attend a critical minerals summit next week but his visa was pulled because the meeting with Bolsonaro was determined to be outside his diplomatic authorization, Brazil's Supreme Court ruled on Thursday, Bloomberg and The Guardian reported.

After the ruling, current Brazilian President Luiz Inacio Lula da Silva ordered his government to revoke Beattie's visa entirely, at least partially because U.S. President Donald Trump denied Brazilian health minister Alexandre Padilha a visa and revoked visas held by his wife and daughter.

"That American guy who said he was coming here to visit Bolsonaro, he's been barred from visiting and I have forbidden him from to Brazil so long as they don't free up the visa of my health minister, which has been blocked," Lula said on Friday.

Bolsonaro is serving a 27-year prison sentence after he was convicted for plotting a coup after losing the 2022 election to Lula.