It shall be lawful for, and the right is hereby conferred upon, cities of the second class of this Commonwealth, their assigns, lessees, and licensees, to connect the tracks of railways, acquired, constructed, owned, or operated under the rights conferred by this act, with the tracks of any railroad or railway company, upon such terms and conditions as may be agreed upon; and to contract with such company for the use of its tracks or for the interchange of cars, whether passenger or freight, for continuous movement over any such connecting tracks, upon such terms and conditions as may be agreed upon between the mayor and council of such cities and the said company and as may be authorized by ordinance of such cities. Such cities, their assigns, lessees, and licensees, may use such portions of the tracks of any street passenger railway company, surface, elevated, or underground, or motor-power company, as may be required either to complete a circuit upon any railway constructed, owned, or operated under the rights conferred by this act; or to connect any such railway with another railway, upon such terms and conditions as may be agreed upon between the mayor and council of such cities and the said company, and as may be authorized by ordinance of such cities. Provided compensation for such use shall have been paid or secured.
53 P.S. § 25484