This is very possible. It really depends on the functionality of the equipment.
I’ve done this on a VegaStream 8 port FXO calling another 8 port FXO Vega.
so: PSTN—FXOCalifornia—via H.323/SIP/MGCP/whatever—FXONew York—PSTN
The Vega in California would receive a call on its POTS ports (vega contains dialing rules) and sends the call to the FXO in New York via VoIP, then the Vega in New York will have a pre-configured number to send the call to.
very basic and easy to setup.