The xf40's I have are these:
one 3T and one 4T. Usually specified as a 4503 and a 4504, like in the grin simulator.
I don't know if your xf40 is the same thing, since the second set of numbers is much smaller, and afaik that number is teh width of the magnets / stator, so mine would be a 45mm width, and yours would only be two-thirds of that, which means it has only two thirds of teh torque, etc.
Mine can handle 3kw in a 20" wheel fine, but in a bigger wheel you'd derate that to 2kw.
Yours would probably be 2kw in a 20" wheel, or 1000-1500w in a bigger wheel (depending on the wheel size).
Peak power can be much higher for a few seconds at a time, of course, but continuous power has to stay below the overheating points.
If your motor version is listed in the http://ebikes.ca/simulator, you can figure out what the max power you can put thru it is under your specific conditions with your specific system.
FWIW, this is the 4503 on the right and an old 9c 28mm (similar to your 30mm) motor on the left, to compare thickness: