How to mute and unmute your microphone from command-line on Windows operating system

SoundVolumeView is a freeware tool for Windows which allows you to easily mute and unmute any sound device from command-line and GUI.
In order to mute or unmute your microphone, you have to run SoundVolumeView, and find the microphone that you want to mute/unmute:

Let's say that you want to mute the 'Microphone' device in the above screenshot, so the command to mute the 'Microphone' device is:
SoundVolumeView.exe /Mute "Microphone"

However, if there are multiple items with the same name, you have to use the string appeared under the 'Item ID' column or 'Command-Line Friendly ID' column in order to uniquely identify the correct Microphone device.
In the example of the above screenshot, you can use the '3- USB Audio Device\Device\Microphone\Capture' string to identify the device, for example:
SoundVolumeView.exe /Mute "3- USB Audio Device\Device\Microphone\Capture"

if you want to unmute the device, simply use the /Unmute command:
SoundVolumeView.exe /Unmute "3- USB Audio Device\Device\Microphone\Capture"

You can switch between mute and unmute state by using the /Switch command, for example:
SoundVolumeView.exe /Switch "3- USB Audio Device\Device\Microphone\Capture"

If the Microphone you want to mute or unmute is the default capture device ('Capture' appears under the 'Default' column), you can simply specify "DefaultCaptureDevice" instead of the device name/ID, for example:
SoundVolumeView.exe /Mute "DefaultCaptureDevice"

Be aware that SoundVolumeView works on any version of Windows, starting from Windows Vista and up to Windows 10. Windows XP is not supported.