As you discovered, this pedal is just a momentary switch.
You need a midi "head" device to read the switch state and convert to midi; a way to plug that head unit into your computer; and then software to make use of the midi input.
Alternatively, you can look into devices which convert to joystick inputs. People who make cockpit simulators use real switches to interface with their sim software. If you go this route, you would use a simple joystick-to-midi driver and then again, software suitable for use with the inputs.
Note that you can get a 10$ gamepad and hack leads onto the circuit board and connect 1$ Radio Shack switches mounted on a board for a whole bank of foot pedals. You would use the joy-midi driver to route the signals to a DAW or Amp Simulator.
Usually, for music interface and recording integration, you want a DAW application (Digital Audio Workstation).
There are also wah-wah pedal style audio intrerfaces which have ports for expression pedals. These are usually for guitar, but there is no reason you can't use them as general audio interfaces, and the midi signals can be routed to ANY function, so the rocker pedal can be used for e.g. crossfade, volume, wah, toggle switch etc etc
Even with an appropriate device to get the button push to register on your PC, you cannot use Audacity for this. You can try the free "vsthost" and some VST effect proccessors (try "simuanalog" also free). The VSTHost is a host to load amp sims and can route midi and joystick input signals to any exposed function/button/dial on a VST application. It has a built-in recorder, and you can then edit the files with audacity.
Anything that generates voltage can be plugged into the microphone jack and generate a recordable signal so long as it doesn't set the computer on fire and even then...
So: to recap. You need to hack your two wires (1/4-1/8 inch cable stripped and soldered to a joypad) or otherwise get the signal onto the computer in joystick or midi form. Then you can translate that signal to anything that handles it. Joy2midi, Midi translator, midi2joy.