HOUSTON — Democratic presidential candidates Julián Castro and Bernie Sanders pitched their candidacies Saturday to one of the largest Muslim gatherings in the country, earning recognition as the only White House hopefuls to show up and address a voting bloc deeply alienated by President Donald Trump.

Addressing the annual convention of the Islamic Society of North America, Castro and Sanders pledged to overturn Trump's travel ban, which targets several Muslim-majority countries, and vowed to create a vastly more welcoming environment for Muslims in the United States.

"It begins at home by saying that you are full partners in American progress," Castro told thousands of attendees inside the George R. Brown Convention Center. "The fact is, as I know, that Muslim Americans for generations have been part of the fabric of our American family. They have helped make America the great nation it is, and we need to fully embrace it. Too often in our country's history, the message to the Muslim American community has been that somehow you're the enemy or you're the problem, and I completely disagree with that."

Organizers said they invited all presidential candidates, Democrats and Republicans, and only Castro and Sanders came. While Muslim leaders praised their attendance, they also did not mince words about the rest of the field.

"It’s important that the presidential candidates engage American Muslims directly on the issues that matter most to us," Kalia Abiade of the Pillars Fund, a pro-Muslim philanthropy group, said in a statement ahead of the convention. "While it’s good to see that two of them are planning to attend ... we need the others to step up if they want our communities’ consideration."

Asked afterward about the light attendance by the 2020 field, Castro would only discuss why he was there, telling reporters he wants to be a president for all Americans and that Muslim Americans are too often "other-ized." Castro commended Sanders, who was standing nearby, "for being here and I know that he has a track record of speaking out on many of the issues that we addressed today."

Sanders, the independent U.S. senator, got a particularly enthusiastic response inside the convention hall as he gave a speech that hit on his usual campaign themes while zeroing in on issues specifically affecting the Muslim world, including in foreign policy. He was introduced by his campaign manager, Faiz Shakir, who is Muslim.

"We must speak out when we have a president and an administration who believe — and I quote — that 'Islam hates us,'" Sanders said, referring to a comment Trump made while campaigning for president in 2016. "We must speak out at hate crimes and violence targeted at the Muslim community and call it what it is: domestic terrorism."

At the same time, Sanders pointed to causes for optimism: the non-Muslims who joined in airport protests against the travel ban and the Muslim who have been elected to Congress under Trump. "What that tells me is that the American people understand our country is at our best when we stand together regardless of our religious or spiritual beliefs," Sanders said.

On foreign policy, Sanders touted his 2002 opposition to the the Iraq War, which, he noted, created instability in the region and gave rise to the Islamic State terrorist group whose victims are overwhelmingly Muslim. Sanders also broached a topic that has not gotten wide discussion in the 2020 field, criticizing India for recently revoking the autonomy of Kashmir, a disputed region with Pakistan.

"India's action is unacceptable," Sanders said. "The communications blockade must be lifted immediately, and the United States government must speak out boldly in support of international humanitarian law and in support of a U.N.-backed peaceful resolution that respects the will of the Kashmiri people."

Both Castro and Sanders made other stops in Houston prior to the ISNA convention. Castro appeared at a protest organized outside a migrant detention facility on the outskirts of downtown, railing against the Trump administration policy of separating migrant children from their parents at the border.

“We want to say, 'Ya basta,' with this policy, enough with the cruelty of the Trump administration," Castro said at the protest, which was organized by the Service Employees International Union, adding that Trump "has made migrants a scapegoat and a political piñata ever since he started his campaign four years ago."

Sanders, meanwhile, headlined a low-dollar campaign fundraiser at an Indian-Pakistani restaurant where he was introduced by Abdul El-Sayed, a former Michigan gubernatorial candidate. Sanders spoke about creating a movement bigger than any one election but also expressed confidence about his chances in Texas, saying he was asking for support "to help me win the Democratic primary here — and I think we can do it."

Democratic presidential candidates will descend on Houston again next month when 10 are set to participate in the third primary debate at Texas Southern University. Castro told reporters he was looking forward to the debate because Houston "represents the future of our country" — growing, young and diverse — and will "showcase the best of Texas."