fps and res can obviously be altered during conversion.
I'll presume windows platform?
With such a diverse amount of formats and codecs, There is no one tool that can do a complete job of this.
However, the best tool I've come across for format conversion is "SUPER". It's got an ugly (imo) gui, but it's quite straight forward. Obviously this doesnt matter if it is to be automated, and I dnt know if SUPER supports command line operation.
Next tool, which definately does have command line operation, is ffmpeg. There are various builds out there which support various extra codecs etc. The good thing is the source is available, so if you have the skills, you can add in support for just about anything.
Anyways, moving on, first of all you need to detect the file type. Easy way to do this is the file extension, but obviously it wont always be right ( lots of people have avis labelled as movs, vice versa). So then you really want to code a script in your language of choice, to read the first chunk of the file and work out what the file is.
if its WMV, you have a few issues, the main one being DRM. The second being tools to convert the WMV into X. There arent many, and most only support earlier video codecs. SUPER uses direct show to get round this.
AVI, i'd be using avisynth probably.
MPEG, ffmpeg deals with mpeg1-4 pretty well. Not sure about advance x264 profiles?
MKV - SUPER will do it, dont think ffmpeg supports them.
Ogg audio - depending on the container format, you may have issues with ogg audio decoding.
Years ago I wrote some PHP to read the header of a variety of video formats, took about a days worth of research, but it could decode WMV, AVI and MPEG headers

not got the code anymore though.