Can I use the ESP32 WROOM, for example?
Check the ESP32 WROOM (whichever version of that you have, there's multiple!) datasheet / board material. Comes with a schematic that shows you exactly how the on-board ESP32 SoC is connected to the contacts of the module.
It is important so I can know how to set up the I2C timing for example.
No, it's not. I²C is I²C; and while you mustn't be faster than the maximum standard-allowed transmission speed (100 kHz for standard, 400 kHz for fast) when toggling the SCL line, you cannot "set up" timing. That's not how I²C works! It's a bidiretional bus, where the slave device can "hold still" the bus for as long as it needs.
then program the ESP32 to synchronize as a slave,
Are you sure you mean "synchronize", and not just "to act as a slave on the I²C bus"?
There's no synchronization on I²C. A standard-compliant I²C master must respect if the slave holds the clock line low at the end of any bit.
People, including me, would recommend considering using an existing and tested IP core instead of implementing an I²C peripheral in an FPGA yourself; there's just too many ways you can miss a detail. It's a superficially easy, in practice a bit complicated to robustly implement protocol. You don't tell us anything about your FPGA, but chances are very high there's some at least rudimentary tested I²C peripheral for that FPGA – if in doubt, you'd use a FPGA system-on-chip-framework like LiteX to build something like I²C controller + small soft CPU to talk to that and control data flow + a bus interface to whatever you're doing on that FPGA.
and establish a TCP connection.
So, your primary job here really is writing firmware for the ESP32 and making it communicate with the FPGA over some bus.
Unless you need to connect a lot more peripherals, just use the UART or the SPI interface, not I²C: To communicate between exactly two devices, you don't need any of the features of I²C; not the addressing, not the bus arbitration, not flexible clocking, not the multi-mastering, …
Implementing an SPI interface is orders of magnitudes easier than implementing a I²C interface, and even if you use (which I'd strongly recommend) an existing I²C IP core for your FPGA, it's easier to implement SPI than to implement an interface into an I²C core.