Hamas said it has agreed to a deal proposed by Qatar and Egypt to pause the militant group’s war with Israel in Gaza, fueling optimism that a long-awaited breakthrough in negotiations could be close.

The proposal would see Hamas release half of the hostages it still holds from the October 2023 attack on Israel that triggered the conflict, one diplomat briefed on the negotiations said, in return for the freeing of Palestinian prisoners and a partial withdrawal of Israeli troops.

The deal — which would pave the way to a more comprehensive agreement — is almost in line with one put forward by U.S. Special Envoy Steve Witkoff in May, the diplomat said, without being more specific. It’s not clear whether Israel has received the proposal from Qatar and Egypt, the key mediators, nor whether Prime Minister Benjamin Netanyahu’s government will agree to the terms or to a phased deal.