Is there a command to convert all the fonts of a docx at once to a desired font using swriter?

Is there a command to convert all the fonts of a docx at once to a desired fonts using swriter?

Example:
If a docx document has Calibri, Abadi etc fonts in different places can we convert all to let’s say “Times New Roman” via command line using swriter

Select the entire text with Ctrl+A.
Keep all the text selected and double-click the Body Text paragraph style. If the desired font is not set, right-click the Body Text style, select the desired font in the Font tab, and click OK.
Save your document in ODT format to keep all settings.
For more detailed information, you should specify which operating system and LibreOffice version you are using.

I can only answer for GUI interaction because I don’t practice command line.

It depends on how the DOCX is formatted.

If you use Word paragraph styles, just change the paragraph styles configuration. This will work if you have no other formatting, e.g. you changed font on a single word, because Word has no notion of character style. Every thing overloaded on text is done with direct formatting which can’t be controlled centrally.

On a computer where your “offending” fonts are not installed, you can create a replacement table with Tools>Options, LibreOffice>Fonts, but this does not change the document itself. It only provides a substitution for this session.