For Linux users:
place a script with the following content in the folder with the files you’d like to convert:
find -name "*.docx" -type f -exec sh -c '
for f; do
pandoc -f docx -t markdown -o "${f%.*}.md" "$f"
done
' find-sh {} +
Then execute the script via terminal like this: ./name-of-script
If you want to remove the original file, add the following line
rm "$f"
before the “done” command