Apparently there are quite a few of these modules which look "exactly alike". I suspect they would all have similar electrical properties, but you can run a simple test to see if they are safe to connect to a Pi directly. This is what the "Pi side" of circuitry of the module looks like:
5V ------///------|>|------|>|------- control pin
There are two forward biased diodes (the LED and the one in the optocoupler) and a resistor (1K in my case) in the path from the 5V supply to the pin for connection to the Pi. The diodes seem to cause a sufficient voltage drop to make the connection safe.
o Connect a 5V supply to the module.
o Measure the voltage between any one of the 8 control pins (for connection to the Pi outputs) to the ground. In my case this was 2.8V, indicating that a total of 2.2V remain as the junction potentials on the diodes. (LEDs and the optocoupler LEDs -probably a GaAs version- have larger junction voltages than ordinary diodes.) This 2.8V is the highest potential that this pin will see, unless current is forced into the module - even then, it will be limited by the voltage produced by Pi.
o Next, set your multimeter into the current measuring mode and measure the current from this pin to the ground. You will notice that the relay trips, and the LED will light up. This corresponds to the maximum current that the Pi pin will have to sink. In my case this is about 2ma. (There is a 1K resistor in the path - there is no way this current can be 20ma. Other interesting things would happen if a 20ma current were to flow through a LED so small.)
So, for my module, I saw no reason why not to connect it directly to the Pi pins directly. Obviously, now a "0" on the pin means "on" and a "1" (or tri-state) on the pin means "off".