Configuration for gpio garage door

Is there a best way to setup a card for a garage door controlled by the pi gpio pins
Something like this:

        "accessory": "RaspPiGPIOGarageDoor",
        "name": "Garage Door",
        "doorSwitchPin": 23,
        "doorSensorPin": 24,