Assuming you're running companion 2.4.x, If you go to the settings page, on the right hand side under "remote control" select the "OSC" tab,
and it'll provide you with an OSC reference for companion. (it allows for momentary press, press and hold, release (when held), etc).
Alternatively, in the button configuration screen, if you select a button as if you're going to configure it, it will give you the hint
required to fire that specific button, e.g.:
Hint: Control buttons with OSC or HTTP: /press/bank/1/22 to press this button remotely. OSC port 12321!
-John