An alliance begun in 2021 at four airports in the New York area and Boston allowed the airlines to sell tickets on each other’s flights and share revenue.