12 V input on 3.3 V GPIO, TVS pulled down or Schottky pull up?
This is actually an age old problem with PLCs and not nearly as simple as your
intended solutions.
The biggest issue you have is that as well has having a wide variety of potential logic voltages you need to be able to handle, the actual logic levels can be far higher than the 3.3V rail you are using internally. Some sensors and devices have logic thresholds up above 5V. As such simply using a cut-off circuit as you have indicated will not detect the low level from such sensors.
The input stage of PLCs needs to be much more flexible.
Even if the low level logic level is acceptable these circuits each suffer from different issues.
Zener / TVS Limiting.

This circuit has the benefit that, for a known input voltage, the zener can be sized to never allow the voltage to exceed the rail voltage. Normally you would chose a zener with a smaller reverse voltage than the rail, but higher than the high level logic threshold.
However, the zener will spend a lot of it's life reverse biased, as such you pay a penalty in the form of reverse recovery time when the input signal drops which will delay your signal a smidge.
The other issue with the Zener, is the actual voltage it will limit at is dependent on the current through it. As such that voltage will depend on the signal voltage to some extent. You therefore need to design the resistor for the maximum input voltage, and recalculate for lower voltages to see if the zener is not limiting the voltage below your \$V_{IH}\$ level.
Over-Rail Limiting Diode

Using the diode up to the rail has the issue that the output voltage will still exceed Vcc all be it only by a little. However, that can still be detrimental to the input. Further, in this case the reverse recovery time means, for fast input edges, a high voltage will make it through very briefly.
So
Since both of these circuits include a high resistor at the input, both of them require whatever is driving the input to have a low output impedance. Of the two, the zener version provides better protection but at the cost of performance. Neither of them will work if \$V_{OL}\$ of the attached sensor &gt; 1.5V or so.
Alternatives

Opto-Coupling.
A common method used by PLCs is to use opto-couplers.



simulate this circuit &ndash; Schematic created using CircuitLab
This method gives you the added benefit of isolation and ground separation. The issue with it is you need some form of signal conditioning between the sensor and the input to ensure the LED is lit at the right threshold, and that the correct amount of current is fed through the LED. That conditioning could be the simple resistor shown above, or a complex circuit which includes a comparator of some sort.
The speed of the opto-coupler is also a limiting factor.
However, this method is commonly used because it gives you complete flexibility.
Analog Input Conditioning
Another method is to accept the signal in an analog form, compare it to a variable reference with hysteresis, and generate the logic level that way.



simulate this circuit
Obviously the components, including the comparator, need to be chosen to accommodate the maximum input voltages. The circuit shown is fairly simple, it can get much more complex with filters, regulators, ESD protection etc.
Combination
For isolation reasons, you could combine the above, and have the comparator power a constant current driver to the LED of an opto-coupler.
If I were developing a product, I would assemble all that on a small plug-in module that could be plugged into card edge sockets on a &quot;mother&quot; board, like they use for cards in PCs. That way you can easily replace them should one get fried. That method also lets you make other input types available, for example, a fibre-optic input.