At 400 FPS, these 177 caliber steel BBs can easily take out an eyeball. It can easily penetrate basic clothing, and be lodged deep enough to cause some problems. It can easily deter someone from coming toward you. Just hope they don't have something more powerful. If nothing else, it will inflict severe pain, which is quite often more than enough to end a bad situation.
Dannyboy, please consider the following. I have about 45 years of experience with various airguns and firearms, including many pistols in the performance envelope you describe and terminal performance against a wide variety of targets. Though .177 or even .22 caliber pellets (each heavier and carrying more energy than .177 BBs) at a nominal 400 fps can "take an eye out", penetrate some clothing, etc..., the deterrence factor against a human being is simply not significant. If your target interloper is inclined to leave before you shoot them, they well may leave when you do -- or shooting them may commit them to a different course of action like STOPPING YOU. If they are not already inclined to leave, your escalation is quite likely to be met with an attack. "Severe pain" is NOT to be confused with significant injury that can stop an attack -- and the latter inflicted with an air pistol such as you describe is incredibly improbable to the point of being practically impossible. The effects produced by such an air pistol are NOT likely to end a truly bad situation, let alone be "more than enough".
What you choose to do is, of course, your business, but my recommendation would never include employing an air pistol against another person unless it was airsoft or paintball in a force-on-force exercise/game. Best of luck.