Esp8266 gate opener

I am wondering if it is possible to program a nodemcu/wemos d1 mini pro board along with a relay board like this so that it triggers an open/close of my gate.
I think it should work ok as long as the relay can be set up as a momentary switch which I can connect to the Open connector on my gate’s board:


And then set it up in esphome something like this: Simple Garage Door — ESPHome

Has anyone here done something similar?

I’ve used RasPi with relay board to control gate

Gates just looking for closure of contact for open/ close/hold inputs

What your trying is great use. Only issue is ensuring WiFi signal to location. Mine was >200’ so I use ubuiquiti PtoP AP pair and add switch at remote location. Camera and RasPi used Ethernet for connection

Yes I use an ESP32 with a relay with esphome. This is the code I use for the switch.

switch:
  - platform: gpio
    pin: 15
    id: relay
  - platform: template
    name: "Gate Remote"
    icon: "mdi:gate"
    turn_on_action:
    - switch.turn_on: relay
    - delay: 500ms
    - switch.turn_off: relay

I added an INA219 to monitor the bell. I have an automation that can open the gate by pressing the bell for example when I am expecting someone.

Thanks for confirming, I suspected it should be as simple as that.
I need it to control two gates, hence the double relay and the gates also have one of those wired magnetic alarm sensors, to detect if open/closed so it should be straightforward enough to wire I believe.

Yes I currently have a gogogate2 system that controls the gates but having horrible connection issues with it.
I suspect something is wrong with the HA integration however because the gogogate2 app works ok and I even tried LAN cable and still many disconnects, HA only.
I plan to use a w1 mini pro with the external antenna for better signal - I think my issue is wifi pollution from neighbors

I used integrations and MQTT and found it less than 100%

I had RasPi with HA so i change to HA rest API and no issues after. I now change out for Zwave relay to reduce device support need