My solution requires sending the intents with superuser (root) privilege and unfortunately, the Send Intent action in MacroDroid does not permit that. So I've used the Script action of MacroDroid as a workaround.
Sending a broadcast (it is universal, not Tasker specific) alone would not do anything here. Using the logcat, I noticed that the app starts the service named ForceDozeService and then issues the relevant broadcast.
Script (en.sh) to enable the ForceDoze:
#!/system/bin/sh
su -c 'am startservice com.suyashsrijan.forcedoze/.ForceDozeService'
su -c 'am broadcast -a com.suyashsrijan.forcedoze.ENABLE_FORCEDOZE -n com.suyashsrijan.forcedoze/.EnableForceDozeService'
Script (ds.sh) to disable the ForceDoze:
#!/system/bin/sh
su -c 'am stopservice com.suyashsrijan.forcedoze/.ForceDozeService'
su -c 'am broadcast -a com.suyashsrijan.forcedoze.DISABLE_FORCEDOZE -n com.suyashsrijan.forcedoze/.DisableForceDozeService'
Use the action Script in Macrodroid as:
sh FILE_PATH
// such as /sdcard/en.sh
That should work.