Regarding your code question: no, you cannot hardwire the transformer.
I believe this falls under NEC 400.7:
400.7 Uses Permitted.
(A) Uses. Flexible cords and cables shall be used only for the following:
- Pendants
- Wiring of luminaires
- Connection of portable luminaires, portable and mobile signs, or appliances
- Elevator cables
- Wiring of cranes and hoists
- Connection of utilization equipment to facilitate frequent interchange
- Prevention of the transmission of noise or vibration
- Appliances where the fastening means and mechanical connections are specifically designed to permit ready removal for maintenance and repair, and the appliance is intended or identified for flexible cord connection
- Connection of moving parts
- Where specifically permitted elsewhere in this Code
At a stretch, if you could permanently attach the transformer, you could maybe consider this to be under 400.7(A)(8), but then you're still required to have a removable plug:
(B) Attachment Plugs. Where used as permitted in
400.7(A)(3), (A)(6), and (A)(8), each flexible cord shall
be equipped with an attachment plug and shall be energized from a receptacle outlet or cord connector body.
Additionally, I think this could be interpreted as violating 400.8:
400.8 Uses Not Permitted. Unless specifically permitted in 400.7, flexible cords and cables shall not be used for the following:
- As a substitute for the fixed wiring of a structure
- Where run through holes in walls, structural ceilings,
suspended ceilings, dropped ceilings, or floors
- Where run through doorways, windows, or similar
openings
- Where attached to building surfaces Exception to (4): Flexible cord and cable shall be permitted to be attached to building surfaces in accordance with the provisions of 368.56(B)
- Where concealed by walls, floors, or ceilings or located above suspended or dropped ceilings
- Where installed in raceways, except as otherwise permitted in this Code
- Where subject to physical damage
So I'd say, no, you cannot just hardwire the transformer in any way.
Additionally, you need to ensure the transformer (and all connections) are accessible for servicing. Transformers also get hot and need cooling - failure to have adequate cooling could cause the transformer to prematurely malfunction and/or lead to all the other problems of hot things in contact with flammable materials like your walls.
I'd find some area (such as under the stairs) that is accessible and unfinished, and run a new receptacle there. Then you can plug in the transformer, run the low voltage wires back to the LED strips, and you're good to go.
It's quite common to remotely mount transformers -- eg, it's very common for low-voltage under-cabinet lighting in kitchens that the transformer is located in the basement near the electrical panel or other unfinished (serviceable) area.
Your design is dangerous because you don't have safe light fixtures. Outdoor light fixtures, especially at 220V, need to safely insulate all electrical conductors. In an environment full of moisture and active, moving animals, you need fixtures that are secure and sealed. If you can't buy these, maybe you can make some, but don't expect regular indoor fixtures to be safe.
Let's think about how this system gets dangerous. Some of the wiring gets exposed, and a person or animal gets between the hot and neutral legs, completing the circuit. This could happen with two adjacent puddles of water, maybe one touching a hot and the other a neutral. Or a puddle and a rake that's pierced some of your above-ground cabling.
Your "ground" wire doesn't help. Bonding neutral to ground is good because it means that a loose hot wire that touches some exposed metal (or other good conductor bonded to ground) will blow the fuse quickly. You're not in an environment with lots of good conductors; even wet dirt may not conduct well enough to blow the fuse. If you had for example a metal walkway and a nearby metal pipe, you should definitely bond those so they can't be separately energized. But if you're just talking about an electrical system out in a field, bonding the field to neutral doesn't buy you much.
An RCD (residual current device) or GFI (ground fault interruptor) may not help much either, because again you're not likely to leak current to ground. However, these might be a little more sensitive than your fuse so they could help a bit.
The safe approach here is to use proper light fixtures designed for outdoor use in wet areas. These can be low-voltage or high. Low voltage is safer, because even if the fixtures or wiring fails the available energy is not enough to kill you. But a 220V setup that includes sufficient protection for your junctions and the light bulbs would also be relatively safe.
If you stick with your design, at least realize that your ground does not make it any safer. Protect your fixtures and junctions from moisture and from access by people and livestock.
Best Answer
It's not approved for use in AC wiring
See the backslanted RU? That means the power supply is only RU-Recognized as a component of some future product that will then be UL-Listed.
You are not allowed to install RU-Recognized things in house wiring. You can only install UL-Listed things.
An RU-Recognized thing can be converted to a UL-Listed thing by packaging it in an enclosure that conforms to the UL White Book and sending it off to UL for approval along with labeling and instructions. One challenge you would need to resolve is how to put the mains wires inside the box and the low-voltage wires outside the box. Note most UL-listed 24V thermostat transformers do exactly that, mounting in a knockout or as a junction box lid, and providing terminals on the correct side.
As you grind through the UL Listing process, UL will notice that your active component is RU-Recognized, and they will not tear it down and do their usual testing suite, since they already have. That is the value/purpose of RU.
Typically this module would be part of a luminaire (light fixture) and the luminaire would be UL Listed in the usual way.
Other than that, you can go to the final arbiter of approval: your local electrical inspector, and ask them if they will approve some sort of mounting method.