to run grass tools from the command line, I don't know how to do it through OSGEO4W shell but I figured out that we can do it through the grass shell inside the grass plugin.
just go to OPEN GRASS TOOLS -> Under Modules Tree -> GRASS Modules -> shell - Grass shell
inside this grass shell call your file e.g if your file is 'SampleCommand.sh' file then, you write in the command line "sh SampleCommand.sh". This command runs your '.sh' extension file which has the code for the GRASS tool to be run. In my case my 'SampleCommand.sh' file had the following code:
echo "Processing your IDWInterpolation$f"
v.surf.idw input=NewABDWellPoints@NewABD layer=1
column=Saturation npoints=4 power=2.0
This code "v.surf.idw input=NewABDWellPoints@NewABD layer=1 column=Saturation npoints=4 power=2.0 output=SampleIDWInterpol_duplicate_cmd01" can be obtained from your grass tools OUTPUT window. The OUTPUT window of grass tools show your exact command that it had called to run your tool.
This way you can generate outputs through GRASS Shell command line and when you have 1000(s) of files to process, you can loop through in your 'SampleCommand.sh' file and run it in a single command. You are done!!!