The parenthetical statement linked to this denial is God is our witness.
While flattery is easy to observe, motives are not. It is therefore appropriate that Paul should appeal to God as his witness with regard to his real motives during the initial visit to Thessalonica.
5 For we never came with words of flattery, as you know, nor with a pretext for greed God is witness.