I tried backing up APIC running configuration using SolarWinds NCM with the custom device template I found here.
However, I noticed that the configuration file was incomplete and seems NCM stopped downloading the configuration when it detected # " on the config line.
Has anyone resolved this issue or had a workaround?
Many thanks! 
****DEVICE TEMPLATE***
<Configuration-Management Device="Cisco APIC" SystemOID="1.3.6.1.4.1.9.1.2238" AutoDetectType="BySystemOid" SystemDescriptionRegex="">
<Commands>
<Command Name="RESET" Value="terminal width 0${CRLF}terminal length 0" />
<Command Name="Reboot" Value="reload${CRLF}Yes" />
<Command Name="RebootAt" Value="reload at ${HH}:${NN}${CRLF}Yes" />
<Command Name="EnterConfigMode" Value="configure" />
<Command Name="ExitConfigMode" Value="end" />
<Command Name="Startup" Value="running-config" />
<Command Name="Running" Value="running-config" />
<Command Name="DownloadConfig" Value="show running-config all" />
<Command Name="UploadConfig" Value="${EnterConfigMode}${CRLF}${ConfigText}${CRLF}${ExitConfigMode}" />
<Command Name="DownloadConfigIndirect" Value="copy ${ConfigType} ${TransferProtocol}://${StorageAddress}/${StorageFilename}" />
<Command Name="UploadConfigIndirect" Value="copy ${TransferProtocol}://${StorageAddress}/${StorageFilename} ${ConfigType}" />
<Command Name="EraseConfig" Value="write erase${CRLF}Yes" />
<Command Name="SaveConfig" Value="write memory" />
<Command Name="Version" Value="show version" />
<Command Name="DownloadConfigIndirectSCP" Value="show running-config all" />
</Commands>
</Configuration-Management>