Text messages between a Portland police bureau (PPB) officer and far-right leader Joey Gibson appear to show a warm and cooperative relationship and even exchanges of legal and tactical information.

First reported by Willamette Week, which obtained them with a public records request, the texts show months of exchanges between Gibson, the leader of the Patriot Prayer group, which has staged sometimes violent rallies in the city for almost two years, and Lt Jeff Niiya, head of the PPB rapid response team, which patrols political rallies.

Niiya offered congratulations on Gibson’s plans run for Senate, expressed concern for the safety of his family, and wrote: “I want you to know you can trust me. Don’t want to burn that.”

Other messages appear to show the officer offering advice about police tactics.

On 23 December 2017, Niiya texted to Gibson: “Heads up just told 4-5 black Bloch [antifascists] heading your way. One carrying a flag. We will have officers nearby but you may want to think about moving soon if more come.”

Niiya also appears to advise Gibson about avoiding the arrest of group member Tusitala “Tiny” Toese, who has allegedly been involved in acts of violence in the city.

On 8 December 2017, discussing Toese’s presence at a rally at a time when he was the subject of an outstanding warrant, Niiya wrote: “Just make sure he doesn’t do anything which may draw our attention. If he still has the warrant in the system (I don’t run you guys so I don’t personally know) the officers could arrest him. I don’t see a need to arrest on the warrant unless there is a reason.”

Members of Portland city government reacted sharply. Newly elected commissioner Jo Ann Hardesty – the first African American woman elected to the council – said the news “simply confirms what many in the community have already known – there are members of the Portland police force who work in collusion with rightwing extremists”.

Mayor Ted Wheeler, also the PPB commissioner, called the messages “disturbing” and said: “Incidents like this contribute to the distrust that so many community members have about the Portland police bureau.”

Hardesty called for an independent investigation; Wheeler said he had directed the PPB chief Danielle Outlaw to investigate. PPB announced an internal investigation and released the texts and related emails.

Last week, the Portland city council passed a resolution denouncing the city’s racist history, white supremacy in general and “those who propagate hate and incite fear and violence in our community”. The motion was widely interpreted as referring to Patriot Prayer rallies. Gibson testified at the relevant meeting, reading from the Bible.

PPB has regularly been accused of bias in favour of Patriot Prayer, and against leftwing counterprotesters.

On 4 August 2018, PPB officers fired “less than lethal” rounds into a crowd of counterprotesters, injuring several, including a woman who said she was peacefully protesting and who has commenced legal action. No such police action was taken against 500 protesters on the rightwing side of the event.

Patriot Prayer members have been involved in alleged acts of violence outside rallies, with apparent impunity.

Community groups who helped the city council draft its resolution on white supremacy expressed disappointment with the Gibson texts.

Eric Ward, the director of the anti-racist Western States Center, said: “This continued cycle of collusion with the ‘alt-right’ places the PPB directly at odds with the rule of law and values and priorities expressed by elected Portland city leadership.”

Other leftwing groups were similarly scathing. Olivia Katbi-Smith, the co-chair of Portland Democratic Socialists of America, said: “There is a reason for the saying ‘cops and Klan go hand in hand’. American police forces were founded to protect white supremacy and the ruling capitalist class that enforces it.”

PPB did not immediately respond to questions about the texts, other incidents and potential bias.