What size junction box do I need for a wall mount with a 3.5 inch base?
Generally, assume you want a 4" octagon box, which is 3.5" on the flats and 4" in the cornerish dimension. If it just fits inside a 4" square box, that's the one.  

They also make a 3.5" octagon box, which is 3" across the flats and 3.5" cornerish. That is generally too small, and this size is largely deprecated.   

You can get a plate to adapt 4" boxes to those looking for 3.5" boxes, but not the other way 'round.