make a batch file that accepts pipe input

Shell
@echo off
setlocal

set /p "piped="

echo piped: %piped%

Source

Also in Shell: