Israel had threatened to close the British Consulate in East Jerusalem, a center of outreach to Palestinians for decades. A last-minute agreement means a smaller diplomatic service will remain.