I don't believe you can use Vimeo's advanced API with only JavaScript. To do that, you need to authenticate with OAuth using a server-side language:
http://vimeo.com/api/docs/getting-started
Vimeo's JavaScript API allows you to do things like load a single video, or get information about a videos in JSON/XML. This doesn't include video.search unfortunately.
http://vimeo.com/api/docs/player-js
If you still want to use the JavaScript API, you need to turn the API on in the actual video by adding api=1. With an iframe, add it as a query string: http://player.vimeo.com/video/VIDEO_ID?api=1 or if using Flash, add it as a separate param tag <param name="flashvars" value="api=1" />.
Then just use document.getElementById() to start using the API. Method calls on their universal embed (iframe) gets a little tricky, because they only allow messages sent as a serialized JSON objects. I recommend using their Froogaloop javascript framework which handles most of this for you.
https://github.com/vimeo/player-api/tree/master/javascript
Vimeo also has a working example online.